Professional Documents
Culture Documents
1 Random Variables, Distributions, Multidimen-Sional Random Variables
1 Random Variables, Distributions, Multidimen-Sional Random Variables
= √ xe 2σ2 dx
2πσ −∞
1 Z∞ u2
= √ (u + µ)e− 2σ2 du
2πσ −∞
1 Z ∞ − u22 1 Z ∞ − u22
= √ ue 2σ du + µ √ e 2σ du
2πσ −∞ 2πσ −∞
At this point we can recognise the second integral as the integral of a N (0, σ 2 )
r.v being integrated over all its range, so we can use the normalisation property
to get
1 Z ∞ − u22
E(X) = √ ue 2σ du + µ · 1
2πσ −∞
Here we can tackle the remaining integral either by noting that u is an odd
u2 u2
function and e− 2σ2 is even so that ue− 2σ2 is odd and its integral over (−∞, ∞)
u2 −u2
u2
this gives ue− 2σ2 du = −σ 2 e 2σ2 +c,
R
is 0 or by making the substitution v = 2σ 2
,
−u2
noting that e 2σ2 goes to 0 as u ↑ ∞ or u ↓ −∞ gives the definite integral as
0.
2. Show the the variance of N (µ, σ 2 ) is σ 2
Solution.
Z ∞
V ar(X) = (x − µ)2 fX (x)dx
−∞
1 Z∞ (x−µ)2
= √ (x − µ)2 e− 2σ2 dx
2πσ −∞
1 Z ∞ 2 − u22
= √ u e 2σ du
2πσ −∞
f g 0 du = [f g] − gf 0 du, with f = u,
R R
Here we can use integration by parts,
u2 u2
f 0 = 1, g 0 = ue− 2σ2 and g = −σ 2 e− 2σ2 . Then
Z ∞
1 2
− u2 ∞ u2
V ar(X) = √ 2
[−σ ue 2σ ]−∞ + σ 2
e− 2σ2 du
2πσ −∞
1 Z ∞ − u22
= σ2 √ e 2σ du
2πσ −∞
= σ2 · 1
3. Show that for any random variable X with a finite second moment E(X 2 ) < ∞,
Since Y ∼ N (µ, σ 2 ),
1 (x−µ)2
fY (x) = √ e− 2σ2 .
2πσ
Therefore
1 (ln x−µ)2
fY (ln x) = √ e− 2σ2 ,
2πσ
and thus
1 (ln x−µ)2
fX (x) = √ e− 2σ2 .
2πσx
5. X has N (20, 22 ) distribution and Y has N (0, 1) distribution and they are
independent.
6. X has N (20, 22 ) distribution and Y has N (0, 1) distribution, and X and Y are
correlated with correlation ρ = 0.5.
7. Let X and Y by random variables with E(X) = 20, V ar(X) = 4, and E(Y ) =
10, V ar(Y ) = 1, ρ = 0.5.
Find the covariance and the correlation between X and U = 2X − 3Y
Solution.
Rearranging the formula for correlation gives
q
Cov(X, Y ) = ρ ∗ V ar(X)V ar(Y )
√
= 0.5 ∗ 4 ∗ 1
= 1.
Cov(X, U ) = Cov(X, 2X − 3Y )
= (1)(2)Cov(X, X) + (1)(−3)Cov(X, Y )
= 2V ar(X) − 3Cov(X, Y )
= 2∗4−3∗1
= 5.
Cov(X,U )
By the definition of correlation we have Corr(U, X) = √ .
V ar(X)V ar(U )
We need V ar(U ),
V ar(U ) = Cov(U, U )
= Cov(2X − 3Y, 2X − 3Y )
= 4Cov(X, X) + 2(2)(−3)Cov(X, Y ) + (−3)(−3)Cov(Y, Y )
= 4V ar(X) − 12Cov(X, Y ) + 9V ar(Y, Y )
= 4 ∗ 4 − 12 ∗ 1 + 9 ∗ 1
= 13.
√
Hence Corr(U, X) = √5 = √5 = 5 13
.
13∗4 2 13 26
8. Let X1 and X2 both have Lognormal LN (0, 1) and are independent. Find the
following:
(a) Find P (X > Y ). Hint: write this as P (X − Y > 0) and use Theorem 11,
p.18 in the Notes.
Solution. " #
X
P (X > Y ) = P (X − Y > 0). Now notice that X − Y = [1 − 1] .
Y
Thus, by Theorem 11, X − Y is N (aµ,"aΣaT ).# " #
T 1 ρ 1
We have aµ = 0 and aΣa = [1 − 1] = 2 − 2ρ,
ρ 1 −1
i.e. X − Y ∼ N (0, 2 − 2ρ). Therefore,
1
P (X > Y ) = P (X − Y > 0) = .
2
Remark: there is no need to calculate the variance. Once we know that
the distribution of X −Y is Normal with mean zero, it is symmetric about
0 so that P (X − Y > 0) = 0.5.
(b) Write an integral epxression for P (X ∈ D) where D is a set on the plane.
Evaluate it for D = {(x, y) : x ≤ y}.
Solution.
Let fX,Y (x, y) be the joint density of X and Y . Then,
Z Z
P (X ∈ D) = fX,Y (x, y)dxdy.
(x,y)∈D
X = µ1 + σ1 Z1 , Y = µ2 + σ2 Z2
for some non-random matrix A. Derive the formula for Σ(U,V ) , the covariance
matrix of (U, V ),
Σ(U,V ) = AΣ(X,Y ) AT .
= a11 a21 V ar(X) + (a11 a22 + a12 a21 )Cov(X, Y ) + a12 a22 V ar(Y ), and
Substitute these values back into the matrix Σ(U,V ) , we find that this is
equivalent to
" #" #" #
a11 a12 V ar(X) Cov(X, Y ) a11 a21
Σ(U,V ) = = AΣ(X,Y ) AT .
a21 a22 Cov(X, Y ) V ar(Y ) a12 a22
(b) Assume (X, Y ) is bivariate Normal. Derive the formula for Σ(U,V ) using
representations for multivariate normal and matrix multiplication.
Solution. " # " #
X Z1
Since (X, Y ) is Normal, it has representation = µ(X,Y ) + B
Y Z2
T
for some matrix B such that Σ(X,Y ) = BB . Thus,
" # " # " #
U X Z1
=A = Aµ(X,Y ) + AB .
V Y Z2
12. Show that the average of n independent identically distributed Normal random
variables N (µ, σ 2 ) is a Normal random variable with mean µ and variance σ 2 /n
Solution.
Let X be multivariate normal with mean vector
µ
.
.
.
µ
σ2 0 ···
0
0 σ2 ··· 0
Σ= .. .. ... .. .
. . .
0 0 · · · σ2
We are interested in n1 ni=1 Xi which is the same as aX where a is the 1 × n
P
13. Simulate two observations on the bivariate normal (X1 , X2 ) with mean 0,
V ar(X1 ) = 1, V ar(X2 ) = 4 and correlation ρ = 0.9.
Solution. First, simulate a pair of independent standard normal Z1 and Z2 .
To do this in Excel, we first generate Uniform(0,1) random variable U using
command “=rand()”, then obtain Z1 from the inverse of standard Normal
distribution “=normsinv(U )”. Repeat the steps for Z2 . Then calculate
q
X1 = µ1 + σ1 Z1 and X2 = µ2 + ρσ2 Z1 + 1 − ρ2 σ2 Z2