Lecture 18: MGFs Continued

피망이·2023년 12월 18일
0
post-thumbnail

Expo MGF

  • XExpo(1)X \sim Expo(1), find MGF, moments

    cf. 물리학에서의 관성 모멘트와 분산이 관련이 있음

    • MGF: M(t)=E(etx)=0etxexdx=0ex(1t)dx=11tM(t) = E(e^{tx}) = \int_{0}^{∞} e^{tx} e^{-x} dx = \int_{0}^{∞} e^{-x(1-t)} dx = \displaystyle \frac{1}{1-t}, t<1t < 1

      • 0eax=1aeax0=1a\int_{0}^{∞} e^{-ax} = \displaystyle \frac{1}{-a} e^{-ax} \biggr|_{0}^{∞} = \frac{1}{a}
    • Derivative: M(0)=E(X)M'(0) = E(X), M(0)=E(X2)M''(0) = E(X^2), M(0)=E(X3)M'''(0) = E(X^3), ...

      • t<1|t| < 1, 11t=n=0tn\displaystyle \frac{1}{1-t} = \sum_{n=0}^{∞} t^n (taylor expansion)

      • n=0n!tnn!E(Xn)=n!\displaystyle \sum_{n=0}^{∞} n! \frac{t^n}{n!} \Rightarrow E(X^n) = n!

    • YExpo(λ)Y \sim Expo(\lambda), let X=λYExpo(1)X = \lambda Y \sim Expo(1),

      • so Yn=XnλnE(Y)=n!λnY^n = \displaystyle \frac{X^n}{\lambda^n} \Rightarrow E(Y) = \frac{n!}{\lambda^n}

Standard Normal MGF

  • Let ZN(0,1)Z \sim N(0, 1), find all its moments.

    • E(Zn)=0E(Z^n) = 0 for n odd by symmetry.

    • MGF: M(t)=et2/2=n=0(t2/2)nn!=n=0t2n2nn!=n=0t2n(2n!)(2n!)  2nn!M(t) = e^{t^2/2} = \displaystyle \sum_{n=0}^{∞} \frac{(t^2/2)^n}{n!} = \sum_{n=0}^{∞} \frac{t^{2n}}{2^n • n!} = \sum_{n=0}^{∞} \frac{t^{2n} (2n!)}{(2n!) \;2^n • n!}

    E(Z2n)=(2n!)2nn!\Rightarrow E(Z^{2n}) = \displaystyle \frac{(2n!)}{2^n • n!} {n=1E(Z2)=1=1n=2E(Z4)=3=13n=3E(Z6)=135=15\begin{cases} n=1 \Rightarrow {E(Z^2) = 1 = 1} \\ n=2 \Rightarrow {E(Z^4) = 3 = 1 • 3} \\ n=3 \Rightarrow {E(Z^6) = 1 • 3 • 5 = 15} \\ \end{cases}

Poission MGF

  • XPois(λ)X \sim Pois(\lambda)

    • E(etx)=k=0etkeλλk/k!=eλeλet=eλ(et1)E(e^{tx}) = \displaystyle \sum_{k=0}^{∞} e^{tk} e^{-\lambda} \lambda^{k}/k! = e^{-\lambda} e^{\lambda e^t} = e^{\lambda(e^t - 1)}
  • Let YPois(μ)Y \sim Pois(\mu) indep. of XX, Find distribution of X+YX+Y.

    • Multiply MGFs: MXMy=eλ(et1)eμ(et1)=e(λ+μ)(et1)M_X M_y = e^{\lambda (e^t-1)} e^{\mu(e^t-1)} = e^{(\lambda + \mu)(e^t-1)}

      X+YPois(λ+μ)\Rightarrow X+Y \sim Pois(\lambda + \mu)

    • Counterexample) if XX, YY dependent:

      • X=Y=X+Y=2XX=Y \Rightarrow = X+Y = 2X is not Pois. since even

      • E(2X)=2λE(2X) = 2\lambda, Var(2X)=4λVar(2X) = 4\lambda increasing! (is not Pois)

Joint Distribution (결합 분포)

  • XX, YY r.v.s

    • joint CDF

      F(x,y)=P(Xx,Yy)F(x, y) = P(X \le x, Y \le y)

    • joint PMF

      P(X=x,Y=y)P(X=x, Y=y)

    • marginal CDF

      P(Xx)P(X \le x) is marginal dist. of X.

    • joint PDF(continuous)

      f(x,y)f(x, y) such that P((x,y)B)=Bf(x,y)dxdyP((x, y) \in B) = \iint_{B} f(x, y) dxdy

    • independence

      XX, YY indep. if and only if F(x,y)=FX(x)FY(y)F(x, y) = F_X(x)F_Y(y)

      Equiv. to
      P(X=x,Y=y)=P(X=x)P(Y=y)P(X=x, Y=y) = P(X=x)P(Y=y) (discrete)
      f(x,y)=f(x)f(y)f(x, y) = f(x) f(y) all xx, yRy \in R

  • Getting marginal distribution (주변 분포)

    • P(X=x)=yP(X=x,Y=y)P(X=x) = \sum_{y} P(X=x, Y=y) discrete

      fY(y)=fX,Y(x,ydx)f_Y(y) = \int_{-∞}^{∞} f_{X, Y} (x, y dx)

  • Example

    • X, Y Bernulli
    Y=0Y=1
    X=026\displaystyle \frac{2}{6}16\displaystyle \frac{1}{6}36\displaystyle \frac{3}{6}
    X=126\displaystyle \frac{2}{6}16\displaystyle \frac{1}{6}36\displaystyle \frac{3}{6}
    ----------------
    46\displaystyle \frac{4}{6}26\displaystyle \frac{2}{6}
  • They are independent.

    • all of P(X=0)P(X=0) * all of P(Y=0)P(Y=0) =4636= \displaystyle \frac{4}{6} • \frac{3}{6}

      P(X=0,Y=0)=26\Rightarrow P(X=0, Y=0) = \displaystyle \frac{2}{6}

  • This one is dependent.

    • all of P(X=0)P(X=0) * all of P(Y=1)P(Y=1) =1214= \displaystyle \frac{1}{2} • \frac{1}{4}

      P(X=0,Y=1)=0\nRightarrow P(X=0, Y=1) = 0

Examples

  • Ex1. Uniform on square {(x,y):x,y[0,1]}\{(x, y): x, y \in [0, 1]\}

    • joint PDF const. on the square,

      {0,outsidec,0x1,0y10,otherwise\begin{cases} 0, {outside} \\ c, {0 \le x \le 1}, {0 \le y \le 1} \\ 0, {otherwise} \\ \end{cases}

    • Integral is area, c=1area=1c = \displaystyle \frac{1}{area} = 1

      • marginal: XX, YY are indep. Unif(0, 1)
  • Ex2. Uniform in disc, {x2+y21}\{x^2 + y^2 \le 1\} ← 제약 조건식으로 인해 독립이 아님!

    • joint PDF

      {1π,x2+y210,otherwise\begin{cases} \displaystyle \frac{1}{\pi}, {x^2 + y^2 \le 1} \\ 0, {otherwise} \\ \end{cases}

    • XX, YY Dependent

      • Given X=xX=x, 1x2y1x2- \sqrt{1-x^2} \le y \le \sqrt{1-x^2}

profile
물리학 전공자의 프로그래밍 도전기

0개의 댓글