## 2 Methodology
### Weighting Model with C/N0 for the Sun-Pointing Attitude Mode
Research results demonstrate that the estimate of single-antenna attitude systems based on the signal strength measurements is feasible in theory [38]. Therefore, we established a C/N0-based weighting model to accommodate the LEO satellite attitude impact, which can be expressed as follows:  
\[\text{MP}(\text{C/N0})=a+b\cdot\frac{1}{e^{1/(\text{C/N0}-25)^{2}}} \tag{5}\]  
where MP(C/N0) represents the multipath and measurement noise; C/N0 is the carrier-to-noise ratio; \(a\) and \(b\) are coefficients. A secondary benefit of the model is that it au  
Figure 2: Sketch of the onboard GNSS antenna radiation pattern rotation. The red curve denotes the gain variation of signal strength. The rotation yields negative elevation signals and changes the noise characteristics. tomatically extends the weighting model to the low or negative elevation cases. The elevation-dependent function can properly handle the high elevation angle observations but is not always reasonable for the low and negative elevation cases. The C/N0-based weighting model can be built in advance using previous observations and then applied in the real LEO KOD. To build the weighting model, the coefficient \(a\) and \(b\) are obtained with the minimum norm quadratic unbiased estimation (MINQUE) [39]. In the MINQUE method, the carrier-to-noise ratio C/N0 is directly provided by the onboard GNSS receiver. The multipath and measurement noise can be computed with constructing the code-phase linear combination and handling ionosphere and ambiguity [40]. Since the majority of bias terms in the code and phase measurements are the same, thus the code noise can be isolated with the code-phase combination  
\[P_{r}^{s}-L_{r}^{s}\approx 2I_{r}^{s}+\lambda^{s}B_{r}^{s}+\varepsilon_{p}^{s}- \varepsilon_{l}^{s} \tag{6}\]  
where the symbols are defined as above. The carrier phase noise is only about \(1/100\) of the code noise, so the phase noise is ignorable. The ionosphere and ambiguity biases can be handled by the time-difference method. If cycle slips occur, the corresponding code-phase combinations are not considered. In the MINQUE model, the variance-covariance (vc-) matrix of the observations can be expressed as:  
\[Q_{yy}=\sum\limits_{i=1}^{m}\sigma_{i}^{2}Q_{i} \tag{7}\]  
where \(\sigma_{i}^{2}\) is the variance component. The MINQUE method attempts to construct a quadratic form \(y^{T}My\) to estimate the vc-matrix. \(y\) is the observation residual and \(M\) is a matrix to be constructed meeting three conditions: invariant, unbiasness and minimum norm. The three conditions can be equivalently expressed as:  
\[ \begin{split} tr(MA)=0\\ \sigma_{i}^{2}=tr(MQ_{i})\\ tr(MQMQ)=\text{min}\end{split}  \tag{8}\]  
where \(tr(\cdot)\) is the trace operator of a matrix \(Q=\sum\limits_{i=1}^{m}Q_{i}\). The problem can be equivalently converted to a constrained minimum optimization problem and solved with the Lagrange multiplier algorithm. With the matrix \(M\) determined, the variance components can be estimated with a least-squares procedure. The full variance of the OMC observations can be expressed as the sum of the variances of measurement noise, satellite orbit correction, satellite clock offset correction, and prior ionospheric correction. The measurement noise of the pseudorange observation or carrier phase observation is proportional to the square of the pseudorange chip length or carrier phase wavelength [41]. Considering the presumption of much higher precision of phase observations than code observations, the phase multipath and noise can be ignored in the GRAPHIC observation [42]. According to error propagation law, the complete weighting model is as follows:  
\[\left\{ \begin{array}{l}\sigma_{p}^{2}=\sigma_{orb}^{2}+\sigma_{clk}^{2}+ \sigma_{ion}^{2}+\varphi^{2}(\text{C/N0})\\ \sigma_{8}^{2}=\sigma_{orb}^{2}+\sigma_{clk}^{2}+\varphi^{2}(\text{C/N0})/4 \end{array} \right. \tag{9}\]  
where \(\sigma_{orb}^{2}\) and \(\sigma_{clk}^{2}\) are the variance of precise satellite orbit and clock offset correction, respectively.