# New Quality Control Algorithm Based on GNSS Sensing Data for a Bridge Health Monitoring System
## 2 Quality Control Algorithm and Quality Measures
### Quality Control Algorithm Procedure  
#### 2.2.1 Detection  
As mentioned previously, when it is assumed that a systematic error is eliminated from measurements and no outliers exist, the residuals of measurements estimated through least squares estimation converge as a normal distribution, whereas if outliers exist, they are related to the variance estimated from the measurements. The variance, which is estimated from the measurements, including those of the outliers, therefore plays an important role in detecting the outliers. For this process, an F-distribution is used. The F-distribution consists of an a posteriori variance factor and variance ratio of the population (statistic: \(\hat{\sigma}_{0}^{2}/\sigma_{0}^{2}\)). This is also called the global test on the variance factor (_VF_). It is applicable only when the a priori information on the precision of measurement is available and hypothesis testing is applied for the positioning solution, which has been through a previous adjustment. To this end, hypothesis testing is conducted. The relation between the F-distribution and chi-square is as follows:  
\[F_{r,\infty}=\chi_{r}^{2}/r \tag{15}\]  
Null hypothesis \[H_{0}:\sigma_{0}^{2}=\hat{\sigma}_{0v}^{2}\] (16)  
Alternative hypothesis \[H_{a}:\sigma_{0}^{2}\
eq\hat{\sigma}_{0}^{2}\] (17)  
where \(\sigma_{0}^{2}\) is the variance factor and \(\hat{\sigma}_{0}^{2}\) is the a posteriori variance factor. When this test is used for the detection of outliers, it is usually expected that \(\hat{\sigma}_{0}^{2}>\sigma_{0}^{2}\) with regard to most outliers induced by GNSS positioning. Therefore, the null hypothesis test is:  
\[H_{0}:\sigma_{0}^{2}=\hat{\sigma}_{0}^{2}\;\textit{under}\;H_{a}:\sigma_{0}^{ 2}>\hat{\sigma}_{0}^{2} \tag{18}\]  
A one-tailed test is recommended, where:  
\[\frac{\hat{\sigma}_{0}^{2}}{\hat{\sigma}_{0}^{2}}<F_{r,\infty,1-\alpha} \tag{19}\]  
Substituting Equation (19) into Equation (20), we can summarize :  
\[\frac{\hat{\sigma}_{0}^{2}}{\hat{\sigma}_{0}^{2}}=\frac{v^{T}pv}{r\sigma_{0}^{ 2}} \tag{20}\]  
where:  
\[v^{T}C_{l}^{-1}v<rF_{r,\infty,1-\alpha}=\chi_{r,1-\alpha}^{2} \tag{21}\]  
If the variance factor exceeds the test limit (rejection criteria), the adjustment model is considered invalid. The variance factor test may fail because of input or programming errors, and the presence of outliers in the measurements or model errors, or with poor estimation of the a priori covariance matrix. In this study, it is assumed that the variance factor test fails only under the presence of outliers because the variances of the measurements are known. Assuming that outlier \(\
abla l_{i}\) exists, an alternative hypothesis can be written, and the linearized adjustment model may be defined as:  
\[A\hat{x}+e_{i}\
abla l_{i}=l+\hat{v} \tag{22}\]  
where:  
A is the \(n\times m\) design matrix,  
\(\hat{x}\) is the vector of m least squares parameter estimates,  
l is the vector of n measurements,  
\(\hat{v}\) is the vector of n least squares residual estimates and\(e_{i}\) is a unit vector in which the \(i^{th}\) component has a value equal to 1 and dictates the measurement to be tested:  
\[e_{i}=[0\;0\;\dots 1\dots 0] \tag{23}\]  
We can express this by the probability distribution of the observation vector \(l\) as follows:  
\[\text{Null hypothesis }H_{0}:E\left[l|H_{0}\right]=Ax \tag{24}\]  
\[H_{0}:\sigma_{0}^{2}=\hat{\sigma}_{0v}^{2}\]0  
Under the null hypothesis, the expectation of the residuals is 0:  
\[H_{0}:\sigma_{0}^{2}=\hat{\sigma}_{0v}^{2}\]1  
Therefore, the alternative hypothesis is:  
\[H_{0}:\sigma_{0}^{2}=\hat{\sigma}_{0v}^{2}\]2  
The relationship between \(\
abla l\) and \(\
abla v\) from the previous equation is as follows:  
\[H_{0}:\sigma_{0}^{2}=\hat{\sigma}_{0v}^{2}\]3  
In the alternative hypothesis, for measurements containing outliers, the expectation of \(\frac{\partial_{0}^{2}}{\sigma_{0}^{2}}\) can no longer be 1.