0% found this document useful (0 votes)
205 views38 pages

Nilai Harapan Dan MGF Bersamaa

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1/ 38

1 of 45

EXPECTED VALUE OF A FUNCTION &


JOINT MGF

9:01

Prepared by : M. Dokhi, Ph.D.

Sessions target
2 of 45

Nilai harapan bersama (Joint expected value)

Kovarian (Covariance)
Korelasi (Correlation)
Nilai Harapan Bersyarat (Conditional Expected Value)
MGF Bersama (Joint MGF)

9:01

Prepared by : M. Dokhi, Ph.D.

Expected value (Review)


3 of 45
Expected value of discrete R.V.

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

E ( X ) x p x (1 p )1 x 0 p 0 (1 p )1 1 p1 (1 p )0 p
x 0
1

E ( X 2 ) x 2 p x (1 p )1 x 02 p 0 (1 p)1 12 p1 (1 p) 0 p
x 0

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

9:01

Prepared by : M. Dokhi, Ph.D.

Expected value (Review)


4 of 45

( 1)

Expected value of continuous R.V.

f ( x)

1
e
2

1
x2
2

; x

x
k a

xe

x e x dx

dx k !a k 1

12

1 12 x2
1 12 x2
E( X ) x
e dx 2 x
e dx 0

0
2
2

E( X 2 ) x2

1
e
2

1
x2
2

dx 2 x 2
0

V ( X ) E[ X 2 ] E[ X ] 1 02 1
2

9:01

Prepared by : M. Dokhi, Ph.D.

1
e
2

1
x2
2

dx 1

Joint pdf and expected value


5 of 45

Let X and Y be random variables with joint probability f(x, y).


Their expected values (means) are written as

Discrete random variables:

X x f ( x, y )
x

Y y f ( x, y )

X x f ( x)

or

Y y f ( y )
y

Continuous random variables:

x f ( x, y)dydx

9:01

Prepared by : M. Dokhi, Ph.D.

x f ( x)dx

y f ( x, y)dxdy

or

y f ( y)dy

Contoh
6 of 45
A joint pdf of two random variables X, Y is given by
xy
96
f ( x, y )
0

for

E[ X ]

0 x 4, 1 y 5

xf ( x, y )dxdy

otherwise

E[Y ]

xy
x
dydx
96

x 0 y 1
4

x2 y
dydx
96

x2 y2

192
0
4

dx

1
5

x2
dx
8

x3 4 8

24 3
9:01
0
Prepared by : M. Dokhi, Ph.D.

yf ( x, y)dxdy

xy
y
x0 y1 96 dydx
4

xy 2
dydx

96

0 1
4
3 5
xy

dx

288
0
1
4

31x
dx
72
0

31x 2

144

31

9
0
4

Expected value of a function


7 of 45

R.V. X

f ( x)

Misalkan H u( X ) adalah sembarang fungsi dari X, maka

EH

u ( x). f ( x)

; X diskrit

u( x) f ( x)dx

; X kontinu

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

Jika u( X ) ( X E[ X ])2 E u ( X ) E X E ( X )

E( X 2 ) E[ X ] V X X2
2

9:01

Prepared by : M. Dokhi, Ph.D.

Expected value of a function


8 of 45

If X and Y has a joint pdf f(x,y) and if H u ( X , Y ) is a


function of X and Y, then

Discrete random variables:

E( H ) u( x, y) f ( x, y)
x

Continuous random variables:

E ( H ) ... u( x, y) f ( x, y)dxdy

9:01

Prepared by : M. Dokhi, Ph.D.

Expected value of a function


9 of 45

If f ( X 1 , X 2 ,..., X k ) adalah joint fungsi dari X 1 , X 2 ,..., X k


maka untuk H u ( X 1 , X 2 ,..., X k )

E ( H ) ... u( x1 ,..., xk ) f ( x1 ,..., xk )


x1

xk

E ( H ) ... u( x1 ,..., xk ) f ( x1 ,..., xk )dx1...dxk


x1

9:01

xk

Prepared by : M. Dokhi, Ph.D.

Jika X 1 , X 2 ,..., X k diskrit

Jika X 1 , X 2 ,..., X k kontinu

Example
10 of 45

Joint pdf of two random variables X, Y is given by


xy
96
f ( x, y )
0

0 x 4, 1 y 5

for

otherwise

Let H u ( X , Y ) 2 X 3Y
The expected value of H is

E[2 X 3Y ]

(2 x 3 y) f ( x, y)dxdy

xy
(2 x 3 y) dxdy
96
x 0 y 1
4

x 2 y xy 2

dydx
48 32
0 1
47

3
4

9:01

Prepared by : M. Dokhi, Ph.D.

Covariance: Definition
11 of 45

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

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

E X X Y Y

X X Y Y f ( X , Y )

X,Y discrete

X X Y Y f ( X , Y )dxdy

X,Y continuous

y x

Covar X , Y
XY
9:01

Prepared by : M. Dokhi, Ph.D.

Ukuran keeratan
hubungan linear
antara 2 R.V.

Variance vs. Covariance


12 of 45
Case of 2 R.V.

Case of 1 R.V.

Var X X2

Covar X , Y XY
E X E[ X ]Y E[Y ]

E X E( X )

E ( X 2 ) E[ X ]

Rumus hitung
Variance

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

E ( XY ) E[ X ]E[Y ]

Rumus hitung
Covariance

Var( X ) Covar( X , X )

Some properties of Covariance


13 of 45

If X and Y are random variables and a and


b are constant, then

Cov(aX , bY ) abCov( X , Y )
Cov(a X , b Y ) Cov( X , Y )
Cov( X , aX b) aCov( X , X ) aVar( X )

If X and Y are independent, then

Cov( X , Y ) E( XY ) E( X ).E(Y ) 0
9:01

Prepared by : M. Dokhi, Ph.D.

Example

Prepared by : M. Dokhi, Ph.D.

Example

Prepared by : M. Dokhi, Ph.D.

Example

f ( x, y )

Prepared by : M. Dokhi, Ph.D.

1
xy
16

Example

Prepared by : M. Dokhi, Ph.D.

Example

Prepared by : M. Dokhi, Ph.D.

Example

Prepared by : M. Dokhi, Ph.D.

Covariance: Example
20 of 45
A joint pdf of two random variables X, Y is given by
xy
96
f ( x, y )
0

for

0 x 4, 1 y 5
otherwise

8
xy
E[ X ] x dxdy
96
3
x 0 y 1
4

31
xy
y
dxdy

x0 y1 96
9
4

E[Y ]

E[ XY ]

xyf ( x, y)dxdy

1
xy
xy dxdy

96
96

x 0 y 1
0
4

2 2
x
y dydx
1

248
27

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

XY
9:01

248 8 31
E[ XY ] E[ X ]. E[Y ]
0
27 3 9

Prepared by : M. Dokhi, Ph.D.

Variance of a function
21 of 45

9:01

Some properties of variance

If c is a constant, Var[cX] = c2Var[X]

If X and Y are independent random variables, then


Var[X Y] = Var[X] + Var[Y]
Var[aX + bX]= a2Var[X] + b2Var[Y],
where a, b are constants

Prepared by : M. Dokhi, Ph.D.

Correlation Coefficient
22 of 45

9:01

Correlation is another measure of the strength of


dependence between two random variables.
It scales the covariance by the standard deviation of
each variable.
If X and Y are independent, then = 0, but = 0 does
not imply independence

Prepared by : M. Dokhi, Ph.D.

Correlation Coefficient: Problem


23 of 45

Assume the length X in minutes of a particular type of


telephone conversation is a random variable with
probability density function

1 x / 5
f (X ) e
5

0 x

Determine

The mean length E(X) of this telephone


conversation.

Find the variance and standard deviation of X

Find E[( X 5) 2 ]

9:01

Prepared by : M. Dokhi, Ph.D.

Correlation Coefficient: Problem


24 of 45
Use integration by part:

E[ X ]

9:01

Prepared by : M. Dokhi, Ph.D.

1
xe x 5 dx

50
uv vdu

1
5 xe x 5 5e x 5 dx
0
5

e x 5
1
x 5

5 xe 5
5
1 5 0

1
5 xe x 5 25e x 5 0
5
1
25
5
5

ux
du dx

dv e x 5 dx
v 5e x 5

Correlation Coefficient: Problem


25 of 45

E[ X ]
2

1 2 x 5
x e dx

50
uv vdu

1
2 x 5
x 5
5x e
10 xe dx
0
5
1
5 x 2 e x 5 10 5 xe x 5 5e x 5 dx
5

1
5 x 2 e x 5 10 5 xe x 5 25e x 5 0
5
1
5 x 2 e x 5 50 xe x 5 250e x 5
5
250
50
5

u x2
du 2 xdx

var( X ) E ( X 2 ) ( E ( X )) 2 50 5 2 25
9:01

std ( X ) var(X ) 5

Prepared by : M. Dokhi, Ph.D.

ux
du dx

dv e x 5 dx
v 5e x 5

dv e x 5 dx
v 5e x 5

Correlation Coefficient: problem


26 of 45

E[(X + 5)2]

9:01

Prepared by : M. Dokhi, Ph.D.

= E[(X2 + 10X + 25)]


= E[X2] + 10E[X] + E[25]
= 50 + 10[5] + 25
= 125

Correlation Coefficient: problem


27 of 45

The joint density function of X and Y is given by

1
200

f ( x, y )

20 x y 40

elsewhere

Find the covariance and correlation coefficient of X and Y

9:01

Prepared by : M. Dokhi, Ph.D.

Correlation Coefficient: problem


30 of 45

Consider the joint density function

16 y
f ( x, y ) 3
x

f ( x, y ) 0
Compute

9:01

Prepared by : M. Dokhi, Ph.D.

f(x),

x >2; 0 < y < 1;


elsewhere;

f(y), E[X],

E[Y],

E[XY],

XY, XY.

Moment
31 of 45

The kth moment about the origin of a random variable X is

x k f ( x)
if X is discrete

x
k
'k E[ X ]
k
x f ( x) if X is continuous

The kth moment about the mean is

k E[ X E ( X )] k E ( X ) k

9:01

Prepared by : M. Dokhi, Ph.D.

Moment
32 of 45

Moments are useful in characterizing some features of the


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

'1 E[ X ]

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

'
1

' 2 E[ X 2 ]
2 ' 2 ( '1 ) 2

The second moment about the mean is the variance.

2 E[ X ] 2 2

9:01

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


a distribution.

Prepared by : M. Dokhi, Ph.D.

Moment Generating Function (MGF)


33 of 45

9:01

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.

Prepared by : M. Dokhi, Ph.D.

Moment Generating Function (MGF)


34 of 45

M X (t ) e txi f ( xi )
i 1

M X' (t ) xi e txi f ( xi )
i 1

9:01

Prepared by : M. Dokhi, Ph.D.

(r )
X

(t ) x ir e txi f ( xi )
i 1

Moment Generating Function (MGF)


35 of 45

(r )
X

(t 0) x i f ( xi )
r

i 1

E[ X ], E[ X ],..., E[ X ]

9:01

Prepared by : M. Dokhi, Ph.D.

Moment Generating Function (MGF)


36 of 45

Find the moment-generating function of the binomial random


variable X and then use it to verify that np and 2 npq
n
tx n x n x
M X (t ) e p q
x 0
x
n
The last sum is
n t x n x
the binomial
pe q
expansion of
x 0 x
(pet+q)n


pe q

First derivation, E[X]

Second derivation,

dM X (t )
n pet q
dt

E[X2]

9:01

Prepared by : M. Dokhi, Ph.D.

n 1

pet

d 2 M X (t )
t
t

np
e
n

1
pe
q
2
dt

1
'
Setting t = 0 we get E[ X ] 1 np

Therefore,

1' np

n2

pe t pe t q

E[ X 2 ] 2' npn 1 p 1

2 2' 2 np(1 p) npq

n 1

et

Conditional Expectation
37 of 45

If X and Y are jointly distributed R.V. then the conditional


expectation of Y given X=x is given by

E(Y | x) y f ( y | x)

X dan Y diskrit

E (Y | x) y f ( y | x)dy
y

9:01

Prepared by : M. Dokhi, Ph.D.

X dan Y kontinu

Conditional Expectation: latihan


38 of 45

f ( x, y) x y 0 x 1,0 y 1
Carilah

E ( y | x)

f ( y | x)

9:01

f ( x, y )
x y

f ( x)
x 0.5

Prepared by : M. Dokhi, Ph.D.

0 y 1

Conditional Expectation: latihan


39 of 45
Jika X dan Y memiliki joint distribusi maka

E X EY Y | X EY (Y )

E X EY Y | X E (Y | x). f ( x)dx
x

y f ( y | x ) f ( x )dydx
x y

M
EY (Y )
9:01

Prepared by : M. Dokhi, Ph.D.

Joint MGF
40 of 45
Definisi : Joint MGF dari vector random X ( X 1 , X 2 ,..., X k ) adalah

M X (t ) E exp ti X i

i 1
Dimana

9:01

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

Prepared by : M. Dokhi, Ph.D.

dan

h ti h

for h > 0

You might also like