Characterization of Degenerate Configurations in Attitude Determination of Three-Vehicle Heterogeneous Formations

The existence of multiple solutions to an attitude determination problem impacts the design of estimation schemes, potentially increasing the errors by a significant value. It is therefore essential to identify such cases in any attitude problem. In this paper, the cases where multiple attitudes satisfy all constraints of a three-vehicle heterogeneous formation are identified. In the formation considered herein, the vehicles measure inertial references and relative line-of-sight vectors. Nonetheless, the line of sight between two elements of the formation is restricted, and these elements are denoted as deputies. The attitude determination problem is characterized relative to the number of solutions associated with each configuration of the formation. There are degenerate and ambiguous configurations that result in infinite or exactly two solutions, respectively. Otherwise, the problem has a unique solution. The degenerate configurations require some collinearity between independent measurements, whereas the ambiguous configurations result from symmetries in the formation measurements. The conditions which define all such configurations are determined in this work. Furthermore, the ambiguous subset of configurations is geometrically interpreted resorting to the planes defined by specific measurements. This subset is also shown to be a zero-measure subset of all possible configurations. Finally, a maneuver is simulated to illustrate and validate the conclusions. As a result of this analysis, it is concluded that, in general, the problem has one attitude solution. Nonetheless, there are configurations with two or infinite solutions, which are identified in this work.


Introduction
Attitude determination is the computation of the angular relation between different frames in a given moment. Information about attitude serves a critical role in autonomous navigation of any system. It has been well studied since the dawn of spacecraft technology, when one of the most recognized methods, the Tri-Axial Attitude Determination (TRIAD) algorithm, was developed [1]. This algorithm constructs two triads of orthonormal reference and observation vectors from two non-collinear vector references and observations, which are related by a unique orthogonal matrix. Shortly after, Wahba formulated an optimization problem combining several measurements into a cost function [2]. This problem has remained central in attitude determination, hence many methods for its solution exist. A widely known and employed solution is the Quaternion Estimator (QUEST) algorithm [3], which makes use of the quaternion representation of a rotation matrix. Moreover, there are more recent approaches, such as the fast linear quaternion attitude estimator (FLAE), which can reduce the computational time while having similar accuracy to other methods, as described in [4]. As the variety of applications for autonomous systems expanded, the interest in vehicle formations has grown, because of their potential to solve complex problems this framework can be applied is in chained leader-follower constellations, where each spacecraft only has line of sight relative to its nearest neighbor. In all these, the advantage of the formation in [13] is that it does not require line of sight measurements between the furthermost vehicles to solve the attitude determination problem.
The contributions of this work include the full characterization of all the configurations for which there is more than one set of attitudes that satisfy all the constraints imposed by the measurements. In addition, an intuitive geometric reasoning is given for the different cases. Hence, this paper improves the special configurations' description in [17], which was based on the analysis of the solution equations. The new results not only provide a full insight to the geometry of the problem, but also include a proof for each of the conclusions. First, the analysis focus on just two of the vehicles of the formation. Their relative and inertial attitudes are shown to have either one, two, or infinite solutions and the specific conditions for each outcome are specified. The cases with a unique solution are related to the problems in [9,11], whereas the cases with infinite solutions correspond to a loss of information in the measurement set. Then, the whole formation is shown to have either one, two, or infinite solutions. Again, the respective configurations are specified. Moreover, the cases with two solutions result from information symmetries and, as before, infinite solutions relate to information loss. Finally, the ambiguous configurations' subset is shown to be a zero-measure subset, while the simulations show that the neighborhood of such cases is important as well, due to possible estimation errors.
This paper is organized as follows. First, recurrent notation, definitions and properties are described. Then, in Section 3, the problem and respective solution, from [13], are summarized. Section 4 initially characterizes the number of solutions for the relative and inertial attitudes with the measurements from two of the vehicles. Then, it analyzes the number of solutions for the entire formation. The distinction between the general case and some ambiguous configurations requires the analysis of the symmetry of the whole formation, which provides an extra condition for the existence of two solutions. At the end of the section, the geometric intuition for such cases is shown, followed by the proof that these ambiguous configurations are a zero measure subset. Section 5 shows a simulation of a simple maneuver which illustrates and validates the conclusions in this paper. Finally, Section 6 summarizes and comments the results obtained in this work.

Notation, Definitions, and Properties
Throughout this document, scalars are represented in regular typeface, whereas vectors and matrices are represented in bold, with the latter in capital case. Reference frames are represented in calligraphic typeface and between brackets, such as {I}. Body-fixed frames are numbered and represented by the letter B, with the respective number as a subscript. The symbol 0 represents the null vector or matrix and I represents the identity matrix with the appropriate dimensions. The four-quadrant inverse tangent function is denoted by atan2(b, a), with a, b ∈ R. The set of unit vectors in R 3 is denoted by S(2) := x ∈ R 3 : x = 1 . The special orthogonal group of dimension 3, which describes proper rotations, is denoted by SO(3) := {X ∈ R 3×3 : XX T = X T X = I ∧ det(X) = 1}. The skew-symmetric matrix parameterized by x ∈ R 3 , which encodes the cross product between x and another vector, is denoted by The rotation matrix in SO(3) that transforms a given vector, in R 3 , expressed in {B i } to {B j }, i, j ∈ N 0 , is denoted by R j i . If a frame is not body-fixed, the respective letter is used instead. Moreover, multiple candidates for the same quantity are identified by a subscript capital case letter, such as R j i A . The rotation matrix of an angle θ ∈ R about the axis described by the unit vector x ∈ S(2) is denoted by R(θ, x), which is written, recalling (1), as [18] R(θ, x) := cos(θ)I + (1 − cos(θ))x x T − sin(θ)S(x).

Problem Definition
Consider a formation with three vehicles, where {B 1 }, {B 2 }, and {B 3 } are the bodyfixed frames of the respective vehicles and {I} represents the inertial frame. In the proposed framework, there are two kinds of measurements: one is a LOS vector that points to the position of another vehicle and the other is an inertial reference vector, for example, a known physical field direction. All measurements are unit vectors obtained in the respective body-fixed frame. Moreover, the inertial references are known in the inertial frame.
In the formation, the main constraint is that two of the vehicles, called the deputies, cannot measure LOS vectors between them. Meaning, for example, that these two vehicles are too far from each other. Furthermore, each vehicle can measure one inertial vector independently. The vehicle that measures LOS to the other two is identified as vehicle 1 and is denominated as chief, whereas the deputies are identified as vehicles 2 and 3. The subgroup with the chief and a deputy is called a branch of the formation, hence there are two branches in this case. The branch 1-2 includes the chief and vehicle 2, whereas branch 1-3 includes the chief and vehicle 3. The geometry of the framework is represented in Figure 1. In the figure and throughout this document, d i/j , i, j = 1, 2, 3, i = j, represents the LOS vector from the i-th to the j-th vehicles, expressed in {B i }, and d i , i = 1, 2, 3, represents the inertial vector measured by the i-th platform, expressed in {B i }. A left superscript specifying the frame is used whenever a vector is expressed in a different frame. For example, I d i , i = 1, 2, 3, is the inertial vector of the i-th vehicle, expressed in {I}.
The problem that is here considered is that of determining all the rotation matrices, both relative (R 1 2 , R 1 3 , R 2 3 ) and inertial (R I 1 , R I 2 , R I 3 ), using the measurement vectors that were described, as well as the references I d 1 , I d 2 , and I d 3 .

Solution
The solution proposed in [13] resorts to multiple stages, as represented in Figure 2. First, the candidates for R 1 2 and R 1 3 are determined. Afterwards, these are used to obtain the candidates for R I 1 . Since computing R I 1 using either R 1 2 or R 1 3 is equivalent, then it is possible to disambiguate the problem. Therefore, a comparison between the candidates for R I 1 is carried out. Finally, the remaining matrices are found from the disambiguated solutions for R 1 2 , R 1 3 , and R I 1 . A more detailed algorithm flowchart can be found in [13].

Relative Attitude
In this section, the solution for the candidates of R 1 2 is provided. The solution for R 1 where X 2 is substituted by the candidate reference A or B, and X 3 is substituted by the candidate reference C or D. In conclusion, the inertial attitude candidate for R I 1 is given by R I 1 X i = R θ X i , I d 1 R * , where X i represents the candidate reference A, B, C, or D, accordingly, and θ X i is defined by the corresponding expression of (17). For example, consider candidate A. Then, R I 1 A = R θ A , I d 1 R * , with θ A obtained from substituting the relative attitude candidate R 1 2 A in (17a). Since these results are analogous to the relative attitude solution in [13], the proof is omitted.

Comparison
To compare the candidates for R I 1 , from different branches, consider the parameter defined by where R I 1 X and R I 1 Y represent two different candidates. This parameter is based on the dependence of the rotation matrix trace and its angle of rotation. Thus, φ is zero when both candidates are equal, which enables the disambiguation.

Complete Solution
The remaining attitude matrices, that is R 2 3 , R I 2 , and R I 3 , are obtained from a product between the attitudes already determined, see [13] for further details.

Sensor Errors
In the presence of sensor errors, the comparison between the inertial candidates is imperfect, hence the values of φ are, in general, different from zero. In that case, the solution is given by the smallest φ. Optionally, the pair of candidates with the lowest value of φ are averaged using the singular value decomposition (SVD) to obtain an improved estimate for R I 1 . Nonetheless, if there are multiple values of φ close to zero, the minimum may not correspond to the correct solution. The characterization of the problem given in this work identifies the configurations where such situation may happen.

Computational Complexity
This algorithm is based on a small number of measurements and their operations are relatively simple. Computationally, the operation which is more costly is the SVD that is performed to find a mean rotation, however this operation is optional. Moreover, there are computationally efficient algorithms to perform the SVD of 3 × 3 matrices.

Characterization
This section analyzes the relation between each possible configuration of the formation and the respective number of attitude solutions. If there is no other information, any attitude set that satisfies all the constraints is considered a solution for the problem. Therefore, it is important to understand which configurations result in more than one solution, otherwise there may be large errors, or even divergence from the correct attitude, in the design of estimators. Thus, these configurations are properly identified in the sequel.
In general, there is only one attitude set which satisfies the constraints for a given configuration. However, there are degenerate configurations, where there are infinitely many attitudes which verify all the constraints. Furthermore, there are ambiguous configurations, where there are exactly two possible attitude sets that satisfy all the constraints.
The degenerate configurations are generated by a set of constraints with an incomplete amount of information, which result in, at least, an extra degree of freedom for the system. Likewise, some ambiguous configurations result from a measurement set with poor quality. Nonetheless, these configurations are usually the result of symmetric information in both branches of the formation, which in turn results in identical pairs of candidates for R I 1 . The analysis is divided into three parts. First, a branch analysis investigates the constraints used in the branch 1-2 to find the solutions of R 1 2 and R I 1 . Then, it identifies the conditions which lead to degenerate, ambiguous, and unambiguous branches, respectively, with infinite, two, or one solution. Analogous conclusions are taken relative to the branch 1-3. Afterwards, a formation analysis investigates the various conditions found in the branch analysis and connects them to the number of solutions for the entire formation. Finally, a symmetry analysis is required to find ambiguous configurations which are not determined by the number of solutions of the branches. This analysis explores the problem symmetry to find conditions for the ambiguous configurations. Such configurations are explained geometrically and the respective set is shown to be a zero measure subset of all possible configurations. Lastly, the results of this section are discussed and compared with related work.

Branch Analysis
The analysis of a single branch, which includes only two vehicles, hints at the possible number of solutions for the overall formation. The number of candidates in a branch is either one, two, or infinite. Therefore, a branch can be classified as either unambiguous, ambiguous, or degenerate, respectively. Consider the solutions for R 1 2 and R I 1 using measurements from branch 1-2. The ensuing results and conclusions are analogously applicable to the branch 1-3, due to the symmetry of the problem.
First, consider the solution for R 1 2 given by the parameters from (10) and (11). Since this solution relies on the constraints given in (9a) and (9b), then the degenerate and unambiguous branch configurations are a result of how much information is encoded in these constraints.
The basic idea behind the different number of solutions is that having collinear independent measurements translates into information loss, because one of the axes is not constrained. Moreover, in this case, the coplanarity of the independent vectors eliminates the inherent ambiguity of the branch. In (9a) and (9b), there are three independent vectors, hence two collinear relations are possible: The effects of each of these conditions are explored before showing the different number of solutions for R 1 2 . Assume that the former relation, i.e., d 1 = ±d 1/2 , is true. It follows, from (8), (10) and (11), that the constraint (9b) can be rewritten as or, equivalently, from (4), 1 2 , as defined in (8), satisfies both (9a) and (9b), with any θ 2 ∈ R. Moreover, recall (15), (16) and (17a). Since, by definition, I d 1 = R * d 1 , then (6) implies that Then, substituting (8) and (19) in the constraint (14b) yields which, recalling the assumption d 1 = ±d 1/2 , can be written as It follows that, R I 1 , as expressed in (19), satisfies both (14a) and (14b) with any θ X 2 ∈ R, because θ 2 is arbitrary.
Assume instead that d 2 = ±d 2/1 . Then, recalling (9a), the constraint (9b) can be rewritten as Consequently, since R(θ 1 , n 1 ) satisfies (9a), which can be verified by substituting R 1 2 by R(θ 1 , n 1 ) in (9a), it follows that R 1 2 , as expressed in (8), satisfies both (9a) and (9b) with any θ 2 ∈ R. Additionally, substituting (8) in (14b) gives Since R(θ 1 , n 1 ) satisfies (9a), then applying the assumption d 2 = ±d 2/1 gives which, from (4), results in Hence, if d 1 = ±d 1/2 and I d 1 = ± I d 2 , there is a unique value for R I 1 that satisfies both (14a) and (14b), because the second constraint becomes independent of R 1 2 . The intuition given before provides some conditions which affect the information encoded in the constraints. However, the connection between the number of solutions and a set of conditions for the measurements relies on the expressions used for the solution. Therefore, the next lemma addresses the relation between the collinear conditions, considered above, and particular values of the coefficients c s 12 and c c 12 , as defined in (12), which are related to special cases of the solution. It establishes the logical connection used to relate the degenerate cases to an infinite number of solutions for R 1 2 . Since this is a technical result, the respective proof is given in Appendix B.
Lemma 1. Consider c s 12 and c c 12 as defined in (12). Then, both c s 12 = 0 and c c 12 = 0 if and only if either Knowing the conditions associated with c s 12 = 0 and c c 12 = 0 allows to find the degenerate configurations, because that is the only case for which the expressions that result in R 1 2 A and R 1 2 B are not defined. Furthermore, from (8), with the respective parameters given in (10) and (11), it follows that the ambiguity, which yields two candidates, is encoded in the angle θ 2 , as is evidenced in (11a). Inspecting such expression leads to the conclusion that there are cases with only one solution for θ 2 , namely, when arccos   c p 12 with k ∈ Z. The next theorem addresses all possible numbers of solutions for R 1 2 , considering the measurements of branch 1-2.
Proof. This proof is divided into three parts: (i) Consider that (24a) or (24b) are verified. Then, [13] (Lemma 3) ensures that there are infinite solutions for R 1 2 . Otherwise, consider that neither (24a) nor (24b) are verified. Then, it follows from Lemma 1 that either c s 12 = 0 or c c 12 = 0, or both. In any case, (8)- (13) are all well-defined and there are, at most, two solutions for R 1 2 , i.e., a finite number of solutions. By contra-position, if there are infinite solutions for R 1 2 , either (24a) or (24b) must be satisfied, thus completing the first part of the proof.
(ii) Assume that neither (24a) nor (24b) are verified, then atan2(c s 12 , c c 12 ) is always defined. Since (2) is periodic relative to the angle, with period 2π, it is concluded, from (11a), that R 1 2 has a unique solution if and only if It follows that (26) is equivalent to c s 12 cos(θ 2 ) = c c 12 sin(θ 2 ). Then, expanding the coefficients by applying (12) and introducing Recall (2) and (13). Then, (27) is equivalent to (25). (iii) All other cases result in two solutions for R 1 2 , because they yield two distinct values for θ 2 , considering their representation in the same 2π interval, as concluded from the inspection of (11a). Hence, the proof is complete.

Remark 1.
In short, the first condition, for infinite solutions, is verified when the measurements of one vehicle are collinear. Moreover, there is a unique solution if the involved vectors, given in the same reference frame, are coplanar, but not collinear as in the first case. Otherwise there are two solutions.
The problems described in [9,11] consider coplanar vectors, which means that (23) is satisfied. Thus, those problems have only one solution in general. Note that the case with a coplanar vector configuration is a particular case of the general problem addressed in the relative attitude solution of the branch. Thus, the information of a second branch is required to disambiguate the solutions.
Finally, consider the solution for R I 1 , with the information available within the branch 1-2. The constraints (14a) and (14b) involve only two independent vectors, and therefore, there is only one possible collinearity condition, which is given by I d 1 = ± I d 2 . Applying such condition in (14b) yields Therefore, R I 1 = R * R θ X 2 , d 1 satisfies (14b) for any θ X 2 ∈ R. Furthermore, this condition influences the solution of R 1 2 , because it implies that (25) is satisfied. Therefore, if none of the expressions in (24) are verified, there is an unambiguous solution for R 1 2 . As before, to evaluate the number of solutions for R I 1 , the expressions which give such attitude must be considered. Hence, recall that (15), with (16)  In every other case, each relative attitude candidate generates an inertial attitude candidate, because the two independent vectors involved are coplanar by definition, and therefore, satisfy the analogous of (25). The unambiguous character of this solution is expressed by (15)- (17). In such conditions, the number of inertial candidates is the same as the number of relative attitude candidates.

Formation Analysis
The attitude solution for the entire formation results from the fusion of information between both branches. Therefore, the number of attitude solutions of each branch directly influences the number of solutions for the formation.
Recall the nomenclature used to characterize each branch relative to the number of candidates it provides, that is, the branch is degenerate, ambiguous, or unambiguous, respectively, if it has infinite, two, or one solution. Table 1 shows possible combinations of branches configurations and gives the respective number of solutions for the whole formation. Multiple degenerate conditions for each branch can be verified simultaneously, but this analysis, and this table, considers that only one of them, for each branch, is verified at each moment.

Configurations with Infinite Solutions
The conditions which result in infinite solutions for the entire formation require that at least one branch is degenerate, which is expressed in Table 1. All such cases are described below, alongside some details that support the conclusions.
In the cases where both branches are degenerate, all conditions in (14) are satisfied by R I 1 = R * R(θ X , d 1 ), with any θ X ∈ R. Therefore, there are infinite attitude solutions for the problem.
In the case that d 2 = ±d 2/1 , (21) and (22) imply that the only constraint which depends on R 1 2 is (9a), and therefore, there are infinite solutions for R 1 2 even if the opposite branch gives a unique candidate for R I 1 and R 1 3 . The same conclusion is analogously applicable to the case with d 3 = ±d 3/1 .

Configurations with Two Solutions
The conditions which result in two solutions for the entire formation require that at least one branch is ambiguous, as expressed in Table 1. All such cases are described below, alongside some details that support the conclusions.
Consider the case where one branch is ambiguous and the other is degenerate. First, assume that d 1 = ±d 1/2 while the branch 1-3 is ambiguous. In this case, if R I 1 is known, then (20) provides a second constraint to R 1 2 . Hence, the two different candidates for R I 1 , that emerge from branch 1-3, can be used in (20) to find two candidates for R 1 2 . The result is a set of two solutions for the entire formation. Assume instead that I d 1 = ± I d 2 while the branch 1-3 is ambiguous. Since (28) implies that (25) is satisfied, then there is a unique solution for R 1 2 . Therefore, there are two solutions for the formation attitude, because branch 1-3 is ambiguous, which means it gives two candidates for both R I 1 and R 1 3 . The same conclusions arise when considering that branch 1-2 is ambiguous and that either According to Table 1, there may be two solutions in the general case where both branches are ambiguous. A more detailed analysis is required to determine these cases. However, the basic idea is that, in such cases, there are two distinct pairs of identical candidates for R I 1 . This analysis follows in Section 4.3, where the conditions which result in such ambiguous cases are found.

Configurations with One Solution
Besides the general case which will be analyzed later, the only other possibility for a unique solution requires that at least one branch is unambiguous.
Consider the case where the branch 1-3 is unambiguous. Hence, there is a unique solution for R 1 3 and R I 1 . The goal of this analysis is to understand whether a single candidate for R 1 2 can be extracted as well. Assume that d 1 = ±d 1/2 , then (28) can be used as a constraint for R 1 2 , given that R I 1 is already determined. Therefore, a unique solution for R 1 2 exists. Assume instead that I d 1 = ± I d 2 . Since (25) is verified, then, from Theorem 1, there is a unique solution for R 1 2 , and therefore, a unique solution for all attitudes. Otherwise, in the case where one branch is unambiguous and the other is ambiguous and in the case where both branches are unambiguous, there is clearly a unique solution for every attitude of the formation.

Symmetry Analysis
The number of solutions of the branches is not enough to determine the number of solutions of the formation when both branches give two candidates for each attitude. In this case, the symmetry between both branches is responsible for the number of compatible attitudes. The ensuing analysis completes the picture presented in Table 1, by showing whether the solution is unique or ambiguous, when both branches are ambiguous.
An important detail for the ensuing analysis is that any three-dimensional unit vector can be written as the result of two rotations whose axes are orthogonal to each other. Consider that I d 1 = ± I d 2 and I d 1 = ± I d 1/2 , which are verified when both branches are ambiguous, then for some combination of angles α 1 , α 2 , β 1 , and β 2 , it follows that The notation and definitions, which are given next, simplify the expressions used to determine the ambiguous configurations. Hence, consider the inertial attitude candidates, which, recalling (15), are given as and with R * defined in (16) and θ A , θ B , θ C , and θ D defined in (17). Moreover, denote the reference measurements in the intermediate coordinate frame as and Therefore applying (30)-(32) to (14b) and (14c), gives and Additionally, consider a unit vector a ∈ S(2) and define the normal to a plane given by I d 1 and a as Finally, consider the superscript ⊥ to denote the transformation which makes a given vector orthogonal to I d 1 , as follows with a = ± I d 1 and ψ a ∈ R, such that

Relation between Measurements of the Same Branch
The transformation defined in (36) allows to represent the system measurements in a plane orthogonal to I d 1 , which is convenient for establishing the relations between I d 1/2 and I d 2 , and analogously between I d 1/3 and I d 3 . Such relations are respectively derived in Lemmas A5-A8, in Appendix C, and assume that the candidates that are identical to the inertial attitude are known. Hence, recalling the angles and candidates defined in (30) and assuming that both branches are ambiguous, as defined in Theorem 1, if R I 1 = R I 1 A , then with k A , k B , k C , k D ∈ Z.

Relation between Same Type of Measurement
The relation between measurements across branches completes the set of relations required to establish a connection between the identical candidates and the system measurements.
The only measurement shared by both branches is I d 1 , hence the transformation defined in (36) is also convenient for establishing the relation between I d 2 and I d 3 , and analogously between I d 1/2 and I d 1/3 . Such relations are derived in Lemmas A9 and A10, in Appendix D, and are given as and with α 1 and α 2 respectively defined in (29a) and (29b), and with k 1 , k 2 ∈ Z.

Ambiguous Conditions
Advancing to the determination of the ambiguous conditions, recall that the ambiguous configurations with ambiguous branches satisfy either while both R I 1 A = R I 1 B and R I 1 C = R I 1 D . Thus, the definitions in (30) applied to (42) imply one of two cases: The main result of this work relates the ambiguous definitions in (42) with the set of formation configurations. For that purpose, it considers the relations encoded in (29) and is given in the following theorem. Theorem 2. Consider the definitions for the four candidates of R I 1 and the angles θ A , θ B , θ C , and θ D defined in (30) and expressed in the same interval of length 2π. Assume that and that with n ∈ Z. Consider as well the angles α 1 , α 2 ∈ R defined in (29). Then, if and only if with k ∈ Z.

Remark 2.
The configurations where θ A = θ B = θ C = θ D may satisfy (45). However, such configurations were already defined by Theorem 1 and the conditions which define them do not depend on the angles α 1 and α 2 . Therefore, the cases where θ A = θ B = θ C = θ D can be distinguished from the truly ambiguous configurations.
Importantly, left multiplying (29b) by R I 1 and recalling (5)- (7), implies that the relations in (29) can be rewritten as Therefore, the ambiguous configurations can be determined without solving the attitude problem.

Geometric Interpretation
The application of the constraint given by (45) to the relations in (29) provides a simple geometric interpretation in the inertial frame. Consider the planes defined by I d 1 and each of the other measurements, as represented in Figure 3. If the angle between the planes with LOS measurements (i.e., I d 1/2 , I d 1/3 ) is the same as the angle between the planes with inertial references (i.e., I d 2 , I d 3 ), then the configuration is ambiguous, assuming that the branches are ambiguous as well. For another interpretation of this symmetry, take the perspective of the information available for each branch. If the information about the inertial frame is identical in both branches, then an ambiguous solution results from the two ambiguous branches. A simple example is the collinear formation with parallel inertial vectors of the deputies, as represented in Figure 4. In this case, both branches are equivalent in the inertial frame, that is α 1 = β 1 = β 2 = 0 and α 2 = π. Thus, the two candidates for R I 1 from both branches coincide. This situation is even more evident when R 1 2 = R 1 3 , because both candidates for R 1 2 are identical to both candidates for R 1 3 . The measurements of the configuration in Figure 4 can be transformed according to three degrees of freedom given by α 1 , β 1 , and β 2 as defined in (29), with α 2 constrained by (45). Thus, there are infinite such configurations. Nonetheless, these are a zero measure subset of all possible configurations, as it will be shown next.

Ambiguous Configurations Subset Measure
An interesting and very important property of the subset of ambiguous configurations is its measure. Even though it is shown that the set of ambiguous configurations is, in fact, a zero measure subset, this does not mean that these configurations can be ignored. As it will be shown in the simulations, the ambiguous configurations can have an impact in the attitude estimation when noise is introduced and the formation is near the ambiguity. Hence the importance of this study.
Consider the parameterization of x ∈ S(2) given by Furthermore, consider the parameterization of X ∈ SO(3) given by where µ X is the rotation axis of X.
The following theorem shows that the subset of ambiguous configurations is a zero measure subset of the configuration set.

Discussion of Results
The branch analysis showed that, in general, there are ambiguities in the branch measurements and therefore two attitudes satisfy the measurement constraints. These ambiguities were identified in [9,11], where the authors constrain their problem geometry such that it gives a unique solution. Theorem 1 identifies the same condition used to ensure the uniqueness of the solution in those works. However, in the formation considered in this work, such constraint is not required, because there is more information available in the other branch. Thus, by combining the information of both branches, a unique solution can still be determined.
The formation analysis considers the fusion of the information in both branches and how the number of solutions of each branch impacts the number of solutions of the entire problem. It was shown that combining the data in both branches reduces the limitations inherent to the isolated branch. This conclusion is expressed in Table 1, where it is visible that the number of solutions for the entire formation can be unique even when there are branches with two or infinite solutions.
The symmetry analysis distinguishes the configurations in which the branch ambiguities extend to the entire formation, from the configurations which have a unique solution. In general, the latter case is verified. In the former case, the ambiguities at the level of the formation result from symmetries between both branches. The simple geometric intuition given by Figure 3 is useful to evaluate whether the configuration is ambiguous or not, and can be employed while designing estimators.
Finally, the fact that all the configurations with multiple solutions are a zero measure subset of the entire configuration space is relevant for the design of estimators, because it means that such designs have the potential to converge to small errors for almost all configurations.

Simulation
In this section, a simulation illustrates and validates the characterization of the attitude problem considered in this article. Since the degenerate and ambiguous configurations are independent of the attitudes, then, in this simulation and for simplicity, their values are constant and equal to the identity matrix. At the initial time, consider the formation with a unique solution, where the LOS measurements, represented in the inertial frame, Assuming position sensing diodes as sensors, the measurement noise follows the large field of view sensor model [21]. Therefore, the measurement in the sensor frame, s d j , is related to the focal coordinates ξ j = [ χ j ψ j] T , considering a unit focal length, by The focal covariance is given as where σ j is a known standard deviation. Then, the covariance of the sensor is given as where is the respective Jacobian of the relation between the sensor and focal coordinates.
For simplicity, it is assumed that the sensors are aligned with the standard unit vector of the maximum component of the measurement in the body-fixed frame. Thus, the six possible transformations between the body-fixed frame and the sensor frame are given by The simulation takes 100 s, the same duration of the maneuver. It is assumed that all sensors are synchronized and have a sampling rate of 10 Hertz, which means that a measurement is taken every 0.1 s. Moreover, all sensors are characterized by σ = 17 × 10 −6 radians. At each sampling instant, each measurement is sampled as follows: first, its true value is represented in the respective sensor frame, which, in turn, gives the true focal coordinates. Both are used to compute the sensor covariance, P, by applying (54) and (55). The respective noise is sampled from a zero mean normal distribution with covariance P, which is then added to the measurement. Moreover, the inertial references, in the inertial frame, are known a priori and considered noiseless. With the complete set of measurements, corrupted by noise, the attitude is computed using the algorithm described in Section 3.
The results of this simulation are given by the estimation errors, the relation between the values of θ A , θ B , θ C , and θ D , and also by the relation between the values of α 1 and α 2 . The first are expressed by the norm of the 3-2-1 sequence of Euler angles of the error matrix of each inertial attitude, that is, the product between the true value by the transpose of the estimated value, and are shown in Figure 5. The second are expressed by the comparison parameters φ AC , φ AD , φ BC , and φ BD as defined in (18). The third are expressed as the cosine of their difference, i.e., cos(α 1 − α 2 ). Both are shown together in Figure 6.
In the ambiguous configuration, at about 25 s, φ AC ≈ 0 and φ BD ≈ 0. Therefore, near that instant both R I 1 A ≈ R I 1 C and R I 1 B ≈ R I 1 D , which means that the estimated attitude may jump between both solutions, due to the noise, which does happen and is visible in Figure 5. Notice that there is no significant change in the error magnitude before or after the ambiguous configuration, because it is a matter of information symmetry, whereas the degenerate configurations result from a loss of information about a component of the coordinate frame. Moreover, in this case the value of α 1 − α 2 satisfies (45), i.e., cos(α 1 − α 2 ) ≈ ±1, which can be seen in Figure 6.
In the degenerate configuration, at about 75 s, the error magnitude of the estimate for R 1 2 increases gradually as the degeneracy gets closer, until it raises sharply approximately at the 75 s mark. This specific degenerate configuration is given by I d 2/1 = − I d 2 , which from (22) implies that there is a unique solution for R I 1 , despite there being infinite solutions for R 1 2 . This observation, justifies both the values of φ AC and φ BC as seen in Figure 6 and the fact that while the error in R 1 2 increases the other errors remain at the same magnitude as observed in Figure 5. Moreover, since (11a) may not be valid, then a rotation compatible with the constraints is chosen in such a case, for example, selecting a value that satisfies both (9a) and (9b).

Conclusions
In this paper, we analyzed the uniqueness of the solution for the attitude determination problem in a three-vehicle heterogeneous formation, considering both the branches and the entire formation. With respect to the entire formation, there are three possible configurations: degenerate, ambiguous, or regular configurations, respectively, with infinite, two, or one solution. With respect to a single branch, there are also three possibilities: degenerate, ambiguous, or unambiguous branches, respectively, with infinite, two, or one solution. However, the general case is the ambiguous branch. Furthermore, we found the conditions which characterize the ambiguous and degenerate configurations, and branches, thus enabling their detection without solving the attitude problem. We also showed that the measure of the subset of ambiguous configurations is a zero-measure set. Finally, we simulated a maneuver that reaches both a degenerate and an ambiguous configuration and validates the conclusions in this paper. The identification of degenerate and ambiguous configurations is a valuable information for the design of estimators, applicable to this formation, because such configurations introduce challenges to the error stability. Therefore, these results represent one more step towards the design of attitude estimators for three vehicle heterogeneous formations.

Conflicts of Interest:
The authors declare no conflict of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript, or in the decision to publish the results.

Abbreviations
The following abbreviations are used in this manuscript: Lemma A1. Consider a, b, c, d ∈ S(2), k ∈ Z, and λ ∈ R such that and Then, with k ∈ Z.
Proof. Rewrite (A3) by substituting (A2), which gives Since (A4) implies that b, c, and d are all coplanar and orthogonal to a, then, for some α ∈ R, it follows that d = R(α, a)c. Recall that c ∈ S(2) implies that c T c = 1. Further recall that cos(−α) = cos(α) and that (A4) implies both a T c = 0 and c T S(a)c = 0. Then, (A8) is given as Applying the inverse cosine function to both sides of (A9) yields Analyzing each sign separately, consider first that α = λ − α + 2kπ, which after some rearrangements results in Finally, analyzing the other sign, consider that α = −λ + α + 2kπ. It follows that which is excluded from the solutions of (A9) by (A1). Thus, the proof is complete by substituting (A10) in (A7) which yields (A5).
Lemma A2. Let a, b, c, d ∈ S(2). If and then, Proof. Take the left side of (A13) and substitute (2), which gives Then, Proof. This proof follows similarly to the one from Lemma A2. That is, take the left side of (A19), then apply the rotation definition, the triple vector product, and recall conditions (A17) and (A18) to show that it yields the right side of (A19). Therefore, the details of the proof are omitted.

Appendix B. Technical Lemma
This appendix contains the proof for Lemma 1, which is reproduced below.
Lemma A4. Consider c s 12 and c c 12 as defined in (12). Then, both and if and only if either Proof. First, assume that (A21) is true. Since S(x)x = 0, for any x ∈ R 3 , then substituting (A21) in (12) yields (A20a) and (A20b). Next, assume that (A22) is verified and left multiply it by R(θ 1 , n 1 ), with parameters defined in (10), which gives R(θ 1 , n 1 )d 2 = ±R(θ 1 , n 1 )d 2/1 . Recalling (13) and that, by definition, −d 1/2 = R(θ 1 , n 1 )d 2/1 [13], it follows that (A22) is equivalent to Then, from S(x)x = 0 and substituting (A23) into (12)  Consider that c = 0, which means that (A21) is verified, then both c s12 = 0 and c c12 = 0 because S(x)x = 0. Otherwise, consider that c = 0, which means that c and c are orthogonal. Since verifying both c s12 = 0 and c c12 = 0 implies that a, b, and c are coplanar, while a, b, and c are coplanar, then a and b must be collinear because c and c are orthogonal. Therefore, in this case, (A23) is verified which was previously shown to be equivalent to (A22) and thus concludes the proof.

Appendix C. Relation between Measurements of the Same Branch
This appendix shows both the relation between I d 1/2 ⊥ and I d 2 ⊥ , and the relation between I d 1/3 ⊥ and I d 3 ⊥ . Since the derivation of such relations is analogous in the four ensuing lemmas, only the first lemma is accompanied by its proof.
Lemma A5. Recall the definition of R I 1 A , θ A , and θ B in (30). Further recall the vector transformation in (36). Suppose that both branches of the formation are ambiguous, as defined in Theorem 1, and assume that R I 1 = R I 1 A . Then Proof. First, substitute (33) in I d T 1 I d 2 , which implies that or, equivalently, from (4), Similarly, consider the inner product given by R I 1 d 1/2 T I d 2 , which from (30) and (33) implies that or, equivalently, Next, consider the angle ψ 1 ∈ R. Then, apply Lemma A2, in Appendix A, with a = I d 1 , b = d * 2A , c = d * 2B , and d = R * d 1/2 , recalling that in such case (A11) and (A12) are given respectively by (A25) and (A26). It follows that where m d * 2A and m d * 2B are defined in (35). Since ψ 1 is arbitrary, recall (36) and choose ψ 1 such that (A27) is expressed as Similarly, consider the angle ψ 2 ∈ R and recall from (37) that, by definition, Then, apply Lemma A3, in Appendix A, with a = I d 1 Recall that in such case (A17) and (A18) are given respectively by (A29) and (A28). It follows that where m R * d 1/2 is defined in (35). Then, recalling (36) and choosing the appropriate value for ψ 2 gives Next, from (37), recall that which is rewritten, by applying (A32), as Afterwards, recall the definition (35) and consider the numerator of m d * 2A . It follows from (7) and (A32) that Meanwhile, consider the denominator of m d * 2A . It follows, from (A32), that and then, from (3) and (7), that Consequently, recalling the definition of both m d * 2A and m d * 2B in (35), it is concluded that (A34) and (A35) imply Therefore, recalling (6), it follows that (A33) is also given as which, from (A36), yields or, equivalently, from (36), Next, consider that θ A − θ B = 2πk, with k ∈ Z. Then, the conditions for Lemma A1, in Appendix A given by (A2), (A3) and (A4), are respectively verified by (A37), (A30) and (A31), with λ = θ B − θ A , a = I d 1 , b = d *
Lemma A6. Recall the definition of R I 1 B , θ A , and θ B in (30). Further recall the vector transformation in (36). Suppose that both branches of the formation are ambiguous, as defined in Theorem 1 and assume that R I 1 = R I 1 B . Then Lemma A7. Recall the definition of R I 1 C , θ C , and θ D in (30). Further recall the vector transformation in (36). Suppose that both branches of the formation are ambiguous, as defined in Theorem 1 and assume that R I 1 = R I 1 C . Then