Professional Documents
Culture Documents
Exercise 3 - Solution
Exercise 3 - Solution
(Continuous variables)
1.
The following graph depicts the density function of a continuous random variable. What is the value of
b (correct to 4 decimal places)?
Solution
1 1
area 1 0.5 (b 1) 0.5 1 b 4
2 2
2.
The random variable X has the following PDF:
cx n , 0 x 1
f ( x)
0, else
a. What is the value of c (as a function of n)?
b. Find P ( X x ) for 0 x 1 .
Solution
a.
1
c n 1
1
c
0 cx dx 1 n 1 x 0 n 1 1 c n 1
n
b.
1
P( X x) (n 1)t n dt t n 1 1 x n 1
1
x
x
3.
The random variable X has the following PDF:
a bx 2 , 0 x 1
f ( x)
0, else
1
a b
1
a b
E ( X ) 0.6 x(a bx )dx x 2 x 4 0.6
2
0 2 4 0 2 4
3a b 3 a 0.9
2a 2b 2.4 b 0.3
4.
For X ~ U (0,1), Y ln X , find the PDF for Y.
Solution
FY ( y ) P(Y y ) P( ln X y ) P(ln X y ) P ( X e y ) 1 e y
d
fY ( y ) FY ( y ) e y
dy
5.
The random variable X has the following PDF:
cx 2 , x 1
f ( x)
0, else
a. What is the value of c ?
b. Find E ( X ), V ( X ) .
c. Find P ( X 0.5)
Solution
a.
1
c 3
1
2c
f ( x)dx 1 1 cx dx 1 3 x 1 3 1 c 1.5
2
b.
1
c
1
E ( X ) x cx dx x 4 0
2
1 4 1
1
c
1
2c
E ( X 2 ) x 2 cx 2 dx x5 0.6 V ( X ) 0.6
1 5 1 5
c.
1
c 3
1
c
P( X 0.5) 0.5 cx dx 3 x 0.5 3 1 0.125 0.4375
2
6.
1 x
The random variable X has the following PDF: f ( x) e
2
Find the CDF for: Y X
2
Solution
y
0
1 1
FY ( y ) P (Y y ) P ( X 2 y ) P y X y
2 y
e x dx
2
0
e x dx
1 x 0 1 y
e e x 1 e y
2 y 2 0
7.
Let X and Y be two jointly continuous random variables with joint PDF:
1 x 2 16 y, 1 x 1, 0 y 2
f X ,Y ( x) 4
0, else
a. Find the marginal PDFs, f X ( x ), fY ( y ) .
b. Find P ( X 0, Y 1) .
c. Find P ( X 0 or Y 1) .
d. Find P ( X 0 | Y 1) .
e. Find P ( X Y 0) .
Solution
a.
2
f X ( x)
2
1
4 x 2 16 y dy 14 x 2 y 16 12 y 2 12 x 2 13
y 0
0
1
fY ( y ) 1
4 x 2 16 y dx 14 13 x3 16 yx 16 13 y
x 1
1
b.
1 1 1 1
1
P( X 0, Y 1) x 2 16 y dxdy 14 13 x3 16 yx dy 121 16 y dy
1
1
4 x 0
0 0 0 0
6
c.
1 0 2 1
P( X 0 or Y 1)
0
1
1
4
x 2 16 y dxdy
0
0
1
4
x 2 16 y dxdy
1 2
14 13 x3 16 yx dy 14 13 x3 16 yx dy
0 1
x 1 x 0
0 0
1 2
2
121 16 y dy 121 16 y dy 121 y 121 y 2 y 0 121 y 121 y 2 y 0
1 2
0 0
3
d.
P( X 0, Y 1) 1/ 6 1/ 6 1
P( X 0 | Y 1)
P(Y 1) P(Y 1) 1/ 3 2
1 1
1
P(Y 1) fY ( y )dy 16 13 y dy 16 y 16 y 2
1
0 0
0 3
e.
0 2 1 2
P( X Y 0)
1 x
1
4
x 2 16 y dydx
0
0
1
4
x 2 16 y dydx
0 1
dx 14 x 2 y 121 y 2 dx
2 2
14 x 2 y 121 y 2
y x y 0
1 0
0 1
1
1
4
x 3 125 x 2 13 dx
0
1
2
x 2 13 dy
0 1
161 x 4 365 x 3 13 x 16 x 3 13 x 0.9097
1 0
8.
Solution
a.
A = event the machine functional P ( A | Q q ) q
1 1
1 2 1 1
P( A) P( A | Q q) fQ (q)dq qdq q
0 0
2 0 2
b.
Y = number of days the machine was functional during n days Y ~ B(n, 0.5)
n m
q (1 q) n m 1
PY (m | q) fQ (q) m
fQ|Y (q | m)
PY (m) PY (m)
1 1
n
PY (m) PY |Q (m | q ) fQ (q )dq q m (1 q ) n m dq
0
0
m
n1 m n m !(n m)!
q (1 q ) n m dq
m 0 m (n 1)!
n m nm
q (1 q)
m q m (1 q ) n m (n 1)! m n !(n 1) m
fQ|Y (q | m) q (1 q ) n m q (1 q ) n m
n m !(n m)! m !(n m)! m !(n m)! m !(n m)!
(n 1)!
m (n 1)!
n
(n 1) q m (1 q ) n m
m
n
fQ|Y (q | m) (n 1) q m (1 q) n m , 0 q 1, m n
m
9.
Solution
E ( X ) X , E (Y ) Y
V ( X ) X 2 , V (Y ) Y 2
E ( Z ) E (2 X 3Y ) 2 E ( X ) 3E (Y )
2 X 3Y
V ( Z ) V (2 X 3Y ) V (2 X ) V ( 3Y ) 2 2V ( X ) ( 3) 2V (Y )
4 X 2 9 Y 2
10.
A defective coin minting machine produces coins with probability of head a random
variable with PDF:
1 sin(2 ), 0 1
f ( )
0, else
In essence, a specific coin produced by this machine will have a fixed probability
of giving the result head. A coin is selected and tossed repeatedly, with
successive tosses being independent.
a. Find the probability that the first toss results in head.
b. Given that the first toss resulted in head, find the conditional PDF of .
c. Given that the first toss resulted in head, find the conditional probability of
head on the second toss.
Solution
a.
1 1 1 1
P( H ) P ( H | ) f ( )d 1 sin(2 ) , d d sin(2 ) d
0 0 0 0
1 1 1
1 1 1 1
1
1 1 1
2
2 0 2
cos(2 )
0 2
0
cos(2 )d
2 2 2 2
sin(2 )
0
1
P( H )
2
b.
P ( H | ) f ( ) 1 sin(2 )
f |H ( )
P( H ) ( 1) / 2
2 1 sin(2 )
, 0 1
f |H ( ) 1
0, else
c.
2 1 sin(2 )
, 0 1
Now: f ( ) 1
0, else
1 1
2 1 sin(2 ) 2
1 1
P( H ) P( H | ) f ( ) d d 2
d 2 sin(2 )d
0 0 1 1 0 0
2 1 3 2 1 2
1 1
1
1
cos(2 )
1 3 0 1 2 0 2
2 cos(2 ) d
0
2 2 1 2 1
1
1
1
3( 1) 1 2
1 2
sin(2 )
0 2
sin(2 ) d
0
2 1 2 1 2 1 2 3
1
cos(2 )
3( 1) 1 1 2 2 0 3( 1) 1 3( 1)
2 3
P( H )
3( 1)
11.
Solution
a.
1 1
0 0
f ( x, y )dxdy 1
1 1
1 3 1 2 1 1
c x 2 xy dxdy c
1 1 1 1
0 0 0 3
x
2
x y
0
dy c 0
3 2
y dy
0
1
1 1 7 12
c y y2 c 1 c
3 4 0 12 7
x
1 3 1 2 y 1 1 2
y x y
F ( x, y ) c x '2 x ' y ' dx ' dy ' c 3 x ' 2 x ' y ' dy ' c 0 3 x 2 x y ' dy '
3
0 0 0
x ' 0
y
1 1 12 1 1
c x 3 y ' x 2 y '2 x3 y x 2 y 2
3 4 y ' 0 7 3 4
c.
1
12 1
1
1
f X ( x) c x 2 xy dy c x 2 y xy 2 x 2 x
0
2 y 0 7 2
1
1 12 1 1
1
1
fY ( y ) c x xy dx c x3 x 2 y y
2
0
3 2 x 0 7 3 2
12 1 3 1 2 12 x3 x 2
x
x 12 2 1
FX ( x) x ' x ' dx ' x' x'
0 7 2 7 3 4 0 7 3 4
1 2 12 y y 2
y
y 1 1 1
FY ( y ) c y ' dy ' c y ' y '
0
3 2 3 4 0 7 3 4
d.
c x y x y dxdy
1 1 1 1
E ( XY ) cxy x 2 xy dxdy 3 2 2
0 0 0 0
1
1 1 4 1 3 2 1 1 1 2
c 4 x y 3 x y dy c 0 4 y 3 y dy
0
x 0
1
1 1 12 1 1 17
c y 2 y3
8 9 0 7 8 9 42
1 1 1 1
E ( X ) cx x 2 x dx c x 3 x 2 dx
0
2 0
2
1
1 1 12 1 1 5
c x3 x3
4 6 0 7 4 6 7
1 1 1 1 1 1
E (Y ) cy y dy c y y 2 dy
0
3 2 0
3 2
1
1 1 12 1 1 4
c y 2 y3
6 6 0 7 6 6 7
1 1 1 1
E ( X 2 ) cx 2 x 2 x dx c x 4 x 3 dx
0
2 0
2
1
1 1 12 1 1 39
c x5 x 4
5 8 0 7 5 8 70
1 1 1 1 1 1
E (Y 2 ) cy 2 y dy c y 2 y 3 dy
0
3 2 0
3 2
1
1 1 12 1 1 17
c y3 y 4
9 8 0 7 9 8 42
2
39 5
V (X ) 0.0469
70 7
2
17 4
V (Y ) 0.0782
42 7
17 5 4
Cov( X ) 0.0034
42 7 7
12.
X ~ N 12, 52
a. P ( X 8) ?
b. P ( X 6) ?
c. P(3 X 8) ?
d. P(7 X 17) ?
e. P ( X 15 | X 6) ?
f. P( X a ) 0.75, a ?
g. P(12 a X 12 a) 0.65, a ?
Solution
a.
8 12
P( X 8) 0.8 1 0.8 1 0.7881 0.2119
5
b.
6 12
P( X 6) 1 1 1.2 1 1.2 0.8849
5
c.
8 12 3 12
P(3 X 8) 0.8 1.8
5 5
1 0.8 1 1.8 1.8 0.8 ...
d.
17 12 7 12
P(7 X 17) 1 1 2 1 1 0.6826
5 5
e.
P ( X 15 X 6) P(6 X 15)
P( X 15 | X 6)
P( X 6) P( X 6)
15 12 6 12
5 5 0.6 1.2
6 12 1 1.2
1
5
0.6 1 1.2 0.7257 1 0.8849
...
1.2 0.8849
f.
a 12 a 12
P( X a) 0.75 0.75 0.674 a 15.37
5 5
g.
a a
P (12 a X 12 a ) 0.65 0.65
5 5
a a a
2 1 0.65 0.825 0.935 a 4.675
5 5 5
13.
X ~ B 120, 0.7
a. P ( X 85) ?
b. P ( X 85) ?
c. P (X 85) ?
d. P(80 X 90) ?
e. P( X 80 | X 90) ?
Solution
Normal approximation: X ~ N 84, 25.2
a.
84 0.5 84
P( X 85) P( X 84) 0.1 0.5398
25.2
b.
85 0.5 84
P( X 85) 0.3 0.6179
25.2
c.
85.5 0.5 84 84.5 0.5 84
P( X 85) P(84.5 X 85.5) 0.4 0.2
25.2 25.2
0.6554 0.5793 0.0761
Compare with: P( X 85)
120
0.7 0.3 0.0783
85 35
85
d.
90 0.5 84 80 0.5 84
P(80 X 90) 1.29 0.7
25.2 25.2
1.29 1 0.7 0.6595
e.
P( X 80 X 90) P(80 X 90) 0.6595
P( X 80 | X 90) 0.7316
P( X 90) P( X 90) 0.9015
90 0.5 84
P( 90) 1.29 0.9015
25.2