Satellite Attitude Control Using Control Moment Gyroscopes

In space missions, there is often a need for an attitude control system capable of maintaining the desired attitude. In situations that require agile and accurate responses, which also require large torques, control moment gyroscopes (CMGs) may be used. Control moment gyroscopes are high angular moment gyros mounted on gimbals and are responsible for changing the direction of the angular momentum vector, consequently generating the control torques. There are several linear and nonlinear techniques that can be employed in the design of control laws with the final choice being a compromise between simplicity, effectiveness, efficiency and robustness. The main objective of this study is to evaluate the performance of control systems techniques with 4 CMGs in a pyramidal arrangement, either by using Linear Quadratic Tracker (LQT) with integral compensator or Exponential Mapping Control (EMC). A reference attitude will be defined to be traced in the presence of disturbance torques caused by the gravitational gradient.


INTRODUCTION
Satellites can perform various missions and, in some, such as monitoring or telecommunication, attitude control is critical and several techniques can be used in order to execute it, some of which are presented by Wie (2008). There is a wide field of studies in the development of new ways of acting for attitude control. Among the techniques already consolidated for missions that involve the need of agile and precise responses, such as monitoring, control moment gyroscopes (CMGs) mounted on gimbals can be used.
The CMGs are responsible for changing the direction of the angular momentum vector, consequently generating the control torques, and they have been widely studied with different control methods. Many linear methods are used, as presented by Tayebi et al. (2017), who compared the performance of a linear-quadratic regulator (LQR) with a linear-quadratic-Gaussian (LQG) for a single gimbal CMG. Kojima et al. (2020) proposed a new CMG design that minimize singularities, named the doublegimbal scissored-pair CMG (DGSPCMG), which controls it by using a quaternion feedback law. Some studies focus on nonlinear J. Aerosp. Technol. Manag., São José dos Campos, v12, Special Edition, [94][95][96][97][98][99][100][101][102][103][104][105]2020 control techniques to overcome external disturbances, parameters uncertainties and wider operation ranges, such as Toriumi and Angélico (2020), who developed a nonlinear feedback linearization control in a cascade structure and compared the simulations with experimental results, and Baghi et al. (2018) considered a satellite with large flexible appendages, employing a nonlinear PD controller and proving its globally asymptotical stability using a Lyapunov function.
There are several arrangements of CMGs with different characteristics and Wie (2008) presented a pyramidal arrangement of four CMGs. Attitude control design using CMGs with this type of arrangement is the main objective of this work. A classical Linear Quadratic Tracker (LQT) controller was developed and was compared against the Exponential Mapping Control (EMC), a new nonlinear control scheme presented by Castro (2015) and Castro et al. (2015), to evaluate and compare their performance.
To accomplish this, the dynamics of the orbiting satellite and the dynamics of the CMGs were modeled, the two control techniques were implemented in simulation for the same system and their performances and control actions are presented and discussed at the end of the work.

METHODOLOGY
The methodology of this study is divided in order to follow the logical sequence of implementation used. Initially, the modeling of the rotation dynamics is presented and, subsequently, the techniques used to design the attitude control systems. Since the purpose of this paper is to evaluate attitude controllers, the translational dynamics of the satellite is neglected. This is possible because the orbit considered is circular and, according to Wie (2008), the rotation dynamics is decoupled from the translation dynamics for this type of orbit.

Dynamic Modeling
According to Wie (2008), the equations of the rotation dynamics of a rigid spacecraft equipped with CMGs are given by Eq. 1: (1) in which H s is the vector that represents the angular momentum of the system, T ext is the total external torque vector and ω is the body's angular velocity vector. All of them represent the body-fixed coordinate system.
The total angular momentum vector, H s , is given by the sum of angular momentum of the main body and CMGs. It is written as presented in Eq. 2: (2) where I b is the spacecraft inertia matrix, including the CMGs, and h is the total angular momentum vector of the CMGs, both expressed in the body's reference system. In this work, the small inertial variation due to the gimbal rotation is neglected.
The combination of Eqs. 1 and 2 result in Eq. 3: (3) and, by emphasizing the CMG control torque vector, u, Eq. 3 can be rewritten as presented in Eq. 4: where u satisfies the relation given by Eq. 5: There are several external torques that can act on the system but only the Earth's gravity gradient torque is considered in this study. The model used is the one shown by Wie (2008), in Eq. 6: where n is the orbital rate and k b is the vector with origin on the body's center of mass and pointing to the Earth's center.
The total angular momentum vector of the CMG, h, depends on its configuration. For this study, a single-gimbal control moment gyroscope (SGCMG) is adopted. In this case, with a four-gimbal configuration in a pyramidal shape, h is given by the sum of the individual angular momentum of each gimbal, expressed by Eq.7: where H i is the individual angular momentum of the i-th gimbal and δ i is the angle between the angular momentum vector H i and the respective pyramid base.
The rotation δ i occurs so that the angular velocity vector δ . i is always perpendicular to the respective pyramid side, as shown in Fig. 1 for δ i = 0. This means that the i-th CMG rotates an angle δ i about an axis perpendicular to the respective face of the pyramidal system and the H i vector of the CMG is always contained in the plane of this face. The β angle in Fig. 1 corresponds to the inclination of the pyramid's side faces. According to Wie (2008), in general, β = 54.73° is used because it is an orientation that presents enough robustness against control singularities.
Based on Fig. 1, Eq. 7 can be expanded as presented in Eq. 8: The time derivative of h is given by Eq. 9: where, L is defined as shown in Eq. 10: and, δ is expressed by Eq. 11: Finally, according to Wie (2008), the pseudoinverse matrix L + is used to get the dynamics of the CMGs in the form shown in Eq. 12: From Eq. 5, one can express h . as shown in Eq. 13: and by making Eq. 13 in Eq. 12 the dynamics of the CMGs as a function of u (torques from the control system) and h (calculated as a function of δ by Eq. 7, where the angles, δ, are states of the augmented dynamics) is obtained.

Design of the Control Systems
The design of the control systems was made with two techniques, the Linear Quadratic Tracker and the Exponential Mapping Control.

Linear Quadratic Tracker
The Linear Quadratic Tracker (LQT) technique considers a linear system described in the state space form by Eq. 14: (14) in which A and B are the Jacobian matrices of the system, x is the state vector, u is the control vector and y is the output of the system, related with x by the C matrix. The pure integral compensator dynamics is described by Eq. 15: where F, D, G and J are the matrices of the compensator, w is the state vector of the compensator, v is the output and e is the error vector of the compensator, given by Eq. 16: where r is the reference, and z = Hx contains the tracked states. H is a matrix that will select ϕ, θ and ψ as tracked variables. The C matrix is different from H, specifically for the case C = l 6x6 .
With the block diagram of Fig. 2, it is possible to write the u vector as given by Eq. 23: It's possible to determine the optimal gain matrix K 1 , according to Stevens et al. (2015), minimizing the same performance index that one linear quadratic regulator (LQR) with a cost function J 1 , given by Eq. 24: in which Q is a positive semidefinite Hermitian matrix and R is a positive definite Hermitian matrix. These matrices define the relative importance of the state and the consumption of energy by the controls.

Exponential Mapping Controller
Exponential Mapping Control (EMC) was first proposed by Castro et al. (2012). According to the author, it unifies some advantages of two distinct methods, the conceptual simplicity of a sliding mode control (SMC) and a fuzzy logic controller (FLC), in order to abandon the need for a model, to deal with nonlinearities and to have the capability of using heuristics for tunning. The method is also based on a boundary layer solution, able to deal with the chattering that can be experienced by SMC designs in systems with actuator delays or limited sampling rate.
Since its proposition, the effectiveness of the method has been verified through simulations and experiments for several different systems. Castro et al. (2012) applied the method in simulation to control a small single-engine aircraft and a widebody jet airliner under stochastic winds and wind shear. Castro (2015) formalizes the method and presents simulation and experimental results in a Quanser laboratory helicopter. Portella et al. (2018) presented a comparison between an optimized EMC and an optimized LQT applied to an inverted pendulum system. The results show that the two designs can perform very well, but EMC converges quicker towards the sub-optimal solution. A highly nonlinear system, including unsteady aerodynamics and time variating inertias, was approached by Luz et al. (2019), where the system was successfully controlled using EMC.
To implement the EMC, it is necessary to define two initial parameters heuristically. The first parameter is the error range, e r , which is found by applying a maximum control input in a stable plant and then analyzing both its steady-state output and its settling time. This value can also be thought as the maximal acceptable error before applying the maximum control action. The second parameter is the format of the controller input function, u s , which is found by comparing the input with the output function format. Both parameters are determined from the output of a stable plant in open loop, when the maximum control input is applied. One of the possible interpretations is that the system will reach zero steady state error by following the path used to reach its limits, which is its natural path.
This controller implementation requires the following steps: 1. Commuted error evaluation, obtained through Eq. 25: where x ref is the reference of any x state and e r is the first project parameter. 2. e t parameter is bounded to the -1 and 1 limits, as in Eq. 26: 3. Exponential function evaluation, expressed by Eq. 27: where sing(e s ) is a function which returns the e s sign and u s is the second project parameter, usually ranging from -10 to 10. 4. Control output computation, according to the Eq. 28: where u max and u min are the maximum and minimum control outputs, respectively, and u is the computed actuator output.
Thus, it is possible to define a gain vector, K 2 , expressed as in Eq. 29: with j representing the number of tracked variables. The used technique on this project minimizes a cost function J 2 , which is like the integral of the time weighted absolute error (ITAE), that follows in Eq. 30: where t p represents a time value greater than the settling time. Therefore, a new closed loop simulation must be performed for each iteration.
The control system architecture is analogue to the one shown in Fig. 2. Since EMC is a single input single output (SISO) control method, it is required to associate a control variable to each error. For example, the control output u x ϕ is generated to correct the angular position error e ϕ and the control output u x ϕ is generated to correct the angular velocity error e ϕ . Thus, the control torque u x at the x axis is defined as Eq. 31: The control torques u y and u z , acting respectively on the y and z axis, are determined similarly. The control vector produced by the EMC is defined by Eq. 32: (32)

Plant and operation parameters
For the simulation, the inertia parameters of the Amazon I satellite were used, its inertia tensor, I b , is described by Eq. 33: Due to the idealization adopted for the gimbals, their angular moments were estimated from other satellites, as expressed in Eq. 34: The orbit was designed as circular and with a 2-hour orbital period, which leads to an orbital rate n of 8.7266 × 10 -4 rad/s. To perform the maneuvers, a part-defined function given by Eq. 35: was used as a reference, where t s = 70.s is the rise time, the vectors r i and r f contain the variables tracked at initial and final equilibrium condition, respectively. The vector r f is given by Eq. 36: where the final angular velocities P f , q f and r f are obtained by calculating the equilibrium condition for the final attitude defined by the Euler angles θ = 30°, ϕ = 20° and ψ = 10°. Note that the angular velocities P f , q f and r f , relative to roll, pitch and yaw velocities, are inertial and represented in the body system. The angles θ, ϕ and ψ are the roll, pitch and yaw Euler angles, referred to as the three elementary rotations (rotation sequence adopted is the aerospace sequence, 321) from the Local-Horizontal-Local-Vertical (LHLV) to the body frame.

Linear Quadratic Tracker gains
To compute the optimal gain matrix, the linearized plant of the system and the weighting matrices R = l 3x3 and Q = H T a H a are considered. The optimal gain matrix K 1 is, according to Stevens et al. (2015), given by Eq. 37: where S is obtained from the solution of Riccati algebraic equation, shown in Eq. 38 (38) The solution of Eq. 38 is found by using a ®MATLAB function called LQR. Thus, the matrices K y and K v are given by Eq. 39 and Eq. 40, respectively:

Exponential Mapping Control gains
The choice of EMC parameters occurred through a minimization process, which converged to the parameters shown in Eq. 41:

RESULTS AND DISCUSSION
With the obtained results, it is possible to analyze the behavior of both implemented control techniques, using the same initial angular position and angular tracking position. It is important to highlight that the main goal of this study is not to compare both controllers, but to evaluate the performance of a control structure not yet implemented in this type of plant. Therefore, this new structure is compared to a well-known and consolidated control technique. Figure 3 shows the angular position and angular velocity of both methods and the tracking angles ϕ, θ and ψ which begins at 0° and ends at 30°, 20° and 10°, respectively. As shown, both structures are successful since, in the worst case -yaw -, they reach the equilibrium condition in less than 2 minutes.
The angular velocities move towards the desired condition faster through the EMC technique; however, it displays a higher oscillatory behavior. These oscillations are repercussions of the control output of each of the methods. Although there is this difference, both techniques performed the maneuver and obtained zero steady-state error.       Through the comparison of the control laws presented in Fig. 5, it is possible to conclude that the EMC control displayed higher control outputs, which generated higher peaks of short duration when compared with the settling time. In Fig. 5, the CMGs' higher control output is visible. In addition, the control output during time is more oscillatory than the LQT method. In reality, a more intense control output requires a bigger and heavier actuator.
In general, the high settling time obtained for the LQT can be credited to the use of only an integral compensator, instead of an integral and derivative compensator. The settling time could be reduced if a proportional integral derivative compensator (PID) was used, for example.

CONCLUSION
A satellite in a circular orbit with four CMGs in a pyramidal arrangement was modeled. Therefore, a nonlinear (EMC) and a linear (LQT) control technique for attitude maneuvers were evaluated. The EMC's gain matrix shown in Eq. 41 was obtained numerically while the LQT's gain matrices were obtained analytically, as presented in Eqs. 39 and 40.
The performed simulation considered the gravity-gradient torque disturbance and the change in the satellite attitude reference. As shown in Fig. 3, both controllers could follow the angular reference and keep the desired final angular velocity in less than 2 minutes. It is also possible to observe that the EMC displayed a faster but more oscillatory performance than the LQT. However, this conclusion is not always valid since the LQT performance can be altered through the weighting matrices, as displayed in subsection Linear Quadratic Tracker gains. Distinct techniques were used to obtain the gain matrices and define the cost functions. Therefore, a direct comparison between the performance of both methods is not possible. In further works, it is suggested minimizing the same indexes and bounding them to the same restrictions in order to determine the EMC and LQT gains, this allows a direct comparison between these two control techniques. It is also suggested to evaluate both algorithms' robustness in different operation regions, far from the equilibrium point, with which higher angular references can be used.