pertemuan 3-4 - nilai harapanxxxx dan mgf

Upload: konokimochid

Post on 04-Jun-2018

224 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    1/30

    Prepared by : M. Dokhi, Ph.D.9:01

    1 of 45

    EXPECTED VALUE OF A FUNCTION &

    JOINT MGF

    EXPECTED VALUE OF A FUNCTION &

    JOINT MGF

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    2/30

    Prepared by : M. Dokhi, Ph.D.9:01

    2 of 45

    Sessions target

    Nilai harapan bersama (Joint expected value)

    Kovarian (Covariance)

    Korelasi (Correlation)

    Nilai Harapan Bersyarat (Conditional Expected Value)

    MGF Bersama (Joint MGF)

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    3/30

    Prepared by : M. Dokhi, Ph.D.9:01

    3 of 45

    Expected value (Review)

    Expected value of discrete R.V.

    1( ) (1 ) ; 0,1x xX f x p p x

    1

    1 0 1 1 0

    0

    ( ) (1 ) 0 (1 ) 1 (1 )x x

    x

    E X x p p p p p p p

    12 2 1 2 0 1 2 1 0

    0

    ( ) (1 ) 0 (1 ) 1 (1 )x x

    x

    E X x p p p p p p p

    22 2( ) [ ] [ ] (1 )V X E X E X p p p p

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    4/30

    Prepared by : M. Dokhi, Ph.D.9:01

    4 of 45

    Expected value (Review)

    21

    21( ) ;2

    xX f x e x

    2 21 1

    2 2

    01 1( ) 2 02 2

    x xE X x e dx x e dx

    2 21 1

    2 2 22 2

    0

    1 1

    ( ) 2 12 2

    x x

    E X x e dx x e dx

    22 2( ) [ ] [ ] 1 0 1V X E X E X

    0( 1) xx e dx

    12

    1

    0 !

    xk ka

    x e dx k a

    Expected value of continuous R.V.

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    5/30

    Prepared by : M. Dokhi, Ph.D.9:01

    5 of 45

    Joint pdf and expected value

    LetXand Ybe random variables with joint probability f(x, y).Their expected values (means) are written as

    Discrete random variables:

    or

    Continuous random variables:

    or

    ( , )Xx y

    x f x y ( , )Yy x

    y f x y

    ( , )X x f x y dydx

    ( , )Y y f x y dxdy

    ( )Xx

    x f x ( )Yy

    y f y

    ( )X x f x dx

    ( )

    Y y f y dy

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    6/30

    Prepared by : M. Dokhi, Ph.D.9:01

    6 of 45

    Contoh

    A joint pdf of two random variablesX, Yis given by

    otherwise

    yxforyxf

    xy 51,40

    0),( 96

    4 5

    0 1

    4 5 2

    0 1

    54 2 2

    0 1

    4 2

    0

    43

    0

    [ ] ( , )

    96

    96

    192

    8

    824 3

    x y

    E X x f x y d xd y

    xy

    x d yd x

    x yd y d x

    x yd x

    xd x

    x

    4 5

    0 1

    4 5 2

    0 1

    54 3

    0 1

    4

    0

    42

    0

    [ ] ( , )

    96

    96

    288

    31

    72

    31 31144 9

    x y

    E Y y f x y dxdy

    xy

    y dydx

    xydydx

    xydx

    xdx

    x

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    7/30

    Prepared by : M. Dokhi, Ph.D.9:01

    7 of 45

    Expected value of a function

    E H ( ). ( )

    x

    u x f x

    ( ) ( )x

    u x f x dx

    ; X diskrit

    ; X kontinu

    Misalkan ( ) adalah sembarang fungsi dari X, makaH u X

    Jika ( ) [ ( )] [ ] Rata-rataXu X X E u X E X X

    22

    22 2

    Jika ( ) ( [ ]) ( ) ( )

    ( ) [ ]X

    u X X E X E u X E X E X

    E X E X V X

    R.V. ( )X f x

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    8/30

    Prepared by : M. Dokhi, Ph.D.9:01

    8 of 45

    IfXand Yhas a jointpdf f(x,y) and if is afunction ofX and Y, maka

    Discrete random variables:

    Continuous random variables:

    ( ) ( , ) ( , )x y

    E H u x y f x y

    dxdyyxfyxuHE

    ),(),(...)(

    ),( YXuH

    Expected value of a function

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    9/30

    Prepared by : M. Dokhi, Ph.D.9:01

    9 of 45

    If adalah joint fungsi darimaka untuk

    1

    1 1( ) ... ( ,..., ) ( ,..., )k

    k k

    x x

    E H u x x f x x

    1 2( , ,..., )kH u X X X

    Expected value of a function

    1 2, ,..., kX X X1 2( , ,..., )kf X X X

    Jika diskrit1 2, ,..., kX X X

    Jika kontinu1 2, ,..., kX X X

    1

    1 1 1( ) ... ( ,..., ) ( ,..., ) ...

    k

    k k k

    x x

    E H u x x f x x dx dx

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    10/30

    Prepared by : M. Dokhi, Ph.D.9:01

    10 of 45

    Example

    Joint pdf of two random variablesX, Yis given by

    Let

    The expected value of His

    960 4, 1 5

    ( , )0

    xy x yf x y for

    otherwise

    4 5

    0 1

    4 5 2 2

    0 1

    [2 3 ] (2 3 ) ( , )

    (2 3 )96

    48 32

    47

    3

    x y

    E X Y x y f x y dxdy

    xyx y dxdy

    x y xydydx

    ( , ) 2 3H u X Y X Y

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    11/30

    Prepared by : M. Dokhi, Ph.D.9:01

    11 of 45

    Covariance: Definition

    X,Y discrete

    X,Y continuous

    Ukuran keeratanhubungan linear

    antara 2 R.V.

    Misalkan ( , ) ( [ ])( [ ])H u X Y X E X Y E Y

    Covar ,

    XY

    X Y

    ( , )

    ( , )

    X Y

    X Yx y

    X Y

    y x

    E X Y

    X Y f X Y

    X Y f X Y dxdy

    [ ] [ ]E H E X E X Y E Y

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    12/30

    Prepared by : M. Dokhi, Ph.D.9:01

    12 of 45

    Variance vs. Covariance

    Case of 1 R.V.

    2

    2

    22

    Var

    ( )

    ( ) [ ]

    XX

    E X E X

    E X E X

    Case of 2 R.V.

    Covar ,

    [ ] [ ]

    ( ) [ ] [ ]

    XYX Y

    E X E X Y E Y

    E XY E X E Y

    Rumus hitungVariance

    Rumus hitungCovariance

    Var( ) Covar( , )X X X

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    13/30

    Prepared by : M. Dokhi, Ph.D.9:01

    13 of 45

    Some properties of Covariance

    If Xand Yare random variables and a andb are constant, then

    IfXand Yare independent, then

    ( , ) ( , )Cov aX bY abCov X Y

    ),(),( YXCovYbXaCov )(),(),( XaVarXXaCovbaXXCov

    0)().()(),( YEXEXYEYXCov

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    14/30

    Prepared by : M. Dokhi, Ph.D.9:01

    14 of 45

    Covariance: Example

    A joint pdf of two random variablesX, Yis given by

    Thus, Cov(X,Y) = E[XY] E[X]E[Y] :

    otherwise

    yxforyxf

    xy 51,40

    0

    ),( 96

    3

    8

    96][

    4

    0

    5

    1

    x y

    dxdyxy

    xXE9

    31

    96][

    4

    0

    5

    1

    x y

    dxdyxy

    yYE

    4 5 4 5

    2 2

    0 1 0 1

    [ ] ( , )

    1 248

    96 96 27x y

    E XY xyf x y dxdy

    xyxy dxdy x y dydx

    0

    9

    31

    3

    8

    27

    248][].[][

    YEXEXYEXY

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    15/30

    Prepared by : M. Dokhi, Ph.D.9:01

    15 of 45

    Variance of a function

    Some properties of variance

    If cis a constant, Var[cX] = c2Var[X]

    IfXand Yare independent random variables, thenVar[X Y] = Var[X] + Var[Y]

    Var[aX+ bX]= a2Var[X] + b2Var[Y],

    where a, b are constants

    222222 ])[(][][])[( XEXEXEXEX

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    16/30

    Prepared by : M. Dokhi, Ph.D.9:01

    16 of 45

    Correlation Coefficient

    Correlation is another measure of the strength ofdependence between two random variables.

    It scales the covariance by the standard deviation ofeach variable.

    IfXand Yare independent, then = 0, but = 0 does

    not imply independence

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    17/30

    Prepared by : M. Dokhi, Ph.D.9:01

    17 of 45

    Correlation Coefficient: Problem

    Assume the lengthXin minutes of a particular type oftelephone conversation is a random variable with

    probability density function

    Determine

    The mean length E(X) of this telephoneconversation.

    Find the variance and standard deviation ofX

    Find

    5/

    5

    1)( xeXf x0

    ])5[(

    2XE

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    18/30

    Prepared by : M. Dokhi, Ph.D.9:01

    18 of 45

    Correlation Coefficient: Problem

    5

    255

    1

    255

    5

    1

    5155

    5

    1

    55

    5

    1

    51][

    0

    55

    0

    55

    0

    55

    0

    5

    xx

    xx

    xx

    x

    exe

    exe

    dxexe

    vduuv

    dxxeXE5

    5

    5 x

    x

    evdxdu

    dxedvxu

    Use integration by part:

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    19/30

    Prepared by : M. Dokhi, Ph.D.9:01

    19 of 45

    Correlation Coefficient: Problem

    505

    250

    2505055

    1

    2551055

    1

    55105

    5

    1

    1055

    1

    5

    1][

    5552

    0

    5552

    0

    5552

    0

    552

    0

    522

    xxx

    xxx

    xxx

    xx

    x

    exeex

    exeex

    dxexeex

    dxxeex

    vduuv

    dxexXE

    5

    5

    5 x

    x

    evdxdu

    dxedvxu

    25550))(()()var( 222 XEXEX

    5)var()( XXstd

    5

    52

    52 x

    x

    evxdxdu

    dxedvxu

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    20/30

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    21/30

    Prepared by : M. Dokhi, Ph.D.9:01

    21 of 45

    Correlation Coefficient: problem

    The joint density function ofXand Yis given by

    Find the covariance and correlation coefficient ofXand Y

    120 40

    200( , )

    0

    x y

    f x y

    el sewh ere

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    22/30

    Prepared by : M. Dokhi, Ph.D.9:01

    22 of 45

    Correlation Coefficient: problem

    In order to calculate the covariance, we need the values of E[XY],E[X], and E[Y]. First compute the marginal pdf ofXand Y

    20 < x < 40 20 < y < 40

    Then from the marginal pdf calculate E[X], and E[Y]. The E[XY] iscalculated from the joint pdf

    x

    dyxgx

    005.02.0200

    1)(40

    1.0005.0

    2001)(

    20

    y

    dxyhy

    67.26

    )005.02.0(][40

    20

    dxxxXE33.33

    )1.0005.0(][40

    20

    dyyyYE

    9002

    800

    200

    1

    200

    1][

    40

    20

    3

    4040

    20

    dxx

    x

    dydxxyXYEx

    Jadi,XY

    = Cov[XY]

    Cov[XY] = E[XY] E[X]*E[Y]

    = 900 26.67(33.33)= 11.09

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    23/30

    Prepared by : M. Dokhi, Ph.D.9:01

    23 of 45

    Correlation Coefficient: problem

    In order to calculate the correlation coefficient, we need the values of

    E[X2], E[Y2], Var [X] and Var[Y].

    X2 = Var[X] = E[X2] E[X]2 = 733.33 (26.67)2 = 22.204

    Y2 = Var[Y] = E[Y2] E[Y]2 = 1133.33 (33.33)2 = 22.244

    Thus the correlation coefficient is

    33.733

    )005.02.0(][ 4020

    22

    dxxxXE33.1133

    )1.0005.0(][40

    20

    22

    dyyyYE

    [ ] 11.090.499

    [ ] [ ] 22.204 22.244

    XY

    X Y

    C o v E X

    V ar X Var Y

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    24/30

    Prepared by : M. Dokhi, Ph.D.9:01

    24 of 45

    Correlation Coefficient: problem

    Consider the joint density function

    x>2; 0 < y< 1;

    elsewhere;

    Compute f(x), f(y), E[X], E[Y], E[XY], XY, XY.

    3

    16),(

    x

    yyxf

    0),( yxf

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    25/30

    Prepared by : M. Dokhi, Ph.D.9:01

    25 of 45

    Moment

    The kth moment about the origin of a random variableXis

    The kth moment about the mean is

    continuousisXifxfx

    discreteisXifxfxXE

    k

    x

    k

    k

    k

    )(

    )(]['

    kk

    k XEXEXE )()]([

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    26/30

    Prepared by : M. Dokhi, Ph.D.9:01

    26 of 45

    Correlation Coefficient: problem

    Moments are useful in characterizing some features of the

    distribution

    The first and the second moment about the origin are given by

    We can write the mean and variance of a random variable as

    The second moment about the mean is the variance.

    The third moment about the mean is a measure of skewness of

    a distribution.

    22

    2 ][ XE

    ]['1 XE ]['2

    2 XE

    2122 )'(' '1

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    27/30

    Prepared by : M. Dokhi, Ph.D.9:01

    27 of 45

    Moment Generating Function (MGF)

    Moment-generating function is used to determine the moments of

    distribution

    It will exist only if the sum or integral converges.

    If a moment-generating function of X does exist, it can be used to

    generate all the moments of that variable.

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    28/30

    Prepared by : M. Dokhi, Ph.D.9:01

    28 of 45

    Moment Generating Function (MGF)

    m

    i

    i

    tx

    X xfetM i

    1

    )()(

    m

    i

    i

    tx

    iX xfextM i

    1

    ' )()(

    m

    i

    i

    txrr

    X xfextM i

    i

    1

    )( )()(

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    29/30

    Prepared by : M. Dokhi, Ph.D.9:01

    29 of 45

    Moment Generating Function (MGF)

    ][],...,[],[ 2 kXEXEXE

    m

    i

    i

    rr

    X xfxtM i1

    )( )()0(

  • 8/13/2019 Pertemuan 3-4 - Nilai Harapanxxxx Dan MGF

    30/30