1WNWNWE110Wk§ Intelligent Precision Attitude Control for the USAF A-10 Aircraft by Bradley Thomas Burchett Submitted to the Department of Aeronautics and Astronautics in partial fulfillment of the requirements for the degree of Master of Science at the Massachusetts Institute of Technology June 1995 @Bradley T. Burchett, 1995 All rights reserved The author hereby grants to MIT permission to reproduce and to distribute publicly paper and electronic copies of this thesis document in whole or in part. Signature of Author D6partment of Aeronautics and Astronautics , submitted: May 12, 1995 I I Certified by Frofessor John J. Deyst, Jr. Thesis Supervisor, Massachusetts Institute of Technology Approved by Edward V. Bergmann Technical Supervisor, The Charles Stark Draper Laboratory, Inc. Approved by_ -Thesis Thomas V. McNamara Supervisor, The Charles Stark Draper Laboratory, Inc. Accepted by ....... irotessor Harold Y. Wachman Chairman, Department Graduate Committee -v MASSACHUSETTS INSTITUTE OF TECHNOLOGY JUL 07 1995 LIBRARIES Aero - - -'--'-- -- -- Intelligent Precision Attitude Control for the USAF A-10 Aircraft by Bradley Thomas Burchett Submitted to the Department of Aeronautics and Astronautics on May 12, 1995 in partial fulfillment of the requirements for the Degree of Master of Science in Aeronautics and Astronautics Abstract The A-10 aircraft was designed to provide highly accurate weapons delivery for the close air support role. Its primary weapon is the 30mm cannon which is fixed to the airframe; in order to aim the weapon, you must point the aircraft appropriately. The weapon produces a considerable amount of recoil. Since the force axis of the gun is not through the aircraft center of mass, it produces substantial pitch torque, upsetting the pilot's aim. This gun also produces enough smoke to disrupt the airflow over the aircraft horizontal stabilizer while that control surface is opposing the recoil. The purpose of this thesis is to improve the aircraft disturbance rejection. This task is subdivided into two tasks. 1) Improve the estimate of elevator input necessary to offset the gun recoil. 2) Improve the estimate of smoke disturbance. These improved estimates can be used to better design a feed forward control input to offset the disturbances. This paper uses a recursive least squares technique to estimate mass properties of the airplane. These updated mass properties are used to predict the input necessary to offset the disturbances. A Radial Basis Function network models the deterministic portion of the smoke disturbance, and is used to update our disturbance model after each gun pass. Thesis Supervisor: Professor John J. Deyst, Jr. Title: Professor of Aeronautics and Astronautics, MIT Technical Supervisor: Edward V. Bergmann Title: Technical Staff Member, The Charles Stark Draper Laboratory, Inc. -D. _ __ 1__ __11_1_~ 1 I Acknowledgments (12 May 1995) I thank Mr. Edward Bergmann for all his technical assistance and insight in the writing of this thesis. I truly appreciate his expertise. I also thank Jeff Eggers for all his assistance with this thesis. The writing of this thesis also benefited from the technical assistance of Mr. Brent Appleby. Thank you. This thesis was prepared at The Charles Stark Draper Laboratory, Inc., under Air Force contract F04606-89-D-0035-0006. Publication of this thesis does not constitute approval by Draper or the United States Air Force of the findings or conclusions contained herein. It is published for the exchange and stimulation of ideas. I hereby assign my copyright of this thesis to The Charles Stark Draper Laboratory, Inc., Cambridge, Massachusetts. Bradley T. Burchett Permission is hereby granted by The Charles Stark Draper Laboratory, Inc., to the Massachusetts Institute of Technology to reproduce any or all of this thesis. Let me thank you in order of your appearance in this venture. Thanks to Javed Siddiqui for the application to MIT. Thanks to Nate Smith for your friendship and encouragement, even before I was a Draper fellow. Thanks to Jack Stebe and John Sweeney of Draper Lab for "giving that guy from Maine a chance". Thanks to Professor H. Asada for his insight into how to apply a Radial Basis Function to this problem. Mom and Dad thanks for everything. Thanks especially, to my wife Carol. You definitely have the tougher career! Without you, I couldn't be an AF pilot, MIT graduate, and father of four! Thanks to Tabitha, Claudia and Lydia for their patience, understanding, and encouraging love. Jeff Eggers, and Nate Smith I enjoyed sharing an office with you. Thanks for the friendship. But these were all merely instruments in the hands of the Creator who is praised forever. Kai amoi tvigrlo1v awi6v t cprpia 6d' t6 aiw rob apvtou, m i td to6v X6yov tf ourut&v, Ioexi o)c TiyxlG V TV fl'v uXlv abruv dXpt v ro-6rotq adoiv cava&rou. AHOKAAYTIE 12:11 CEpVtKW v 81 td rob dyaxioavAoI 8:. PQMAIOYX 8:37 __ ~_~~_~_~_~_~~~ ~ ._ Table of Contents List of Figures.................................................... ...................................................... 7 List of Acronyms & Selected Abbreviations ..................................... ............. 9 1.0 Introduction .......................................................... ............................................ 11 1.1 Background ........................................................................ ................... 11 1.2 Problem Statement ............................................. ........ 11 1.3 Approach to Solution ............................................ ....... 12 2.0 System Requirem ents....................... .............................................................. 16 3.0 Improving the Plant Model................................................ 17 3.1 A Framework for Flight Dynamics............................. ...... 17 3.2 Aerodynamic Forces Estimator......................................19 3.2.1 Approximate Nature of Aerodynamic Models: ................ 19 3.2.2 Example of Coefficient of Moment at zero pitch dynam ics: .................................... .............................. 20 3.2.3 Relation of Center of Gravity Location to Aerodynamic Model: ............................................... 21 3.3 Mass Properties Identifier ............................................... 22 3.3.1 Development of a non-linear Recursive Least Squares Identifier: ................................................... 22 3.3.2 Why not Kalman Filter ? ......... ........................................... 25 3.3.3 The Recursive Least Squares Algorithm...................26 3.3.4 Determining which parameter to update by crosscorrelation of internal variables: ..................................... ... 29 3.4 Persistent Excitation .................................................... 31 3.5 Test Results from Mass Properties Identification...............................32 3.6 Input Predictor......................................................35 3.7 Hierarchical Implementation of Predicted Input ............................ 36 3.8 Adding Feedback..................................... ........... 37 4.0 Improving the disturbance Model .............................................. 38 4.1 General Approach................................................. ..................... 38 4.2 Modeling the disturbance as a change in density: ........................... 38 4.3 Use of the Radial Basis Function....................................38 4.4 Kawato's Method ...................................................... .. ........ 39 4.5 Representing Dynamical Systems with a Radial Basis Function.............................................................................................................41 4.5.1 Example Illustrating the simplicity of System Identification with a Linear Network .................................... 41 4.5.2 Examples Illustrating how the Radial Basis Function may Represent Arbitrary Functions ..................................... 43 4.5.3 A Function Suitable for Testing the Radial Basis Function Disturbance Approximation....................... .....46 4.6 Propagating the Disturbance Through the A-10 Plant How RBF Fits into Our A-10 Controller Design .................................... 52 5.0 Com parison to Old System ............................................................................. 65 6.0 Conclusions and Recommendations ....................................... ..... 69 6.1 C onclusions ................................................................................................. 6.2 Future issues: ..................................................................................... Appendix A : A dditional Test Results ............................................................. Appendix B: M atlab Scripts.................................................................................. References............ ....................................................................................... 69 69 70 79 95 --*-- -- List of Figures Figure page 1: Airplane as a rigid body with Recoil Force and Torque .............................. 12 2: Proposed system with Airplane Block Diagram ............................................... 14 3: A -10 shooting tank ............................................................................................. 16 4: Aircraft Body axis system ..................................................... 18 5: Earth and Body axis systems ................................................... 19 6: Cm and Cmo approximation curves ................................................................... 20 7: Raw distances between autocorrelation vectors ............................................... 30 8: Histograms of distances between autocorrelation vectors....................... 31 9: Convergence of (1/Iyy) estimate for A-10.................................. ..... 33 10: Convergence of (1/mass) estimate for A-10 ....................................... 34 11: Convergence of cg_x estimate for A-10.........................................................34 12: Block diagram of Input Predictor .............................................. 35 13: Hierarchical Implementation of Predicted Input .................................... 37 14: Using the feedback signal to improve the Disturbance Model ................. 40 15: Linear network representation of Difference Equation........................... 42 16: Results of System Identification with Linear Network................... 43 17: Two-dimensional Gaussian Function .......................................................... 44 18: Typical Radial Basis Function Neural Network............... ... 45 19: Output of Two Hidden Unit Gaussian Network..................................46 20: Non-linearity of "arbitrary" function..........................47 21: Effect of varying Receptive Widths ............................................ 49 22: Network Approximation at two different airspeeds.....................................50 23: Thirty-two two-dimensional Gaussian functions with Unit Weighting................................................................................ ............................... 50 24: Thirty-two two-dimensional Gaussian functions with Trained weigh ts ....................................................................................... ............................. 51 25: Network output after training at two distinct airspeeds ........................... 52 26: Experimental Increasing Density Disturbance Function Surface ............ 53 27: RBF Approximation of smoke disturbance after one learning iteration ................... ......................................................... ............................... 54 28: Pitch response with new system...........................................55 29: RBF approximation after two learning iterations .................................... 55 30: Pitch response with new system. ................................................................. 56 31: Pitch response without disturbance model..................................................56 32: RBF Approximation after one learning iteration.......................... ... 57 33: Pitch response with new system ............................................................ .........57 34: Disturbance surface and Approximation..........................................58 35: New system Pitch response with and without Disturbance Prediction................................................................................ ................................ 59 36: Experimental Decreasing Density Disturbance Function Surface...........60 37: Disturbance surface and Approximation.................................61 38: Pitch response with and without Disturbance Prediction ........................ 61 -sii 39: Progressive learning when feedback controller is saturated .................... 62 40: Disturbance Approximation with learning truncated..................................63 41: Pitch Responses with inaccurate disturbance estimate ............................. 64 42: Pitch Response when disturbance is assumed constant after learning truncation ................................................................................................. 64 43: Pitch response of Old system during gun firing.............................. ... 66 44: Pitch rate of Old System during gun firing .................................... .... 67 45: Old feedback signal and Least Squares estimate ............................................. 67 46: Airspeed during Gun Firing ........................................................................ 68 Al: Convergence of (1/Iyy) estimate for maneuvering T-38.............................70 A2: Convergence of (1/mass) estimate for m aneuvering T-38 ....................................................................................................... 71 A3: (1/Iyy) for T-38 with A-10 like mass properties.......................... .... 71 A4: (1/Total_Mass) for T-38 with A-10 like mass properties ............................ 72 A5: Convergence of (1/Iyy) estimate for A-10.....................................72 A6: Convergence of (1/mass) estimate for A-10................................ .... 73 A7: Convergence of cg_x estimate for A-10 .................................... ..... 73 A8: Convergence of (1/Iyy) estimate for A-10.................................................74 A9: Convergence of (1/mass) estimate for A-10................................................74 A10: Convergence of cg_x estimate for A-10 ........................................ 75 All: Convergence of (1/Iyy) estimate for A-10..................................................75 A12: Convergence of (1/mass) estimate for A-10................................ .. 76 A13: Convergence of cg_x estimate for A-10 ......................................... 76 A14: Convergence of (1/Iyy) estimate for A-10.....................................77 A15: Convergence of (1/mass) estimate for A-10................................ .. 77 A16: Convergence of cg_x estimate for A-10 ..................................... .... 78 - -- List of Acronyms AGL CADC CCIP CDU DoD EAC EISE HUD INS IPAC LASTE MIL-STD MRAD MSL PAC RBF RLS SAS USAF - & Selected Abbreviations Above Ground Level Central Air Data Computer Continuously Computed Impact Point Control Display Unit Department of Defense Enhanced Attitude Control Extendible Integrated Support Environment Heads Up Display Inertial Navigation System Intelligent Precision Attitude Control Low-Altitude Safety and Targeting Enhancement Military Standard Milliradian Mean Sea Level Precision Attitude Control (Old System) Radial Basis Function (Neural Network) Recursive Least Squares Stability Augmentation System United States Air Force (_ r^ 1.0 Introduction 1.1 Background The A-10 aircraft was designed to provide highly accurate weapons delivery for the close air support role. Its primary weapon is the 30mm cannon which is fixed to the airframe; in order to aim the weapon, you must point the aircraft appropriately. The weapon produces a considerable amount of recoil. Since the force axis of the gun is not through the aircraft center of mass, it produces substantial pitch torque, upsetting the pilot's aim. This gun also produces enough smoke to disrupt the airflow over the aircraft horizontal stabilizer while that control surface is opposing the pitch change due to recoil. This project will address accurate pointing of the weapon in the presence of a disturbance input, namely the change in density across the horizontal stabilizer as gunsmoke interrupts the airflow. 1.2 Problem Statement Early in the development and testing of the A-10, pilots discovered that the smoke from the cannon affected pitch control about one-half second into a burst. The standard weapons delivery mode gives the pilot augmented stability and closed-loop regulation of the aircraft aimpoint once the trigger is squeezed. The control system provides an "open loop" step input to the elevator at the appropriate time to directly offset the pitch moment from gun recoil and disturbance generated by airflow interruption. This simple but imprecise solution to this problem has improved gun pointing significantly. The size of the step was determined by an average value for the entire fleet and for typical configurations. Unfortunately, this "average value" can be very inaccurate since there are variations between airframe aerodynamics, i.e. airframes may be bent. The CG of a given aircraft varies with payloads. Control authority varies with differences in atmospheric conditions, trim tab settings, etc. These inaccuracies can cause the airplane to "lose the target" during long-range shots at a critical time in the firing sequence. Often this perturbation is large enough that the pilot is unable to reacquire the target before resuming fire becomes impossible for the pass. 1.3 Approach to Solution We can model the perturbations due to gun firing as the reaction of a rigid body to a force and torque. Figure 1 shows a simplified model. In order to predict the aircraft reaction to firing the gun, one must first estimate the mass properties of the aircraft. We will need to identify three mass properties: m-' (inverse of aircraft total mass), cg_x (displacement of the aircraft center of gravity relative to its aerodynamic center along the x-axis) and 1/Iyy (inverse moment of inertia about the y-axis. Airplane Aerodynamic Center cg-x Center of i .. Torque Recoil Figure 1: Airplane as a rigid body with Recoil Force and Torque Figure 2 shows a block diagram of our approach to this solution. We estimate the mass properties prior to gun firing, so the disturbance due to gun firing is absent from this diagram. The Airplane including its existing pitch stability augmentation system (SAS) is enclosed in the top box. The proposed system is contained in the lower box. The proposed system consists of a model of the SAS, an aerodynamic forces estimator, a mass properties identifier, and an input predictor. The "TAS Computer" block represents the conversion from raw sensor variables to the airplane body-axis variables we use in our system. Some of these calculations are already done in the Central Air Data Computer (CADC); we will actually perform others as part of our proposed system. We must first accurately estimate the aerodynamic forces acting upon the aircraft. From the estimated aerodynamic forces and the actual aircraft reactions to real aerodynamic forces, we estimate the mass properties of the airplane. For simplicity, we consider only the longitudinal equations. Considering only the longitudinal equations will not give us sufficient observability to identify mass properties other than m - ', cg_x and 1/Iyy; e.g., it 12 - ~"" mom will not be possible to estimate center of gravity location, or moment of inertia about the other axes. We will assume the aircraft center of gravity location is essentially fixed along the z-axis. In the worst case, an A-10 carrying 11,000 pounds of external stores and no fuel would have a CG location eight inches different in Z direction from the same aircraft with no external stores. However, missions with both external stores, and gun firing are rare. Should it prove necessary, we should be able to estimate cgz in the same manner in which we estimate cg_x. We will ignore the equation for forward velocity, since the force from the engines is particularly difficult to estimate, and we assume that the engines act only in the X direction. Engine thrust does produce a slight nose-down pitch torque which is much smaller than the elevator pitch authority, and can be treated as a disturbance. Once we have good convergence of the mass properties estimates, we can predict the aircraft response to gun firing given the current state as initial conditions. From this predicted response, we can predict the elevator (SAS) inputs necessary to keep the aircraft on target for the first five seconds of firing. Both of these functions (predicting the aircraft response to gun firing, and the necessary elevator inputs to counteract this response) are performed in the input predictor block. Chapter 3 of this paper will discuss mass property estimation and input prediction. While we implement the predicted input, we can formulate a better model of the disturbance. We will use a radial basis function as a trainable model of the disturbance. The radial basis function will allow on-line learning of the disturbance. After each gun pass, the system will have an updated disturbance model with which it can better predict the desired input. Chapter 4 will focus on designing the radial basis function and implementing it in the A-10 Intelligent Precision Attitude Control (IPAC) system. Figure 14 illustrates the relationship of the disturbance force to the overall system as well as our method of updating the disturbance model by using the feedback signal. In order to test the system, we use the A-10 Extendible Integrated Support Environment simulator dynamics as the Real Aircraft Dynamics. We excite the simulator with white noise colored so that the elevator actuator bandwidth is not exceeded. We take the sensor data--u, q, a, and 6 --and estimate the aerodynamic forces on the aircraft. From these aerodynamic force estimates, we predict the motion of the airplane by propagating the 13 forces through the expected mass properties of the airplane. We update these estimated mass properties from the difference in predicted airplane motion and actual airplane motion. When we have a good estimate of the airplane mass properties, we predict the input needed to keep the pitch attitude constant if gun firing should occur at the current aircraft state. We Figure 2: Proposed system with Airplane Block Diagram simultaneously apply the predicted input and our test disturbance to the airplane, and observe the response of the airplane and the feedback signal from the existing precision attitude control regulator. From these observations, we formulate a better model of the disturbance force using the Radial Basis Function. After updating the disturbance model for high and low airspeeds, we test how well the system generalizes for medium airspeeds 14 I__ _ _I ____ _ 1_1 I_ __ by applying the predicted input and test disturbance at an intermediate airspeed which the system has not previously seen. 15 _ 2.0 System Requirements Figure 3 below illustrates a simplified view of the A-10 fire control problem. Whether we model the trajectory of the bullets as a straight line, or a truly ballistic trajectory, the control variable remains the same, namely the pitch attitude of the airplane. Now if the pitch angle (0)is 450 , the distance 12,000 feet as depicted in the illustration, and the target a Russian T-10 tank at 35 feet in length, the target will appear to be 0.002 radians tall in the Heads Up Display (HUD). Thus, we would like our system to constrain the pitch attitude of the aircraft to within 0.001 radians of desired for gun bursts up to five seconds in length. 12000 ft. Figure 3: A-10 shooting tank; showing problem. 16 geometry of aiming ----I--~ -- 3.0 '-I I Improving the Plant Model 3.1 A Framework for Flight Dynamics Figure 4 below shows a typical aircraft (in this case, an Air Force T-38 adapted from [12]) with the axis convention we will use in the remainder of this paper. This picture defines the airplane centered axis system, linear and angular velocities in relation to this axis system, and the angles relating the airplane centered axis system to the wind axis system. In this paper P -Sideslip angle--is assumed to be zero. Thus, the Stability axes (only S1 is shown here) are coincident with the wind axes, and the order of transformation is unimportant. The velocities u, v, and w and the angular rates p, q, and r are also depicted and defined below: X, Y, Z = Aircraft axes a = Angle of attack # = Sideslip Angle Si = Stability axes Wi = Wind Axes u = Airplane forward velocity wrt the air mass along the X axis v = Airplane velocity wrt the air mass along the Y axis (= 0) w = Airplane velocity wrt the air mass along the Z axis p = Angular rate about the X axis q = Angular rate about the Y axis r = Angular rate about the Z axis XL = Sum of moments about aircraft X axis M = Sum of moments about aircraft Y axis IN = Sum of moments about aircraft Z axis 17 X u p (roll rate) W1 q (pitch rate) r (yaw rate) Y V Z w W3 Figure 4: Aircraft Body axis system Figure 5 below illustrates the earth (or North, East, Down) and bodycentered axis systems and their relationships through the three Euler angles 0, 0, and ty (pitch, roll, heading). This axis system is very important in aircraft navigation applications. In our treatment of stability and control, it will be necessary only to relate the gravity vector to the body axis system. 18 I- - ~ ~' --'- ~ (North) 1 E3 (Down) Figure 3.2 Aerodynamic 5: Earth Forces and Body axis systems Estimator 3.2.1 Approximate Nature of Aerodynamic Models: Modeling an aerodynamic system generally results in uncertainty. Aerodynamic models make many inexact approximations for complex relationships such as the type of airflow around the wing, compressibility effects, and the effect of finite wings. In order to simulate this uncertainty and show the system capabilities in a realistic environment, we intentionally introduce a level of uncertainty to our aerodynamic model. In order to predict the motion of the aircraft longitudinal axis, we need to estimate the aerodynamic forces in the X and Z directions, as well as the aerodynamic moments about the aircraft Y axis. By summing the aerodynamic and gravitational forces, we can predict the aircraft linear acceleration along the Z axis and angular acceleration about the Y axis. This provides us with two independent equations from which we can solve for the two unknowns m - ' and 1/Iyy. We will discuss estimation of the third unknown, cg_x, from the same two equations, in the sequel. 19 3.2.2 Example of Coefficient of Moment at zero pitch dynamics: The software used for the "real airplane aerodynamics" is taken from a simulator package called A-10 Extendible Integrated Support Environment (EISE). Its aerodynamic model is primarily composed of one-dimensional linear interpolations of look-up tables. However, some coefficients are determined by using Boolean logic to select the appropriate line fit from several different lines. The underlying function is probably second or higher order, but using several intersecting lines with logic is faster than an exact high-order polynomial. A good example of this is Cmo, the moment coefficient for steady state (no angle of attack acceleration or pitch angular velocity). The actual Cm0 curves (here we draw curves for Mach 0.37 and 0.7) are shown in figure 6. cmO and cm0 approximation for various Mach numbers 0.3 --x-- = low mach number 0.2 --o-- = high mach number -----= approximation 0.1 E 0 -0.1 -0.2 0I -02 Figure 6: -0.1 0 C,, 0.1 Alpha (rad) and Cm, I 0.2 approximation I 0.3 0.4 curves One can see from Figure 6 that we may further approximate this complex function by fitting several lines to the region of interest. The airplane will most often have a small positive angle of attack. In that region, we have virtual coincidence of the approximation curves and their underlying "real" counterparts. We can approximate Cmo for typical attack airspeeds by the simple polynomial: Co = 0.019875 - 0.08375(M- 0.45)- 0.425a + 0.825(M- 0.45)a 20 ... .^x--""--- ------ - - ---- ---" IE- where M is Mach number, and a is angle of attack in radians. The Aerodynamic Forces estimator will be composed of similar polynomial approximations of each aerodynamic coefficient needed. Many of the curves used in the A-10 model will be exactly represented by first order (linear) polynomials. Using such polynomial approximations will reduce the computational burden, producing a system which could realistically be implemented. For example, in calculating the elevator lift coefficient, C,,, the table lookup method requires 21 floating point operations (flops). The polynomial method requires only two. Polynomial approximations also introduce uncertainty into the simulations. Since we are using a simulation to demonstrate our results, we have an exact aerodynamic model, namely that which determines the simulated aircraft motion. Realistically, there would be errors in the estimator. We must intentionally add uncertainty to the aerodynamic forces estimator to make our simulation results more valid. 3.2.3 Relation of Center of Gravity Location to Aerodynamic Model: As implied in Figure 1, a statically stable conventionally configured airplane will have a positive displacement from the aerodynamic center to the airplane center of mass. Here, when I write aerodynamic center, I am referring to the "neutral point" of the airplane. I. E. if the airplane center of mass were to move aft to the "neutral point", changes in angle of attack of the aircraft would not affect the total moment about the Y axis. The sum of lift and drag forces acts through the aerodynamic center. Thus, the noncoincidence of aerodynamic center and center of gravity creates a moment in addition to the total aircraft aerodynamic couple. We model 1W. as a sum of the aerodynamic moment and the couples created by non-coincidence of the airplane aerodynamic center and center of gravity. That is: 9 = CA MV o + ZCGFx - XCGFz (1) Where CAmo is the aerodynamic couple, XCG and ZCG are the X and Z coordinates of the center of gravity respectively, and Fx and Fz are the aerodynamic forces in the X and Z directions respectively. It will be essential to have a good XCG estimate in order to have a good 1/Iyy estimate. The coefficient of moment due to elevator displacement CM, is also an ingredient in determining 1M, since the elevator moment arm will be determined by the distance from the horizontal stabilizer center of lift to the airplane center 21 of gravity. The Ada software from which my longitudinal dynamics were derived defines the airplane axis origin at station number 463.3. (Station numbers are the Department of Defense convention for determining aircraft center of gravity. Station numbers are generally given in inches aft of a reference datum. In the case of the A-10, the reference datum is approximately 125 inches forward of the nose of the airplane.) Based on this coordinate system, the airplane cg envelope: sta. no. 421.71 < cg < sta. no. 434.27 implies: 29.03 < cg_x < 41.59. The horizontal stabilizer aerodynamic center is located at approximately station number 720. Thus, the elevator moment arm can vary from 298.29 to 285.73 inches. For a nominal cg of 427.4 i.e. an elevator moment arm of 292.6 inches C =-0.0131. After some algebra, we find that we must multiply the nominal value of -0.0131 by: (720 - (463.3 - 12XCG))/ 292.6 (2) where XCG is given in units of feet forward of the aircraft axes origin. Note that CM, only varies about three percent for the extreme cases of cg location. We need to estimate 1/Iyy to better than two percent precision, however, as the difference in 1/Iyy from empty to full fuel tanks is only about two percent. The Aerodynamic Forces Estimator will pass its estimates of [1M Z EX] to the Mass Properties Identifier. 3.3 Mass Properties Identifier 3.3.1 Development of a non-linear Recursive Least Squares Identifier: Our knowledge of the physics of aircraft flight dynamics puts us at a distinct advantage towards identifying a non-linear model. The non-linear equations of motion are: [1] 22 -----L -- -- - - ---x- -- u +qw - rv - cg d3 = YX / m + ru - pw - d 32 g =Y /m v + pv - qu - d 33g = .Z / m I p - (i + pq) L + rq I I, + (p 2 - r2) l+ I, pr I I Iry IZ I (3 I (3) CIZZ d3, +d33q - d32r = 0 d32 +d 31r -d 33p = 0 d33 + d32p - d31q = O Where the variables u, v, w, p, q, and r are as defined above. ii, v, vw, p, q, and i are the time derivatives of u, v, w, p, q, and r respectively. E.G. ii is the linear acceleration along the X axis. g is the acceleration due to gravity. XX , XY, and XZ are the sums of forces in the X, Y, and Z directions respectively. IL, XI, and IN are the sums of moments about the X, Y, and Z axes respectively. The I s are moment and products of inertia and are defined as follows: I = f (y2 + 2)dm m I, = f (x2 + Z)dm m I= (x 2 + y 2 )dm (4) m I, = f xy dm m etc For aircraft which are symmetric with respect to the X-Z plane (the A-10 included) the other products of inertia are zero, so we may ignore them. The dij are direction cosines derived from the Eulerian angles as follows: 23 d 1 = cos Ocos V dl2 = sin sin 8 cos - cos sin Iy d13 = cos sin 8 cos + sin sin i/ d21 = cos 0sin d22 = sin sin 8 sin + cos cos f d23 = cos Sin 8 sin - sin Ocos (5) d 31= -sin 0 d32 = sin 0 cos 0 d 33 = cos 0 cos 0 We use these direction cosines primarily to relate the gravitational acceleration to the airplane centered axis system. Note that the di, are coefficients for gravitational acceleration in each of the linear acceleration equations. For simplicity, I will only model the aerodynamics necessary to estimate XZ, and XYM. Thus, I assume XY = YL = YX = 0. I assume no sideslip--pilots usually attempt to fly coordinated--making v and3 = 0. In fact, the A-10 yaw stability augmentation system maintains zero sideslip for most flight conditions, so the pilot must intentionally fly uncoordinated to generate sideslip. Finally, I assume p = 0, which has no great consequences since pilots roll the airplane to establish a turn, then hold a constant bank angle. A steady-state banked turn is characterized by non-zero r, and q and zero p. That is, out of the total flying time, a small portion is spent rolling into and out of turns. Most of the time is spent in wings-level flight or steady-state turns. Furthermore, the airplane would normally be just as likely to make left turns as right, so the inaccuracies posed by such an assumption would have zero mean. At high roll rates, like those experienced during an aileron roll, p >>r, and the best solution is to suspend the estimation until p becomes small again. By applying the above assumptions to eq (3), and eliminating equations with no mass properties, we produce: 24 -- ------- " ti /m (61) ru- d32g = 0 S- qu - d33g = Z m (6.2) (6.3) ii +qw - d3 g = --r +rq IXX iq= 0 (6.4) = q-r 2 yy, (6.5) I i+qr-i-=0 (6.6) IZ The above assumptions isolate the longitudinal dynamics of the airplane, in which we are primarily interested for designing a longitudinal control law which will optimize gun aiming about the pitch axis. The remaining equations are: i + qw + gd3, = X / m vi - qu - gd33 = Z / m 4 = (1 (7) + r21z) / Iyy We keep the r21U term to preserve generality here. We can write the differential equations as difference equation approximations: u(k + 1)= u(k) + T * (-q(k)w(k)- d3l(k) + IX / m) w(k + 1)= w(k) + T o (q(k)u(k) + d33 (k) + _Z / m) q(k + 1) = q(k) + T *(EI + r 21) (8) / y We put eq (8) in the following form for recursive least squares identification: Z/m = w(k + 1)- w(k) -((k)q(k + l)u(k + 1)-gd33 (k + 1) T T q(k)- q(k + 1) (9) T We can find an update equation for cg_x as well from eqs (1) and (9): q(k+1)-(k) X XCGF z = +r(k) 2 + CAERO + ZCGFx (10) Since we know the non-linear relationships explicitly, we can use recursive least squares, accounting for the non-linearities as above. [2] 3.3.2 Why not Kalman Filter ? Here we choose recursive least squares identification, because it gives the best solution in a least-squares sense with no a priori knowledge of the random disturbances. This is a good assumption considering the uncertainty of aerodynamic models. By reducing the problem to three scalar problems, 25 we reduced the computational load by a factor of three. In the Kalman filtering scheme, if there is little or no prior knowledge of the random disturbances, the initial covariance matrix must be made very large, and optimal maximum likelihood estimation becomes weighted least squared estimation. [7] 3.3.3 The Recursive Least Squares Algorithm Recursive Least squares is a method used to generate the pseudoinverse or least squares solution to an overdetermined linear system one equation at a time. [3] Consider the linear system: Y=DO+E Where e is a random error such that there is no exact linear solution 0 to the system. The least squares solution is: & = (4)T DTy T)-' The weighted least squares solution is: 0 = (T'WO)-OTy Where we choose: ayN +' -" 0 0 0 ... 0 ...ay ... O 0 a This choice of W with y < 1 and a = 1 - y gives the filter a finite memory. We want the filter to have a finite memory since the mass properties we are estimating are slowly time varying. If we define: ' = [(n) ... q(N) O(N+1)] We can write the product as a sum: N+1 Ow = 1. (k)w(k)T(k) k=n We can then break the sum into two terms N D T WO = 1 0 (k)ayyN-k T (k) + (N + 1)aT (N + 1) k=n Since we need the inverse of this matrix for the solution, we define the covariance matrix as: P(N +1)= [OT (N + 1)WO(N+ 1)]1 Using the two-term form of the sum: 26 _____~^_ ^^___ ~1___1__ __ ~__ _I _I ~^___ ~_ P(N + 1)= [yP-'(N)+ (N + 1)a~ (N + 1)]- 1 This form allows us to apply the matrix inversion lemma [13]: (A + BCD)-' = A- ' - A-1B(C- 1 + DA-1B)-DA -1 by substituting: A = yP-1(N) C= w(N+1)-a P(N) ~ 1 7 P(N), ( +1 y a P(N + 1) = P(N) 7 P(N) 7 From the pseudoinverse solution: o = P(N +1)( TWY = P(N + 1( y (k)w(k)y(k)+ O(N)ay(N)) (k=n 0(N + 1)= P P P yy P 0( 1+ OT P 0) a P [1 y O P[y TW Y(N )+ ay] but PNT WY(N) = 8(N) -1 P O(N + 1)= O(N)+ - ay2-P'0 (. Y Inserting the identity a1 7)-# P O'T(N) + )-1 -0 P between 0 and a in the second term on the right, we can combine the terms which multiply y and write: 0(N + 1) = O(N)+ L(N + 1)(y(N + 1)- rOT(N)) where we define L(N+ 1) = P (1 +i -1 y atthe structure of our recursive least Now, let's look specifically at the structure of our recursive least squares identifier. The "state" of our identifier will be : 12 / M (1,, + r2 zx Yy XcG!z Thus, 27 w(k)- w(k -1) - q(k)u(k) - gcos 0(k) T y(k)= q(k - 1)- q(k) T q(k) - q(k - 1) + yy + CAERO + ZCGFx T (k)=Z E+r£2 Fz 0 mZ XCG Note that we make a careful distinction between XZ and Fz . Here XZ is an estimate of the total Z forces (both aerodynamic and gravitational) while F z is only the aerodynamic Z forces. We can initiate the recursive algorithm two ways. One is to choose arbitrary values for the P matrices and the 0 vectors. The other is to collect N samples of the inputs, outputs, and states (where N denotes the largest dimension of 0 vectors), synthesize the 4 and y vectors from these samples, and calculate the P matrices and 0 vectors from 0 and y. We choose the first method here choosing Pw = Pq = 1, Pc = 50 and: 00 =[mean(m- 1) mean(I-1) mean(XCG)] Each 4 sample will come from the aerodynamic force estimator. Once initiated as above, the recursive least squares algorithm is as follows: [3] 1. Let k = N. P(k) (k1) 1+ (k +1) P ( k ) ( 1)y a Y 3. Collect y(k+l) from sensor data 4. 0(k + 1)= 0(k)+L(k + 1)(y(k + 1)(k + 1)(k)) 1 5. P(k + 1)= [I - L(k + 1)T (k+ 1)]P(k) 2. L(k +l) (11) (12) (13) 6. Form 0(k + 2) from aero forces estimator 7. Let k = k + 1 8. Go to step 2. Note that, in the software, I have decoupled the three parameters, such that we actually have three scalar identifiers, thus essentially reducing the computational requirement by a factor of three. We include exponential weighting in the form of the scalars a and y where a = 1- y , and we set y = 0.996. The memory length is approximated by the value 1/(1 - y ) so that the identifier has a "memory" of approximately 250 samples, for the parameters Fi- and i'. 28 We will run the estimator at 50 Hz, __ )~ ~I I~_ I so this memory length corresponds to five seconds. We use y =1 and a=0.1 for XcG so that the XCG approximation converges faster than the I;'. Recall that knowing the cg location is essential in finding an accurate estimate of the inverse moment of inertia. The value of a is less than one to retain statistical consistency in the identification. We cannot expect the parameter to converge in a single sample, especially if we are considering random plant disturbances. Thus a-' becomes analogous to the plant noise covariance matrix (R,) in optimal estimation. [3] When a mass "jump" such as a bomb drop occurs, we can adjust P accordingly; i.e. ignore all data prior to the bomb drop. Note, since we have reduced the above matrix algorithm to three decoupled scalar algorithms, we may use any implications associated with the stochastic approximation algorithm as described by Ljung: ". .. by replacing the matrix R(t) [P(t) in our algorithm, in general, the covariance] by the scalar r(t) = trR(t). The resulting algorithm is usually referred to as a stochastic approximation variant.. ." [4] 3.3.4 Determining which parameter to update by cross-correlation of internal variables: Since the parameters I-I. and XCG are interdependent, we may only update one or the other during any particular sample. We will decide which parameter to update by cross-correlation of internal variables as follows. Eq (1) is essential for this development. -9 = CRO + ZCGFx - XCGFz (1) Because of the relation between XCG and Z1i we can determine whether our XCG is valid by correlating errors in our q prediction with our Fz estimates. We make this cross-correlation by comparing fourth-order homogeneous response models of the two variables. That is, we want to determine whether or not 4 and Fz are correlated in frequency content. They will differ greatly in amplitude. In order to accomplish this, we identify the trajectory of each variable as a fourth-order homogeneous difference equation. That is: (k) = Fz(k) = Where: 29 Fz(k - 4) (k - 4) Z -3) F(k (k - 3) SF(k - 2) (k -2) LFz(k - 1)_ (k- 1) F and 0' and 0, are four element row vectors of fictional parameters. These functions now fit very well into the context of recursive least squares as described above. In order to allow the update decision to be based upon the most current data, we will use a very short memory Recursive Least Squares estimation based upon the value y =0.75. We determine the level of crosscorrelation between the variables by measuring the "distance" between the vectors of fictional parameters of the describing difference equations. That Cartesian distance is given as simply: This distance will be shorter for signals that are cross-correlated--indicating the need to update XCG first--and longer for signals that are not crosscorrelated. We show experimental values of this distance below, where "correlated" samples were generated by using an aerodynamic forces estimator with the XCG intentionally inaccurate, and the "uncorrelated" Distance between autocorrelation coefficients . 3.5 Correlated="+" Uncorrelated="." 3 2.5 4 2 ) 0 1.5 oO "'..; : . • '... : 4• .. : ........................................ ..... :'" "" ;':". " .,*. 500 • . 1000 1500 2000 Samples of experimental data (one correlated and one uncorrelated datum for each sample) Figure 7: Raw distances between 30 autocorrelation 2500 vectors ~~....- -'--- --- --- ------ -I ---- &. samples came from the same system with 1CG and XCG exactly equal. Histograms of Correlation distances 2000 1800 1600 Correlated="-" Uncorrelated= "--" 1400 ca 1200 ,r ------1I 100 141 S1000 0 800 400i I 200 0 Figure 8: 0 IiI II I I L rI I- - _ l 0.5 Histograms 1 I , 2 2-. 5 1.5 2 distance of distances 2.5 between 3 3.5 autocorrelation vectors We can see from the experimental values in Figure 7, that the dividing line between correlated and uncorrelated signals is about 0.2. Thus we use the decision criterion: d <0.2 update XG 0.2 update I' Experimental results confirm that this intelligent choice of updates works very well. 3.4 Persistent Excitation In order to allow for random inputs, and avoid numerical problems and "parameter drift" [3], we must define a persistent excitation condition. The simplest persistent excitation condition is the invertibility of the TQ, matrix in a least squares or pseudoinverse solution. In recursive least squares, the ITD or 4TWD matrix is replaced by the P matrix. Thus, our persistent excitation condition will hinge upon the invertibility of the P matrix. Note from our exponential weighting, the P matrix could be expressed as: 31 ay250 DWD = [(k - 249) ... (k - 1) O(k)] 0 " 0 0 0 0 ay 0 0 ay O(k j0 - 250) (k T (k) Thus, 0 must, apparently be non-zero for the last 250 samples for the P matrix to be non singular. However, since we have decoupled the equations into two scalar equations, (one each for w and q) 1OW1 being non-singular, is k simply implied by the scalar sum: Yq(i)ayk+1-iO (i) being non-zero. Thus, i=k-250 we may define our Persistent Excitation condition as IF and/or 9WM being non-zero or greater than a "noise threshold" for at least one of the previous 250 samples. However, recall that the "0 s" in our identifier are only estimates of the forces acting upon the aircraft. Thus, we should employ an equivalent condition based upon the "ys"--4 and wi. Since 5 = OO --y, a non-zero q is k equivalent to a nonzero y. Similarly, the non-zero sum ,(i)ayk+1-igT(i) i=k-250 k implies a strictly positive sum: Iy(i)2 Thus, we use the persistent i=k-250 k excitation condition, Cy(i)2 > b where b is a "noise threshold" constant. i=k-250 Note that this is a scalar, deterministic version of the vector stochastic equation given by Bittanti and Campi [6]. EA T (p(i)<p(i)r [f a, Vt t+1' We already employ a form of this condition by setting upper and lower bounds on m- 'and 1/Iyy. These upper and lower bounds prevent the solution from settling to something outside of the aircraft weight and balance envelope. They were devised when we were testing the filter with "chirp" inputs, and the initial low-frequency portion of the chirp proved not to be persistently exciting. 3.5 Test Results from Mass Properties Identification Figures 9- 1 show typical test results from the basic A-10 simulation. We present m , basic results as well as results from T-38 simulator maneuvering flight in Appendix A. For each mass property to be estimated, we show the actual mass property versus the estimated in the top plot. The 32 ...I -..- - ----- - ----- ----------- ---- - - --- ------- - --- ,, bottom plot shows the estimation error as a dotted line and the variance or standard deviation as a solid line. Note that in some plots we use the variance since the standard deviation would exceed the estimation error by several orders of magnitude. For example, the variance of the I- estimate is on the order of 10-6, and the standard deviation is therefore on the order of 10-3. Since the actual value of I- is on the order of 10-5, the estimation error and standard deviation would not fit on the same plot since they would differ by two orders of magnitude. The initial divergence of I- estimate is due to the inaccuracy in the initial XcG estimate. We have intentionally made the initial XCG estimate inaccurate in order to demonstrate the ability to decide which parameter to update. This also shows that the XCG estimate is allowed to converge much quicker than the II estimate. Since XCG has no effect on the m- 1 estimate, th- converges quickly without any divergence. Overall, these results are more than satisfactory. 9 x 10-6 Convergence of (1/lyy) estimate trim point 1 I I I I 8.9 8.8 Actual (1/y ) ....... 8.7 Estimated (1/lyy) -- 8.6 <-Deviation due to inaccurate cgx estimate 0 500 x 10-6 1000 1500 Samples (20 ms/sample) 2000 2500 2000 2500 AX1 I u"Overconfidence" due to inaccurate cgx estimate 3 - Variance of (l/lyy) Estimate b 2 /" (1/lyy) Estimation Error --------- 2 S-- 0 Figure 500 9: 1000 1500 Samples (20 ms/sample) Convergence of 33 (l/Iyy) estimate for A-10 Convergence of (1/Total_Mass) estimate trim point 1 10 4 x 9i I I I Actual (1/Total_Mass) ........ Estimated (1/Total_Mass) .5 8" .5 0 20 I 500 n I 1000 1500 Samples (20 ms/sample) 2000 25( x 10 s Standard Deviation of (1/Total_Mass) Estimate Estimation Error for (1/Total_Mass) -------- 15 105 0- 1000 1500 Samples (20 ms/sample) 500 Convergence 10: Figure 2500 estimate (1/mass) of 2000 for A-10 Convergence of cg_x estimate trim point 1 Samples (20 ms/sample) 0.08 I,*., 0.06 Standard Deviation of cgx Estimate Estimation Error for cgx 0.04 - 0.02 rrl I rL i 0 Figure 11: 50 500 II 100 1111 IIII 150 I i III 1000 1500 Samples (20 ms/sample) II I Convergence of 34 cg_x 2000I B 2000 estimate for 2500 A-10 I Yr 3.6 Input Predictor The input predictor will include the algorithms for aerodynamic force estimation and bias estimation. We can thus expand the "Input Predictor" block: Aircraft State at Gun Switch toggle Aero bias at GS t Aerodynamic Forces Estimator Gravity Estimator + (y_+ Mass Property Estimates O,Z,M XZIM delta_e delta_e=( 1M+ b_m-M_GUN-chord*Term_1l*cmO+ cmq+cmad-cg_z*F Xhatl+cg_x*F_Z_hatl)/ (Term_2*(chord*cmde+clde*(cgz*s_A-cg_x*c_A))) (New Aircraft State) Figure 12: Block diagram of Input Predictor The equation for predicted Elevator input (delta_e) was developed as follows. XM represents the desired sum of moments about the Y-axis calculated from the following equations: qdes = ( 0 - Ok)/ T qdes = 19des (qdes - qk) 4des T 1/ yy Where 00 represents the aircraft pitch attitude at Gun initiation. Note that r is assumed to be zero during gun firing, so the r 2 term is eliminated here. Thus, the Elevator input attempts to return the aircraft to its initial pitch attitude in just one sample--dead beat control. The term b_m is the bias in aerodynamic moment estimates at the time of input estimation as supplied by the bias estimator. M_GUN is the moment due to gun firing, assumed to be constant and well modeled. cg_x and cg_z are the center of gravity location in the x and z directions respectively. In this paper, cg_x is supplied by the mass properties identifier, and cg_z is assumed to be constant. Term_l1 is the dynamic pressure at the time of input estimation. Term_2 is the 35 dynamic pressure adjusted for smoke effects i.e. dynamic pressure the elevator will experience during gun firing. c_A and s_A are cos(a) and sin(a) respectively. The coefficients cmq and cmad are not multiplied by dynamic pressure because they are given in units of ft-lbs that is, dynamic pressure is already figured in. The predicted input is a dynamic quantity--different at each sample. It is calculated based upon a three degree of freedom model of the airplane dynamics. It has an initial transient response due to the change in angle of attack when gun firing is initiated. When the gun fires, the elevator initially opposes just the moment due to gun firing. This is the first degree of freedom. This elevator input amounts in more elevator "down" force, and subsequently a "higher" angle of attack. As the AOA approaches a "steady state" value, the elevator input also settles down. That then is the second degree of freedom. The third degree of freedom is the airplane X-axis. We first estimate the total X forces (LY) by differentiating the forward velocity u over samples immediately preceding input estimation: u = (u(k) - u(k - 1)) / T YX o = (u + q(k)w(k))m Where m is the total mass of the airplane as estimated by our filter. We then assume X force changes only in gravity component. These changes can be directly related to the estimated changes in pitch attitude by: AFGX = -Namg(sin(O(k)) - sin(0 0 )) Thus, our forward velocity, and factors related to it--such as cmq--can change if there are perturbations in the estimated pitch attitude. This adds further dynamics to the predicted elevator input. 3.7 Hierarchical Implementation of Predicted Input The predicted input may be implemented by a discrete signal from the gun switch. Depressing the gun switch halfway down, the first detent, currently activates target acquisition mode, Precision Attitude Control 1 or PAC1. This system allows the pilot to steady the aircraft on target and is essentially like an autofocus camera, where the first detent focuses the lens, and the second detent trips the shutter. Depressing the gun switch all of the way down, the second detent, activates hold mode, Precision Attitude Control 2 or PAC2, in the present system. Our solution is to add the predicted input to the feedback solution when the gun switch is depressed and held in the 36 - -Pi second detent. Thus, the Airplane and SAS can be represented as a hierarchical control system where the feedback controller is subsumed by higher levels of complexity as determined by the gun switch position. For a more complete treatment of the subsumption method of hierarchical control, please see Brooks [5]. In Figure 13 below, subsumption nodes are pictured as divided circles while the summing junction is an empty circle. Gun Switch Figure 13: Hierarchical Implementation 3.8 of Predicted Input Adding Feedback Open loop tests indicated that a precise feedforward input trajectory alone will not provide one milliradian tracking accuracy as we have specified. Thus, we included the existing "PAC2" regulator in the feedback loop as pictured in the hierarchical control scheme, Figure 13. This regulator provides the necessary precision as well as added damping required when the AOA becomes especially oscillatory. 37 4.0 Improving the disturbance Model General Approach We will use a radial basis function neural network as the model of our disturbance. This model should be able to learn the disturbance in real time, since we train it using the Recursive Least Squares algorithm. The disturbance model will thus be improved after each gun firing. The improved disturbance model can then be used to predict the input for the next gun firing. 4.1 Modeling the disturbance as a change in density: We will first assume that the deterministic part of the smoke disturbance can be modeled simply as a change in air density across the tail of the airplane. This is a good assumption since the forces, both lift and drag, on any aerodynamic surface are proportional to the density of the air flowing around the surface : 1 L, = -pV 2Sc,6, (14) 2 That is, lift created by the horizontal tail is the product of one-half, density, velocity squared, tail area, coefficient of lift due to elevator displacement, (a function of angle of attack, Mach number, and airfoil shape) and elevator displacement. Thus, any disturbance on the airfoil could be expressed as a ratio of "disturbance density" to expected density. 4.2 4.3 Use of the Radial Basis Function We will use the radial basis function to estimate this ratio of disturbance density to expected density. We will assume that the ratio is time varying--the density of smoke varies with time after the gun begins firing. Also, we assume that the rise time and the intensity of smoke reaching the elevator may depend upon airspeed. These assumptions seem intuitively valid given the facts that we would expect the smoke to build up with time-not behave discontinuously as in a step input--be transported from nose to tail with the speed of the surrounding air mass, and dissipate in proportion to this speed. Aside from these assumptions, we would like the model of smoke to be as arbitrary as possible since we cannot accurately model this disturbance apart from experimental data. For example, I cannot intuitively tell whether 38 _ _ ^_L_~__I_ _^___~~~ I_ II__ _ the smoke produces an increase or decrease in the density encountered at the tail. For instance, we expect an increase in density because the smoke contains particles foreign to the air mass. However, we could expect the density to decrease since the smoke will be hotter than the surrounding air mass. The radial basis function seems a logical choice for two other reasons. First, it should offer us quick convergence based on the recursive least squares learning algorithm. Second, it should provide generalization for flight conditions not previously experienced--e. g. an airspeed not exactly the same as that used to train the network. There are two additional issues I expect will be necessary to address given the nature of this problem. First is, this is a distal teacher problem. I cannot directly measure the density of the smoke where it exits the aircraft, much less at the tail of the airplane. I cannot even measure the force generated by the tail directly, only the airplane's reaction to this force. The airplane reaction is the only available teacher, and is distal from the density of the smoke, the quantity we wish to model. Second, no matter how good our aerodynamic model is, it will not be perfect. Thus, the ratio of expected tail force to tail force will be noisy as a result of inaccurate aero force predictions. A third issue is that of meeting persistent excitation criteria in a closedloop system. If the inputs to the recursive least squares learning are not persistently exciting, the disturbance estimate will be inaccurate. For example, if the current feedback regulator keeps the airplane steady on target despite the smoke disturbance, the disturbance estimator would likely conclude from the aircraft reaction to the predicted input that there is no disturbance at all. The current system uses a high-gain proportional-derivative feedback controller to improve disturbance rejection and eliminate oscillations of the unstable plant. Preliminary investigation shows that, when firing, this feedback keeps the plant from meeting persistent excitation criteria. 4.4 Kawato's Method All three issues may be tackled by an approach well proven by Kawato [8]. We will use the feedback signal to assess the difference between our previous disturbance model and the real world disturbance: 39 __ __~I I__ __ _I Figure 14: Using the signal feedback to improve the Disturbance Model In this case, Kawato's method is likely to work well because the disturbance density ratio is exactly r= 3, / 0e- 5r) This relationship comes directly from eq (14). Let me define subscript e variables as estimated quantities or values upon which I base my input prediction. Variables with subscript a will be the actual quantities. We assume the only difference between expected tail lift and actual tail lift is created by the difference between expected density and actual density. Thus, we can define actual elevator displacement as the elevator displacement required to produce the expected tail lift given the actual density. Le = La = 2 2 PeV2 SCe ee PaV2Sc, Sea Le = La Actual elevator displacement is approximated by the sum of the predicted input and the regulator feedback, since the regulator attempts to restore the aircraft to its initial attitude. 3ea 4e - 45e =345 40 r,; ___ __^_L1^_ _ ~I~ I ____~_ 2 I~_ ___ 2 1 2-PaV S)) pV2Sc p,(a, Pe e,- , We define r =Pa Pe Once these issues are overcome, the problem becomes modeling a dynamic parameter by the radial basis function with limited training data. 4.5 Representing Dynamical Systems with a Radial Basis Function 4.5.1 Example Illustrating the simplicity of System Identification with a Linear Network Given an nth order linear, time-invariant discrete system, the system can be uniquely described by the difference equation: y(k) = blu(k - 1) + b2u(k - 2)+...+bu(k - n) + a y(k - 1) + a 2y(k - 2)+...+a,y(k- n) Thus, the system can be described by a linear equation with 2n coefficients. This can be represented by the linear network in Figure 15. The output of this network is: y(k) = WTh Where: b1 b2 u(k -1) b, a1 u(k - n) y(k- 1) a2 y(k - 2) a,, y(k - n) u(k - 2) 41 u(k- 1) Figure 15: Linear network representation of Difference Equation System Identification using the linear network is just a matter of training the vector of weights, W, since it contains all of the coefficients of the underlying discrete linear transfer function or difference equation. As an illustration of the simplicity of training a linear network using the Recursive Least Squares algorithm, I trained such a network as follows: 1. Excite the system to be modeled, and the network with a chirp input. 2. Sample the system and network outputs 3. Update the network gains by: S= y - W T h W = W + Rh(1+ h T Rh)-1' R = R- Rhh TR(1 + hTRh) - 1 Here y is the system output, and R is a covariance matrix. Figure 16 shows the results of system identification using the linear network. The actual second order output is plotted against the output of the approximate model. Granted, we have great prior knowledge of the system order including the number of zeros. 42 --------- IV~ Approximating a second order system by a second-order linear network 100 . Actual Approximation------ m. 90 80 70 60- I I 5 0- I 60 1I 20 I I- ; / 0 0 Figure 16: 50 Results of 100 150 Samples(20 ms/sample) System 200 Identification with 250 Linear Network 4.5.2 Examples Illustrating how the Radial Basis Function may Represent Arbitrary Functions The output of the non-linear radial basis function will be: y(k) = W T h Where: W= 2 h = [exp(-(x -,)C(x- ) i = 1,2,...,n wn. x is the input vector, u is a mean vector for the particular element of h, and C is a covariance matrix, allowing for different receptive widths along each input direction. Each exponential , or gaussian, function is called a neuron or hidden unit. Again, system identification using the non-linear network is just a matter of training the vector of weights, W using the Recursive Least Squares algorithm. There are methods to train u and C, however such training is beyond the scope of this paper. 43 One advantage of using a radial basis function is we can represent nonlinearities in the system. Consider the first-order system: y(k) = bu(k - 1)+ ay(k - 1) We can generalize this first order linear system to a non-linear first order system: y(k)= f(u(k -1),y(k -1)) using the radial basis function. The degree of nonlinearity will be a function of the number of hidden units. We can visualize the plane of (u(k),y(k-1)) with two-dimensional gaussian functions protruding upward to form the y(k) dimension. These gaussian functions will typically have differing means and variances for each direction. Having different variances in each dimension allows us to use input variables, without rescaling, that may differ by orders of magnitude . The equation for a multidimensional gaussian is given by Brown and Hwang [9]: fx(x) = exp{-[(x - TC-(x - ) where y is the vector of selected means, x is the input vector, and C is a matrix of variances. Graphically, a typical multi-dimensional gaussian looks like this: 1 0.8" 0.6% fJ(x) 0.4 0.21 10 10 6 5 1 4 00 2 x2 Figure 17: Two-dimensional Gaussian Function A typical Radial Basis Function network is shown in Figure 18. Here we use two-dimensional gaussians for two inputs. 44 .. - ---- -- - -- -- - x, c) y(k) Figure 18: Typical Radial Basis Function Neural Network The value of y (k) described by this radial basis network will be a linear sum of the gaussian functions evaluated at the input. In the case of the A-10, we choose airspeed and time since gun fire initiation as our inputs. This choice of input eliminates the dependence of the output upon previous samples of the output, however it also gives us a great deal more freedom in the type of functions we can approximate. A remaining question is "can we determine the number of units based upon the number of coefficients in the original non-linear equation?" The answer, unlike the linear case, is not intuitively obvious. If we were representing the exact non-linearities in the hidden units, we could make such an association, but since we use the "generic" gaussian function to represent all non-linearities, the association is unclear. One simple approach would be to say that we could represent N sample data points uniquely with N hidden units. This is taking us back to the original linear thinking, however because such a situation could have a unique solution without any non-linearities. We could again remove the radial basis functions since we would most likely pick the means to be at the first N points. Let's try to determine the number of hidden units by determining how many different "means" we shall use in each dimension. For instance, if we 45 pick only two values as means, then the two-input case would only need four hidden units to uniquely represent all possible non-linearities. That is 2N where N is the number of inputs. This makes the problem seem more tractable, however, intuition tells me that in order to represent any real nonlinearities, we should pick at least three mean points in each dimension. This follows from the fact that two points uniquely describe a line whereas three points uniquely describe a parabola or other conic section which is indeed non-linear. Figure 19 shows an example that defeats my intuition, however, as two gaussian functions combine to form a function that is not adequately described by even a sixth-order polynomial. Ouput of two-unit gaussian network with sixth-order polynomial approx. 1.2 1 0.8- O 0.40.2 002 0 2 4 Input 6 8 10 Figure 19: Output of Two Hidden Unit Gaussian Network For the following discussion, we choose a network with 32 units. We choose sixteen different means along the "time" axis, and two along the "airspeed" axis. 4.5.3 A Function Suitable for Testing the Radial Basis Function Disturbance Approximation Let me formulate an "arbitrary" function, which we will later see isn't completely arbitrary, and attempt to represent it apart from the aircraft plant using a radial basis function. Keeping with the assumptions already stated, I 46 _ I I_ _ ~_~_ ~~~~_ would like the function to have varying rise times due to one input variable. Also, I desire a function which cannot be modeled by a linear system driven by a step input. In order to satisfy these requirements, I took white noise and filtered it through two different low-pass filters. The output of the filter with a higher bandwidth has a shorter rise time, and the random noise produced an unpredictable response. I then took each output and approximated it by a sixth-order polynomial through a simple least-squares regression. This eliminated the noisy part of the output, but kept a significant amount of the unpredictable behavior. I obtained the following plots by attempting to identify a fourth-order linear system which most closely approximated the sixth order polynomial. With only the arbitrary function available, and assuming the function was generated by a system driven by a step input, I was limited to using a step function as the input, and the arbitrary function as the output for system identification. Figure 20 shows the best possible results using the algorithm described for the second-order linear network above. Plot showing inaccuracy of linear approximation Function Approximation --------- 2- 0 , 0 1 2.5 I I 2 Time (sec) I 3 4 5 4 5 1 21.5 1 Function Approximation -------- 0.5 0 1 2 Time (sec) 3 Figure 20: Non-linearity of "arbitrary" function Clearly from Figure 20, a linear approximation will not be sufficient. Determining what means and variances I will use for the units will require some a priori knowledge of the function I am trying to describe. Let's assume that the density ratio describing the smoke disturbance will take 47 __ values from 0 to 2. This value can describe normally occurring densities from well below -5000 feet MSL to infinity, where the ratio would be 0, as a ratio of smoke density to sea-level density. Now it becomes clear why I chose the above "arbitrary" function as it fits well into these additional assumptions. Recall also that I assumed the smoke density would vary with airspeed and time from gun firing initiation. Thus, the most practical way to model such a disturbance is with airspeed and time as inputs and no feedback loops necessary. Such an approach allows us to place sixteen pairs of units along the "time" axis. Each pair has a function for high speeds, and one for low speeds. Note, I am simplifying the problem significantly for computational reasons. My intuition, as above, tells me I should use at least three functions for each time partition. Once, we have trained the network for one "fast" airspeed and one "slow" airspeed we should have an "exact" smoke surface solution for those training sets. Additional training sets will make the problem overdetermined, and the network will converge to the best leastsquares solution. However, my intuition was proven wrong previously, and we shall see how it stands in the experimental data. The ultimate test of such a network will be whether it can generalize and give valid estimates for an airspeed not included in the training set. Continuing the attempt to model the disturbance apart from the plant, the next issue is to pick specific means and variances for each hidden unit. We attempt to train the network for a single airspeed with the variance in the time direction equal to 1/36. We accomplish the training by: 1. Determine the input vector as airspeed (a constant) and time x = [u(k) 0.02k] 2. Evaluate each gaussian at the operating point h, = exp{-[(x - Li) T C-'(x- i)]} where u is the vector mean of the selected gaussian and =[40000 C= 10 03 1/36 3. Update the network gains by: 6 = y(k) - WTh W = W + Rh(1 + hTRh)ylR = R- RhhTR(1 + hTRh) - 1 48 --- -' I I l~b Again, y is the desired output, and R is the covariance matrix. Figure 21 shows the effect of varying the receptive widths of the hidden units. The top plot shows a network with receptive widths too small. The function approximation is not smooth enough. One might expect a good solution would be to add more hidden units at intermediate points. However, widening the receptive widths produces very satisfactory results as shown in the second plot. Widening the receptive widths is accomplished by replacing the C matrix above with: 01 4000 1/6 C=[ C= Approx by 32 RBFs sigmaA2 = 1/36 I i IF Function 1 ,,Approximation 00/ 1 --------- -& -------------- 2- Figure 1 21: 2 Time (sec) Effect 4 5 ..-- Function Approximation -------- F-2""t 1 -tw 0 I I 2 3 Time (sec) Approx by 32 RBFs sigma^2 = 1/6 of varying 3 4 Receptive 5 Widths Figure 22 shows that the two columns of gaussian functions do indeed converge to two exact solutions for two different airspeeds. I generated these plots by first training the network with both sets of training data, then testing with each set. 49 Velocity=465 fps , function approximation 3I Function 1 Approximation -------- , I, 2 Time (seconds) Velocity=756 fps, function approximation 2.5 Figure 22: Network Approximation at two different airspeeds 0.8 h 0.6 0.4 0.2 800 700 2 600 airspeed time 500 400 Figure 23: Thirty-two two-dimensional Unit Gaussian functions with Weighting Figure 23 shows all thirty-two gaussian functions with unit weights in the time-airspeed plane. Notice how closely they mesh along the time axis. 50 The valley in between airspeed partitions may cause problems with our airspeed generalization. We shall see this after some experimental runs of the system and improve the network design, time permitting. Figure 24 shows the 32 gaussians with weighting specified by the two training data sets. Note they do not describe terribly smooth functions as the function approximation is a sum of all gaussians at each point in the plane. 32 weighted two-dimensional gaussians for function synthesis w. h . 0.5. 0. 800 700600 airspeed 500 400 -0 Figure 24: Thirty-two 1 two-dimensional Trained - time Gaussian functions with weights In Figure 25 below we present the function approximation surface after training with both training sets. Note the smoothness, and the striking resemblance to our training sets. We have another representation of the exact solutions with what we should expect to see if we were to ask for any intermediate generalizations. 51 Final estimate surface generalized for two training sets Xwih i" 1 0.5 0 800 700 5 600 3 airspeed 500 2 400 Figure 4.6 25: Network output Propagating the tme 0 after training at Disturbance Through two the distinct A-10 airspeeds Plant: How RBF Fits into Our A-10 Controller Design Now we take the two functions developed above, and create a logical generalization for all possible airspeeds and times we will see in firing the A10 cannon. Recall, our goal is to hold the airplane on target for five seconds. Thus, we are only concerned with the first five seconds of the disturbance input. Airspeeds from 400 - 800 ft/s should suffice for all firing conditions. This represents all Mach numbers from 0.3584 to 0.7169 and our model is only valid from 0.37 to 0.7 In order to generalize the functions into a surface, we take each coefficient pair from the two sixth-order polynomials developed in paragraph 4.2.3, and linearly interpolate four intermediate values. We can then define a surface using the resulting six sixth-order polynomials. Note, we have also scaled the previous functions to make them fit all of our assumptions. We have subdivided increasing density and decreasing density cases, so all disturbances will begin at a disturbance density ratio of 1.0. Thus, we modify the radial basis function such that f(t,u)= 1+ W'h ,essentially adding a bias term with constant gain of 1. In order to test the Radial Basis Function application in the A-10, we apply the predicted input based upon the estimated aircraft mass properties 52 ------- ---- --- -- -- -- and current aircraft state to the actual aircraft dynamics. We are essentially simulating the system shown in Figure 14. The "Aircraft Aero", "Mass Properties", and "'PAC2' Regulator" blocks represent the actual aircraft dynamics. The Predicted Input comes from our input predictor discussed in paragraph 3.6. We simultaneously apply the simulated recoil and smoke disturbances. The recoil is modeled by a constant -10000 pound force along the aircraft X axis. This model is taken directly from the EISE software. The sign convention denotes that the gun recoil acts in the negative X direction. The smoke disturbance is a surface shown in figure 26. Since the original predicted input did not account for the smoke disturbance, we can estimate the smoke disturbance through the feedback regulator signal. We train the radial basis function with high and low speed simulations. Then, we predict an input for an intermediate speed based upon the radial basis function model of the disturbance, estimated aircraft mass properties, and current aircraft state. Applying this input simultaneously with the recoil and smoke disturbances provides the ultimate test, as the airplane should hold on target for the entire time of firing. Surface for increasing densities 1.7 1.6 1.5 800 700F igue:tl 600 ne ". 500 airspeed Figure 26: Experimental 1 400 0 Increasing 2 3 4 n5 time Density Surface The radial basis function is trained as follows: 53 D"- Disturbance Function 1. Calculate the ratio of predicted elevator displacement to actual elevator displacement r = ae / (1e - 6r) 2. Determine the input vector as airspeed and time since gun firing x = [u(k) 0.02k] 3. Evaluate each gaussian at the operating point ,) TC-'(x -i)]} h, = exp{-[(x - where p is the vector mean of the selected gaussian and 1/6 1/6 4 00 C=[ 00 0 4. Update the network gains by: 5 = r-(1+ WT h) W = W + Rh(l + h'Rh)-' R = R - RhhT R(1 + hrRh) -1 where W the weight vector is initialized at zero and R is the covariance for learning the weights and is initialized at 91*1. Smoke_Factor and its approximation after one iteration 1.6 1.4 ----------------- --- 1.2 1 :' SmokeFactor S r =3e /(e- ) ....... Radial Basis Function -------Approximation 0.8,: 0.6: 0.40.2 0 Figure 27: I I 0 50 RBF 100 150 Samples (20 ms/sample) Approximation learning of smoke 200 disturbance 250 after one iteration Figures 27-30 show how well the network learns the disturbance density ratio after one and two passes at a single high initial airspeed of 756 fps. The airspeed during gun fire is actually a dynamic quantity with its 54 ~_ ^*I ~ ~____~ 1_1 ~I trajectory depending primarily on aircraft attitude and throttle position. The pitch plots show how well the aircraft is able to hold on target with the disturbance predicting radial basis function in place. 0.0294 100 150 Samples (20 ms/sample) Figure 28: Pitch response 250 with new system Smoke_Factor and its approximation after two iterations A -C 1.4 1.2 1 ,° =o .. ,:Radial Basis Function -----Smoke_Factor - 0.8 z. 0.6 I r) ........ r =8e10e-8 I I I o . II 0.4 0.2 100 150 Samples (20 ms/sample) Figure 29: RBF approximation 55 after two 200 250 learning iterations 0.0294 Pitch deviation due to cannon disturbance using predicted input after two disturbance learning iterations ''0.0288 s 0.0286 0.0284 0.0284 0.0282 0.028 - 0 Figure L 100 150 Samples (20 ms/sample) 50 30: Pitch response with I 200 new 250 system Figures 31-33 show similar learning at a slow initial airspeed of 465 fps. 0.064 0.062 Initial Airspeed = 465 ft / sec 0.06 "0.058 Pitch deviation due to cannon disturbance using predicted input before disturbance leaming S0.056 Q 0.054 0.052 0.05- 0 Figure 50 31: Pitch 100 150 Samples (20 ms/sample) response 56 without 200 disturbance 250 model _ __ I I Smoke_Factor and its approximation after one iteration 50 Figure 32: RBF 100 150 Samples (20 ms/sample) Approximation after 200 one learning 250 iteration 0.0535 0.053 .-0.0525 0.052 0. 0.0515 0.051 0 Figure I 50 33: a 100 150 Samples (20 ms/sample) Pitch response with 200 new I 250 system The real test, as mentioned above, is whether the radial basis function can improve input prediction for an airspeed not contained in the training set. Figure 34 shows how successful we were at predicting the "arbitrary" 57 disturbance after learning only the high and low speed training sets. To generate Figure 34, I trained the network using the high and low speed predicted inputs. The weights were initialized at zero for the first training set; after training one set, I carried the resulting weights into training by the second set. The covariance matrix was reset to 91*I for each training set. I then predicted an appropriate disturbance rejecting input for the intermediate airspeed using the radial basis function. Figure 34 shows the increasing density disturbance surface given above overlaid with the surface described by the radial basis function at the three relevant airspeeds. Figure 35 compares the pitch response with input predicted at approximately 600 ft/s initial forward speed, a speed almost exactly between the speeds for the training sets. "Real smoke disturbance surface and RBF approximation D 1I 0 5 10 5 10 15 20 Real="-" RBF="--" 25 2 10 2 I I ---------I --------------- 15 20 I 25 2 Figure 34: Disturbance 58 surface and Approximation I__ ___ I_ _ ^_X 1__ __ __ __ _I~_ __ ^~ _ Pitch response with and without RBF disturbance estimator 100 150 Samples (20 ms/sample) Figure 35: New system Pitch response with Disturbance Prediction 250 and without The ascending line is the pitch response without radial basis function approximation of the disturbance. The almost flat line is the response with radial basis function approximation in the prediction loop. As you can see, the network improved target tracking considerably. Now, in order to insure generality of the design, let us train it using a "decreasing density" disturbance. The decreasing density case presents us with yet another issue. Initially, I defined the decreasing density surface as simply the increasing density surface reflected about the Disturbance Density Ratio r = 1 plane. This disturbance, however, caused saturation of the feedback controller and made it impossible for the network to converge in one pass through the training set. I suspect, because of the way the disturbance is defined (as a ratio) and how the control input is planned, the network should converge to the proper disturbance model after several iterations even when the initial pass saturates the feedback controller. In order to handle this problem short term, I assume that the disturbance input will not saturate the controller, and modify the disturbance surface appropriately. This allows me to design a disturbance that varies 59 more along the airspeed axis anyway, and provides another good test-Can the network generalize well in the case that the disturbance varies greatly with varying airspeeds? The surface for decreasing densities is given in Figure 36. Surface for decreasing densities I ,II I' 'I i' 1~.11 ) ii' ~'' rl'' ,I II . 0.4 400 airspeed Figure 36: time Experimental Decreasing Density Disturbance Functi on Surface We took the same network as above and trained it exactly as above. The results are shown in Figure 38 where the descending line is the response without using the radial basis approximation in the input prediction. Again, with the disturbance prediction in the loop, the system holds on target much better. Figure 37 shows the decreasing density disturbance surface given above overlaid with the surface described by the radial basis function at the three relevant airspeeds. 60 ..----------- ---- '- ILi "Real" smoke disturbance surface and RBF approximation Figure ).028 37: Disturbance surface and Approximation Pitch response with and without RBF disturbance estimator ).026 With ).024 ).022 0.02 ).018 ).016 Without ).014 ).012 0.01 ).008 Figure 38: I 50 0 Pitch response 1 100 I 200 150 with 61 and without 250 Disturbance Prediction Plot showing progressive leaming when feedback controller is saturated 0.95 - 0.9 0.85 First iteration approximation 0.8 Second approximation and real input 0.75 0.7 0.65 0.6 0 Figure 39: 50 Progressive 100 150 Samples (20 ms/sample) learning when 200 feedback 250 controller is saturated Figure 39 proves my suspicion that the network will converge after multiple passes through disturbances that saturate the controller. The top dotted line shows a flat response where the feedback controller was saturated. By recreating the no-disturbance predicted input--simply dividing by the expected disturbance density ratio--we can train the network for larger disturbances. Essentially, the feedback controller has twice the authority on the second pass, since the radial basis function exerts all of the feedback controller's effort from the first pass. When the network has converged, the expected disturbance density ratio will very closely approximate the actual disturbance density ratio. Figures 40-42 deal with another issue. Seldom does the pilot actually hold the trigger down for an entire five seconds. We must determine the effect upon longer bursts, which only occur occasionally, of learning on short bursts, which are much more prevalent, and how to compensate for this. At first, we use the disturbance approximation directly from the shorter learning cycle. We then apply the assumption that the disturbance ratio will assume a constant value for longer periods which are not generally available in the training set. This assumption works well given the nature of our fictional 62 ------------ ---- disturbance. It is impossible to tell whether this will work on the real system as the real disturbance doesn't apparently consist of mainly deterministic factors. A better real-life solution may be to use the Radial Basis Function to approximate the initial disturbance due to smoke, then the PAC2 gains may be reduced, enhancing the closed-loop stability. RBF disturbance approximation with learning truncated at 126 samples 11 1.05 0 0 .E C0.95 0 00.9 C o 0.85 0 * 0.8 . C0.75 0.7 0.71 ri Figure 40: 50 100 150 200 Samples (20 ms/sample) Disturbance Approximation 63 250 with 300 learning truncated Pitch Response to Predicted input, Disturbance Learning truncated at 126 samples a 0.028E 0 . (N 0.026U- U"A41 0n v.v- 0 I 20 40 I I I I 60 80 100 120 140 m 0.02 o o v) 0.01 4) .LL 50 Figure 41: Pitch 100 150 Samples (20 ms/sample) Responses with 200 inaccurate 250 disturbance estimate Pitch Response, Learning Truncated, zeroth order disturbance thereafter 0.03 0.028 ,0.026 ") . 0.024 0. Av.vr A I 0.02 Figure 42: I I ., l vI8 0 Pitch I 100 150 Samples (20 ms/sample) Response after when learning 64 I 200 disturbance truncation 250 is assumed constant ---- 5.0 ----- - - U Comparison to Old System Currently, the Air Force technical order for A-10 gunfire reads "Sufficient SAS control actuator authority for the PAC mode to counteract pitching moments produced during gunfire is provided by a 20 nose down elevator trim change through the LASTE computer. The trim change occurs when the aircraft is in flight, WD-1 mode is selected on HUD control panel, air-to-air refueling door is closed, N (NO) option is selected for gun gas DIVERTER, and master armament switch is in ARM."[10] In Figure 43, we plot the data from one gun pass on a typical sortie. The duration of the trigger pull is 238 samples or about 4.75 sec. Note that the pitch attitude deviates considerably--about -6 to +2 millirads from desired for the existing controller while the proposed system deviates no more than 3 millirads initially but then holds very well for an extended duration. The large deviation at 220 samples is due to the pilot starting his "pull up" while holding the trigger down. Given the pitch attitude, pitch rate, and PAC command, all plotted below, we were also able to identify a simple approximation for the real PAC inputs. We incorporated this model into the feedback loop as mentioned in paragraph 3.8 "Adding Feedback". Figure 45 shows the actual PAC command and our least squares approximation of this command. There are some discouraging signs from this data also, however. First, we cannot determine the pilot inputs during gun firing, and whether the pilot is actually forcing the aircraft off target. Second, there is no readily apparent deterministic disturbance indicated by the PAC feedback signal, as we expect with the smoke disturbance. The initial pitch up deviation may indicate this disturbance, as it occurs approximately one-half second after the trigger is squeezed, but that would seem to indicate that the subsequent meandering is due to instability of the feedback loop. We compare the actual response to a simulation of our proposed system using the identical initial conditions. We also assume that our system has an exact model of the disturbance. Creating Figures 43-46 led me to some additional insights regarding the input predictor. It will not be able to predict changes in throttle and stick position by the pilot. This explains why the "proposed" airspeed plot has a constant slope, while the actual plot has varying slope. Also, the initial pitch-down of the proposed system is due to the inaccuracy in the Cmo estimate since the AOA was negative at the 65 initiation of gun fire. Thus, we may need to improve our Cm0 model for predicting the input if gun passes typically start with a negative AOA. We need to do a further analysis of this data by determining the trim point of the elevator and attempting to find the deterministic portion of the disturbance by training our Radial Basis Function Network with the resulting data. Pitch Response during gunfire, existing and proposed systems 100 150 Samples (20 ms/sample) Figure 43: Pitch response of 66 Old system during gun firing ~~..~.~.._ - ------ -I-- -- "~ ' Pitch Rate during gunfire, existing and proposed systems 0.15 Existing="-" 0.1 Proposed="--" 0.05 - _. 1-11'\ --I-na,-v-V---/ --- -tI I K" 150 100 200 250 PAC command during gunfire, existing and proposed systems 4- 'a vE 02 01 U - 50 0 Figure 44: 200 100 150 Samples (20 ms/sample) Pitch rate of Old System 250 during gun firing Real Pac and LS identified Pac a, 10 - E Fo co L. .2. 0 a, 100 150 Samples (20 ms/sample) Figure 45: Old feedback signal 67 and Least Squares estimate '--~---)~I"- -Lr 610 Airspeed during gun firing, existing and proposed systems 600 590 ,580 0 570 a560 550 50 Figure 100 150 Samples (20 ms/sample) 46: Airspeed 68 during 200 Gun Firing __~I__ I I_ ~_ 6.0 _ Conclusions ____I and a Recommendations 6.1 Conclusions In this paper, we have demonstrated that predicting feedforward inputs for a system with a sudden disturbance effectively increases control authority. Deterministic disturbances can be modeled by a radial basis function for use in predicting the appropriate input. 6.2 Future issues: In order to successfully implement this system in the aircraft, we must first determine a very precise aerodynamic model of the airplane. I recommend this be done using the technique of Garcia-Velo [11]. Second, the system should undergo a closed-loop test at the Draper Cockpit Simulation Lab. This would include both the mass identification-input prediction phase and the disturbance model update phase. I recommend the mission consist of three gun passes; one low speed and one high speed to train the disturbance model, and one medium speed to test the disturbance model. We have assumed throughout that the model of gun recoil is exact. The actual implementation will therefore require a precise model of the gun recoil to include gun run-up, the initial ramp of firing rate, and subsequent recoil and torque ramps. Also, the effects of gun vibration should be studied and included in such a model if possible. The Radial Basis Function approximating the smoke disturbance should be redesigned to emphasize the attack airspeed regime of the aircraft flight envelope. I also recommend using the maximum number of airspeed partitions possible when deciding where to select means and variances for each individual hidden unit. The ultimate goal of this project is to produce a control system which will compensate for all expected disturbances during gun fire. Thus the pilot's technique becomes no pitch inputs whatsoever during gun firing. The system must therefore be flight tested to determine how well the system compensates without pilot pitch inputs. In its present form, the system will interpret pilot stick and throttle inputs as deterministic disturbances, thus we must determine whether compensation for such inputs needs to be made in the disturbance modeling portion of the system. 69 Additional Appendix A: Test Results Figures Al and A2 show the convergence of mass property estimates for the T-38 simulator during maneuvering flight. These show that, with perfect estimates of just YZ and 19M, we can still accurately estimate the mass properties, even though p, r, andO are non-zero. The pilot flew a series of r. steep banked turns so that p, r, and 0 are non-zero, but in no case is p >> Figures A3 and A4 show that the I zx estimate is unimportant, as we have adjusted the mass properties of the simulator to make the r 21 zx term significant. The error induced in the (1/Iyy) estimate by a 1600 slug-ft error in I zx estimate is three orders of magnitude less than the most significant figure of the true (l/Iyy). Figures A5 through A13 show the convergence of mass property estimates for the A-10 for various initial conditions--slow and high airspeeds, forward and aft centers of gravity. Figures A14 through A16 demonstrate the estimates converging while the airplane is being driven by real pilot inputs rather than colored noise. In this case, the pilot flew a series of steep banked turns to demonstrate that the pitch inputs from such maneuvers were indeed persistently exciting. x 10-5 Convergence of (1/lyy) estimate maneuvering flight (T-38) 2 2- Actual (1/Iyy) .... Estimated (1/lyy) 1 0 3000 4000 2000 Samples (20 ms/sample) 1000 X 10 5000 6000 3 Variance of (1/lyy) Estimate (l/lyy) Estimation Error -------- 1.5 -l 1 0.5 0 - 0 Figure Al: L------ 1000 Convergence ---.--------L L-----------L L------------ 2000 3000 4000 Samples (20 ms/sample) of (1/Iyy) 70 estimate .----------- L 5000 for 6000 maneuvering T-38 I ~~ ~~ I__ ___ __ _ _ x 10-3 Convergence of (1/Total_Mass) estimate maneuvering flight (T-38) I 1 3.2 - 3 j.Estimated Actual (1/Total_Mass) ........ 2.8 2.6 (1 /TotalMass) - - 0 2000 3000 4000 Samples (20 ms/sample) 1000 5000 6000 x 10-5 Standard Deviation of (1/Total_Mass) Estimate - 15 Estimation Error for (1/Total_Mass) -------- 10 5- 1000 0 Figure 2000 3000 4000 Samples (20 ms/sample) Convergence A2: of 5000 (1/mass) estimate 6000 for maneuvering T-38 Convergence of (1/Iyy) estimate T-38 with A-10 like x 10s mass properties 0 1000 2000 3000 4000 Samples (20 ms/sample) 5000 60 x 10. I I I Variance of (1/lyy) Estimate (1/lyy) Estimation Error -------- 1000 Figure A3: (1/Iyy) A . 2000 3000 4000 Samples (20 ms/sample) for T-38 71 with A-10 A 5000 6000 like mass properties x Convergence of (1/Total_Mass) estimate T-38 with A-10 like mass properties 10-3 3.1 .- -. _ - - . .. ..-. ... . .. . . .. 1. . . .. . .... 3 2.9 Actual (1/Total_Mass) ....... 2.8 Estimated (1/Total_Mass) 2.7 2.6 - 4000 2000 3000 Samples (20 ms/sample) 1000 0 6000 5000 x 10-4 Standard Deviation of (1Total_Mass) Estimate 15 Estimation Error for (1/Total_Mass) - -----.--- 100 1000 x 106 -------- --- 200 300 400 500 2000 3000 4000 5000 Samples (20 ms/sample) (1/Total_Mass) Figure A4: -------------- -------- for T-38 with A-10 like 6000 mass properties Convergence of (l/lyy) estimate trim point 2 Actual (/lyy)...... Estimated (1/lyy) <-Deviation due to inaccurate cg_x estimate 0 1000 n, x 10-6 4- 25()0 2000 1500 Samples (20 ms/sample) 500 I confidence" due to inaccurate cg_x estimate II II Variance of (1/lyy) Estimate -LI -1 -- (1/lyy) Estimation Error -------1 500 Figure A5: 5 00-0 150-I 1000 1500 Samples (20 ms/sample) Convergence of 72 (1/lyy) 2500 2000 estimate for A-10 ......... .__ ...... _ ..... Q vl x 104 -- I , - -- ----- ---- Convergence of (1/Total_Mass) estimate trim point 2 Actual (1/Total_Mass) ........ 8.5 Estimated (1/Total_Mass) 8 - 7.5 0) 20 500 2000 2500 x 10"5 Standard Deviation of (1/Total_Mass) Estimate Estimation Error for (1/Total_Mass) --------- 15 10 1000 1500 Samples (20 ms/sample) 10 5 - 0 500 Figure A6: - 1 - -91 1000 1500 Samples (20 ms/sample) Convergence of (1/mass) 2000 estimate 2500 for A-10 Convergence of cgx estimate trim point 1 8 Actual cg_x ........ Estimated cg_x --- 6 di... .................. 500 1500 1000 Samples (20 ms/sample) 2000 2500 2000 2500 0.08 Standard Deviation of cgx Estimate Estimation Error for cg_x -------- 0.06 0.04 0.02 .1 500 Figure A7: 1000 1500 Samples (20 ms/sample) Convergence of 73 cg_x estimate for A-10 ------------------- Convergence of (1/lyy) estimate trim point 3 x 10 - 9.1 9- 8.9 8.8 Actual (1/y) 8.7 ........ Estimated (1/lyy)-- 8.6 - <-Deviation due to inaccurate cgx estimate 500 0 1000 1500 Samples (20 ms/sample) 25( )0 2000 x 10-6 4 "Overconfidence" due to inaccurate cg_x estimate -I 3 Variance of (1/lyy) Estimate "- 2 (1/lyy) Estimation Error -------- ' -- n _-------500 Figure A8: x 10 4 11 10 .5 .. 1000 ---. .. 2000 1500 Samples (20 ms/sample) of Convergence for estimate (1/Iyy) 2500 A-10 Convergence of (1/Total_Mass) estimate trim point 3 1 ......... 1 ................. 10- .......... 1 .......... ... . Actual (1/Total_Mass) ........ 9.5 - Estimated (1/Total_Mass) 9 8.5 5 500 0 20 I i i 1000 1500 Samples (20 ms/sample) 2000 25(00 2000 2500 x 10-5 "1 15 Standard Deviation of (1/Total_Mass) Estimate Estimation Error for (1/Total_Mass) -------- 10 5 -----------------.. II----------I II 0 -5 o Figure A9: 500 1000 1500 Samples (20 ms/sample) Convergence of 74 (1/mass) estimate for A-10 __ I_ _ __ - Convergence of cg_x estimate trim point 3 2.8 Actual cg_x ........ Estimated cg_x - 2.6 - 500 1000 1500 Samples (20 ms/sample) 2000 2500 2000 2500 0-ORE Standard Deviation of cg_x Estimate Estimation Error for cg_x - 0.06 0.04 I 0.02 I F. Ir 1000 1500 Samples (20 ms/sample) 500 Figure A10: x 10, Convergence cg_x estimate for A-10 Convergence of (l/lyy) estimate trim point 4 ....................................... ...... .............. 9.9 Actual (1/ly) .8 ........ Estimated (1/lyy) 8 .6 0 3 <-Deviation due to inaccurate cg_x estimate 500 1000 1500 Samples (20 ms/sample) 2000 25( x 10-6 "Overconfidence" due to inaccurate cg_x estimate 2Variance of (l/lyy) Estimate (1/lyy) Estimation Error -------- 1 500 Figure All: -------- -----------1000 1500 2000 Samples (20 ms/sample) Convergence of 75 (/llyy) estimate 2500 for A-10 x 11 I Convergence of (1/Total_Mass) estimate trim point 4 10 1 10.5 ,.. - 1 -- --- 101Actual (1/TotalMass) ........ 9.5 " Estimated (1/Total_Mass) 0 I I 500 1000 I I 1500 2000 25(00 Samples (20 ms/sample) x 10-5 20 15 Standard Deviation of (1/Total_Mass) Estimate -" E s t im a ti n o Error for (1Total_Mass) -------- 105 ----- 0 ------ --------------------I 5r;; 0 Figure 500 A12: 1000 1500 Samples (20 ms/sample) Convergence of (1/mass) 2000 estimate 25(00 for A-10 Convergence of cg_x estimate trim point 4 1000 1500 Samples (20 ms/sample) 2500 A flo V.VO Standard Deviation of cgx Estimate Estimation Error for cg_x --------- 0.06 0.04 0.02 I Figure A13: 500 1000 1500 Samples (20 ms/sample) Convergence of 76 cg_x 2000 estimate for 2500 A-10 - -- -- ' --- -' --- -- g; Convergence of (1/lyy) estimate real pilot input x 106 x 106 "Overconfidence" due to inaccurate cg_x estimate 2 hVariance 1 (1/lyy) Estimation Error -------- '~ -10 of (1/lyy) Estimate , - 0 Figure 2000 A14: x 7.95.. , , 4000 6000 Samples (20 ms/sample) Convergence of (1/Iyy) 8000 estimate 10C)00 for A-1 0 10-4 Convergence of (1/Total_Mass) estimate real pilot inputs . 7.9 Actual (1/Total Mass) ........ Estimated (1/Total_Mass) 7.85 7.8 7.75 I 7.7 20 ) x 10 I I p1;S~Lvi,;~~Ctiry p - 8000 4000 6000 Samples (20 ms/sample) 10000 -5 Standard Deviation of (1/Total_Mass) Estimate - 15 Estimation Error for (1/Total_Mass) -------- 10 5 O0 n ~I~YL ~ ~Y'-~ -~--~ ~HLC- 2000 Figure A15: r--T---CIYII 4000 6000 Samples (20 ms/sample) Convergence of 77 (1/mass) 8000 estimate 10000 for A-10 Convergence of cg_x estimate real pilot inputs 3.6 I I I 3.4 Actual cg_x ........ 3.2 Estimated cg_x 3 2.8 0 2000 4000 6000 Samples (20 ms/sample) 8000 10000 x 10-5 I / L . 5 I I L JrI ".- Standard Deviation of cgx Estimate Estimation Error for cg_x-- 0 0O Figure A16: 200 2000 600 400 6000 4000 Samples (20 ms/sample) of Convergence 78 cg_x 80 8000 estimate for 10000 A-10 _.,. ---- 1 ---- - Appendix B: Matlab Scripts %nainplane % tain program for A-10 denos: echo off clear clg clc hold off sg.sqra PE_f lag; glbal QDsqr Q % trimrat: natrix of trim point values for initiation of test inputs: % [FX_ENGINE, Nz, TotalMass, Iyy, alpha, theta, W, U, Elev_Position]; trim_nat = [ 2.0386e+04, 5.5e+03, 9e+03, 2.1274e+04, 1.2749e+04, 1.8705e+04, 1.0093e+04, 1, 1, 1, 1, 4, 5, 1, 952.76, 952.76, 1290.2, 1290.2, 1290.2, 1290.2, 1290.2, 110597, 110597, 112943, 112943, 112943, 112943, 112943, 1.2325, 2.6262, 3.7395, 1.6319, 10.559, 7.6089, 1.5116, 0.0223, 0.0511, 0.0659, 0.0285, 0.1841, 0.1330, 0.0264, 16.2765, 19.2384, 27.6372, 22.0503, 100.745, 94.3461, 15.8728, 756.53, 419.43, 422.85, 773.96, 540.46, 706.26, 601.50, % Initialize nrass property estimates: TotalMass =(1.290229845713451e+03+9.527598457134509e+02)/2; nassinv(1) = 1./Total_Mass; Iyy =(1.129439725738912e+05+110597)/2; riyy(1) = 1/Iyy; cg x = 41.59/12; % Initialize Aircraft State: FX_EN3INE = trimmat(2,1); Nz = trim_mat(2,2); Tobtal_Mass =[trimmrat (2,3) *ones (9730,1)] ; MASSINV = 1 ./Total.Mass; Iyy =[trimmat(2,4) *nes (9730,1)] ; RIYY = 1 ./Iyy; Degrees_to_Radians = pi/180; Q(1) = 0.0; 0rOT = 0; Alpha_Rate (1) = 0; Alpha (1) =trim_rat (2,5); theta_rad(1) =trim_rrat(2,6); c_th(1) = cos(theta_rad(1)); W(1) = trimrrat(2,7);% U(1) = trim_nat(2,8);% m = 1; % Initialize Covariances: 79 1.5075; 6.4276; 8.2061; 1.9829; 20.196; 15.963; 4.7845]; P_W = 1; PQ P_C L_W LQ L_K acq rcq acz rcz = = = = = = = = = 2.5e-06; 50; 0; 0; 0; zeros(4,1); 100*eye(4); acq; rcq; % Initialize SAS states: XQ3 = 0; XQ2 = 0; XQ1 = 0; Elevator_Crmd = 0; Gun_Switch = 0; % Generate Colored Noise Test Input: rand ( 'nornal' ) ul = rand(2048,1); numd = [0 0.00995016625083]; dend = [1.00000000000000 -0.99004983374917]; u = 6 .*filter (numd,dend,ul); u = [0; u]; Elevator_Position = (trim_at (2,9)) *ones (u)+u; n = 1:1:9730; gamma = 0.75; a = 1-gama; T = 0.02; % Main Loop For Aircraft Mass Properties Estirraticn: for m = 1:length(u) % Procedures Necessary to Propagate Aircraft Sirrulation: % Determine Real Aerodynamics: [Force_Z (m), Force_X (m) , M_AERO, s, CKO_Value (m), dcd (m) ] =real_aero (U(m), ... Alpha (m) ,AlphaRate (m) , Elevator_Position (m) , Q(m) , 0, 0) ; % Determine Real Gravitational Forces: [FGZ, FGX] = gravity(Nz, c_th(m), theta_rad, TotalMass (m) ,m); % Sum Forces acting upon the aircraft: [TOIMILM (m), TItALZ, TCIAL] =sum_4ces (M_AERO, ForceX (m), ForceZ (m), FGX,... 80 .rr.^---- ____. r-l IEi ---- FGZ, Gun_Switch, FXa3INE) ; % Find Aircraft Rates: [QDOT, WDOT, UDTYr] =find_rates ('ITALZ, 'IIM? (m) ,MASSINV (m) ,RIYY (m), Q (m), ... U(m) ,W(m) , IrIALX); %Move Sinulated Aircraft: [U (m+1), W(m+l) , Q(m+l) ,Alpha (m+l) ,Alpha._ate (m+l) , theta_rad (m+l), ... , theta_rad(m) , WDOT, QDOT, UDOT); c_th (m+l) ] --move_ac (U(m) , W(m) , % Procedures in the Mass Properties Estimator: % Estimate Aerodynamic Forces [F Z hat (m) , 'IM_hat (m) , FZ_hatl, F X hat (m), s_A, cA, acm (m) , arde, cmrq, ... anad, clde, Term1_ , Term_2, Couple_Y] =aero_4ce_stimatr (U (m) ,Alpha (m), ... Alpha_Rate (m) , Elevator_Position (m) , Q (m) , cgx (m) , 0, 1); % Determine and ccpare fourth-order autocorrelation functions for % F_Zhat and delta_Q YQ = (Q (m) -Q (m+1) ) /T; phiQ = Mhat (m) ; deltaQ (m) = (YQ-phi__Q*riyy (m)); if(m >= 5) hq = [delta_Q (m-4:m-1) ]'; hz = [F_Zjat (m-4:l)] '; ) *q) ; Icq = rcq/gamr*hq*inv(i1/a+hq'* (rcq/ga Icz = rcz/gamra*hz*inv(1/a+hz'*(rcz/gamrra)*hz); acq(:,nm-3) = acq(:,m-4) +cq* (deltaQ(m)-acq(:,rn-4) '*hq); acz (:,m-3) = acz (:,m-4)+1cz* (F_Z_hat (m) -acz (:,m-4) '*hz); rcq = (1/gama) * (eye(4) -lcq*hq') *rcq; rcz = (1/ganma)*(eye(4) -cz*hz') *rcz; distance(m) = sqrt ( [ (acq(:,m-3) -acz ( :,3) ) ] '(acq: ,3)-... acz(: ,m-3))); if (m >= 100) % if distance > 0.2 update massinv and riyy estimates: if(distance(m) > 0.2) PW (ml) [riyy (m+l) ,rassinv (m+l), cgx (m+, ,P, P,Q(r+l) ,P_C (m+1), ... deltaQ (m) I =mas_propest2 (W,Q, U, c_th, F _Zat (m) , IM_hat (m) ,... riyy(m), massinv (m),cgx (m) ,P_W(m) ,PQ (m) ,P_C(m) ,n(m) ,im, ... CoupleY, F Xhat (m)) ; PC (m+l) = P_C (m) ; cg_x(r(ml) = cg x(m); % if distances 5 0.2 update cgx estinate: else PQ (m 1), PC (ml), ... [riyy (m+l) ,massinv(m+1) ,cgx (m+l) ,P_W (ml), P delta_Q (m) ] =mas_propest2 (W,Q, U, c_th, FZhat (m) ,M_hat (m), ... riyy (m) ,nmassinv(m) ,cgx (m), PW (m) ,PQ (m) ,P_C (m) ,n (m) ,m,... 81 Couple_Y, FXat (m)); PW(m+I) = PW(m); PQ(m+l) = PQ(m); riyy (m+l) = riyy (m) ; massinv(m+l) = rrassinv(m); end end end % Allow 100 sanples for faster estimates (distance) to settle out: if(m < 100) PC (m+l) = PC (m); cgx (m+l) = cgx (m); PW(m+l) = PW(m); P Q (m+l) = P_Q (m); riyy (m+l) = riyy (m) ; nassinv(m+l) = massinv(m); end % Calculate and apply SAS input: if u(m)==0 Elevator_Cmd(m+l) = pacl (Q,theta_rad,m); else [Elevator_Cmd (m+l) , XQ1, XQ2] =sas (AlphaRate (m+l) , XQI, XQ2); end if m < length(u) Elevator_Position (ml) =Elevator_Position (m+1) -ElevatorCmd (rn+l); if Elevator_Position(m+l) > 35.0 Elevator_Position(m+1) = 35.0; elseif Elevator_Position(m+1) < -10 Elevator_Position(mn1) = -10; end end end %Main Loop for Mass Properties Estimation % Predict Input for Gun firing: [delta_e, U_HAT] =prdictdein (U, Alpha,AlphaRate, Q, W,massin (m), ... riyy (m) ,theta_rad, Nz, c_th, 2, cgx (m), 0, 0); % rbfl.m % inplement gun fire sequence and real-time learning of % disturbance clear % load predicted elevator input and previous RBF weights: load run4.dat; load wate.dat Wr = wate; 82 .- - ----- ---- ------ -""~I ~" ~"-"--- delta_e = run4; Nz = 1; XQ1 = 0; XQ2 = 0; Gun_Z_Pos = 32/12; Recoil = -10000; b_m = 0; cgx = 35.9/12.0; cgLz = 10.6/12; chord = 8.943; M_GUN = -Recoil*Gun_Z_Pos; % Initialize Aircraft State: FX_ENGINE = 2.1274 Total_Mass = 1.290e+03; Iyy = 1.129439725738912e+05; MASSINV = 1/Ibtal.Mass; RIYY = 1/Iyy; U(2) = 7.739643906159881e+02; Alpha(2) = 1.63191714789529; Alpha_Rate(2) = 0; Q(2) = 0; W(2) = 22.05027016257672; theta_rad(2) = 0.02852904143307; c_th(2) = cos(theta_rad(2)); moo = means, C = receptive widths R = learning covariance % Initialize Radial Basis Function: % mool = [465*anes(16,1); 773*ones(16,1) ]; moo2 = [(0:1/3:5)'; (0:1/3:5)']; moo = [mool, moo2]; C = [40000, 0; 0, 1/6]; cinv = inv(C); R = 91.0291870434372*eye(32); m= 1; ganma = 1; a = 1; %Main Loop for Disturbance update / gun firing: for k = 1:length(delta_e)-1 % Determine real aerodynamic forces: [Force_Z (m+k), ForceX (m+k), M_AERO, Smroke_Factor (k+1) ]=real_aero (... U(m+k) ,Alpha(m+k), AlphaRate (m+k), deltae (k), Q(m+k), 1,k*0.02); % Determine gravity forces: [FGZ, FGX] = gravity (Nz, c_th (m-k), theta_rad,Tobtal_Mass,m+k); 83 I* % Sum forces on the aircraft: ['IOIA(m+k) , TrALZ, 'IILX]=sum_4ces (M_AERO, ForceX (mrk), ... Force_Z (m+k), FGX, FGZ, 1,FX_EINE) ; % Determine Aircraft Rates: [QDOT, WDDIT, UDC] =find_rates (I LZ, Q(mk) , U(mk), W(mk) , OIALX); M(m+k), MASSINV(m), RIYY (m),... %Move Aircraft: [U (mk+l), W(m+k+l) , Q(m+k+1) ,Alpha (m+k+1), AlphaRate (m+k+), ... theta_rad (m+k+l) , c_th (m+k+1) ] =move_ac (U (mk),W(m+k) ,Q(m+k), ... theta_rad (m+k), WDTl, QDOT, UDOT) ; % Calculate and apply PAC2 Input: [Elevator_Cmd (k+l), XQ1,XQ2] =sas (AlphaRate (m+k+l), XQ1,XQ2, 1,2,... theta_rad, Q,m+k) ; k < length(delta_e) if delta_e (k+l) =delta_e (k+l)-Elevator_Cmd (k+1) ; if delta_e(k+l) > 35.0 delta_e(k+l) = 35.0; elseif delta_e(k+l) < -10 delta_e (k+l) = -10; end end % Determine Disturbance Density Ratio: ratio (k+l) = run4 (k+l) /delta_e (k+l) ; if (ratio (k+l) > 2) ratio (k+l) = 2; elseif(ratio(k+l) <= 0) ratio(k+l) = 0.0001; end % Train RBF using Disturbance Density Ratio: X = [U(k+l), k*0.02]; for n = 1:32 h(n,1) = exp(-((X-moo(n,:))*cinv* (X-moo(n,:)))); end delta = ratio(k+l)-(1+Wr' *h); Wr = Wr + (R * h ./ (1 + h' * R * h) )*delta; R = R - R * h * h' * R ./ (1 + h' * R * h); end % Main Loop For disturbance learning and gun fire simulation: % Calculate Estirrated Disturbance Density Ratio for plotting: for k = 1:250 84 --- ~--- It- X = [U(k+l), k*0.02]; for n = 1:32 h(n,1) = exp(-((X-noo(n,:))*cinv* (X-moo(n,:)))); end ratio_hat(k) = 1+Wr' *h; end % Subroutines: % Real Aircraft Aerodynamics functicn [ForceZ, Force_.X, MAE , Sbroke_Factor, CMOValue,... dcd] =real_aero (U, Alpha,AlphaRate, Elevator_Position, Q,Gun_Switch, t) % Look up tables for Stability Derivatives: Clean_Lift = [0, 0.37, 0.57, 0.69, 0.74; -14.0, -0.3, -0.31, -0.32, -0.33; -8.0, -0.82, -0.90, -0.95, -1.0; -6.0, -0.47, -0.50, -0.55, -0.61; -2.0, -0.1, -0.16, -0.25, -0.32; 0.0, 0.08, 0.09, -0.04, -0.08; 4.0, 0.46, 0.41, 0.36, 0.35; 8.0, 0.79, 0.79, 0.79, 0.79; 12.0, 1.14, 1.17, 1.21, 1.25; 16.0, 1.46, 1.55, 1.62, 1.67; 20.0, 1.14, 1.17, 1.21, 1.25; 30.0, 0.49, 0.52, 0.54, 0.57]; CMSTAL = [0, 18.6; 0.225, 18.1; 0.35, 17.2; 0.45, 16.2; 0.6, 13.0; 0.7, 9.4]; Clean_Drag = [0.2, 0.0448; 0.49, 0.0448; 0.55, 0.0465; 0.60, 0.0489; 0.65, 0.0521; 0.70, 0.0557; 0.75, 0.0763]; Stall_Drag = [-180, 0; -90.0, 1.8033; -20.0, 0.2509; -15.0, 0.1244; -10.0, 0.0541; -5.0, 0.0095; -4.0, 0; 20.0, 0; 25.0, 0.1774; 30.0, 0.3663; 35.0, 0.5835; 40.0, 0.7623; 45.0, 0.9333; 50.0, 1.1023; 85 55.0, 1.2573; 60.0, 1.3903; 65.0, 1.5133; 70.0, 1.5963; 75.0, 1.6743; 80.0, 1.7583; 85.0, 1.7993; 90.0, 1.8033; 180.0, 0]; DCDCIF2 = [0.2, 0.068; 0.5, 0.068; 0.6, 0.1025; 0.65, 0.1236; 0.7, 0.175; 0.75, 0.271]; CLFCbTIN = [0.2, 0.1324; 0.5, 0.1324; 0.6, 0.2233; 0.65, 0.2636; 0.7, 0.2878; 0.75, 0.2407]; Elevator_Lift = [0.225, 0.007; 0.45, 0.005; 0.60, 0.005; 0.70, 0.004; 0.75, 0.004]; cg x = 35.9/12.0; cg z = 10.6/12; CMOA = 0.0159; CMOM = 1.25; CMDE = -0.0131*1.0194;%*0.9765for aft cg;%for forward cg; CNQ = 0.67; CMAD = 0.60; Wingarea = 506.0; density = 2.38444e-03; Chord = 8.943; Degrees_to_Radians = pi/180; % Look up tables for Smoke Disturbance: x = 0:1/3:5; speed = 400:80:800; y2 = [1.0000 0.9611 0.83,27 0.7661 0.73 24 0.7177 0.7162 1.0000 0.9340 0.8176 0.7569 0.7235 0.7057 0.6985 1.0000 0.9064 0.8014 0.7463 0.7138 0.6931 0.6805 1.0000 0.8785 0.7844 0.7345 0.7030 0.6793 0.6614 1.0000 0.8498 0.7665 0.7218 0.6910 0.6646 0.6422 1.0000 0.8209 0.7475 0.7078 0.6777 0.6489 0.6219]; y2 = [y2, [0.7249 0. 7406 0.7579 0.7701 0.7718 0. 7631 0.7564 0.7003 0.7093 0.7210 0.7291 0.7278 0.7150 0.6985 0.6763 0.6799 0.6882 0.6954 0.6957 0.6855 0.6694 0.6511 0.6482 0.6514 0.6549 0.6523 0.6381 0.6130 0.6263 0.6189 0.6187 0.6216 0.6206 0.6089 0.5845 86 I-'----' -- -~t~ 0.5629 0.5783 0.5823 0.6004 0.5875 0. 5827 0.5305]]; 0.9057 y2 = [y2, [0.7831 0.7036 0.7825 0.6672 0.7222 0.5908 0.6061 0.5560 0.5503 0.4422]]; 0.4842 1.3760 1.4097 1.4412 1.3409 1 .2945 1.2090 y = [1.0276 1.3992 1.4291 1.4544 1.3642 1.0241 1.2189 1.3135 1.4224 1.4486 1.4682 1.3875 1.3325 1.0207 1.2288 1.4456 1.4680 1.4814 1.4108 1.3515 1.2387 1.0173 1.4688 1.4876 1.4952 1.4342 1.3705 1.2486 1.0138 1.4920 1.5070 1.5085]; 1.4575 1.3895 1.2585 1.0104 1.4919 1.5099 1.4868 1.4874 1.4813 y = [y, [1.4662 1.5477 1.4923 1.5200 1.4790 1.4778 1.4810 1.4809 1.4724 1.4941 1.5217 1.4784 1.4754 1.4793 1.4827 1.4797 1.4762 1.4934 1.4652 1.4655 1.4734 1.4821 1.4859 1.4779 1.4952 1.4645 1.4631 1.4717 1.4839 1.4932 1.4604 1.4517 1.4535 1.4659 1.4835 1.4995 1.4674]]; y = [y,[1.6019 1.6509 1.5522 1.5588 1.5293 1.5461 1.4959 1.4367 1.4898 1.4072 1.4401 1.3151]]; smoke = [0,0.01,x(2:length(x));speed',y]; if Gun_Switch Smoke_Factor = table2(smoke,U,t); else Smoke_Factor = 1; end Dynamic_Pressure = 0.5*density*U^2; E_DynamnicPressure = Dynamic_Pressure * Smoke_Factor; Terp = Chord/ (2.0*U); Mach = U/1115.98; Stall_Alpha = tablel (CNS'ALL,Mach); if Alpha < -4.0 Limit = -4.0; CMI = -0.01638*(Alpha + 4.0); elseif Alpha < StallAlpha Limit = Alpha; CM = 0.0; else Limit = Stall_Alpha; if Alpha - Stall_Alpha > 60.0 CM1 = -1.14; else CMIl = -0.019*(Alpha - Stall_Alpha); 87 end if Alpha < 0.0 CG2 = -0.78 - 1.49*(Mach - 0.45); else CM2 = -0.34 + 0.66*(Mach - 0.45); end CM2 = CM2 * Limit * Degrees_to_Radians; CMO_Value = CmIOM * (CMOA - 0.067*(Mach - 0.45) + CnM + CM2); CMDE_Value = CMDE * Elevator_Position; CNQ Value = CMQ * (-11.5) * Q * Tesp; CMAD_Value = CMAD * (-5.3) *Alpha_Rate*Tenp; Y_Ccaponent = CMO_Value + CCLValue + CMAD_Value; Y_Carponent2 = CMDE_Value; % Frcn procedure lift.a Z_Ccponent = table2(Clean_Lift,Alpha,Mach); Z_Ccnponent2 = tablel (Elevator_Lift,Mach) *Elevator_Position; % Frcman procedure drag.a dcd = (Z_Cmaponent+Z_Ccuponent2-tablel (CLFCG IN,Mach)) ; CMO_Value = tablel (DCECLF2,,Mach)* (dcd^2) ; X_Carpanent = tablel(Cle DraMach)tablel (StallDrag, Alpha) +CMOValue; % Frcn procedure total_aero.a Term_l1 = Dynamic_Pressure * Wingarea; Term_2 = EIynamic_Pressure * Wingarea; cosAlpha = cos (Alpha*Degrees to_Radians); sinAlpha = sin (Alpha*Degrees to_Radians); Force_X = Term_l1* (Z_Carponent*sinAlpha-X_Ccmponent*cos_Alpha); Force_X = Force_X+Term_2* (Z_Ccaponent2*sin_Alpha); Force_Z = Term_l* (-Z_Ccrrponent*cos_Alpha-X_Ccaponent*sinAlpha); Force_Z = Force_Z+Term_2* (Z_Ccmponent2*cos_Alpha); Couple_Y = (Term_1 * Y_Ccaponent +Term_2 * Y_Carponent2) * Chord; M_AERO = Couple_Y + cg_z*Force_X - cg x*Force_Z; function [FGZ,FGX, delGX] = gravity (Nz,cos_theta,thetarad,Total_Mass,m) % function gravity.m % Determine real gravitational forces acting upon the aircraft g = 32.1739; FGZ = Nz*cos_theta * Total_Mass * g; FGX = -Nz*sin(theta_rad(m)) * Total_Mass * g; if nargout==3 del_GX = -Nz * Total_Mass * g * (sin (theta_rad (m)) -... sin(theta_rad(m-1)) ); end % gravity.m function [IOTIALM,ITOTALZ,TOTALX] =sum_4ces (M_AERO, ForceX, Force_Z, FX,FGZ, ... Gun_Switch, FXENGINE) % FUNCJTION sum_4ces % provide the sumning junction for aero, gravity, gun, and engine forces Gun Z Pos = 32/12; Recoil = -10000; Gun Marent = -Recoil*Gun Z Pos; 88 __ __ _II ~~~~~~~____ 'ICIALX = Force_X + FX_ENGINE + FGX; if GunStwitch if nargin=6 'IOIALX = 0; else 'IOIALX = 'IIALX + Recoil; end VLAERO = M_AERO + Gun_Mxrent; end 'TOIALZ = Force_Z+ FGZ; =-'IOILM M_AERO; function [QDOT, WDrOT, UDOT] = find_rates ('IIALZ, TOrALMASSINV, RIYY, Q, .. U,W,'DADX) % function findrates: find aircraft rates % Find QDOT, WDOT, UDOT if nargin==6 UDOT = 0; else UDOT = -Q*W + IOIALX*MASSINV; end WDOT = Q*U + TOIALZ*MASSINV; QDOT = -TIOT LM*RIYY; function [U, W,Q,Alpha, Alpha_Rate, theta_rad, cos_theta] =--ove_ac (U, W,Q,... theta_rad, WDIT, QDOT, UDOT) % function trove_ac % Integrate QDOT, WDI'X, and UDOT to find velocity and position % Updates Radians_to_Degrees = 180/pi; U = U+UDOT*0.02; W = W+WDO*0. 02; Q = Q + QDOT*0.02; Alpha = Radians_to_Degrees*atan (W/U); XsqrZsqr = U^2+W2; AlphaRate = (U*WDOT-W*UDOT) /Xsqr_Zsqr; theta_rad = theta_rad + Q*0.02;% + G(4)*v(m); cos_theta = cos(theta_rad); function [Force Z hat,IOALMhat,F Z hatl, FXhat, s_A,c_A, cm0, arde, ... cmrrq, cmad, clde, Te1rml, Term_2, CoupleY] =aerc_4ce_stiatr (U, Alpha, ... AlphaRate, Elevator_Position, Q,cgx, Gun_Switch, Smoke_Factor) % Estimate Aero Forces % Estinator using polyncmials in place of look up tables: T = 0.02; Clean_Lift = [0, 0.37, 0.57, 0.69, 0.74; -14.0, -0.3, -0.31, -0.32, -0.33; -8.0, -0.82, -0.90, -0.95, -1.0%; -6.0, -0.47, -0.50, -0.55, -0.61; -2.0, -0.1, -0.16, -0.25, -0.32; 89 0.0, 0.08, 0.09, -0.04, -0.08; 4.0, 0.46, 0.41, 0.36, 0.35; 8.0, 0.79, 0.79, 0.79, 0.79; 12.0, 1.14, 1.17, 1.21, 1.25; 16.0, 1.46, 1.55, 1.62, 1.67; 20.0, 1.14, 1.17, 1.21, 1.25; 30.0, 0.49, 0.52, 0.54, 0.57]; Wingarea = 506.0; density = 2.38444e-03; Chord = 8.943; cg_z = 10.6/12; Degrees to Radians = pi/180; Y_Ccnaponent = 0.0; CMDE = -0.0131*(720-(463.3-cg_x*12))/292.6; if Gun_Switch Smnke_Factor = 1; else Smoke_Factor = 1; end m = 1; Pickle = 0; Dynamic_Pressure = 0.5*density*U^2; Term_l1 = Dynamic_Pressure * Wingarea; Mach = U/1115.98; Mach_sqr = Mach * Mach; cnq = -185. 872880263286*U*Q* (density/2.38444e-03); crad = -76.71327180236862*U*Alpha_Rate* (density/2.38444e-03); cm0 = 0.019875 - 0.08375 * (Mach - 0.45) - 0.425 * Alpha * Degrees_to_Radians; cmO = cmnO + 0.825 * (Mach - 0.45) * Alpha * Degrees to_Radians; if Mach < 0.45 clde = -0.00888888888889*Mach + 0.00900000000000; elseif Mach <=0.6 clde = 0.005; else clde = -0.01000000000000*Mach + 0.01100000000000; end if Mach<=0.49; Clean_Drag = 0.04480000000000; else Clean_Drag = 0.14573602515979*Mach_sqr0.12103021203206*Mach+0.06907097494167; end if Alpha<-4.0 StallDrag = -0.01494737417943*Alpha-0.07365164113786; elseif Alpha<=20 Stall_Drag = 0; else Stall.Drag = 0.02687692857143*Alpha-0.36373107142857; end if Mach<=0.5 DCDCLF2 = 0.06800000000000; CLFCIN = 0.13240000000000; else 90 --- -- B CLFCEMIN = 0.79457142857143*Mach -0.25990000000000; DCDCLF2 = 2.27818181818184*Mach_sqr2.21394545454548*Mach+0.60618363636365; end A_sqr = Alpha * Alpha; cmde = CM[E * Elevator_Position; Z_Carmonent = table2 (Clean_Lift,Alpha,Mach); Z_Carponent2 = clde*Elevator_Positicn; X_Ccrpcnent = Clean_Drag + Stall_Drag + CDCLF2 * (Z_Ccrponent + Z_Capcnent2-CLFCEMIN) ^2; Term_2 = Term_l*S1ke_Factor; c_A = cos (Alpha*Degrees_to_Radians); s_A = sin (Alpha*Degrees_to_Radians); F_Z_hatl = Terml* (-Z_Carponent*c_A-XCarponent*s_A); Force_Z_hat = F_Z_hat1+Term_2* (Z_Ccarpnent2*c_A) ; F_X_hat = Terml* ( (Z_Carpoent+Z_Ccrponent2) *s_A-X_Carpnent*c_A); Couple_Y= (Term_1*car+Term_2*cmde) *Chord+crq +anad; M_AERO = Couple_Y + cgz*F_X_hat - cgx*Force_Z_hat; OIa.M_hat = M_AERO; function [riyy,massinv, cgx, P_W, P_, PC, delta.Q] =raspropest2 (W,Q,U, ... cos_theta, Force_Z_hat, 'IALMhat, riyy, rassinv, cgx, P_W, P__Q, P_C, n,m, ... CoupleY, ForceX) % Exponentially weighted least-squares mass properties identifier Nz = 1; T = 0.02; g = 32.1739; cgz = 10.6/12; Y_W = (W(m+l) -W(m)) /T-Q(m+t) *U (mil) -g*Nz*cos_theta (m+l) ; YQ = (Q(m)-Q(m+1))/T; Y_C = -YQ* (1/riyy)+Couple_Y+cg_z*Force_X; phiQ = 'IOILMhat; deltaQ = (YQ-phiQ*riyy); % Reset Covariances after a Bamb Drop: if (n<5) P_W = 1; PQ = 2.5e-06; P_C = 50; else phi_W = Force Z hat; phi_C = phi_W; Pickle = 0; % Reset Covariance flag at bcab drop tirre: if Pickle n=l; end gamra = 0.996; a = 1- gamra; 91 L_W = P_W/ganMa*phi_W*inv (1/a+phi_W* (P_W/gamm) *phi_W); LQ = PQ/gamm*phi.Q*inv (1/a+phiQ* (PQ/gama) *phiQ); L_C = PC*phiC*inv(l/O0. 1+phi_C* (PC) *phi_C) ; % if(PEflag) %can be unccrroented for persistent excitation test nassinv = Irassinv+LW* (Y_W-phi_W*massinv); riyy = riyy+LQ*deltaQ; cgx = cg_x+LC* (Y_C-phiC*cgx) ; % end % Logic stops on mass paraxmeters to prevent drift outside of aircraft % weight and balance envelope: if (riyy<le-7); riyy=le-7; end if(cgx < 28/12) cgx = 28/12; elseif (cg_x > 42/12) cgx = 42/12; end P_W = (1/gama) * (l-L_W*phi_W) *P_W; PQ = (1/gan ) * (1-LQ*phi_Q) *PQ; P_C = (1-L_C*phiC) *PC; end % ras_prop est2.m function [Elevator_Cmd] = pacl (Q,theta_rad,m) % Fracn procedure sas.a: % Sinulate closed-loop modes of the sas % Sinulate "PAC1 " Elevator_Cmd = -100* (theta_rad(l) -theta_rad (m1) ) +180*Q (mil); if Elevator_Cmd < -2.0; Elevator_Cad = -2.0; elseif Elevator_Cmd > 5.0; Elevator_Cmd = 5.0; end function [Elevator_Cmd, XQ1, XQ2] =sas (AlphaRate, XQ1, XQ2, Gun Switch, k,... theta_rad, Q,m) % Fran procedure sas.a: % Simulate closed-loop modes of the sas % Sinulate "PAC2" if nargin==3 Gun_Switch=0; end if Gun_Switch % Simulate PAC2 % k denotes sauple when Gun_Switch was activated Elevator_Crd = -93.83* (theta rad (k) -theta_rad (mtl) )+38. 084*Q (m+1); XQ1 = 0; XQ2 = 0; else % Simulate Normal SAS operation XQ3 = AlphaRate * 63.03 - (4.5 * XQ1 + 5.9 * XQ2); XQ2 = 0.02 * XQ3 + XQ2; 92 ---^-I- .I --~I- - -R- XQ1 = 0.02 * XQ2 + XQ1; Elevator_Ormd = 4.5 * XQ2 + 0.45 * XQ3; % Inplement SAS control authority limits: if Elevator_Cmd < -2.0; Elevator_Cmd = -2.0; elseif Elevator_Cmd > 5.0; Elevator_Cmd = 5.0; eid function [delta_e, U] =prdict_de_in (U, Alpha, AlphaRate, Q,W,massinv, ... riyy, theta_rad, Nz, cth,m, cgx, bm, bz) % Predict Elevator_input % Predict PAC2 inputs for hierarchical irrplementation: chord = 8.943; cgz = 10.6/12; GunrZ_Pos = 32/12; Recoil = -10000; M_GUN = -Recoil*Gun_Z_Pos; t_m1/rrassinv; UDOT = (U(m) -U(m-) ) /0.02; ICaMLXl = (UDOT + Q(m) *W(m) ) /massinv; % Ccmrented lines below needed to inplemrent predicted disturbance % density ratio in predicted input: %loadwate.dat; %Wr = wate; %mool = [465*ones(16,1); 773*nes(16,1) ]; %moo2 = [(0:1/3:5)'; (0:1/3:5)']; %moo = [mool, rrmoo2]; %C= [40000, 0; 0, 1/6]; %cinv = inv(C); %Main Prediction Loop: for k = 0:249; %X= [U(m+k), k*0.02]; %for n = 1:32 % h (n, 1) = exp(-( (X-moo(n,: )) *cinv*(X-moo (n,: )) %end Srmoke_Factor = 1; %+Wr' *h; ) ; % Estimate Aerodynamic Forces: [f z h, tm_h,F Z hatl,F X hatl (m+k) ,s_A, c_A, c0, cde, crq, crrad, clde, ... Term_l, Term_2] =aero_4ce_stimatr (U (m+k), Alpha (m+k) ,AlphaRate (m+k) ,... 1,Q(m+k) ,cgx, 1, Sroke_Factor); % Determine QDT needed for dead-beat control: 93 if k= 0 QDOTdes = 0; else Q des = (theta_rad (m) -theta_rad(mk) ) /0.02; QDOT_des = ((Qdes - Q(m+k))/0.02); end TIILMdes = -QDOTdes/riyy; % Determine Elevator Position needed for QDOT desired: delta_e (k+l) = (ITOIM4_des+b_m-M_GUN-chord*Term_1*cm0+cmq+... cmad-cgz*F X hatl (m+k) +cg_x*F Z hatl) / (Term_2* (chord*cmde+clde*... (cgz*s_A-cg_x*c_A))); % Estirrate Aerodynamic Forces based upon Desired Elevator Position: [f_z_h, tmh, fzhl,F X hatl (m+k+l) ]=aero_4ce_stimatr (U(m+k), . .. Alpha (m+k) ,AlphaRate (mk),delta_e (k+l) ,Q(mk), cgx, 1,Smoke_Factor) ; del_X = F X hatl (mk+l)-F_X_hatl (m); tm h = tmn_h-bm; % Estirrate Aircraft Gravitaticnal Forces: [FGZ, FQG, del_GX] =gravity (Nz, cth (m+k) ,theta_rad, tm,r+k); % Sum Aircraft Forces: [TOTALM, TIALZ,TIIALX] =sum_4ces (tmh, 'IOILX1,f z h, del_X+del_GX, FGZ, ... 1,0); % Find Aircraft Rates: [QDOT, WDT, , UDOT] =find_rates ( ALZ, ALM, assinv, riyy, Q(m+k), ... U (m+k) , W(m+k) ,~CALX) ; % Propagate Aircraft State based upon Estiated Aero Forces and % Estimated Mass Properties: [U (m+k+l), W(n+k+l) , Q(m+k+l), Alpha (m+k+l) , Alpha Rate (rk+l), ... theta_rad (mk+l) ,c_th (m+k+l) ] =move_ac (U (m+k) ,W(mk),Q(mk),... theta_rad (mik) ,WOT, QDOT, UDOT) ; end % Main Input Prediction Loop 94 - -- --- " References [1] Kolk, R. W., Modern Flight Dynamics : Englewood Cliffs, N.J.: PrenticeHall, 1961. [2] Ljung, L., System Identification: Theory for the User : Englewood Cliffs, N.J.: Prentice-Hall, 1987 [3] Franklin, G. F., Powell, J. D. and Workman, M. L., Digital Control of Dynamic Systems, 2nd ed. New York, Addison-Wesley, 1992. [4] Ljung, L., "On Positive Real Transfer Functions and the Convergence of Some Recursive Schemes," IEEE Trans. Automat. Contr., vol AC-22, no. 4, pp. 539-550, 1977. [5] Brooks, R., "A Robust Layered Control System For A Mobile Robot," IEEE Journal of Robotics and Automation., vol. RA-2, no. 1, pp 14-23, 1986. [6] Bittanti, S. and Campi, M., "Adaptive RLS Algorithms Under Stochastic Excitation--L 2 Convergence Analysis," IEEE Trans. Automat. Contr., vol. 36, no. 8, pp. 963-967, 1991. [7] Gelb, A., et al., Applied Optimal Estimation, M.I.T. Press, Cambridge, MA, 1974. [8] Kawato, M. Gomi, H.: Learning Control for a Closed Loop System using Feedback-Error-Learning,Proceedings of the 29th IEEE Conference on Decision and Control, pp 3289-3294 (1990) [9] Brown, R. G., Hwang, P. Y. C.: Introduction to Random Signals and Applied Kalman Filtering, Second Edition, Wiley (1992) [10] USAF Series A-10A/OA-10A Aircraft, T. O. 1A-10A-1. 20 February 1983, Change 14, 26 May 1992. 95 milk- [11] Garcia-Velo, J., "Parameter Estimation of an Unstable Aircraft Using an Extended Kalman Filter," MS Thesis, University of Cincinnati, 1991. [12] Lang, James D., Aircraft Performance, Stability and Control, United States Air Force Academy Department of Aeronautics, Colorado Springs, 1974. [13] Householder, A. S., The Theory of Matrices in Numerical Analysis, Blaisdell, Waltham, Mass., 1964. 96