# Airborne Quantum Key Distribution Performance Analysis under Supersonic Boundary Layer
## 2 Method
### Photon Scattering under the Boundary Layer  
Given the density field distribution of the boundary layer, the refractive index distribution of the flow field can be calculated by  
\[n=1+K_{GD}\cdot\rho, \tag{1}\]  
where \(\rho\) is the density, and \(n\) is the refractive index of BL. \(K_{GD}\) is the Gladstone-Dale constant with unit of m\({}^{3}\)/kg. \(K_{GD}\) is usually calculated by the empirical formula  
\[K_{GD}=2.23\times 10^{-4}\bigg{(}1+\frac{7.52\times 10^{-3}}{\lambda^{2}}\bigg{)}, \tag{2}\]  
where \(\lambda\) is the wavelength photons with unit of micron. With the settings in Table 1, the G-D coefficient is \(2.237\times 10^{-4}\) m\({}^{3}\)/kg.  
The scattered photon path through the boundary layer can be calculated by ray tracing methods [30]. With the varying refractive index, the boundary layer can be divided into several sufficiently small cube units. And the internal refractive index of each unit \((i,\ j,\ k)\) is uniform which is \(n(i,\ j,\ k)\). Then, the photon will be refracted at the boundary of the two grids, as shown in Figure 2, and the new direction of communication can be calculated by [PERSON] law  
\[\theta_{2}=\arcsin\bigg{[}\frac{n(x_{1},\ y_{1},\ z_{1})\sin(\theta_{1})}{n(x_ {2},\ y_{2},\ z_{2})}\bigg{]}, \tag{3}\]  
where \(n(x_{1},\ y_{1},\ z_{1})\) is the refractive index of unit \((x_{1},\ y_{1},\ z_{1})\), \(\theta_{1}\) is the incident angle, \(\theta_{2}\) is the refraction angle. In the air-to-ground communication scenario, the incident angle \(\theta_{1}\) is equal to zenith angle \(\varphi\) which can be calculated as  
\[\varphi=\arctan\bigg{(}\frac{d}{\hbar\cos\alpha}\bigg{)}. \tag{4}\]  
When the azimuths angle is \(0^{\circ}\), the incident angle \(\theta_{1}=\varphi=\arctan(d/h)\). It is worth noting that when the azimuth angle is \(0^{\circ}\), the incident angle is not \(0^{\circ}\).  
And the new incident angle can be calculated by \(\theta_{2}\) when the photon propagated to the next grid. Then, recording the whole location \((x_{1},\ y_{1},\ z_{1}),\ (x_{2},\ y_{2},\ z_{2})\ldots(x_{n},\ y_{n},\ z_{n})\) by reciprocating the Snell law, the scattered photon path X via the boundary layer can be calculated.  
Then, the wavefront information could be calculated. Optical path length (OPL) is calculated by integrating the refractive index \(n\) along the propagation path X [30].  
\[\text{OPL}=\int_{X}ndx. \tag{5}\]  
And the optical path difference (OPD) is defined as follows,  
\[\text{OPD}=\text{OPL}-\langle\text{OPL}\rangle. \tag{6}\]  
Afterward, assumed that the photon source conforms to the distribution of the Gaussian beam, the normalized intensity of the Gaussian beam can be expressed as  
\[I(r,l)=\frac{2}{\pi\cdot\omega_{LP}}\exp\left(\frac{-2r^{2}}{\omega_{LP}^{2}} \right), \tag{7}\]  
where \(r\) is the radial distance from the center axis of the beam, \(l\) is the axial distance from the beam's focus, and \(\omega_{LP}\) is the effective beam waist of the downlink signal at the ground station [31]  
\[\omega_{\text{LP}}=\sqrt{{\omega_{L}}^{2}+\left({\sigma_{T}}\cdot l\right)^{2 }}. \tag{8}\]  
Here, we assumed that the Transmitter pointing precision \(\sigma_{T}=150\)\(\upmu\)rad that is given in [21]. \(\omega_{L}\) is the beam waist at the Ground station prior to pointing errors:  
\[\omega_{L}=l\frac{\lambda}{\pi\cdot\omega_{0}}\Bigg{[}1+0.83\cdot\sec(\varphi )\left(\frac{D_{T}}{\tau_{0}}\right)^{5/3}\Bigg{]}^{3/5}. \tag{9}\]  
where \(r_{0}=0.4\) m is the Fried parameter in zenith, and \(\varphi\) is zenith angle as shown in Figure 1. \(\omega_{0}\) is the waist radius of the Gaussian beam  
\[\omega_{0}=0.316D_{T}. \tag{10}\]  
The angled brackets denote the spatial average over the optical aperture.  
Figure 2: Two-dimensional schematic diagram of the ray tracing method.