Professional Documents
Culture Documents
HW1 Sol
HW1 Sol
1.1
library(astsa)
Earthquake
Explosion
Time
Overall, the earthquake and explosion have the similiar fluctuation in the phase P and phase S. Also, their
maximal amplitude tend to be equal.
In phase P, the earthquake and explosion have smaller amplitudes, while in phase S, the amplitudes for both
are much larger.
1.2
(a)
1
s1 = c(rep(0,100), 10*exp(-(1:100)/20)*cos(2*pi*1:100/4))
x1 = s1 + rnorm(200, 0, 1)
plot.ts(x1)
5
x1
0
−5
Time
(b)
s2 = c(rep(0,100), 10*exp(-(1:100)/200)*cos(2*pi*1:100/4))
x2 = s2 + rnorm(200, 0, 1)
plot.ts(x2)
2
10
5
x2
0
−5
−10
Time
(c)
We found that the modulating function in (b) decays way slower than that of (a) and produces a longer
signal.
1.7
When h = 0, we have
2
γ(t, t) = Cov(wt−1 + 2wt + wt+1 , wt−1 + 2wt + wt+1 ) = E(wt−1 ) + 4E(wt2 ) + E(wt+1
2 2
) = 6σw
3
2
6σw h=0
4σ 2
h=±1
w
γ(t, t + h) = 2
σ w h=±2
0 |h| ≥ 3
1 h=0
2
h=±1
ρ(h) = 3
1
h=±2
6
0 |h| ≥ 3
True ACF
1.0
0.8
0.6
TrueAcf
0.4
0.2
−0.2
0 2 4 6 8
Lag
4
1.8
(a)
x1 = δ + w 1
x2 = 2δ + w1 + w2
x3 = 3δ + w1 + w2 + w3
Pt−1 Pt
If xt−1 = (t − 1)δ + k=1 wk , then xt = δ + xt−1 + wt = tδ + k=1 wk By induction, we have
t
X
xt = tδ + wk
k=1
(b)
t
X
E(xt ) = E(δt + wk ) = δt
k=1
Xs t
X
γ(s, t) = Cov(xs , xt ) = E[(xs − δs)(xt − δt)] = E( wi wj )
i=1 j=1
i=1
(c)
xt is not stationary since the mean function is not constant and the autocovariance function does not depend
on the lag h = |s − t|.
(d)
r
2
(t − 1)σw t−1
ρx (t − 1, t) = p p =
(t − 1)σw2 2
tσw t
q
t−1
When t → ∞, t → 1, which implies that the series will change very slowly as time increasing.