# A Combined Elevation Angle and C/N0 Weighting Method for GNSS PPP on Xiaomi MI8 Smartphones
## 3 Combined Elevation Angle and C/N0 Weighting Method  
Generally, the observation weight matrix \(\mathbf{W}\) can be depicted as [19]:  
\[\mathbf{W}=\text{diag}\Big{(}\sigma_{1}^{-2},\sigma_{2}^{-2},\dots,\sigma_{m}^{- 2}\Big{)} \tag{3}\]  
where \(m\) is the number of observations; \(\sigma^{2}\) is the observation variance, which can be expressed as:  
\[\sigma^{2}=\sigma_{obs}^{2}+\sigma_{eph}^{2}+\sigma_{lon}^{2}+\sigma_{trop}^{2} \tag{4}\]  
where \(\sigma_{obs}^{2}\) is the receiver-related variance term and \(\sigma_{eph}^{2}\), \(\sigma_{lon}^{2}\) and \(\sigma_{trop}^{2}\) are the variances of the satellite orbit and clock error, ionosphere correction model error and troposphere correction model error, respectively. In this study, we mainly focus on the effect of the receiver-related variance term on the observation weight for smartphone-based GNSS positioning. Therefore, the following mentioned observation variance only refers to the receiver-related variance term \(\sigma_{obs}^{2}\). The traditional observation weighting methods for smartphone-based GNSS positioning mainly rely on the elevation angle or C/N0 [20]. The commonly used elevation-angle-dependent weighting model is depicted as [21; 22]:  
\[\sigma_{ele}^{2}=\sigma_{0}^{2}\ /\sin^{2}(ele) \tag{5}\]  
where \(\sigma_{ele}^{2}\) is the observation variance; \(\sigma_{0}^{2}\) is a constant variance value; sin is the sine function and \(ele\) is the satellite elevation angle. A commonly used C/N0 weighting model is expressed as [23; 24]:  
\[\sigma_{C/N0}^{2}=\sigma_{0}^{2}\times 10^{\frac{\text{mr(MAX-C/N0,0)}}{10}} \tag{6}\]  
where \(\sigma_{C/N0}^{2}\) is the observation variance; _max_ is the maximum function and MAX is a preset maximum C/N0. To jointly use the satellite elevation angle and C/N0 information to determine the observation weight, we propose a combined elevation angle and C/N0 weighting method by normalizing the C/N0-derived variances to the scale of the elevation-angle-derived variances. The combined weighting method is established following the steps below. Firstly, the correlation between the satellite elevation angle and the C/N0 at the L1/G1/B1/E1 frequencies is obvious, as analyzed in Section 2. Thus, a second-order  
Figure 5: C/N0 of quad-constellation GNSS against elevation angles at L1/G1/B1/E1 frequencies. polynomial function is employed to fit the C/N0 against the satellite elevation angle, as depicted below:  
\[C/N0\_cal=a+b\times ele+c\times ele^{2} \tag{7}\]  
where \(C/N0\_cal\) is the fitting C/N0 value and \(a\), \(b\) and \(c\) are the fitting coefficients. According to the correlation between the satellite elevation angle and the C/N0 shown in Figure 5, the fitting coefficients of \(a\), \(b\) and \(c\) can be taken as 35.0833 dB-Hz, 0.1365 dB-Hz/\({}^{\circ}\) and \(-0.0005\) dB-Hz/(\({}^{\circ}\))\({}^{2}\), respectively and may be used as empirical values. Secondly, the C/N0-derived variances are converted to the scale of the elevation-angle-derived variances to unify the variance scale of the two indicators. For the L1/G1/B1/E1 signals, the elevation-angle-derived variances are used as the main part to determine the observation weight, while the C/N0-derived variances, after subtracting the fitting-C/N0-derived variances, are used as a supplement for observation weight determination, as depicted in Equation (8). Such a weighting method can respond to the instantaneous variation in observation accuracy and simultaneously avoid obtaining unstable observation weights. For the L5/E5a signals, since the correlation between the CMN and the elevation angle is not obvious, as analyzed in Section 2, only the C/N0-derived variances are used to determine the observation weight. To keep consistent with the observation variances at the L1/G1/B1/E1 frequencies, the C/N0-derived variances are also normalized to the scale of the elevation-angle-derived variances:  
\[\left\{