Geometric Pseudospectral Method on SE(3) for Rigid-Body Dynamics with Application to Aircraft

General pseudospectral method is extended to the special Euclidean group SE(3) by virtue of equivariant map for rigid-body dynamics of the aircraft. On SE(3), a complete left invariant rigid-body dynamics model of the aircraft in body-fixed frame is established, including configuration model and velocity model. For the left invariance of the configuration model, equivalent Lie algebra equation corresponding to the configuration equation is derived based on the left-trivialized tangent of local coordinate map, and the top eight orders truncated Magnus series expansion with its coefficients of the solution of the equivalent Lie algebra equation are given. A numerical method called geometric pseudospectral method is developed, which, respectively, computes configurations and velocities at the collocation points and the endpoint based on two different collocation strategies. Through numerical tests on a free-floating rigid-body dynamics compared with several same order classical methods in Euclidean space and Lie group, it is found that the proposed method has higher accuracy, satisfying computational efficiency, stable Lie group structural conservativeness. Finally, how to apply the previous discretization scheme to rigid-body dynamics simulation and control of the aircraft is illustrated.


Introduction
The aircraft is usually regarded as a single rigid body in three-dimensional space. The dynamics of a rigid body is an important problem modeling the time evolution of aircraft and other vehicles [1]. In particular, in aircraft simulation and control, its authenticity affects the fidelity of the simulation and also determines whether it can truly reflect the performance of the designed controller to a certain extent. The rigid-body dynamics has fundamental motion invariants; for example, the flow of a Hamiltonian system is symplectic [2,3], the total energy of a rigid body is conserved in the absence of nonconservative forces [4], and the momentum map associated with a symmetry of a rigid body is preserved [5]. Furthermore, the exact flow of a rigid body always stays on a configuration manifold, since the combined configurations of the translation and rotation of the rigid body construct a special Lie group called the special Euclidean group SE(3) [6]. The invariants often manifest through geometric characteristics of exact flow of a rigid body, such as symplecticity, first integrals, symmetry, and Lie group structure. However, for most rigid bodies, obtaining the analytical solution is quite difficult. Thus, under the condition of non analytical solution, it is desired to develop a numerical method whose iterates preserve the previous fundamental invariants [7]. For this purpose, the research area of development of numerical methods for rigid-body differential equations that preserve geometric properties of the numerical solution has been of great interest in recent years [8]. Simos [8,9], Monovasilis et al. [3,10], and Kalogiratou [11] construct several different multistep symplectic integrators based on symplectic geometry in order to preserve the Hamiltonian energy of rigid bodies as the harmonic oscillator, the pendulum, two-body problem, and orbital problem. Lee et al. [5] and Hussein et al. [12] adopt variational integrators to evolve the rigid-body dynamics, which ensure that while the total energy of the rigid body is conserved under conservative forces, the momentum associated with a symmetry of the system is also conserved. Iserles et al. [13] and Lee et al. [5] extend numerical methods in Euclidean Mathematical Problems in Engineering space into Lie group, so that numerical flow of the rigidbody dynamics has Lie group structural conservativeness, which is also the main focus of this paper. Retaining motion invariants under discretization has been proven not only a nice mathematical property, but also the key to improved numerics, as they capture the right dynamics (even in longtime integration) and exhibit increased accuracy [2,7,13,14]. Therefore, for driving the evolution of rigid-body dynamics, it is very important to develop a numerical method with preservation of the previous geometric characteristics.
The difficulty of developing a numerical method on Lie group arises as the group is not the well-known Euclidean space R ; consequently, the rigid-body dynamics evolving on SE(3) cannot be properly integrated by conventional numerical method, including the popular Runge-Kutta schemes, developed for R . For this reason, one resorts to other means to drive the rigid-body dynamics forward while preserving the Lie group structure of the configuration. It can be roughly divided into two categories: classical Lie group methods which discretize the continuous equations of motion and Lie group variational integrators which discretize the variational principles of mechanics. Classical Lie group methods include the Munthe-Kaas (MK) method [15], the Crouch-Grossmann (CG) method [16], the Newmark-type method [17], and the commutator-free (CF) method [18], and so forth. The MK method is based on a differential equation on the Lie algebra and uses a single evaluation of the exponential map. The CG method updates the group elements by multiple evaluations using the exponential map. For detailed information, one can consult to [13]. Lie group variational integrators are proposed in recent years whose idea is to discretize the variational principles of mechanics: Hamilton's principle or Lagranged' Alembert principle [1,5,14]. Both methods have their own advantage and disadvantage. The former has a better time performance, but its accuracy is not an advantage under the same order condition. The latter preserves exactly energy, momentum, symplectic structure, and group structure [12,19] and offers a particularly robust and efficient framework for simulation [14], attitude control [4], motion control [1], and trajectory generating [14] of the aircraft and other vehicles, however; it has no advantage of accuracy, and its performance is subjected to the Newton-type solver for solving the equivalent vector equation [5,14,20]. Regardless of the classical Lie group methods or Lie group variational integrators, they are all based on Kenth Engø's idea about equivariant map which transforms the differential equations evolving on a Lie group into an equivalent differential equation evolving on a Lie algebra corresponding to the Lie group [21].
Since accuracy, time performance, conservativeness, and numerical stability of the aircraft rigid-body dynamics need to be considered comprehensively in aircraft simulation and control, we do not intend to adopt any of the previous methods but use the same idea of equivariant map to develop a new method on SE(3) for driving the evolution of aircraft dynamics. We resort to pseudospectral method, which is widely used in fluid mechanics, quantum mechanics, linear and nonlinear waves, aerospace, and other fields by virtue of its high accuracy, spectral (or exponential) convergence rates, requirement for less computer memory under the same precision condition, and so forth [22]. Furthermore, it is commonly used in optimal control of the aircraft and other vehicles [23] and thereby lay the foundation for our simulation and control application. Unlike variational integrator must analytically derive the first-order discrete necessary optimality, which, more often than not, is nontrival for most optimal control problems [23], typical pseudospectral method can be used to transcribe a continuous optimal control problem into a discrete nonlinear programming problem (NLP), and it has been shown that solving the NLP derived from the pseudospectral transcription of the Gauss form is exactly equivalent to solve the discrete first-order necessary conditions [23,24]. However, when applied to rigid body dynamics directly, general pseudospectral method cannot preserve Lie group structure. For this purpose, a numerical method on SE(3) called geometric pseudospectral method is proposed in this work, which provides satisfactory accuracy, computational efficiency and preserves the essential Lie group structure. To our knowledge, Moulla et al. [25] was the first to pose the concept of "geometric pseudospectral method" not long ago. They suggested a polynomial pseudospectral method that preserves the geometric structure of port-Hamiltonian systems, the phenomenological laws, and the conservation laws without introducing any uncontrolled numerical dissipation. However, their method was designed only for port-Hamiltonian systems having a special structure, that is, the Dirac structure, thus it could not be directly extended to the systems on SE(3). Thereby, how to apply the pseudospectral method to a dynamics system on SE(3) and preserve essential Lie group structure of the system is still an open question, which is the main topic in this paper.
In this work, we establish a completely rigid-body dynamics model of aircraft in body-fixed frame on SE (3). With respect to kinematics, due to the fact that applying the general pseudospectral method directly to the configuration equation of the rigid-body dynamics could not preserve the Lie group structure of the solution of the equation, drawing on the equivariant map, we transform the configuration equation on SE(3) into an equivalent equations in a Lie algebra space and accordingly give the top eight orders reduced truncated Magnus series expansion with its coefficients ( ) (refer to the appendix) of the solution of the equivalent equation under left trivialization. For the condition of each term in [2 ] ( ) being multivariate quadrature, we apply the general pseudospectral method to compute quadrature weights, so that obtaining the values of [2 ] ( ) at the collocation points and the endpoint (collectively referred to discrete points). Finally, we compute configurations at the discrete points via coordinate map. It is worth mentioning that the theories with respect to Lie group methods in the extensive literatures [13][14][15] are almost derived under right trivialization and thus are not suitable for our method, since our modeled aircraft configuration model is left invariant. To this end, we provide a relatively complete set of left trivialization framework for developing geometric pseudospectral method on SE (3). With respect to dynamics, considering the Lie algebra space is isomorphism to R , we use the general pseudospectral method directly to compute the velocities at the same discrete points as that of configuration.
Under the same 4th-order and the same large step size, the proposed method is compared with implicit RK, explicit RKMK, and Gauss pseudospectral method. Through a comprehensive comparison of accuracy, computational efficiency, and Lie group structural conservativeness, the proposed method has higher accuracy, satisfying computational efficiency, stable Lie group structural conservativeness. The proposed method is coordinate-free, no need to switch chart and special handling of singularities. Finally, we give a way of applying the proposed numerical method to rigid-body dynamics simulation and control of the aircraft.
The rest of the paper is organized as follows. In Section 2, a completely left invariant rigid-body dynamics model of the aircraft on SE(3) is established. Geometric pseudospectral method on SE(3) is developed in Section 3. In Section 3.1, for completeness, the basic idea of the general pseudospectral method in Euclidean space is roughly introduced. In Section 3.2, geometric pseudospectral method on SE (3) is developed under left trivialization, and a 4th-order geometric pseudospectral algorithm is given. In Section 3.3, numerical tests are carried out on a free-floating rigid-body model in comparison with four other numerical methods to validate numerical accuracy, computational efficiency, and structural conservativeness of the proposed method. Then, how to apply the proposed method to rigid-body dynamics simulation and control of the aircraft is illustrated in Section 4. Finally, the conclusions and future work are outlined in Section 5.

Aircraft Rigid-Body Dynamics Model on SE(3)
The special Euclidean group SE(3) is the semidirect product of SO(3) and R 3 , whose group element = ( , ) consists of rotational component ∈ SO(3) and translational component ∈ R 3 of the body-fixed frame { }, relative to = +1} is called the special orthogonal group [6]. In this section, we will regard the aircraft as a single rigid body in three-dimensional space and establish a rigid-body dynamics model of the aircraft on SE(3).

Kinematics Model.
The navigation equations of the aircraft are given by [26] [ . (2) Denote [ , , ] and [ , V, ] by ( ) and ( ), respectively, then we havė Also, the kinematic equations are given by [26] [ where, , , and are roll angle, pitch angle, and yaw angle, respectively, which are commonly referred to as Euler angles; , , and denote the roll rate, pitch rate, and yaw rate, respectively, about -body axis, -body axis, and -body axis. Then, we have where ( ) and ( ) are, respectively, called the homogeneous representation of ( ) and that of ( ) = [ ( ), ( )] ∈ se(3), se(3) = so(3) × R 3 is the Lie algebra corresponding to SE(3) where so(3) is the Lie algebra corresponding to SO(3) [6]. The right hand of (7) is the infinitesimal generator of the action corresponding to ( ), and it is left invariant under left multiplication by constant matrices [27]. These properties determine the trivialization way of local coordinate map in Section 3.2.1.

Dynamics Model.
The force equations of the aircraft are given by [28] [ where,,V , anḋdenote -axis component, -axis component, and -axis component, respectively, of the aircraft acceleration in the body-fixed frame, is the aircraft mass, is the wing reference area, is the free-stream dynamic pressure, is the engine thrust, and , , , , and , denote total -axis force coefficient, total -axis force coefficient, and total -axis force coefficient, respectively.

General Pseudospectral Method in Euclidean
Space. General pseudospectral method will be used for computing the velocities in the Lie algebra. For this purpose, we briefly describe the basic principle of general pseudospectral method [24]. Let us take solving the following differential equation in R at , for example, Firstly, we equally divide a time interval [ 0 , ] into several time subintervals [ , +1 ] having a length ℎ and transform the time interval ∈ [ , +1 ] to the time interval ∈ [−1, 1] via the affine transformation Thus, accordingly, (15) We approximate the solution of (17) by the following formula: where ( ) = ∏ =0, ̸ = ( − )/( − ) is the Lagrange polynomials, satisfying the isolation property Equation (18) together with the isolation property leads to the fact that thus ( ) = ( ).
Through expressing the derivative of the Lagrange polynomials at the collocation points in differential matrix form We can write (17) at the collocation points as a set of differential algebra equations as follows: Based on the previous equations, we establish defect equations and apply iterative algorithms to the previous equations so that determining the approximation to ( ) at the collocation points. Finally, according to the following formula, we obtain the approximation to (15) at the endpoint +1 of time subinterval [ , +1 ]: ( )d is quadrature weight corresponding to the collocation points. This approximate solution will be initial value of ( ) over [ +1 , +2 ] and so on.
According to different selection methods of collocation points, pseudospectral methods can be divided into the standard method and the orthogonal method. Common collocation points in the orthogonal method are those obtained from the roots of either Chebyshev polynomials ( ) or Legendre polynomials ( ) belonging to the orthogonal polynomial [29]. The benefit of using the orthogonal method over the standard method is that the quadrature approximation to a definite integral is extremely accurate [24]. Furthermore, according to whether the endpoint is or is not a collocation point, pseudospectral methods fall into three general categories [30]: Gauss methods, neither of the endpoints −1 or 1, is a collocation point; Radau methods, at most one of the endpoints −1 or 1, are a collocation point; Lobatto methods, both of the endpoints −1 and 1, are collocation points. In the rest of this paper, we will develop our geometric pseudospectral method based on Legendre-Gauss points, abbreviated as Gauss points in the following, for two main reasons: firstly, there is an intimate relationship between Gauss method and some implicit RK method whose coefficients in the Butcher Tableau can be used by our method for computing configuration [2]; secondly, when Gauss method is used for transcribing the continues optimal control problem into a discrete nonlinear programming problem, it does not suffer from a defect in the optimality conditions at the boundary points due to the endpoints being not collocation points [23]. (3). First recall and rewrite the aircraft rigid-body dynamics model Equations (7) and (14) in Section 2 as follows:

Geometric Pseudospectral Method on SE
.
Step 2.2.4. End child loop; Step 2.2.5. Use the final iterative results (step) and (step) in child loop to compute the velocity ( +1 ) at the endpoint +1 , Step 2.2.6. Compute configuration ( +1 ) at +1 : Step 2.2.6.1. Compute 4th-order reduced truncated Magnus series expansion [4] ( +1 ) at +1 , [4] Step 2.2.6.2. Use the Cayley map to update configuration ( +1 ), ( +1 ) = ( ) ⋅ cay ( [4] ( +1 )) Step 2.2.7. Compare +1 with , so that determine whether or not to terminate the main loop; Step 3. End loop. For the kinematics Equation (25), it is well known that the solution of (25) stays on SE(3) for all ≥ 0 . How to use pseudospectral method to solve (25) while preserving the structural feature of the differential equation under discretization of ( ) is the main problem to be solved in this section. In R , both the solution space and the tangent space are linear vector space. Classical numerical methods, including general pseudospectral method, just rely on domain space consisting of vectors. However, the special Euclidean group is a nonlinear manifold, so using classical numerical methods directly to solve differential equation on SE(3) will be not able to preserve its Lie group structure. Reference [21] indicated that any differential equation in the form of an infinitesimal generator on a homogeneous space (a manifold with a transitive Lie group action) is shown to be locally equivalent to a differential equation on the Lie algebra corresponding to the Lie group acting on the homogenous space. Also, a Lie algebra corresponding to the Lie group is a Mathematical Problems in Engineering 7 vector space with the additional structure of a commutator. For the previous reasons, the Lie algebra is the natural choice of space for our geometric pseudospectral method. First, we will apply the equivariant map to transform (25) evolving on SE(3) into an equivalent differential equation evolving in se(3). Next, we use the Gauss pseudospectral method to solve the equivalent differential equation in order to obtain th-order truncated approximation of the equation at the Gauss points and the endpoints, followed by mapping the approximate solution back to configuration space via local coordinate map .
For the dynamics equation (26), because the velocity ( ) belongs to se (3), and actually se (3) is isomorphic to the R 6 , we can use Gauss pseudospectral method directly on (26) to compute the velocities at the Gauss points and the endpoint.

Computing Configurations at the Gauss
that is, the following diagram commutes of equivariant map : First, from the definition of an action of on M, we can obtain an equivariant map Φ : → M with respect to the left translation action of on itself and an action of Φ on M as follows: It is known that there is a local coordinate map : g → on with the Lie algebra g; the most typical one is exponential map exp : g → . At this point, we need to find an action of on g such that will be an equivariant map with and the left action of on itself, namely, In the case where is the exponential map, is nothing else than the well-known Baker-Campbell-Hausdorff (BCH) formula: where log : → g is called the logarithm map. Since composition of two equivariant maps is also an equivariant map, we can construct an equivariant map Φ ∘ from g to M with respect to the action on g and Φ on M. Diagram commutes of composition Φ ∘ are as follows: The theorem 3.6 of [21] stated that if is an equivariant map, then the infinitesimal generators of the action with respect to the same element ∈ g are -related vector fields. Thus, the infinitesimal generators g and M of the flows exp( ) and Φ exp( ) , respectively, on g and M are Φ ∘related; that is, Finally, we need to determine what g is, and the following theorem gives the conditions that it needs to meet.
The following commutative diagram describing the equivariant maps of composition Φ ∘ (left) and its infinitesimal generator (right) sums up the previous processes: Also, [21] stated that any differential equation on M which can be written as an infinitesimal generator fits into the previous framework, including all Lie type equations, isospectral flows, and rigid frames. It is noted that, as mentioned in Section 2.1, the right hand of (7) or (25) is an infinitesimal generator on SE(3), and here we assume that the solution ( ) of (25) can be written as the following form [13]: In order to obtain the explicit expression of ( ), we need to solve the following differential equation:   For deriving the previous formula, we differentiate (35) as follows: Comparing (37) with (25) and (35), we have Taking the inverse of previous formula, we obtain (36). It seems from the equivariant map and the previous formula derivation that solving equation (25) can be transformed into a research on the equivalent equation (36), and the manifold M is SE(3) at this point. d −1 − ( ( )) has different forms, according to the different choices of local coordinate map . In the case where is the exponential map, the vector field d −1 − on g can be represented as [13] d exp −1 − ( ( )) = ( ) + 1 2 ad ( ( )) where the adjoint operator ad : g → g is Lie bracket or commutator, ad ( ( )) = [ , ( )], satisfying recursive expression ad ( ( )) = [ , ad −1 ( ( ))], and are Bernoulli numbers [31] In the context of rigid-body motion, the right trivialization corresponds to the differential equation with tangent vectors ∈ X(M), ∈ g, and ∈ , and the left trivialization corresponds to the differential equation with tangent vectors ∈ X(M), ∈ g, and ∈ . The former represents the change of configuration in a space frame, and the latter represents the change of configuration in the bodyfixed frame. Here, let d be the left trivialization of , since the configuration model established in Section 2.1 is in the body-fixed frame. In the case of d being the left trivialization and being the exponential map, we can find an explicit The previous formula can be rewritten as an infinite sum ( ) = ∑ ∞ =0 ( ), where each ( ) is a linear combination of terms that have equal numbers of integrals (exclude the outermost integral from 0 to ) and commutators. We denote each term of ( ) by ( ) and associate it with a binary tree ∈ T , where T is a set which includes all trees with the same number of integrals and commutators. Then, we can rewrite (41) as where   It is worthwhile to note that, unlike right trivialization in [13], here, we take left-trivialized tangent of local coordinate map, thus̃= Based on the binary tree theory, we can find the following th-order approximate solution of (36), where F is the set of all -power rooted trees. Thereby, we give the Magnus series terms with its coefficients ( ) under left trivialization in Table 2, which correspond to the top eight orders rooted trees. Then, we use Gauss pseudospectral method to solve (45), so that we get the approximate solution of (36) at the Gauss points < 1 , . . . , < +1 and the endpoint +1 ≜ + ℎ. To begin with, assume that all of velocities ( ) at the Gauss points are known previously; we use the Lagrange polynomials at these points to approximate the velocity at any time ∈ [ , +1 ] as follows: where each term ( ) is the following form of multivariate quadrature: where = { 1 , . . . , ∈ R| 1 ∈ [0, ], ℓ ∈ [0, ℓ ], ℓ ∈ {1, 2, . . . , ℓ − 1}, ℓ = 2, 3, . . . , } and L denotes multivariate function.
One has wherẽ= { 1 , . . . , ∈ R| 1 ∈ [0, 1], ℓ ∈ [0, ℓ ], ℓ ∈ {1, 2, . . . , ℓ − 1}, ℓ = 2, 3, . . . , } and is similar to −1 . Through computing ( ) of (47) term by term, we obtain th-order approximate solution [ ] ( ) of ( ) at the discrete points. As seen from (48), ( ) depends on the velocities at the Gauss points, and the velocities need to be solved in an iterative manner which will be explained in next section. Thereby, the solutions of configuration at the Gauss points need to be also determined in an iterative manner. Finally, we use [ ] ( ) at the Gauss points to compute configuration corresponding to the same points via the following formula: There are several choices of local coordinate map : g → , such as exponential map and Cayley map [21]. We incline Table 2: Magnus series terms corresponding to the top eight orders rooted trees.

Computing Velocities at the Gauss Points and the
Endpoint. As mentioned above, here, we can directly use general pseudospectral in Section 3.1 to compute velocities at the Gauss points 1 , . . . , and the endpoint +1 . However, due to (26) being implicit, we have to use iterative algorithm to solve it. When computing configurations in the preceding section, we assumed that ( ), = 1, . . . , in (46) are known in advance. Hence, we need to give their solutions, and we are going to do it in this section.
To begin with, we write (26) at all of the Gauss points in a compact matrix form, . . .
wherẽ∈ R × is the submatrix of in Section 3. ] .
By computing the velocity deviation between adjacent iterative steps, we determine whether or not to terminate the iterative process. It is noteworthy that we must ensure that computing configurations and velocities at the same Gauss points.
Finally, after the final satisfying iterative results of the velocities at the Gauss points are obtained, we use the following formula to compute velocity at the endpoint:

4th-Order Algorithm of Geometric Pseudospectral
Method. In accordance with the aforementioned basic principle of geometric pseudospectral method, we develop a 4thorder algorithm for the rigid-body dynamics evolution over time.
Implementation and the Order Condition. Legendre-Gauss point is the root of Legendre polynomial In fact, a convenient way to compute the Legendre-Gauss points is via the eigenvalues of the following tridiagonal Jacobi matrix: Due to the fact that (25)- (26) are implicit, therefore, we have to use iterative algorithm to update the velocities and configurations at the Gauss points. In the interactive processes, we need to compute the velocity deviation and configuration deviation, respectively, between the adjacent interative steps. For velocity deviation, since the Lie algebra space se (3) in which the velocities belong is isomorphic to R 6 , so we are able to use minus directly. However, for configuration deviation, because configuration space is a nonlinear manifold, we introduce the following natural error of configuration [27]: By the way, the reason why we choose the previous metric is its intuitive physical meaning; taking SE(2) as an example, the 2-norm ‖( (step+1) ) (step) ‖ 2 denotes angle difference Δ = (step+1) − (step) between configurations, and the 2- between configurations. The last one required to pay attention to is to ensure computing configurations and velocities at the same Gauss points. Turning to order condition of the algorithm, there are something worthy of our attention. Firstly, if we consider the time symmetry of the Magnus series expansion, the number of terms belong to (47) can be further reduced [13]. According to the time symmetry, function [ ] ( ) can be expanded as the odd power of time , and then [2 ] ( ) = 2 −1 ( ) + O( 2 +1 ). For this purpose, we provide the top eight orders reduced truncated Magnus series expansion in Table 3 which have been used in step 2.2.3.3 and step 2.2.6.1 of Algorithm 1. Secondly, let the Magnus series expansion be truncated up to the th-order trees for ( +1 ) and −1th-order trees for the intermediate stages ( ), then the resulting schemes have th-order [32]. Moreover, [2] stated that the interpolatory quadrature formula with Gauss points is 2 th-order. In summary, our 4th-order geometric pseudospectral method only depends on two Gauss points.

Numerical Test on Free-Floating Rigid Body.
In this section, the performance of Algorithm 1 is tested through evolution of the following free-floating rigid body dynamics equations (60)-(61) on SE (3). Note that, under the condition of no external force, (60)-(61) are equivalent to (25)- (26). Table 1 summarizes the parameters used in the numerical test as follows: ] . (61) For making the numerical test more comparable, we select four 4th-order numerical methods used to compare with geometric pseudospectral method (GPM), including ode45 [33], implicit 4th-order Runge-Kutta (RKi), explicit 4th-order RKMK (RKMK) [13], and 4th-order Gauss pseudospectral method (PM) [24], where iterative number and tolerance of the child loop of GPM and PM are set to 10 and 10 −14 , respectively. Among the previous methods, ode45 is the build-in integrator from MATLAB which is a variable-step method and whose results would be used as the ground truth with a specified tolerance 10 −14 . Both RKi and PM are the methods in Euclidean space. RKMK is an approximate Runge-Kutta method on Lie group [15]. It is worth mentioning that each test must be carried out under the same step size.
In order to intuitively present the difference between these methods, the 240 seconds evolving trajectories of the free-floating rigid body for a large step size are shown in Figure 1. As seen from the evolution versus time, the positions of PM is closest to the ground truth, and that of GPM take second place, but that of RKi and RKMK deviate from the true values to varying degrees. The potential reason resulted in accuracy of GPM being lower than PM is that position of PM is computed by iterative operator with specified iterative numbers and tolerance directly, but position of GPM is truncated to a specific order before iterative operator. Despite inferior to PM, the proposed method is obviously superior to RKi and RKMK in position accuracy. As can be seen, error accumulates faster in translational components than in rotational components . This could be explained by the fact that rotation is decoupled from translation and hence has its own error dynamics, whereas translation suffers from small cumulative errors in rotation. In addition, we also give the total computational time in the first line and the average time per step in parenthesis. Obviously, RKMK needs the least time since it is an explicit method. Both GPM and PM need less time than RKi. From orientation, linear velocity, and angular velocity, there is no obvious difference, so we need to further compare these methods quantitatively.
In order to quantitatively compare the proposed method with the other three methods, deviation statistics and runtime statistics over 10 runs using a wide range of initial conditions on a 240 seconds evolution are provided in Figure 2. Figure 2(a) shows the position deviation against timesteps. It conforms that the accuracy of the GPM is superior to RKi and RKMK under the same large step size, although it is inferior to PM in average position deviation, and the relationship of position deviation between the four methods is consistent with that of Figure 1. In Figure 2(b), we give the orientation deviation against timesteps by calculating the metric ‖log SO(3) ( ode45 )‖ 2 of SO(3) [27], where ode45 denotes the orientation of the free-floating rigid body which is computed by ode45. It should be noted that ode45 transforms from the unit quaternion [26], since in ode45 unit quaternion is selected for parameterizing orientation at this point. Figure 2(c) shows the averaged computation time of four methods. As can be seen, computational efficiency of GPM is inferior to that of RKMK, because RKMK is an explicit method. However, our method requires less computation time than RKi and is nearly twice as efficient as RKi on average.
Finally, we examine the conservativeness of Lie group structure. Considering that configuration is parameterized by unit quaternion in ode45 and implicit RK method, we only compare the proposed method with explicit RKMK and Gauss pseudospectral method. As mentioned, the group element of SO(3) satisfies = , and we compute deviation ‖ 3×3 − ‖ ∞ for evaluating structural conservativeness of the algorithms [5]. Figure 3 illustrates that Gauss pseudospectral method in Euclidean space has no conservativeness of Lie group structure, since it is not a Lie group method; RKMK and geometric pseudospectral method on Lie group are able to preserve Lie group structure with accuracy approaching to machine accuracy.

Simulation and Control Application of Aircraft
It is seen from the numerical test in the previous section that the proposed method has better accuracy, stable structural conservativeness, and satisfying computational efficiency. Thus, it is able to meet the fidelity and timeliness requirements of aircraft dynamics simulation. In view of the aircraft dynamics is complex and underactuated, we adopt optimal control to generate flyable trajectories of aircraft. As mentioned in Section 1, pseudospectral method of the Gauss form can be easily applied to optimal control of the aircraft or other vehicles and satisfies optimization condition. Reference [23] shows that solving the NLP derived from the pseudospectral transcription of the Gauss form is exactly equivalent to solve discrete first-order necessary conditions. The KKT conditions of the NLP are exactly equivalent to the discrete first-order necessary conditions of the Bolza problem. And, KKT multipliers can be mapped to the costate of the continuous-time optimal control problem via costate mapping principle. Because our geometric pseudospectral discretization scheme is also based on Gauss points, we can use it to transcribe a continuous aircraft optimal control problem into a discrete nonlinear programming problem (NLP). Then, the resulting NLP can be solved by many wellknown optimization techniques [34,35]. For this purpose, we follow the Gauss pseudospectral transcription approach introduced in [36]. The optimal control problem can be formulated as in Algorithm 2.
Depending on the specified scenario, cost functions include minimum control effort, minimum time, obstacle avoidance, and the quickest manoeuver. For further details regarding the optimization setup, one can consult to [36]. In this work, referring to the geometric optimal control framework proposed in [37], rotation component of is not treated as our decision variable, for three reasons: firstly, during the optimization, can be reconstructed fromî nternally through evaluating (45), (51), and (54); secondly, the Lie group structural conservativeness could not be considered by NLP solvers, unless additional constraint with respect to structural conservativeness is introduced, which may affect optimality; moreover, computational efficiency is improved. We take obstacle avoidance as our example, with optimal control which is implemented using the combination of GPOPS [36] in MATLAB and SNOPT package in TOM-LAB version 7.7 [38]. Figure 4 shows simulation results for an aircraft avoiding obstacles. Their detailed analysis is the subject of on-going work and will be presented in a future paper.

Conclusions
A completely left invariant rigid-body dynamics model of aircraft on SE(3) is established. For the left invariance of rigidbody dynamics model in body-fixed frame, an equivalent differential equation on se(3) is given under left trivialization. Accordingly, based on Magnus series expansion and exponential map, the solutions of configuration equation at the Gauss points and the endpoint are obtained. Velocities on se(3) at the discrete points are computed based on general pseudospectral method, since se(3) is isomorphic to R 6 . Thereby, a 4th-order numerical method called geometric pseudospectral method is developed. Through a series of numerical tests and comparison with other numerical methods on Lie group and Euclidean space, the proposed method has a comprehensive advantage in accuracy, computational efficiency, and Lie group structural conservativeness. Finally, the way of applying our method to aircraft simulation and optimal control is illustrated.
For the future work, we will further analyze its performance in aircraft simulation and control. For presence of a large number of tedious commutator operator in multivariate quadrature, we will try to find an alternative method to simplify the calculation process so that extend our method to the higher order. Moreover, we will extend the proposed method to a broader kind of left invariant rigid-body dynamics systems in engineering.