-
Notifications
You must be signed in to change notification settings - Fork 0
/
WuleYalker.tex
340 lines (313 loc) · 8.01 KB
/
WuleYalker.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
\documentclass[12pt,letterpaper]{article}
\usepackage{amsmath, amssymb, graphics}
\usepackage{fullpage}
\begin{document}
\section*{Derivation and solution of the ``Wule--Yalker'' equations}
These equations are nothing but the Yule-Walker equations rearranged so that
autocorrelations might be recovered from autoregressive process parameters.
\subsection*{Setting}
The standard AR(p) process is taken as
\[
x_n+a_1x_{n-1}+\dots+a_px_{n-p}=\epsilon _n
\]
in which the \(a_i\) are called the ``parameters" and \(\epsilon _n\sim
N\left(0,\sigma _{\epsilon }{}^2\right)\). By multiplying by \(x_{n-k}\) and
taking the expectation, one arrives at the classical Yule Walker equations:
\begin{align*}
1+a_1\rho ^1+\dots+a_p\rho ^p &= \frac{\sigma_{\epsilon}^2}{\sigma_x^2},
&
k&=0
\\
\rho ^k+a_1\rho ^{k-1}+\dots+a_p\rho ^{k-1}&=0
&
k &> 0
\end{align*}
Here $\rho^i$ denotes the lag $i$ autocorrelation which is symmetric about lag
$0$. These equations are usually solved by a variant of the Levinson-Durbin to
estimate parameters from observed autocorrelations. We want the converse---
computing autocorrelations $\rho^i$ given parameters $a^i$. For $k\geq p$ this
is simple as the latter, iterative relation can be used. However, For $0<k<p$
the equations form a linear system behaving as a ``boundary condition''. Many
authors solve this system explicitly for only $p=1$ and $p=2$ and consider the
matter closed. We seek a systematic way to derive and solve the boundary
condition system, which we call the ``Wule-Yalker'' equations to hint at their
straightforward heritage.
\subsection*{Details}
Several concrete examples of the linear system, derived mechanically using
Mathematica, are now provided. It is nothing but iterating and rearranging the
Yule--Walker $k>0$ relationship considering $\rho ^i$ to be unknown and using
that $\rho^0=1$.
\begin{quote}
\noindent\({\text{Unprotect}[\text{Power}];}\\
{\rho ^{\text{k$\_$}}\text{:=}\rho ^{-k}\text{/;}k<0;}\\
{a_0=1;}\)
\end{quote}
Next come expressions for getting the \(k^{\text{th}}\) equation for given \(p\), collecting all relations for \(1\leq k\leq p\) into a list, extracting
the coefficients on different \(\rho ^i\) terms, obtaining the matrix of coefficients, obtaining the vector of data, and preparing them both for
display.
\begin{quote}
\noindent\({\text{yw}[\text{p$\_$},\text{k$\_$}]\text{:=}\text{Sum}\left[a_i\rho ^{k-i},\{i,0,p\}\right];}\\
{\text{yt}[\text{p$\_$}]\text{:=}\text{Collect}[\text{Table}[\text{yw}[p,k],\{k,1,p\}],\rho ];}\\
{\text{yc}[\text{p$\_$}]\text{:=}\text{PadRight}[\text{CoefficientList}[\text{yt}[p],\rho ]];}\\
{\text{ym}[\text{p$\_$}]\text{:=}\text{Drop}[\text{yc}[p],\text{None},1];}\\
{\text{yd}[\text{p$\_$}]\text{:=}-\text{FullSimplify}[\text{Take}[\text{yc}[p],\text{All},1]];}\\
{\text{yp}[\text{p$\_$}]\text{:=}\text{Thread}[\text{MatrixForm}[\{\text{ym}[p],\text{yd}[p]\}]];}\)
\end{quote}
Examine the matrix of coefficients and vector of data for small \(p\):
\begin{quote}
\noindent\({\text{Do}[}\\
{\text{Print}[\text{$\texttt{"}$p=$\texttt{"}$},p];}\\
{\text{Print}[\text{yp}[p]],\{p,1,8\}}\\
{]}\\
{ }\)
\end{quote}
\[
\begin{bmatrix}
1
\end{bmatrix}
\begin{bmatrix}
\rho^1
\end{bmatrix}
=
\begin{bmatrix}
-a_1
\end{bmatrix}
\]
\[
\begin{bmatrix}
1+a_2 & 0 \\
a_1 & 1
\end{bmatrix}
\begin{bmatrix}
\rho^1 \\
\rho^2
\end{bmatrix}
=
\begin{bmatrix}
-a_1 \\
-a_2
\end{bmatrix}
\]
\[
\begin{bmatrix}
1+a_2 & a_3 & 0 \\
a_1+a_3 & 1 & 0 \\
a_2 & a_1 & 1
\end{bmatrix}
\begin{bmatrix}
\rho^1 \\
\rho^2 \\
\rho^3
\end{bmatrix}
=
\begin{bmatrix}
-a_1 \\
-a_2 \\
-a_3
\end{bmatrix}
\]
\[
\begin{bmatrix}
1+a_2 & a_3 & a_4 & 0 \\
a_1+a_3 & 1+a_4 & 0 & 0 \\
a_2+a_4 & a_1 & 1 & 0 \\
a_3 & a_2 & a_1 & 1
\end{bmatrix}
=
\begin{bmatrix}
\rho^1 \\
\rho^2 \\
\rho^3 \\
\rho^4
\end{bmatrix}
\begin{bmatrix}
-a_1 \\
-a_2 \\
-a_3 \\
-a_4
\end{bmatrix}
\]
\[
\begin{bmatrix}
1+a_2 & a_3 & a_4 & a_5 & 0 \\
a_1+a_3 & 1+a_4 & a_5 & 0 & 0 \\
a_2+a_4 & a_1+a_5 & 1 & 0 & 0 \\
a_3+a_5 & a_2 & a_1 & 1 & 0 \\
a_4 & a_3 & a_2 & a_1 & 1
\end{bmatrix}
\begin{bmatrix}
\rho^1 \\
\rho^2 \\
\rho^3 \\
\rho^4 \\
\rho^5
\end{bmatrix}
=
\begin{bmatrix}
-a_1 \\
-a_2 \\
-a_3 \\
-a_4 \\
-a_5
\end{bmatrix}
\]
\[
\begin{bmatrix}
1+a_2 & a_3 & a_4 & a_5 & a_6 & 0 \\
a_1+a_3 & 1+a_4 & a_5 & a_6 & 0 & 0 \\
a_2+a_4 & a_1+a_5 & 1+a_6 & 0 & 0 & 0 \\
a_3+a_5 & a_2+a_6 & a_1 & 1 & 0 & 0 \\
a_4+a_6 & a_3 & a_2 & a_1 & 1 & 0 \\
a_5 & a_4 & a_3 & a_2 & a_1 & 1
\end{bmatrix}
\begin{bmatrix}
\rho^1 \\
\rho^2 \\
\rho^3 \\
\rho^4 \\
\rho^5 \\
\rho^6
\end{bmatrix}
=
\begin{bmatrix}
-a_1 \\
-a_2 \\
-a_3 \\
-a_4 \\
-a_5 \\
-a_6
\end{bmatrix}
\]
\[
\begin{bmatrix}
1+a_2 & a_3 & a_4 & a_5 & a_6 & a_7 & 0 \\
a_1+a_3 & 1+a_4 & a_5 & a_6 & a_7 & 0 & 0 \\
a_2+a_4 & a_1+a_5 & 1+a_6 & a_7 & 0 & 0 & 0 \\
a_3+a_5 & a_2+a_6 & a_1+a_7 & 1 & 0 & 0 & 0 \\
a_4+a_6 & a_3+a_7 & a_2 & a_1 & 1 & 0 & 0 \\
a_5+a_7 & a_4 & a_3 & a_2 & a_1 & 1 & 0 \\
a_6 & a_5 & a_4 & a_3 & a_2 & a_1 & 1
\end{bmatrix}
\begin{bmatrix}
\rho^1 \\
\rho^2 \\
\rho^3 \\
\rho^4 \\
\rho^5 \\
\rho^6 \\
\rho^7
\end{bmatrix}
=
\begin{bmatrix}
-a_1 \\
-a_2 \\
-a_3 \\
-a_4 \\
-a_5 \\
-a_6 \\
-a_7
\end{bmatrix}
\]
\[
\begin{bmatrix}
1+a_2 & a_3 & a_4 & a_5 & a_6 & a_7 & a_8 & 0 \\
a_1+a_3 & 1+a_4 & a_5 & a_6 & a_7 & a_8 & 0 & 0 \\
a_2+a_4 & a_1+a_5 & 1+a_6 & a_7 & a_8 & 0 & 0 & 0 \\
a_3+a_5 & a_2+a_6 & a_1+a_7 & 1+a_8 & 0 & 0 & 0 & 0 \\
a_4+a_6 & a_3+a_7 & a_2+a_8 & a_1 & 1 & 0 & 0 & 0 \\
a_5+a_7 & a_4+a_8 & a_3 & a_2 & a_1 & 1 & 0 & 0 \\
a_6+a_8 & a_5 & a_4 & a_3 & a_2 & a_1 & 1 & 0 \\
a_7 & a_6 & a_5 & a_4 & a_3 & a_2 & a_1 & 1
\end{bmatrix}
\begin{bmatrix}
\rho^1 \\
\rho^2 \\
\rho^3 \\
\rho^4 \\
\rho^5 \\
\rho^6 \\
\rho^7 \\
\rho^8
\end{bmatrix}
=
\begin{bmatrix}
-a_1 \\
-a_2 \\
-a_3 \\
-a_4 \\
-a_5 \\
-a_6 \\
-a_7 \\
-a_8
\end{bmatrix}
\]
Evidently, the matrices are the sum of two contributions. The first is a
full-rank, unit-lower-triangular Toeplitz matrix. The second is a
rank-deficient Hankel matrix. In the above $p=8$ case, e.g., the decomposition
is
\[
\left(
\begin{bmatrix}
1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\
a_1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 \\
a_2 & a_1 & 1 & 0 & 0 & 0 & 0 & 0 \\
a_3 & a_2 & a_1 & 1 & 0 & 0 & 0 & 0 \\
a_4 & a_3 & a_2 & a_1 & 1 & 0 & 0 & 0 \\
a_5 & a_4 & a_3 & a_2 & a_1 & 1 & 0 & 0 \\
a_6 & a_5 & a_4 & a_3 & a_2 & a_1 & 1 & 0 \\
a_7 & a_6 & a_5 & a_4 & a_3 & a_2 & a_1 & 1
\end{bmatrix}
+
\begin{bmatrix}
a_2 & a_3 & a_4 & a_5 & a_6 & a_7 & a_8 & 0 \\
a_3 & a_4 & a_5 & a_6 & a_7 & a_8 & 0 & 0 \\
a_4 & a_5 & a_6 & a_7 & a_8 & 0 & 0 & 0 \\
a_5 & a_6 & a_7 & a_8 & 0 & 0 & 0 & 0 \\
a_6 & a_7 & a_8 & 0 & 0 & 0 & 0 & 0 \\
a_7 & a_8 & 0 & 0 & 0 & 0 & 0 & 0 \\
a_8 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\
0 & 0 & 0 & 0 & 0 & 0 & 0 & 0
\end{bmatrix}
\right)
\begin{bmatrix}
\rho^1 \\
\rho^2 \\
\rho^3 \\
\rho^4 \\
\rho^5 \\
\rho^6 \\
\rho^7 \\
\rho^8
\end{bmatrix}
=
\begin{bmatrix}
-a_1 \\
-a_2 \\
-a_3 \\
-a_4 \\
-a_5 \\
-a_6 \\
-a_7 \\
-a_8
\end{bmatrix}
.
\]
This special structure is not surprising given that the Yule-Walker system is
symmetric Toeplitz. Gohberg and Koltracht 1989 presented an ``Efficient
Algorithm for Toeplitz Plus Hankel Matrices'' scaling like $5N^2$ operations.
Unfortunately the article details only the case for a real, symmetric sum
stemming from a real, symmetric Toeplitz summand. They hinted that the
non-symmetric algorithm, which we desire, is similar.
\subsection*{TODO}
\begin{enumerate}
\item Actually write the general, closed-form expression for these matrices.
\item Implement Merchant and Parks 1982 to solve the problem.
\end{enumerate}
\subsection*{Comments}
As suggested by Broersen 2006 in ``Automatic Autocorrelation and Spectral
Analysis'' section 5.4, we could obtain the process reflection coefficients
from the parameters and then the autocorrelations from the reflection
coefficients. However, this double Levinson recursion approach appears to be
too numerically unstable to use in practice without requiring $O(n^2)$ memory.
This overhead is admittedly small, but something $O(n)$ would be nicer to have.
\end{document}