-
Notifications
You must be signed in to change notification settings - Fork 0
/
sec_psf_formulation_D.tex
475 lines (441 loc) · 23.4 KB
/
sec_psf_formulation_D.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
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
The validity of the approximations in Equations \ref{eqn:lgsotfa},
\ref{eqn:lgsotfb} and \ref{eqn:lgsotfc} to the model in Equation \ref{eqn:lgsotf}
will depend signficantly on the character of the adaptive optics
system, the optical properties of the instrumentation, and the
importance of these terms relative to the degree of anisoplanatism
inherent in the observational scenario. The importance of
anisoplanatism itself depends on many factors: the distribution of the
sources with respect to the laser and tip-tilt guide star, the
turbulence profile, zenith angle, observing wavelength, and aperture
diameter.
\begin{notes}
Should we start to introduce the concept that the on-axis part
comes from the data itself?
\end{notes}
The state of our knowledge regarding $D_{\rm
\phi_{ao}}(\vec{s},\vec{r} + \vec{s})$ and
$D_{\rm \phi_{inst,sci}}(\vec{s},\vec{r} +
\vec{s})$ at Keck Observatory is currently evolving. This
report presents the methodology to compute $D_{\rm
\phi_{apl}}(\vec{s},\vec{r})$. Knowledge of each of
these quantities is necessary to formulate the prediction of
${\rm OTF}^{\rm LGS}_{\rm sci}(\vec{r})$ in Equation \ref{eqn:lgsotf}, or to
utilize the approximations in Equations \ref{eqn:lgsotfa}, \ref{eqn:lgsotfb}
and \ref{eqn:lgsotfc}.
Proceeding along this line of inquiry, the anisoplanatic structure
function may be expressed in terms of the quantities defined in
Equation \ref{eqn:phidefs} as
\begin{equation}\label{eqn:lgsstrfnexpansion}
\begin{split}
D_{\phi_{\rm apl}}(\vec{r}_{1},\vec{r}_{2}) & =
\left\langle \left\{\phi_{\rm apl}\left(\vec{r}_{1}\right) -
\phi_{\rm apl}\left(\vec{r}_{2}\right)\right\}^{2}\right\rangle \\
&
=\left\langle \left\{
\left[\phi_{\rm sci}\left(\vec{r}_{1}\right) - \phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right) -
\phi_{\rm lgs}\left(\vec{r}_{1}\right) + \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right] -
\vphantom{\left\langle\left\{\right\}^{2}\right\rangle}
\right.
\right.
\\
& \quad
\left.
\left.
\left[\phi_{\rm sci}\left(\vec{r}_{2}\right) - \phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right) -
\phi_{\rm lgs}\left(\vec{r}_{2}\right) + \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right]
\right\}^{2}\right\rangle
\end{split}
\end{equation}
This expression may be written as the sum of 36 two-point phase
covariance functions. For example, the term $\left\langle\phi_{\rm
sci}\left(\vec{r}_{1}\right)\phi_{\rm
sci}\left(\vec{r}_{2}\right)\right\rangle$ represents the
piston-removed wavefront phase covariance on the science target.
For the special
case $\vec{r}_{1}=\vec{r}_{2}\equiv\vec{r}$, this
term simplifies to $\left\langle \left\{\phi_{\rm
sci}\left(\vec{r}\right)\right\}^{2}\right\rangle$,
representing the target piston-removed wavefront phase variance as a
function of the pupil plane coordinate $\vec{r}$. As a
concrete example of the utility of this function, we could measure the
piston-removed wavefront phase using a Shack Hartmann sensor and
compute the variance at each subaperture in the pupil plane. The
function $\left\langle\left\{\phi_{\rm
sci}\left(\vec{r}\right)^{2}\right\}\right\rangle$ would represent
the Kolmogorov prediction corresponding to our measurement.
\section{Two-Point Covariance Functions}
\label{sec:covariance}
The key elements required for the prediction of the structure function
in Equation \ref{eqn:lgsstrfnexpansion} and hence the optical transfer
function in Equation \ref{eqn:lgsotfa} are the two-point covariance
functions that appear in Equation \ref{eqn:lgsstrfnexpansion}. The
following three such functions are required to compute the structure
function.
\begin{align}
\left\langle \phi_{a}\left(\vec{r}_{1}\right) \phi_{b}\left(\vec{r}_{2}\right) \right\rangle &\quad\quad\quad {\rm Piston\text{-}removed\;phase\;covariance} \label{eqn:prphase} \\
\left\langle \phi^{T}_{a}\left(\vec{r}_{1}\right) \phi^{T}_{b}\left(\vec{r}_{2}\right) \right\rangle &\quad\quad\quad {\rm Tilt\;phase\;covariance} \label{eqn:tphase} \\
\left\langle \phi_{a}\left(\vec{r}_{1}\right) \phi^{T}_{b}\left(\vec{r}_{2}\right) \right\rangle &\quad\quad\quad {\rm Piston\text{-}removed\;/\;tilt\;cross\;covariance} \label{eqn:tprphase}
\end{align}
In this expression the subscripts $a$ and $b$ label the two sources,
while the vectors $\vec{r}_{1}$ and $\vec{r}_{2}$
represent coordinates in the telescope aperture.
The derivation of these quanitites assuming a Kolmogorov
turbulence spectrum appears in
\cite{Tyler:1994a} and a complementary approach appears in
\cite{Sasiela:2012}.
For completeness, we outline the derivation and
link to specific code implementations within the AIROPA
pacakge in Appendix \ref{app:kolmogorov_deriv}.
Equation \ref{eqn:prphase} represents the two point piston removed
phase covariance function for two sources at arbitrary ranges and
locations within the field. The parameters that enter into the
calculation of this quantity are the wavenumber $k$, aperture diameter
$D$, turbulence profile $C_{n}^{2}(z)$, source ranges
$\mathcal{R}_{a}$ and $\mathcal{R}_{b}$, and their locations
$\vec{r}_{a}$ and $\vec{r}_{b}$ in the field. All of
these parameters are known in a specific observing geometry such as
that shown in Figure \ref{fig:r_vector_schematic} with the exception of the turbulence
profile $C_{n}^{2}(z)$.
On Maunakea, a $C_{n}^{2}(z)$ profile is measured in real-time
using a MASS/DIMM facility and is made available through the Mauna Kea Weather
Center archive\footnote{\url{http://mkwc.ifa.hawaii.edu/current/seeing/}}.
When no real-time profile is available,
a standard $C_{n}^{2}(z)$ profile may be assumed. Likewise,
Equations \ref{eqn:tphase} and \ref{eqn:tprphase} respectively represent
the tilt covariance and piston-removed / tilt phase cross covariance
for two sources at arbitrary ranges and and locations within the
field. These quantities may be computed using the same inputs.
Calculation of these covariance functions requires two numerical
integrations over the unit circle (i.e over $\vec{\rho}_{1}$
and $\vec{\rho}_{2}$). Assuming this integration is performed
using $\mathcal{N}$ samples across the pupil, then computation of
$\left\langle \vphantom{\hat{\phi}_{a}}
\phi_{a}\left(R\vec{\rho}_{1}\right)
\phi_{b}\left(R\vec{\rho}_{2}\right)\right\rangle$ is an
$\mathcal{O}(\mathcal{N}^{4})$ calculation. Recall from Equation
\ref{lgsotf} that calculation of the four dimensional structure
function $D_{\rm apl}\left(\vec{r}_{1},
\vec{r}_{2}\right)$ must be performed for
$\mathcal{O}(\mathcal{N}^{4})$ values of $\vec{r}_{1}$ and
$\vec{r}_{2}$, each of which requires computation of 36
covariance functions. This indicates that computation of the optical
transfer function is an $\mathcal{O}(36\mathcal{N}^{8})$ process.
Such a calculation is not a realistic proposition for general use in
astronomical data reduction.
\section{Computational Formulation}
\label{sec:compcovariance}
The issue of computability of the structure function and OTF has previously been
explored \cite{Tyler:1994} and simplified
expressions have been developed for each of the integrals that appear in Equations
\ref{eqn:prphase}, \ref{eqn:tphase} and \ref{eqn:tprphase}.
AIROPA utilizes the Arroyo atmospheric modeling package developed by M. Britton
\begin{notes}
CITE?,
\end{notes}
which adheres to the Geugenbauer polynomial formalism developed in
Appendix A3 of \cite{Tyler:1994}. The piston
removed phase covariance is given by
\begin{notes}
What happened to the integrals over the pupil ($\rho_1$ and $\rho_2$)? See the
last equations in the appendix.
\end{notes}
\begin{equation}\label{phasecovariance}
\left\langle \phi_{a}\left(R\vec{\rho}_{1}\right) \phi_{b}\left(R\vec{\rho}_{2}\right)\right\rangle =
\Xi D^{5/3} k^{2} \left\{
\mathcal{A}_{ab}\left(\vec{\rho}_{1}\right) +
\mathcal{B}_{ab}\left(\vec{\rho}_{2}\right) -
\mathcal{C}_{ab}\left(\vec{\rho}_{1},\vec{\rho}_{2}\right) -
\mathcal{D}_{ab}\right\}
\end{equation}
and the tilt covariance is given by
\begin{equation}\label{tiltcovariance}
\begin{split}
\left\langle \phi^{T}_{a}\left(R\vec{\rho}_{1}\right) \phi^{T}_{b}\left(R\vec{\rho}_{2}\right)\right\rangle & =
\Xi D^{5/3} k^{2} \left\{
\left[\vec{\rho}_{1} \cdot \vec{\rho}_{2} \right] \mathcal{E}_{ab} +
\mathcal{F}_{ab}\left(\vec{\rho}_{1}, \vec{\rho}_{2}\right)
\right\}
\end{split}
\end{equation}
Finally, the cross covariance is given by
\begin{equation}\label{crosscovariance}
\begin{split}
\left\langle \phi_{a}\left(R\vec{\rho}_{1}\right) \phi^{T}_{b}\left(R\vec{\rho}_{2}\right)\right\rangle & =
\Xi D^{5/3} k^{2} \left\{
\left[\vec{\rho}_{1} \cdot \vec{\rho}_{2} \right] \mathcal{G}_{ab}\left(\vec{\rho}_{1}\right) +
\mathcal{H}_{ab}\left(\vec{\rho}_{1}, \vec{\rho}_{2}\right) +
\mathcal{I}_{ab}\left(\vec{\rho}_{2}\right)
\right\}
\end{split}
\end{equation}
In these expressions, the following definitions have been employed.
\begin{equation}\label{caliph_A}
\mathcal{A}_{ab}\left(\vec{\rho}_{1}\right) =
\int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
\left[Q_{ab}\left(z\right)\right]^{5/3}
F_{1}\left(\frac{\left\vert\vec{\rho}_{1} + \vec{\Omega}_{ab}\left(z\right)\right\vert}{Q_{ab}\left(z\right)}\right)
\end{equation}
\begin{equation}\label{caliph_B}
\mathcal{B}_{ab}\left(\vec{\rho}_{2}\right) =
\int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
F_{1}\left(\left\vert Q_{ab}\left(z\right)\vec{\rho}_{2} + \vec{\Omega}_{ab}\left(z\right)\right\vert\right)
\end{equation}
\begin{equation}\label{caliph_C}
\mathcal{C}_{ab}\left(\vec{\rho}_{1}, \vec{\rho}_{2}\right) =
\int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
\left\vert\vec{\rho}_{1} - Q_{ab}\left(z\right)\vec{\rho}_{2} + \vec{\Omega}_{ab}\left(z\right)\right\vert^{5/3}
\end{equation}
\begin{equation}\label{caliph_D}
\mathcal{D}_{ab} =
\int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
F_{2}\left(Q_{ab}\left(z\right),\left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert\right)
\end{equation}
\begin{equation}\label{caliph_E}
\begin{split}
\mathcal{E}_{ab} =
16 \int_{0}^{\mathcal{R}_{\rm min}} dz & \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
\left[Q_{ab}\left(z\right)\right]^{-3}
\\
& \left\{\int_{0}^{{\rm max}\left(Q_{ab}\left(z\right)-\left\vert \vec{\Omega}_{ab} \left(z\right)\right\vert,0\right)} d\rho \; \rho^{3} \; \hat{G}\left(\rho\right) +
\right.
\\
&
\quad\quad
\frac{1}{\pi} \int^{Q_{ab}\left(z\right)+\left\vert \vec{\Omega}_{ab}\left(z\right)\right\vert}_{\left\vert Q_{ab}\left(z\right)-\left\vert \vec{\Omega}_{ab}\left(z\right)\right\vert\right\vert}
d\rho \; \rho^{3} \; \hat{G}\left(\rho\right) L\left(\left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert, \rho, Q_{ab}\left(z\right)\right) \\
&
\quad\quad\quad\quad
\left.
\sqrt{1 - \left[L\left(\left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert, \rho, Q_{ab}\left(z\right)\right)\right]^{2}}
\vphantom{\int_{0}^{{\rm max}\left(Q_{ab}\left(z\right)-\left\vert \vec{\Omega}_{ab} \left(z\right)\right\vert,0\right)}}
\right\}
\end{split}
\end{equation}
\begin{equation}\label{caliph_F}
\begin{split}
\mathcal{F}_{ab}\left(\vec{\rho}_{1}, \vec{\rho}_{2}\right) =
\frac{32}{\pi}& \int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}
\left[\vec{\rho}_{1} \cdot \vec{\Omega}_{ab}\left(z\right) \right]
\left[\vec{\rho}_{2} \cdot \vec{\Omega}_{ab}\left(z\right) \right] \\
&
\int^{Q_{ab}\left(z\right)+\left\vert \vec{\Omega}_{ab}\left(z\right)\right\vert}_{\left\vert Q_{ab}\left(z\right)-\left\vert \vec{\Omega}_{ab}\left(z\right)\right\vert\right\vert}
d\rho \; \rho^{2} \; \hat{G}\left(\rho\right)
\left[L\left(\left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert, \rho, Q_{ab}\left(z\right)\right) - \frac{\left\vert \vec{\Omega}_{ab}\left(z\right) \right\vert}{\rho}\right]\\
&
\quad\quad\quad\quad\quad\quad
\left[1 - \left[L\left(\left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert, \rho, Q_{ab}\left(z\right)\right)\right]^{2}\right]^{1/2}
\end{split}
\end{equation}
\begin{equation}\label{caliph_G}
\mathcal{G}_{ab}\left(\vec{\rho}_{1}\right) =
4 \int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
\left[Q_{ab}\left(z\right)\right]^{2/3}
\hat{G}\left(\left\vert \frac{\vec{\rho}_{1} + \vec{\Omega}_{ab}\left(z\right)}{Q_{ab}\left(z\right)}\right\vert\right)
\end{equation}
\begin{equation}\label{caliph_H}
\mathcal{H}_{ab}\left(\vec{\rho}_{1}, \vec{\rho}_{2}\right) =
4 \int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
\left[Q_{ab}\left(z\right)\right]^{2/3} \left[\vec{\rho}_{1}\cdot\vec{\Omega}_{ab}\left(z\right)\right]
\hat{G}\left(\left\vert \frac{\vec{\rho}_{2} + \vec{\Omega}_{ab}\left(z\right)}{Q_{ab}\left(z\right)}\right\vert\right)
\end{equation}
\begin{equation}\label{caliph_I}
\begin{split}
\mathcal{I}_{ab}\left(\vec{\rho}_{2}\right) = &
4 \int_{0}^{\mathcal{R}_{\rm min}} dz \; C_{n}^{2}\left(z\right) \left( 1 - \frac{z}{\mathcal{R}_{a}}\right)^{5/3}\;
\frac{\left[\vec{\rho}_{2}\cdot\vec{\Omega}_{ab}\left(z\right)\right] }{\pi \left[Q_{ab}\left(z\right)\right]^{1/3}
\left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert} \\
&
\quad\quad\quad\quad\quad\quad
\int^{Q_{ab}\left(z\right) +\left\vert \vec{\Omega}_{ab}\left(z\right)\right\vert}_{\left\vert Q_{ab}\left(z\right) - \left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert\right\vert}
d\rho \rho^{2} \left\{1 - \left[L\left(\left\vert\vec{\Omega}_{ab}\left(z\right)\right\vert, \rho, Q_{ab}\left(z\right)\right)\right]^{2}\right\}^{1/2}
\hat{G}\left(\rho\right)
\end{split}
\end{equation}
The following definitions have been employed in Equations \ref{caliph_A} - \ref{caliph_H}.
\begin{equation}\label{F_1_eqn}
F_{1}\left(x\right) =
\left\{
\begin{aligned}
\frac{6}{11}\; \vphantom{F}_{2}F_{1}\left(-\frac{11}{6}, -\frac{5}{6};1; x^{2}\right) & \quad x\le 1 \\
x^{5/3}\; \vphantom{F}_{2}F_{1}\left(-\frac{5}{6}, -\frac{5}{6};2; x^{-2}\right) & \quad x>1
\end{aligned}
\right.
\end{equation}
\begin{equation}\label{2_F_2_eqn}
_2F_1(a,b;c;z) = \frac{\Gamma(c)}{\Gamma(a)\Gamma(b)} \sum_{n=0}^{\infty}
\frac{\Gamma(a + n) \Gamma(b + n)}{\Gamma(c + n)} \frac{z^n}{n!}
\end{equation}
\begin{equation}\label{F_2_eqn}
F_{2}\left(\alpha, x\right) = \frac{2}{\pi \alpha^{2}} \int_{0}^{1+\alpha} d\rho K_{1}\left(\rho, \alpha\right)H\left(\rho, x\right)
\end{equation}
\begin{equation}\label{K_1_eqn}
K_{1}\left(\rho,\alpha\right) =
\left\{
\begin{aligned}
&
\pi \alpha^{2} & \left\vert\rho\right\vert \le 1-\alpha \\
&
\begin{split}
\cos^{-1}&\left(t_{0}\right) - t_{0}\sqrt{1-t_{0}} + \\
&\alpha^{2}\left[\cos^{-1}\left(s_{0}/\alpha\right) - \left(s_{0}/\alpha\right)\sqrt{1-\left(s_{0}/\alpha\right)^{2}}\right]
\end{split}
& \quad 1 - \alpha \le \left\vert\rho\right\vert \le 1+\alpha \\
\\
& 0 & {\rm Otherwise}
\end{aligned}
\right.
\end{equation}
\begin{equation}\label{s0_t0_eqn}
\begin{aligned}
s_{0} = \frac{\rho}{2} - \frac{1 - \alpha^{2}}{2\rho} \quad & \quad t_{0} = \frac{\rho}{2} + \frac{1 - \alpha^{2}}{2\rho}
\end{aligned}
\end{equation}
\begin{equation}\label{H_eqn}
H\left(\rho,x\right) =
\left\{
\begin{aligned}
\rho^{8/3} \vphantom{F}_{2}F_{1}\left(-\frac{5}{6}, -\frac{5}{6};1; \left(x/\rho\right)^{2}\right) & \quad x\le \rho \\
\rho x^{5/3} \vphantom{F}_{2}F_{1}\left(-\frac{5}{6}, -\frac{5}{6};1; \left(\rho/x\right)^{2}\right) & \quad x > \rho
\end{aligned}
\right.
\end{equation}
\begin{equation}\label{G_hat_eqn}
\hat{G}\left(\alpha\right) =
\left\{
\begin{aligned}
-\frac{5}{11} \vphantom{F}_{2}F_{1}\left(-\frac{11}{6}, \frac{1}{6};2; \alpha^{2}\right) & \quad \alpha\le 1 \\
-\frac{5}{12} \alpha^{-1/3} \vphantom{F}_{2}F_{1}\left(-\frac{5}{6}, \frac{1}{6};3; \alpha^{-2}\right) & \quad \alpha > 1
\end{aligned}
\right.
\end{equation}
\begin{equation}
L\left(a, b, c\right) = \frac{a^{2} + b^{2} - c^{2}}{2 a b}
\end{equation}
The above expressions appear complex, but provide significant
computational advantage over Equation \ref{eqn:prphase}. The
calculation of Equations \ref{caliph_A} - \ref{caliph_I} require at
most the calculation of a one dimensional integral over
$C_{n}^{2}(z)$, a one dimensional integral over another variable, and
computation of a hypergeometric function. The latter computation is
easily terminated when contributions of successive hypergeometric
terms fall below a fixed precision. This is vastly more
computationally efficient than the $\mathcal{O}(\mathcal{N}^{4})$
calculation required to compute Equations \ref{eqn:prphase} -
\ref{eqn:tprphase} directly.
The form of Equations \ref{phasecovariance} - \ref{crosscovariance}
permit further computational advantages. Six of the nine expressions
display a reduced dependence on $\vec{\rho}_{1}$ and/or
$\vec{\rho}_{2}$, and may be precomputed and stored for use in
computing the covariance functions over the pupil plane.
In laser guide star adaptive optics systems, one is interested in
computing the field dependent target optical transfer function
${\rm OTF}_{\rm sci}\left(\vec{r}\right)$ assuming fixed locations of
the tip tilt and laser guide stars and for a specific turbulence
profile. For example, if one was interested in modelling a crowded
field imaged by a science camera, one would wish to compute ${\rm OTF}_{\rm
sci}\left(\vec{r}\right)$ at many locations within the field
of view. In such an application, one would precompute the piston
removed phase and tilt covariance functions involving the laser and
tip tilt star that appear in Equation \ref{lgsstrfnexpansion}. One
would then iterate over locations in the field, computing only the
terms in in Equation \ref{lgsstrfnexpansion} that depend on target
location.
\section{Anisoplanatic Structure Function}
\label{sec:strfn}
%\phi_{\rm sci}\left(\vec{r}\right)
%\phi^{T}_{\rm sci}\left(\vec{r}\right)
%\phi^{T}_{\rm ttgs}\left(\vec{r}\right)
%\phi_{\rm lgs}\left(\vec{r}\right)
%\phi^{T}_{\rm lgs}\left(\vec{r}\right)
For computational purposes it is useful to explicitly expand the
structure function in Equation \ref{lgsstrfnexpansion} and group like
terms, yielding
\begin{equation}\label{strfn_x}
\small
\begin{aligned}
D_{\phi_{\rm apl}}&(\vec{r}_{1}, \vec{r}_{2}) =
\\ &
\left\langle\left\{\phi_{\rm sci}\left(\vec{r}_{1}\right)\right\}^{2}\right\rangle +
\left\langle\left\{\phi_{\rm sci}\left(\vec{r}_{2}\right)\right\}^{2}\right\rangle -
2\left\langle\phi_{\rm sci}\left(\vec{r}_{1}\right) \phi_{\rm sci}\left(\vec{r}_{2}\right)\right\rangle +
\\ &
\left\langle\left\{\phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right)\right\}^{2}\right\rangle +
\left\langle\left\{\phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right) \right\}^{2}\right\rangle -
2\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right) \phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right)\right\rangle +
\\ &
\left\langle\left\{ \phi_{\rm lgs}\left(\vec{r}_{1}\right)\right\}^{2}\right\rangle +
\left\langle\left\{ \phi_{\rm lgs}\left(\vec{r}_{2}\right)\right\}^{2}\right\rangle -
2\left\langle\phi_{\rm lgs}\left(\vec{r}_{1}\right) \phi_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\\ &
\left\langle\left\{ \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right\}^{2}\right\rangle +
\left\langle\left\{ \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\}^{2}\right\rangle -
2\left\langle\phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\\ &
2\left[-\left\langle\phi_{\rm sci}\left(\vec{r}_{1}\right) \phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right)\right\rangle +
\left\langle\phi_{\rm sci}\left(\vec{r}_{2}\right) \phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi_{\rm sci}\left(\vec{r}_{1}\right) \phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi_{\rm sci}\left(\vec{r}_{2}\right) \phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right)\right\rangle\right] +
\\ &
2\left[-\left\langle\phi_{\rm sci}\left(\vec{r}_{1}\right) \phi_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle +
\left\langle\phi_{\rm sci}\left(\vec{r}_{2}\right) \phi_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi_{\rm sci}\left(\vec{r}_{1}\right) \phi_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi_{\rm sci}\left(\vec{r}_{2}\right) \phi_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle\right] +
\\ &
2\left[\left\langle\phi_{\rm sci}\left(\vec{r}_{1}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle -
\left\langle\phi_{\rm sci}\left(\vec{r}_{2}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle -
\left\langle\phi_{\rm sci}\left(\vec{r}_{1}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle -
\left\langle\phi_{\rm sci}\left(\vec{r}_{2}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle\right] +
\\ &
2\left[\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right) \phi_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle -
\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right) \phi_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle -
\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right) \phi_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle -
\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right) \phi_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle\right] +
\\ &
2\left[-\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle +
\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{1}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi^{T}_{\rm ttgs}\left(\vec{r}_{2}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle\right] +
\\ &
2\left[-\left\langle\phi_{\rm lgs}\left(\vec{r}_{1}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle +
\left\langle\phi_{\rm lgs}\left(\vec{r}_{2}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi_{\rm lgs}\left(\vec{r}_{1}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{2}\right)\right\rangle +
\left\langle\phi_{\rm lgs}\left(\vec{r}_{2}\right) \phi^{T}_{\rm lgs}\left(\vec{r}_{1}\right)\right\rangle\right]
\end{aligned}
\end{equation}
This equation naturally lends itself to a C++ programming interface in
which a phase covariance function such as $\left\langle\phi^{T}_{\rm
ttgs}\left(\vec{r}_{1}\right) \phi^{T}_{\rm
ttgs}\left(\vec{r}_{2}\right)\right\rangle$ is represented as
an instance of a class {\bf phase\_covariance}, with a member function
\\
\indent {\bf double phase\_covariance::covariance(vec r\_1, vec r\_2)}
\\
The class instance may store partial calculations specific to the
source location, aperture diameter, and $C_{n}^{2}$ profile. For
example, the value of $\mathcal{D}_{ab}$ may be computed at
instantiation, while the values of $\mathcal{A}_{ab}\left(\rho\right)$
and $\mathcal{B}_{ab}\left(\rho\right)$ may be computed as a function
of $\rho$ upon first invocation of the above member function.
Likewise, classes {\bf tilt\_covariance} and {\bf phase\_tilt\_covariance}
may represent the other types of covariance functions in Equation
\ref{strfn_x}.
%\section{Example: Differential Phase Variance}
%\label{sec:variance}
%\begin{equation}\label{uncomp_variance_eqn}
%\end{equation}
%\begin{equation}\label{uncomp_tr_variance_eqn}
%\end{equation}
%\begin{equation}\label{ngs_variance_eqn}
%\end{equation}
%\begin{equation}\label{ngs_tr_variance_eqn}
%\end{equation}
%\begin{equation}\label{lgs_variance_eqn}
%\end{equation}
%\begin{equation}\label{lgs_tr_variance_eqn}
%\end{equation}
%\section{Example: Structure Functions}
%\label{sec:strfn}
%\section{Example: Point Spread Functions}
%\label{sec:psf}
%\section{IDL Bindings}
%\label{sec:idl}