Application of Least Squares with Conditional Equations Method for Railway Track Inventory Using GNSS Observations

Satellite geodetic networks are commonly used in surveying tasks, but they can also be used in mobile surveys. Mobile satellite surveys can be used for trackage inventory, diagnostics and design. The combination of modern technological solutions with the adaptation of research methods known in other fields of science offers an opportunity to acquire highly accurate solutions for railway track inventory. This article presents the effects of work carried out using a mobile surveying platform on which Global Navigation Satellite System (GNSS) receivers were mounted. The satellite observations (surveys) obtained were aligned using one of the methods known from classical land surveying. The records obtained during the surveying campaign on a 246th km railway track section were subjected to alignment. This article provides a description of the surveying campaign necessary to obtain measurement data and a theoretical description of the method employed to align observation results as well as their visualisation.


Introduction
The development of modern rail transport is associated, inter alia, with increasing train speed. This causes specific problems related to railway traffic control, as described, for example, in [1], or with designing fast railway stops as described, for example, in [2]. An increase in train speed requires, primarily, that a high level of rail transport safety should be ensured, which is not possible without well-developed railway infrastructure constructed with the utmost care. Therefore, there is a need

Mobile Surveying Platform
To obtain GNSS surveying data that enable an assessment of the railway track geometry during dynamic surveys (in motion), it was necessary to design and build a mobile surveying platform (MSP). The MSP was conceptualised and developed as part of a research project implemented by the Gdansk University of Technology and Gdynia Maritime University. The mobile surveying platform comprises a railway car ( Figure 1) on which nine mounted guides have been installed to mount  On the surveying platform prepared in this way, any given number of measuring instruments can be installed. During the surveys, the car was connected to a DH-350.11 hydraulic handcar. In this configuration, the test team can configure recorders depending on the type of research for which it is to be used.

Theoretical Basis of the Method of Least Squares with Conditional Equations
In geodetic surveys, there are alignment tasks in which the parameters of the system of observation equations must satisfy additional conditions [41]. In geodetic networks, these conditions may concern the coordinates of certain points being part of a particular network. Such a case occurs when the distance between points is determined with high accuracy, or the conditions between the coordinates result from the geometric structure of the network. Such a case is found in the research problem under consideration, where the position of antennas on the surveying platform are determined from satellite observations as well as from tacheometric surveys conducted prior to the measurement session using satellite measurement techniques. The distances between GNSS receiver antennas were precisely measured prior to commencing dynamic surveys. The geodetic inventory of GNSS antennas was carried out using an electronic total station and the values obtained were adopted as observations determined with high accuracy, which justifies the assumption that they are relatively error-free. Therefore, it follows that the parameters of the observation system (coordinates of GNSS antennas' measuring points on the surveying platform) must satisfy additional conditions, i.e., the distances between GNSS antennas on the MSP. For the cumulative processing of the obtained observations, the Method of Least Squares with conditional equations (LSce) can then be applied. The theory behind the method was discussed in detail inter alia in [42,43]. Its further developments and applications to prepare geodetic observations are discussed inter alia in [41], [44,45]. It should also be noted that conditional equations have also been used in other estimation methods, e.g., in Msplit estimation [46]. The initial tests of the application of LSce to estimate the GNSS receiver antennas' coordinates on surveying platforms were carried out over the test section of tram tracks in the urban agglomeration of Gdansk [47].
Below are the main assumptions and the ways to apply LSce in the context of the surveying platform and the associated observation systems considered in this study. On the surveying platform prepared in this way, any given number of measuring instruments can be installed. During the surveys, the car was connected to a DH-350.11 hydraulic handcar. In this configuration, the test team can configure recorders depending on the type of research for which it is to be used.

Theoretical Basis of the Method of Least Squares with Conditional Equations
In geodetic surveys, there are alignment tasks in which the parameters of the system of observation equations must satisfy additional conditions [41]. In geodetic networks, these conditions may concern the coordinates of certain points being part of a particular network. Such a case occurs when the distance between points is determined with high accuracy, or the conditions between the coordinates result from the geometric structure of the network. Such a case is found in the research problem under consideration, where the position of antennas on the surveying platform are determined from satellite observations as well as from tacheometric surveys conducted prior to the measurement session using satellite measurement techniques. The distances between GNSS receiver antennas were precisely measured prior to commencing dynamic surveys. The geodetic inventory of GNSS antennas was carried out using an electronic total station and the values obtained were adopted as observations determined with high accuracy, which justifies the assumption that they are relatively error-free. Therefore, it follows that the parameters of the observation system (coordinates of GNSS antennas' measuring points on the surveying platform) must satisfy additional conditions, i.e., the distances between GNSS antennas on the MSP. For the cumulative processing of the obtained observations, the Method of Least Squares with conditional equations (LSce) can then be applied. The theory behind the method was discussed in detail inter alia in [42,43]. Its further developments and applications to prepare geodetic observations are discussed inter alia in [41], [44,45]. It should also be noted that conditional equations have also been used in other estimation methods, e.g., in M split estimation [46]. The initial tests of the application of LSce to estimate the GNSS receiver antennas' coordinates on surveying platforms were carried out over the test section of tram tracks in the urban agglomeration of Gdansk [47].
Below are the main assumptions and the ways to apply LSce in the context of the surveying platform and the associated observation systems considered in this study. Let us assume that the coordinates of antennas (x i , y i ), i = 1, 2, · · · , s, on the surveying platform, are contained in the vector X = [x 1 , y 1 , . . . , x s , y s ] T = [X 1 , X 2 , . . . , X r ] T (s-the number of antennas, r-the number of unknown coordinates). Following the previous assumptions about the adopted measurement structure, these quantities must satisfy the following system of conditional equations: For example, if we assume that (x i , y i ) (x j , y j ) are the coordinates of two antennas between which the distance d ij was measured with high accuracy, then in accordance with the general principles of determining geodetic network coordinates, the vector X is determined based on GNSS satellite observations which enable the formulation of the following system of observation equations: where y = [y 1 , y 2 · · · , y n ] T is the observation vector. Using v = [v 1 , v 2 · · · , v n ] T , the vector of random observation errors with the covariance matrix C v = σ 2 0 Q = σ 2 0 P −1 and the vector of expected values E(v) = 0 (Q-known cofactor matrix, P-weight matrix, σ 2 0 -unknown variance coefficient). When we assume that the approximate coordinates X 0 = [X 0 1 , . . . , X 0 r ] T of GNSS receiver antennas are known, then the equation y + v=F(X) can be replaced with a linear observation equation with the following form: The quantity dX is the vector of unknown coordinate increments, such that X = X 0 + dX. The matrix is the design of the system of linear equations, while is the absolute term vector. Let us also assume that the matrix A is a column full rank, i.e., rank(A) = r.
Considering that X = X 0 + dX, the system of observation equations (1) can also be similarly brought to the linear form. After developing the function Ψ(X) to the form the following linear conditional equation is obtained: where: Taking into account the conditions binding the parameters being determined, and the application of the objective function of the least-squares method, it leads to the optimisation of the problem with the following form (e.g., [38]): In order to exactly solve this problem, it is necessary to replace the original objective function ϕ(dX) = v T Pv with the Lagrange function with the following form (e.g., [39]) where κ is the Lagrange's unknown multiplier vector. The optimisation problem minϕ L (dX) = ϕ L (dX) solves such quantities for which the following sufficient conditions are satisfied: Moreover, in the issue under consideration, the necessary condition involving the positive-definite of the second derivative ∂ 2 ϕ L (dX)/∂v∂v T = 2P should be satisfied here. It follows from Equation (8) that If rank(A T PA) = rank(A) = r, then the solution to Equation (10) is vector The correlate vector must satisfy the condition (9). By substituting vector dX described with the dependence (11) to the equation BdX + ∆ = 0, the following is obtained: In practice, task (6) can also be solved in a different way that is simpler from the numerical perspective. To this end, the conditional equation BdX + ∆ = 0 should be replaced with the equivalent observation equation: Since it is required that v * = 0, therefore the vector of fictitious observation errors v * should be assigned such a covariance matrix C v * = σ 2 0 P −1 * so that also fictitious correctionsv * meet the condition v * = 0 (within the calculation precision limits). Thus, task (6) is replaced with the optimisation problem, classical for the LS-method, with the following form: where: Vector v is the total vector of observation errors with the covariance matrix of: where P = diag(P, P * ) is the total weight matrix (σ 2 0 -variance coefficient common for both components of the model (15). The solution to task (14) is the increment estimator dX with the following form: where: By determining the covariance matrix for this estimator, the following is obtained: where: is an estimator of variance coefficient T is a total correction vector determined from the following dependence: The estimator of the GNSS receiver antennas' coordinates is the vector: with the covariance matrix CX = C dX It should be noted that the diagonal elements of this matrix are the squares of mean errors of the determined estimators, i.e., m 2X Considering both presented solutions, the exact one represented by the alignment task (6) with the estimator (11), and the equivalent one represented by the alignment task (14) with the estimator (16) yield the same solutions. Therefore, the equivalent solution that was used in the problem described in this article is more often applied in technical applications.

Practical Applications of GNSS in Railway Surveys and Alignment Results
On 16-17 July 2019, on a route between Tczew-Chojnice-Brusy-Chojnice-Tczew, located in northern Poland, a study was conducted using six Leica GS-18 GNSS receivers ( Figure 2).
Sensors 2020, 20, x 7 of 17 On 16-17 July 2019, on a route between Tczew-Chojnice-Brusy-Chojnice-Tczew, located in northern Poland, a study was conducted using six Leica GS-18 GNSS receivers ( Figure 2). Selected technical data of the receiver are provided in the Table 1.  Selected technical data of the receiver are provided in the Table 1.  To precisely determine the distance between the receiver antennas axes, tacheometric surveys were then conducted using a LEICA TS 1103 total station. The measured distances are provided in Figure 4. Six GNSS receivers were used in the study. Furthermore, 507,251 coordinate surveys were obtained for each receiver from the conducted observations, after rejecting incomplete observations. The data obtained were aligned using the Method of Least Squares with conditional equations.
The observation results were aligned in the flat rectangular coordinate system PL-2000. The system was developed based on the mathematically unique alignment of points on the reference spheroid GRS80 with the corresponding points on the plane, in accordance with the Gauss-Krüger projection theory, and is valid in the territory of the Republic of Poland [48].
Because of the large number of data, the alignment results for only one measurement epoch (marked as 20190717_104340150), conducted in postprocessing, are presented below. The following input data were obtained from satellite observations ( Table 2)  To precisely determine the distance between the receiver antennas axes, tacheometric surveys were then conducted using a LEICA TS 1103 total station. The measured distances are provided in Figure 4.  To precisely determine the distance between the receiver antennas axes, tacheometric surveys were then conducted using a LEICA TS 1103 total station. The measured distances are provided in Figure 4. Six GNSS receivers were used in the study. Furthermore, 507,251 coordinate surveys were obtained for each receiver from the conducted observations, after rejecting incomplete observations. The data obtained were aligned using the Method of Least Squares with conditional equations.
The observation results were aligned in the flat rectangular coordinate system PL-2000. The system was developed based on the mathematically unique alignment of points on the reference spheroid GRS80 with the corresponding points on the plane, in accordance with the Gauss-Krüger projection theory, and is valid in the territory of the Republic of Poland [48].
Because of the large number of data, the alignment results for only one measurement epoch (marked as 20190717_104340150), conducted in postprocessing, are presented below. The following input data were obtained from satellite observations ( Table 2)  Six GNSS receivers were used in the study. Furthermore, 507,251 coordinate surveys were obtained for each receiver from the conducted observations, after rejecting incomplete observations. The data obtained were aligned using the Method of Least Squares with conditional equations.
The observation results were aligned in the flat rectangular coordinate system PL-2000. The system was developed based on the mathematically unique alignment of points on the reference spheroid GRS80 with the corresponding points on the plane, in accordance with the Gauss-Krüger projection theory, and is valid in the territory of the Republic of Poland [48].
Because of the large number of data, the alignment results for only one measurement epoch (marked as 20190717_104340150), conducted in postprocessing, are presented below. The following input data were obtained from satellite observations ( Table 2): • coordinates of GNSS antennas on the MSP, • errors in determining the GNSS antenna position coordinates. The position of antennas on the surveying platform is shown in the Figure 5.  Moreover, for further calculations, the measured distances between antennas ( Figure 4) as well as errors of their determination: 1 3 0.0031 m − = , 1 4 0.0033 m − = , 2 5 0.0034 m − = , 3 6 0.0035 m − = , 4 6 0.0030 m − = , resulting from the total station instrumental errors, were used. In the calculations, the measured distances to three reference stations being part of the SmartNet network [49] were used. The coordinates of the station exposures are provided in the Table 3. The measured data allowed the system of equations comprising 18 observation equations (2) and 5 conditional equations (1) to be recorded. The solution to the alignment task (14) for the data provided above was possible on the assumption that the matrices A  and l  have the following  Table 3. The measured data allowed the system of equations comprising 18 observation equations (2) and 5 conditional equations (1) to be recorded. The solution to the alignment task (14) for the data provided above was possible on the assumption that the matrices A and l have the following forms: By using Equation (16), increments to the coordinates obtained from GNSS observations were obtained, which enable the determination, based on (19), of corrections to the conducted satellite observations; also, by using relationship (20), aligned coordinates of the GNSS antennas' positions were obtained: By using Equation (17) A point position error is a conventional parameter that characterised the accuracy of a point's position following the observation alignment [41]. A geometrical interpretation of the accuracy parameter is a circle with a radius of m i . Even though the point position error is a conventional parameter and has no deeper probabilistic justification, it is very useful in many comparative analyses; therefore, Table 4 presents the percentage of error sizes, for the entire test section, along with the number of points (n) for which their values are present in the intervals (0, 0.001); 0.001, 0.005) ; 0.005, 0.05) ; 0.05, m max . The error values in the 0.05, m max range appear, on average, only in 0.04%. On the other hand, Figure 6 presents the distributions of the values of errors of determining the individual receivers' position coordinates over the entire test section. Table 5 presents the results of statistical analyses of the series of recorded error values. The table provides minimum values, maximum values, sample mean values, confidence intervals for the mean value, variance, standard deviation and the sample size.
The analysis was conducted independently for each of the six GNSS receivers as well as collectively for the entire series of the measured values. The total sample size amounted to 3,043,296. The mean value of the measured error values is in the order of 10 −4 . For the mean value from the sample, confidence intervals with a specified confidence level α = 0.05 were determined, which means that the mean value for the entire error population falls within the specified intervals with a probability of 0.95. It was observed that the confidence intervals were very narrow, i.e., the width of the confidence interval was smaller by two orders of magnitude than the mean value of the sample. This proves that the surveys were conducted very precisely, and the collected data set can be regarded as reliable and credible. This is also confirmed by the very low variance, in the order of 10 −5 . Despite the fact that values higher by as much as four orders of magnitude than the mean value are found in the set; these cases can be considered extremely rare and should be regarded as exceptions or anomalies. These exceptionally high values should be isolated and omitted in further research. Error values of more than 5 cm are primarily found in the urbanised area (Tczew, Chojnice), which is confirmed by Figure 7. The error values in the max 0.05, m range appear, on average, only in 0.04%. On the other hand, Figure 6 presents the distributions of the values of errors of determining the individual receivers' position coordinates over the entire test section.    The analysis was conducted independently for each of the six GNSS receivers as well as collectively for the entire series of the measured values. The total sample size amounted to 3,043,296. The mean value of the measured error values is in the order of 10 −4 . For the mean value from the sample, confidence intervals with a specified confidence level α = 0.05 were determined, which means that the mean value for the entire error population falls within the specified intervals with a probability of 0.95. It was observed that the confidence intervals were very narrow, i.e., the width of the confidence interval was smaller by two orders of magnitude than the mean value of the sample. This proves that the surveys were conducted very precisely, and the collected data set can be regarded as reliable and credible. This is also confirmed by the very low variance, in the order of 10 −5 . Despite the fact that values higher by as much as four orders of magnitude than the mean value are found in the set; these cases can be considered extremely rare and should be regarded as exceptions or anomalies. These exceptionally high values should be isolated and omitted in further research. Error values of more than 5 cm are primarily found in the urbanised area (Tczew, Chojnice), which is confirmed by Figure 7.  Due to the map scale, the coordinates of GNSS antennas faithfully reproduced the route of the surveying set passage. The figure was prepared using the ArcGIS software by ESRI. After zooming in on sections of the passage route, the positions of individual GNSS receiver antennas on any given section of the route can be seen.
For the visualisation provided in Figure 9, orthophotomaps from the GEOPORTAL website [50] were used. The images have a lowered resolution and were taken at a certain angle, which results in minor shifts being visible in the position of receivers in relation to the railway track. Moreover, it can be seen in the figure that the mobile surveying platform moved along the same route in two directions but on different tracks. It should be concluded that the conducted alignment fulfilled its purpose and yielded a very good result for such a large measurement sample implemented in a vast area characterised by various availability of satellites due to the presence of obscuring features (built-up areas, forest areas, an open area). Moreover, the mobile surveying platform moved at different speeds (30-80 km/h), which also affected the continuity of coordinate measurement by GNSS receivers.

Conclusions
The authors adapted the parametric method with conditional equations to align GNSS observations during mobile surveys. The theoretical assumptions of the method were verified using the data from GNSS satellite surveys during the inventory of the railway route of Tczew-Chojnice-Brusy-Chojnice-Tczew in northern Poland.
The 246-km-long test section is located in areas with varying satellite system signal availability (open areas, forest areas and built-up areas). This enabled the suitability of the method to be checked by aligning the observations obtained from GNSS records, which, due to the occurrence of various Due to the map scale, the coordinates of GNSS antennas faithfully reproduced the route of the surveying set passage. The figure was prepared using the ArcGIS software by ESRI. After zooming in on sections of the passage route, the positions of individual GNSS receiver antennas on any given section of the route can be seen.
For the visualisation provided in Figure 9, orthophotomaps from the GEOPORTAL website [50] were used. The images have a lowered resolution and were taken at a certain angle, which results in minor shifts being visible in the position of receivers in relation to the railway track. Moreover, it can be seen in the figure that the mobile surveying platform moved along the same route in two directions but on different tracks. It should be concluded that the conducted alignment fulfilled its purpose and yielded a very good result for such a large measurement sample implemented in a vast area characterised by various availability of satellites due to the presence of obscuring features (built-up areas, forest areas, an open area). Moreover, the mobile surveying platform moved at different speeds (30-80 km/h), which also affected the continuity of coordinate measurement by GNSS receivers. Due to the map scale, the coordinates of GNSS antennas faithfully reproduced the route of the surveying set passage. The figure was prepared using the ArcGIS software by ESRI. After zooming in on sections of the passage route, the positions of individual GNSS receiver antennas on any given section of the route can be seen.
For the visualisation provided in Figure 9, orthophotomaps from the GEOPORTAL website [50] were used. The images have a lowered resolution and were taken at a certain angle, which results in minor shifts being visible in the position of receivers in relation to the railway track. Moreover, it can be seen in the figure that the mobile surveying platform moved along the same route in two directions but on different tracks. It should be concluded that the conducted alignment fulfilled its purpose and yielded a very good result for such a large measurement sample implemented in a vast area characterised by various availability of satellites due to the presence of obscuring features (built-up areas, forest areas, an open area). Moreover, the mobile surveying platform moved at different speeds (30-80 km/h), which also affected the continuity of coordinate measurement by GNSS receivers.

Conclusions
The authors adapted the parametric method with conditional equations to align GNSS observations during mobile surveys. The theoretical assumptions of the method were verified using the data from GNSS satellite surveys during the inventory of the railway route of Tczew-Chojnice-Brusy-Chojnice-Tczew in northern Poland.
The 246-km-long test section is located in areas with varying satellite system signal availability (open areas, forest areas and built-up areas). This enabled the suitability of the method to be checked by aligning the observations obtained from GNSS records, which, due to the occurrence of various

Conclusions
The authors adapted the parametric method with conditional equations to align GNSS observations during mobile surveys. The theoretical assumptions of the method were verified using the data from GNSS satellite surveys during the inventory of the railway route of Tczew-Chojnice-Brusy-Chojnice-Tczew in northern Poland.
The 246-km-long test section is located in areas with varying satellite system signal availability (open areas, forest areas and built-up areas). This enabled the suitability of the method to be checked by aligning the observations obtained from GNSS records, which, due to the occurrence of various field-obscuring features, were characterised by different levels of accuracy and availability of GNSS signal.
The application of the surveying aligning method for satellite observations supported additionally with tacheometric surveys of the position of GNSS receiver antennas on the mobile surveying platform finally enabled the accuracy of the determinations of the antenna position coordinates to be increased and the internally consistent surveying structure to be correctly fitted within the area of measurement performance.
Analysis of the accuracy levels for the final determinations of the antennas' position coordinates demonstrated that the parametric method with conditional equations can be applied in research tasks in which the subject of the study is the internally consistent surveying structure and the obtained observations about the positions of these structures are additionally supported with highly accurate surveys inside the structure under analysis.
The research results described in this article are the next step in checking the suitability of the LSce method in rail transport. Earlier, the authors checked its usefulness on tram tracks [48]. Moreover, the use of the mobile measurement platform is described, for example, in [18][19][20][21]. Previous studies indicate the repeatability of the results and an increase the accuracy of determinations of the position of GNSS receivers' coordinates.
To confirm the possibility for the use of a mobile surveying platform, the authors are preparing to conduct subsequent surveying campaigns on various test sections under different conditions of GNSS signal availability. However, to confirm the universality of the proposed adaptation of the alignment method, testing should be conducted using other vehicles. It will then be possible to fully assess the suitability of the technologies applied and the methods developed for various forms of transport.

Conflicts of Interest:
The authors declare no conflict of interest.