LIDS-P-1984 Il-Optimal Attitude Control of a Space Station M.A. Dahleh D.M. Richards April 30, 1990 Abstract I'-optimal control theory is applied to the space station attitude control and momentum management problem. A linearized model of the space station is used for control design and the responses of the linear systems to a specific sinusoidal disturbance input are studied. This research is partially supported by the U.S. Army Research Office, contract DAAL03-86-K-0171 (Center for Intelligent Control Systems), and by the National Science Foundation under grant NSF 8810178-ECS. 1 Background This report looks at the design of an 11-optimal controller for the attitude control and momentum management of a space station. This problem arises from using momentum exchange devices such as control moment gyros (CMG's) to perform attitude maneuvers such as counteracting disturbance torques [6,7,1,9]. Reaction torques are produced on the station by altering the momentum of the CMG's. Uncontrolled, the CMG's will eventually saturate (reach some upper limit of accumulated momentum) and desaturation maneuvers are necessary. Desaturation is accomplished by applying external torques to reduce the stored momentum. A desirable method of controlling the accumulated momentum is to use gravity-gradient torques which result from unequal gravitational forces across the body of the station. In this scheme, a controller will try to drive the station to a torque equilibrium attitude (TEA) in which the disturbance torque is balanced by the gravity-gradient torque. The major disturbance torque is the aerodynamic torque from atmospheric drag. This is a constant offset with sinusoidal components from density deviations and articulating components of the station such as solar panels or antennas. The constant offset will dictate a constant TEA, but the cyclic components of the disturbance will cause a cyclic attitude profile. Under these conditions, the job of the controller is to seek the constant TEA while minimizing the cyclic excursions around this constant. Another desirable quality of the controller is robustness since other disturbances may be encountered or the properties of the station may change as people or equipment come and go. Finally, the controller will be designed using a linearized version of a non-linear model. Since the linearization is only valid for small deviations away from the linearization point, it is desired to minimize excursions away from this point. For the space station case, variable values are nominally zero, so the objective is to keep all values as small as possible at all times. For these reasons, /loptimal control seems like a good choice for the space station. 11 controllers are designed to minimize the maximum magnitude of system response to arbitrary l°° signals and include some guarantee of robustness [3,5,2]. These properties are just what is called for in the space station problem. 2 2 Space Station Model For examining the problem of space station attitude control and momentum management, a dynamic model of the station's orbital movement was necessary. It was desired to use as simple a model as possible while retaining the essential features of the system. These main features are the rigid body dynamics of the station, the CMG dynamics, and the gravity gradient effects. For space station analysis, three coordinate frames are utilized for convenience of reference. First is the body frame, denoted by XB, YB and zB. This coordinate frame is aligned with the principal axes of the station and is convenient for looking at quantities associated with the station itself such as the CMG torques. Secondly, there is the local vertical local horizontal (LVLH) frame, denoted by XL, YL and ZL. This frame is referenced to the earth and the station orbit. The line from the center of the earth through the space station defines ZL. The line perpendicular to zL in the direction of the orbit defines XL, and YL completes a right-handed coordinate system. The final frame is the inertial frame, denoted by xI, yI, and zI, which is fixed in space. Notice that both the body and LVLH frames are functions of orbital position. The inertial frame is necessary as a fixed reference for the moving frames. The inertial frame is usually fixed as being coincidental with the LVLH frame at some initial time To. The LVLH frame then rotates at orbital frequency with respect to the inertial frame (after one orbit they are again coincident). It will be desired that the space station orbit in LVLH attitude. That is, the body coordinates should be aligned with the LVLH coordinates at all times. This means that, in the inertial frame, the space station must be rotating with orbital frequency w0 as it orbits. The basic equations for the space station rigid body dynamics are Eqns. 1 and 2 where H is the momentum of the station, I is the inertia tensor, and Wis the station rotation in the body frame. H = H = IZ (1) re =I +T xI (2) Eqn. 2 relates the change in momentum of the station to the external torques (re,) acting on the system. er, can be expanded as shown in Eqn. 3, where 3 is the reaction torque of the CMG's on the station, rgg is the gravity gradient torque, and rd is a disturbance torque (which may itself have several contributing terms). TCMG Z Te = -CMG + rg + 7rd (3) The final set of simplified dynamic equations is reached after substituting an expression for the gravity gradient torque, referencing all quantities to the appropriate frames, and assuming small cross products of inertia and small angular deviations. The results are shown in Eqs. 4-6. I 03)3 + 4 - 131 -12 + I202 + 3wo(I 1303 + w2(02 - 11)03 + wo(I - -U01 + W1 (4) 3)02 = -u 2 + W1 (5) 2 + I3)01 = -U 3 + (6) - 3 The ui's represent the body axis components of the control torques, the wi's represent the disturbance disturbance the torques, and the Oi's are the roll, pitch, and yaw (12-3) Euler angles of the body axes referenced to the LVLH frame. Similarly, the simplified CMG dynamics are given by Eqs. 7-9. ul = h1 -w U2 = h2 (8) U3 = h 3 + wohl (9) 0 h3 (7) These sets of equations are standard for the problem and a detailed derivation can be found in Bishop [1] or Wie [9]. Other than the assumptions of small angles and small products of inertia made to simplify the equations, the other main assumption in the model is that flexible body dynamics can be ignored. This is not really a major approximation for attitude control since the flexible body dynamics are generally not in the same frequency range as orbital dynamics. Also, this example is not intended to contain such great detail. The actual values for the Ii and wi were taken from Wie [9] and are typical numbers for most proposed space station models. They are essentially similar to the numbers used in Bishop [1]. Looking at Eqn. 5 it is seen that the pitch dynamics are decoupled from the roll and yaw dynamics. This allows control design to be done on two smaller systems rather than on one large system. 4 Block pitch h fh control Zeros 1, 1, -1 1, 1.3732 1.3732, -1 1, 1, 1.3732 Table 1: Interpolations on T2 2.1 Pitch Axis Controller Design The matrices A, B, and C for the state space description of the pitch dynamics described by Eqn. 5 and Eqn. 8 are listed in Appendix A. Both the continuous time and discretized versions are given. The four states in the pitch axis dynamics are the pitch rate, the pitch, the CMG momentum, and the integral of the CMG momentum. The integral of the momentum is included to ensure that the momentum settles to zero for a step disturbance. The first attempt at an 1' controller design was for the pitch axis dynamics since this was the simplest system. Initially, the regulated variables were the pitch angle, the CMG momentum, the integral of the momentum, and the control input. Scalar weights were used to scale the variables to approximately unity. From [5,8], it is required to compute the zero structure of two matrices T 2 and T 3 . For details on this problem, check [8]. For this particular configuration, both T 2 and T 3 are 4 x 1 matrices. T 3 has no interpolations, and for T 2 interpolations are found for the four SISO blocks since it is a "tall" matrix. The interpolations for each block are listed in Table 1. The interpolations are listed to point out one of the MATRIXx problems that was found. For the f h block, the 'ZEROS' function of MATRIXx does not find the zero at z = -1. This turned out not to be a problem since this is apparently a redundant constraint and was satisfied despite the fact that it was not explicitly included in the LP formulation. The regulated variables, the assigned weights, and the resulting 11 norms for several solutions are given in Table 2.1. The first noticeable feature of these results is that as expected, a larger length of solution (1) yields a lower 5 weight optimal norms I= 9 1= 16 1 = 20 pitch 1.0 0.1164 0.0975 0.0973 Regulated Variables CMG momentum (h) fh control 10 - 4 10-6 10-2 1.2577 0.9332 0.9305 1.2653 0.9482 0.9454 1.2653 0.9482 0.9454 Table 2: Optimization Results With Scalar Weights norm. This will be the case whenever there are interpolations on the unit circle or relations. Note also that the norms in Table 2.1 are the scaled norms. To get the actual values, these numbers should be divided by the scale factors. The units for the unscaled norms are radians, ft-lbs, ft-lb-sec, and (ft-lb)/sec, respectively. The 11norms of the responses represent the largest possible oo-norm of the responses to any l °° signal of unit magnitude. For the I = 20 case, then, the largest possible magnitudes of the regulated variables would be 5.6 degrees, 9305 ft-lbs, 945400 ft-lb-sec, and 95 (ft-lb)/sec. Of more direct interest, however, is the response to the particular disturbance used in this model: (10) w(t) = 4 + 2 sin wot + 0.5 sin 2wot. Figures 1 and 2 show the pitch angle responses for the I = 9 and I = 20 cases. Figures 3 and 4 show the CMG momentum responses, and Figures 5 and 6 show the control input. An interesting characteristic of these solutions is that while the peak magnitudes of the responses decrease with increasing 1, the steady-state peak values actually increase. Presumably this trend would continue until the two quantities were equal. These responses are nearly identical to the LQR synthesized results of Wie [9]. A feature of the l1 optimization revealed by this initial design is that some of the LP constraints are redundant. The optimization was done neglecting 6 5g 0 Ca 0O i ' i' '. i I ' -15 I ; -20 0 I I 4 3 2 1 time (orbits) 5 Figure 1: Pitch Disturbance Response (1 = 9) 7 · · o 1 - 5 ..... ..T) 0 II I ....! iI ..... r a · · I L · · · ..... i · 1 2 3 4 time (orbits) 5 Figure 2: Pitch Disturbance Response (I = 20) 8 25000 20000 ----.------------ --------·---- 15000 2 50000 .......... ....................... ........... ........... 15000 .......................................... E.! . . 5000 E- - 5000 ... .. 0 1 2 3 4 time (orbits) Figure 3: CMG Momentum Disturbance Response (I = 9) 9 5 20000 I C0. , - --0 1 C E E : : 3 4 15000 10000 ' ~-, 2 5 time (orbits) Figure 4: CMG Momentum Disturbance Response (I 10 20) 100 ..--..----.-.-......----.----..--- a_50 -... - ... 0 -50 D' :' 5: Control Figure 3 = 9) 4 2Input (1 0 2|3 11 time (orb~~~its time (orbits) 5 100 50 _ ~~0~~~~~~·e 0 5 0 ......................................................... 0 - Figure06: Control 1 Input 2 (I =320) 0 4 5 1 2 3 4 time (orbits) 5 Figure 6' Control Input (l = 20) 12 the derivative conditions (multiple zeros were ignored) and neglecting the f h interpolation at z = -1 (MATRIXx problem), and the solution was identical to the case with these interpolations included. It is unknown whether any of the relation constraints were redundant, but this is a possibility. A means of eliminating the redundant constraints before starting the optimization would be very helpful, particularly in larger problems, since it would reduce the size of the LP. Calculating the optimal controllers turned out to be very difficult. For the I = 9 and I = 16 cases, controllers were calculated, but did not simplify as they should have. In the I = 20 case, the controller could not be calculated at all. The problem is with determining the minimal realization for a system. Even in the cases for which results were obtained, the controllers had many poles and zeros which should have been canceled but were not. With increasing I this problem became worse until the controller was no longer stabilizing. For calculating the controller the code implemented here was nearly useless. The process had to be carried out one step at a time with careful intervention by the user at each step to manually perform the appropriate cancellations and simplifications. This is a laborious task and is all but impossible beyond SISO systems. To explore the effect of changing the problem, the scale factors were varied and different combinations of the regulated variables were used. This particular problem was relatively insensitive to such changes. The solutions were essentially identical in all cases. The next design approach was to specify rejection of the sinusoidal components of the disturbance in the pitch output. To do this, a sinusoidal weight was introduced on the pitch output of the station as shown in Fig. 7. After optimization, this weight was included as part of the controller rather than as part of the plant. The effect of this is to leave the transfer functions of the unweighted variables unchanged while including the denominator of the weighting function in the numerator of the weighted transfer function, giving the desired rejection of the sinusoid. The actual weighting function was Eqn. 10 which is the disturbance model. The effect of this weighting can be seen in the frequency response of the system. The scalar weighted system is shown in Fig. 8 and the sinusoidally weighted system in Fig. 9. The w-transform is used in Figs. 8 and 13 weighted pitch h control Figure 7: Weighted System -45 i ' -548i........ . .- ............ I I I. I. I. - ........ .... . . i I · i ------ Figure 8: Frequency Response with ; Scalar.. Weight 0 . . . ...... ..... .0001 .00 -60.0001 4 / - . Figue Frqueny 8 Rspose C 54 .0.1 .001. . / . . ' ~~~~. .'.01 . ith calr Wigh ""C--i··ii1-14III III , 20 -60 -20 :: , iI) I' '. .;''. : ! '' '4~4~ ' '' - ......: .: -12 . ...... i - 60. F,, I ,,,F4, 000 _ II _ ; ,-v i * II Ii 01 1 Figure 9: Frequency Sinusoidal Weight . : Response : i i i: with 8 . * scaled i .'.... i f req :i'i ' 10 I : ' ! ! ' I! i 'I II ! ! ! :::: :::id Fi20r ........ ! fe..... RspnewihS~uO~a Wih ......I .. t---t---.(..... .. ~--- t--:-II 9 to scale the frequency axis to approximate the continuous time frequency. The relation is described by Eqn. 11. 1 + wAt/2 1 - wAt/2 (11) Fig. 9 exhibits notches at orbital frequency (0.0011 rad/sec) and twice orbital frequency. This is the result of the weighting to reject the sinusoids at these frequencies. The result in the time domain is a non-cyclic response to inputs at these frequencies. The first iteration of this design used only the weighted pitch as a regulated variable. The resulting system possessed the desired property of rejecting the sinusoidal disturbance, but the transients at startup from zero initial conditions were excessively large as were the required maneuvering rates. As a result, other combinations of variables were explored in an attempt to achieve better values. Since the system regulating the weighted pitch was designed to reject the cyclic portion of the disturbance, the large magnitudes in the disturbance response must have been a result of the step component. To cure this, the regulated quantity was changed to the sum of the weighted and unweighted pitch. This had a profound effect on the disturbance response as can be seen in Fig. 10. After rearranging the system to include the weighting function in the the controller (K -+ K'), the I1 norm of the pitch pulse response is 12 degrees. This is the maximum pitch deviation for any arbitrary l' signal of unit magnitude. The fast oscillations during the startup transient indicate that large control magnitudes are necessary at these points and saturation limits may be exceeded. This situation could be rectified by including the control as a regulated variable to smooth out the peaks somewhat. This, of course, would have the effect of raising the magnitude of the pitch response slightly. An interesting issue arose from the weighted pitch designs. One system was scaled to radians and one was scaled to degrees. It was expected that these would yield identical results (scaled by 180/r, of course), and did in the majority of cases. In several cases MATRIXX would calculate different zeros for the two systems yielding different optimizations. This of course was an error, but in the radian system, the solution had a curious property. The solutions for I = 27, 1 = 28, 1 = 29, and I = 30 were precisely identical 16 2 a, ....................................... -2 -2 L.........:........ -10 0 2 1 time (orbits) 3 Figure 10: Response Regulating Weighted and Unweighted Pitch .^ 11 -i *~~~~~~" 1-- -~~~~~~--~~~~~"1 17 and the solutions for I = 45 and I = 60 decreased as expected. The issue is whether the 1' norm strictly decreasing with increasing 1. If it is, then a plateau as observed in the above problem cannot be a valid solution. 2.2 Roll-Yaw Axis Controller Design The roll/yaw control design for the space station was carried out for only the unweighted case because of difficulties obtaining the parametrization in the very first step. The discretized system is such that it is extremely difficult to obtain a stabilizing set of regulator gains. Only after many trial-anderror iterations was a set finally obtained. The discretized system and the regulator gains are shown in Appendix B. Initially, the design was done regulating only the roll and yaw angles. The roll and yaw axis disturbances were both taken to be l+sin(wot)+0.5 sin(2wo) as in [9], and the resulting responses are shown in Fig. 11. In this case I = 15 and the optimal norm is 1.49 degrees. It was not reasonably possible, however, to derive the controller from the optimal solution. Different values of I were used and the same trend was observed here as was seen in the pitch control design. Larger 1 yielded smaller norms (for example, I = 20 gives a norm of 1.25 degrees compared to 1.49 degrees at I = 15) but slightly larger peak values for the oscillations in steady state. It should also be noted that although the control and momentum variables were not regulated, their values fell well within the saturation limits. Although the momentum and control variables fell within limits, an attempt was made to regulate the momentum in addition to the angular deviations. This was done to test the operation of the algorithm on a more complex system. The. problem appeared to be formulated correctly, but the LP solver could not converge to a solution. More powerful LP software would probably overcome this difficulty. 3 Conclusions An 11-optimal control design has been done for the space station attitude control/momentum management problem. For the pitch axis the design has been formulated to reject cyclic disturbances, at orbital frequency and twice 18 0 -2 _s . *T V w ly- l | j - ---- !r- v-- --a.. .v.--..! 'I_ .... ,5...,......s -- '''......'-'......-'-tI .........--. I - * *.! '... time (orbits) yaw-- roll- - Figure 11: Roll and Yaw Responses 19 i-By- It orbital frequency, which are unknown but bounded. The responses to a specific sinusoidal disturbance have been studied and the deviations are on the order of a few degrees on each axis. For the roll and yaw, solutions were obtained only for the unweighted problem. For the weighted problem, the algorithm failed to provide the initial stabilizing solution due to sensitivity problems, and hence failed to provide meaningful solutions. It appears that much of the problem is due to MATRIXx and the linear programming algorithm. For the future work, we plan to convert this algorithm to run Matlab rather than MATRIXx. The sensitivity problems will then be isolated and removed. We also anticipate using a more reliable LP that can handle a large number of constraints. The new algorithm will then be tested on the weighted problem for the roll and yaw dynamics. Although the responses obtained are essentially similar to other results from the literature, the real test of the 11 controller will be when the actual controllers are derived and used to control the full non-linear system rather than just the linearized versions. It is thought that the 11-optimal controller will provide performance superior to other controllers such as an LQR design as in [9] or a controller based on once-per-orbit samples as in [1]. 20 References [1] L.R. Bishop et al.. "Proposed Momentum Management Scheme for Space Station,"JSC Technical Report. [2] M.A. Dahleh and Y. Ohta. "A necessary and sufficient condition for robust BIBO stability," Systems and Control Letters, Vol. 11, pp. 271275, 1988. [3] M.A. Dahleh and J.B. Pearson. "1 optimal feedback controllers for MIMO discrete-time systems," IEEE Trans. A-C, Vol AC-32, April 1987. [4] M.A. Dahleh and J.B. Pearson. "L 1 optimal feedback compensators for continuous-time systems," IEEE Trans. A-C, Vol AC-32, October 1987. [5] M.A. Dahleh and J.B. Pearson. "Optimal rejection of persistent disturbances, robust stability and mixed sensitivity minimization," IEEE Trans. Automat. Contr., Vol AC-33, pp. 722-731, August 1988. [6] R.E. Oglevie."Space Station Attitude Control - Challenges and Options," AAS 83-066, Annual Rocky Mountain Guidance and Control Conference, Keystone, Colorado, Feb. 5-9, 1983. [7] C.D. Johnson and R.E. Skelton."Optimal Desaturation of Momentum Exchange Control Systems," AIAA Journal, Vol. 9, No. 1, 1971. [8] D.M. Richards. "Il-optimal control: Solution software and design examples," M.S. Thesis, LIDS-TH-1906, MIT, Cambridge, August 1989. [9] B. Wie et al.. "A New Momentum Management Controller for the Space Station," submitted to AIAA Journal of Guidance, Control, and Dynamics Jan. 19, 1988. 21 A Space Station Pitch Axis System Matrix Figures 12 and 13 show the continuous time matrices describing the space station system, and Figures 14 and 15 show the discretized versions with At = 190 sec. Both C matrices are 4x4 identity matrices and are not listed. 0 2.7864x10 - 6 0 0 1 0 0 0 O 0 1 0 Figure 12: Continuous Time Pitch A Matrix 9.2593 x 10-8 0 B1 = 0 9.2593 x 10-8 , B2 = 0 0 0 Figure 13: Continuous Time Pitch B Matrices 1.0507 1.9320 x 102 5.3833 x 10-4 0 0 1.0507 0 0 0 0 1 0 0 0 1.9000 x 102 1 - Figure 14: Discrete Time Pitch A Matrix B Space Station Roll and Yaw System Figures 16 and 17 show the A and B matrices for the discretized space station roll/yaw dynamics. In the B matrix, the first two columns are for the 22 1.7889 x 10 -5 1.7889 x 10- 5 1.6854 x 10 - 3 1.6854 x 10 - 3 0 - 1.9000 x 102 0 -1.8050 x 104 Figure 15: Discrete Time Pitch B Matrices disturbance inputs and the last two columns are for the control inputs.The stabilizing regulator gains are listed in Fig. 18. 23 Columns 1-4: 1.0115 x 100 4.1115 x 10-1 -3.5296 x 10-1 9.4297 x 10-1 1.9074 x 102 3.8889 x 101 -3.3385 x 101 1.8640 x 102 O 0 O 0 O 0 0 0 8.7707 x 10- 4 3.1719 x 10- 5 -1.5352 x 10- 4 1.5203 x 10- 4 1.0832 x 100 2.0053 x 10- 3 -9.7057 x 10 - 3 1.0146 x 100 0 0 0 0 0 0 0 0 Columns 5-8: 0 0 0 9.7824 x 10 - 1 -2.0748 x 10-1 1.8862 x 102 -1.9783 x 101 O 0 0 0 2.0748 x 10 - 1 9.7824 x 10-1 1.9783 x 101 1.8862 x 102 0 0 0 0 0 0 1 0 O0 0 0 0 0 0 0 1 Figure 16: Discrete Time Roll/Yaw A Matrix 3.7935 x 10 - 6 -6.6398 x 10- 7 3.5969 x 10 - 4 -4.1978 x 10- 5 0 0 0 0 6.6398 3.1825 4.1978 3.0526 x x x x 0 0 0 10 - 7 3.7935 x 10-6 -6.6398 x 10 - 7 3.5969 x 10- 4 -4.1978 x 10- 5 -1.8862 x 102 1.9783 x 101 -1.7984 x 104 1.2547 x 103 10-6 10- 5 10 - 4 0 6.6398 x 10 - 7 3.1825 x 10-6 4.1978 x 10- 5 3.0526 x 10 - 4 -1.9783 x 101 -1.8862 x 102 -1.2547 x 103 -1.7984 x 10 4 Figure 17: Discrete Time Roll/Yaw B Matrix 24 Columns 1-4: 1.1595 x 105 4.9158 x 104 2.5428 x 102 -4.1107 x 101 2.5914 x 104 1.0981 x 105 1.8354 x 102 6.0033 x 101 Columns 5-8: 4.1508 x 10- 5 5.2889 x 10 -5 -1.0000 x 10- 7 -1.0000 x 10 - 7 -2.1350 x 10 - 5 3.1989 x 10 - 5 1.0000 x 10-s -1.0000 x 10 - 8 Figure 18: G Such That (A - BG) Is Stable 25