Distribution of Functions of Random Variables
Distribution of Functions of Random Variables
f ( x, y )dxdy
h ( x , y ) z
d
(2) g ( z) G( z)
dy
Example 1
(i) 0 x z y (ii) 0 x z y
0 y z 0 y z
Solving the inner integral
Next solving the second integral
Thus
Then
(1) F ( y ) Pr(Y y ) Pr( g ( x1 , x2 ,.., xk ) y )
..
f ( x1 , x2 ,.., xk )dx1dx2 ...dxk
g ( x1 , x2 ,.., xk ) y
d
(2) f ( y) F ( y)
dy
Example 2
Let X X 1 X 2 X 3 have j.p.d.f
4e (2 x1 2 x2 x3 ) x1 0, x2 0, x3 0
f ( x1 , x2 , x3 )
0, elsewhere
4e (2 x1 2 x2 x3 ) dx1dx2 dx3
x1 x2 x3 y
(i) 0 x3 y x1 x2 (ii) 0 x3 y x1 x2
0 x2 y x1 0 x1 y x2
0 x1 y 0 x2 y
(iii) 0 x1 y x3 x2 (iv) 0 x1 y x3 x2
0 x2 y x3 0 x3 y x2
0 x3 y 0 x2 y
0 x2 y x3 x1 0 x2 y x3 x1
(v) (vi)
0 x1 y x3 0 x3 y x1
0 x3 y 0 x1 y
y y x3 y x2 x3
0
4e (2 x1 2 x2 x3 ) dx1 e (2 x2 x3 )
0
4e 2 x1 dx1
(2 x2 x3 ) 2 x1 y x2 x3
e 2e
0
e (2 x2 x3 ) 2 2e 2( y x2 x3 )
2e (2 x2 x3 ) 2e (2 y x3 )
Solving the innermost integral
y x2 x3 y x 2 x3
(2 x1 2 x2 x3 ) (2 x2 x3 ) 2 x1
4e dx1 e 4e dx1
0 0
(2 x2 x3 ) 2 x1 y x2 x3
e 2e
0
(2 x2 x3 )
e 2 2e 2( y x2 x3 )
(2 x2 x3 ) (2 y x3 )
2e 2e
Next solving the second integral
y x3 y x3 y x3
(2 x2 x3 ) (2 y x3 ) x3 2 x2 (2 y x3 )
2e 2e dx 2 e 2e dx 2 2e dx 2
0 0 0
x3 2 x2 y x3 (2 y x3 ) y x3
e e 2 x2 e
0 0
e x3 (1 e 2( y x3 ) ) 2( y x3 )e (2 y x3 )
Finally solving the third integral
y
x3 2( y x3 ) (2 y x3 )
e (1 e ) 2( y x3 ) e dx3
0
y y y y
0 0 0 0
x3 y y y y
e e 2y
e 2 ye
x3 2y
e 2e
x3 2y
x3 e e
x3 x3
0 0 0 0
1 2e y e 2 y 2 ye 2 y
Thus
F ( y ) 1 2e y e 2 y 2 ye 2 y
d d
f ( y ) F ( y ) 1 2e y e 2 y 2 ye 2 y
dy dy
2e y 2e 2 y 4 ye 2 y 2e 2 y
2e y 4 ye 2 y
The p.d.f of Y is
2e y 4 ye 2 y y 0
f ( y )
0, elsewhere
Example 3
3(1 x) 2 0 x 1
f ( x )
0, elsewhere
2 n
...... [3(1 xi ) ] dx1dx2 ...dxn
min( x1 , x2 ,.., xn ) y
This is equivalent to
F ( y ) Pr min( X 1 , X 2 ,..., X n ) y
1 Pr min( X 1 , X 2 ,..., X n ) y
1 Pr X y1 , X 2 y,..., X n y
n
1 Pr( X
i 1
i y)
1
3 1
Pr( X i y ) 3(1 xi ) dxi (1 xi )
2
y
y
0 ( (1 y )3 ) (1 y )3
n n
i
Pr(
i 1
X y ) (1 y )
i 1
3
(1 y ) 3n
Thus F ( y ) 1 (1 y )3n
d d
f ( y ) F ( y ) 1 (1 y ) 3n 3n(1 y ) 3n 1
dy dy
The p.d.f of Y is
3n(1 y )3n 1 0 y 1
f ( y )
0, elsewhere
Change of variable technique
U g1 ( X , Y )
W g2 ( X ,Y )
If
(i) the functions
X h1 (U ,W )
Y h2 (U ,W )
x x
u w
y y
u w
f ( x, y ) e ( x y ) x 0, y 0
U W UW
we have X and Y
2 2
w u
0 y 0 w u
2
u w and u w w u w ; w 0
The partial derivatives required to obtain the Jacobian of transformation are:
x (u w) 1 x (u w) 1
u u 2 2 w w 2 2
y ( w u ) 1 y (w u ) 1
u u 2 2 w u 2 2
1 1
2 2 1 1 1 1 1
J det 2 2 2
1 1 2 2
2 2
The j.p.d.f of U and W is given by
g u, w f h1 (u , w) , h2 (u , w) J
x y
absolute value of J
u w w u 1 1 w
exp e
2 2 2 2
The j.p.d.f of U and W is
1 w
g u , w e w u w; w 0
2
Let X 1 , X 2 ,..., X k be jointly distributed with j.p.d.f f ( x1 , x2 ,..., xk )
Define a new random vector Y Y1 Y2 ....Yk such that each random
variable in the newly defined random vector is a function of the variables
X 1 , X 2 ,..., X k i.e.
Y j g j ( X 1 , X 2 ,..., X k )
If
(i) The functions Y j g j ( X 1 , X 2 ,..., X k ) are partially
differentiable with respect to each variable Xj
X j h j (Y1 , Y2 ,..., Yk )
(ii) the functions can be determined so that
there is a one-to-one correspondence ;
e ( x1 x2 x3 ) x1 0, x2 0, x3 0
f ( x1 , x2 , x3 )
0, elsewhere
Find the p.d.f of Y Y1 Y2 Y3 such that
X1 X2
Y1 ; Y2 ; Y3 X 1 X 2 X 3
X1 X 2 X 3 X1 X 2 X 3
We begin by obtaining the functions of X 1 , X 2 , X 3 in terms of
Y1 , Y2 , Y3
Given that Y3 X 1 X 2 X 3 ;
X1 X1
Y1 X1 Y1Y3
X1 X 2 X 3 Y3
X2 X1
Y2 X 2 Y2Y3
X1 X 2 X 3 Y3
X 3 Y3 X 1 X 2 Y3 Y1Y3 Y2Y3
x1 x1 x1 y1 y3 y1 y3 y1 y 3
y1 y2 y3
y1 y 2 y 3
x2 x2 x2 y2 y3 y 2 y3 y 2 y 3
J
y1 y2 y3
y1 y 2 y 3
x3 x3 x3 y3 y3 y1 y3 y 2 y3 y3 y1 y 3 y 2 y 3 y 3 y1 y3 y 2
y1 y 2 y 3
y1 y2 y3
y3 0 y1
0 y3 y2
y3 y3 1 y1 y 2
y3 0 y1
0
y3 y2 y3 y3 (1 y1 y2 ) ( y2 y3 )
y3 y3 1 y1 y2
y1 (0 y3 ) ( y3 )
2
X1
Y1 0 y1 1
X1 X 2 X 3
X2
Y2 0 y2 1
X1 X 2 X 3
Y3 X 1 X 2 X 3 y3 0
y32 e y3 0 y1 1;0 y1 1; y3 0
g ( y1 , y2 , y3 )
0, elsewhere
Example 4
Let X 1 , X 2 , X 3 be independent random variables, each with p.d.f
f ( xi ) xi e xi xi 0
Y1 X 1 X 2 X 3 ; Y2 X 2 X 3 ; Y3 X 3
Defining X 1 , X 2 , X 3 in terms of Y1 , Y2 , Y3
Y3 X 3 X 3 Y3
Y2 X 2 X 3 X 2 Y3 X 2 Y2 Y3
Y1 X 1 X 2 X 3 X 1 Y2 X 1 Y1 Y2
x1 x1 x1 ( y1 y2 ) ( y1 y2 ) ( y1 y2 )
y1 y 2 y3
y1 y 2 y3
J
x2 x2 x2
( y 2 y3 ) ( y 2 y3 ) ( y 2 y 3 )
y1 y 2 y3 y1 y 2 y 3
x3 x3 x3 y3 y 3 y 3
y1 y 2 y3 y1 y 2 y 3
1 1 0
0 1 1 1
0 0 1
g ( y1 , y2 , y3 ) ( y1 y2 )( y2 y3 ) y3e ( y1 y2 y2 y3 y3 ) 1
( y1 y2 )( y2 y3 ) y3e y1
Y1 X 1 X 2 X 3 y1 0
Y2 X 2 X 3 y2 0
Y3 X 3 y3 0
Also x2 0 y2 y3 0, y3 y 2
x1 0 y1 y2 0, y 2 y1
Therefore
g ( y1 , y2 , y3 ) ( y1 y2 )( y 2 y3 ) y3e y1 y1 0,
0 y2 y1 ,
0 y3 y2
Generating function technique
For this technique, find the generating function for the function of the
random variables using their j.p.d.f and then compare it to known
generating functions to see if there is a match.
Example 5
Let X 1 , X 2 ,..., X n be independent random variables , each with p.d.f
f ( xi ) e xi xi 0
n
1
X i (t ) p (1 p)
xi 1 xi
e itxi
(1 p) pe it
xi 0
n
n
Z (t ) (1 p) pe (1 p) pe
it it
i 1
n
n
Z (t ) (1 p) pe (1 p ) pe
it it
i 1
n z n z
Pr( Z z ) p (1 p ) ; z 0,1, 2, .., n
z