0% found this document useful (0 votes)
25 views

Tutorial 5 Solution

Uploaded by

pgpcj68rsq
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views

Tutorial 5 Solution

Uploaded by

pgpcj68rsq
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

NATIONAL UNIVERSITY OF SINGAPORE

Department of Mathematics
QF1100 Introduction to Quantitative Finance (Semester 2, AY22/23)
Tutorial in Week 7

1. Toss a pair of fair dice. Let X be the sum of the faces. Then X is discrete, and
its possible values are 2, 3, . . . , 12. Recall that its pdf was given in our lecture.
Compute E[6X 2 − 7X − 30].
Note that
E[6X 2 − 7X − 30] = 6E[X 2 ] − 7E[X] − 30.
We have
1 2 3 4 5 6 5
E[X] =2 × +3× +4× +5× +6× +7× +8×
36 36 36 36 36 36 36
4 3 2 1
+9× + 10 × + 11 × + 12 ×
36 36 36 36
=7,

and
1 2 3 4 5 6 5
E[X 2 ] =22 × + 32 × + 42 × + 52 × + 62 × + 72 × + 82 ×
36 36 36 36 36 36 36
4 3 2 1
+ 92 × + 102 × + 112 × + 122 ×
36 36 36 36
329
= .
6
Then
329
E[6X 2 − 7X − 30] = 6E[X 2 ] − 7E[X] − 30 = 6 × − 7 × 7 − 30 = 250.
6

2. Define (
a + bx + x2 if 0 ≤ x ≤ 1;
f (x) =
0 otherwise.

Do there exist a and b such that f (x) is a probability density function of a random
variable X with mean E[X] = 23 ? If they exist, find the values of a and b and their
variance.
Firstly, since P (X < ∞) = 1, we have
∞ 1 1 ′
bx2 x3
Z Z Z 
2
1 = f (x) dx = (a + bx + x ) dx = ax + + dx
−∞ 0 0 2 3
2 3 x=1
 
bx x 1 b
= ax + + = +a+ .
2 3 x=0 3 2

1
Secondly, since E[X] = 32 , we have
Z ∞ Z 1 Z 1 2 ′
2 2 3 ax 4x3 bx4
=E[X] = xf (x) dx = (ax + bx + x ) dx = + + dx
3 −∞ 0 0 2 3 4
 2 x=1
ax bx3 x4 a b 1
= + + = + + .
2 3 4 x=0 2 3 4

Therefore, we get the following equations.



1 b
 3 + a + 2 = 1; (1)



 a b 1 2
 + + = . (2)

2 3 4 3
1 b b 5
From (1), a = 2/3 − b/2. Therefore, equation (2) becomes − + = .
3 4 3 12
Then we get b = 1 and a = 2/3 − b/2 = 1/6. That is, f (x) = 1/6 + x + x2 when
0 ≤ x ≤ 1, which is non-negative. Therefore, it is a density function.
To obtain the variance of X, we first find E[X 2 ]:
1 1
x5 x4 x3
Z
2 1 91
E[X ] = x ( + x + x2 ) dx =
2
+ + = .
0 6 5 4 18 0 180

Then
91 4 11
Var(X) = E[X 2 ] − (E[X])2 = − = .
180 9 180

3. (Exponential distribution)
The amount of time, in hours, that a computer functions before breaking down is
a continuous random variable X with probability density function given by
(
λe−x/100 if x ≥ 0
f (x) =
0 if x < 0.

Following Question 5 in Tutorial 4, find its E[X] and the standard derivation σX .
By definition, Z ∞
x −x/100
E[X] = e dx.
0 100
Integrating by parts yields

Z ∞
−x/100
E[X] = − xe + e−x/100 dx
0 0

−x/100
=0 − 100e = 100.
0

2
To obtain the variance of X, we first find E[X 2 ]:
Z ∞ 2
2 x −x/100
E[X ] = e dx.
0 100
Integrating by parts yields

Z ∞
2 −x/100
2
E[X ] = − x e + 2xe−x/100 dx
0 0
=0 − 200E[X] = 20000.

Hence
p p √
σX = Var(X) = E[X 2 ] − E[X]2 = 20000 − 10000 = 100.

4. Let X and Y be two random variables. If E(X) = 1, E(Y ) = 2, Var(X) = 3,


and Cov(X, Y ) = 4. Find, E(X(1 + 2Y )), Cov(X + Y, 2 + X), E[(2 + X)2 ] and
Var(4 + 3X).
By Var(X) = E(X 2 ) − [E(X)]2 and Cov(X, Y ) = E(XY ) − E(X)E(Y ), we solve

E(X 2 ) = Var(X) + [E(X)]2 = 3 + 1 = 4;


E(XY ) = Cov(X, Y ) + E(X)E(Y ) = 4 + 1 × 2 = 6.

Then

E(X(1 + 2Y )) = E(X + 2XY ) = E(X) + 2E(XY ) = 1 + 2 × 6 = 13;


Cov(X + Y, 2 + X)
=E[(X + Y )(2 + X)] − E(X + Y )E(2 + X)
=E(X 2 ) + 2E(X) + 2E(Y ) + E(XY ) − 2E(X) − E(X)E(X) − 2E(Y ) − E(X)E(Y )
=Var(X) + Cov(X, Y ) = 3 + 4 = 7;
E[(2 + X)2 ] = E(4 + 4X + X 2 ) = 4 + 4E(X) + E(X 2 ) = 4 + 4 × 1 + 4 = 12;
Var(4 + 3X) = E[(4 + 3X)2 ] − [E(4 + 3x)]2
=16 + 24E(X) + 9E(X 2 ) − [16 + 24E(X) + 9(E(X))2 ]
=9Var(X) = 9 × 3 = 27.

5. The joint density function of the random variables X, Y and Z is


1
p(1, 2, 3) = p(2, 1, 1) = p(2, 2, 1) = p(2, 3, 2) = .
4
Find the exact values of the following:

(a) the density functions of the random variables X, Y , and Z, respectively;


(b) E(X), E(Y ), and E(Z);

3
(c) Var(X), Var(Y ), and Var(Z);
(d) the correlation coefficients ρ(X, Y ), ρ(X, Z), and ρ(Y, Z).
(a).
1 3
pX (1) = p(1, 2, 3) = pX (2) = p(2, 1, 1) + p(2, 2, 1) + p(2, 3, 2) =
4 4
1 1 1
pY (1) = p(2, 1, 1) = pY (2) = p(1, 2, 3) + p(2, 2, 1) = pY (3) = p(2, 3, 2) =
4 2 4
1 1 1
pZ (1) = p(2, 1, 1) + p(2, 2, 1) = pZ (2) = p(2, 3, 2) = pZ (3) = p(1, 2, 3) = .
2 4 4
(b).
1 3 7
E(X) =1 × +2× =
4 4 4
1 1 1
E(Y ) =1 × + 2 × + 3 × = 2
4 2 4
1 1 1 7
E(Z) =1 × + 2 × + 3 × = .
2 4 4 4
(c).
1 3 72 3
Var(X) =12 × + 22 × − 2 =
4 4 4 16
1 1 1 1
Var(Y ) =12 × + 22 × + 32 × − 22 =
4 2 4 2
2
1 1 1 7 11
Var(Z) =12 × + 22 × + 32 × − 2 = .
2 4 4 4 16
√ p
(d). ρ(X, Y ) = 0, ρ(X, Z) = −5/ 33, and ρ(Y, Z) = 2/11.
The tutors will show the details during the tutorials.
6. (Optional) Let X be the normal random variable N (µ, σ 2 ).
Find its variance, i.e., Var(X). Hint: Use the substitution y = (x − µ)/σ and then
integrate by parts.
Since E[X] = µ, we have that
Z ∞
1 2 2
2
(x − µ)2 e−(x−µ) /2σ dx.
 
Var(X) = E (X − µ) = √ (0.0.1)
2πσ −∞
Substituting y = (x − µ)/σ in Equation (0.0.1) yields
Z ∞
σ2 2
Var(X) = √ y 2 e−y /2 dy
2π −∞
Z ∞
σ2
 

−y 2 /2 −y 2 /2
=√ − ye + e dy by integration by parts
2π −∞ −∞
Z ∞
2 1 2
=σ √ e−y /2 dy
2π −∞
2
=σ .

You might also like