| Aerospace Blockset™ | ![]() |
| On this page… |
|---|
Modeling a Classical Three-Loop Autopilot Modeling the Homing Guidance Loop |
This case study explains the design and simulation of a guidance system for a three-degrees-of-freedom missile. The model includes all aspects of the system, from the missile airframe (plant) and environment to the controller.
Note The Stateflow® module in this demo is precompiled and does not require Stateflow to be installed. |
To view the missile guidance system model, enter aeroblk_guidance at the MATLAB® command line.
The missile airframe and autopilot are contained in the Airframe & Autopilot subsystem. The Seeker/Tracker and Guidance subsystems model the homing guidance loop.

The model of the missile airframe in this demo uses advanced control methods applied to missile autopilot design [1], [2], [3]. The model represents a tail-controlled missile traveling between Mach 2 and Mach 4, at altitudes ranging between 3,050 meters (10,000 feet) and 18,290 meters (60,000 feet), and with typical angles of attack in the range of ±20 degrees.
Missile Airframe Model

The core element of the model is a nonlinear representation of the rigid body dynamics of the airframe. The aerodynamic forces and moments acting on the missile body are generated from coefficients that are nonlinear functions of both incidence and Mach number. You can model these dynamics easily with the Aerospace Blockset™ blocks.
The model of the missile airframe consists of two main components:
ISA Atmosphere Model Block calculates the change in atmospheric conditions with changing altitude.
Aerodynamics & Equations of Motion Subsystem calculates the magnitude of the forces and moments acting on the missile body and integrates the equations of motion.
To view the missile airframe model, enter aeroblk_guidance_airframe at the MATLAB command line.

The ISA Atmosphere Model block is an approximation of the International Standard Atmosphere (ISA). This block implements two sets of equations. The troposphere requires one set of equations, and the lower stratosphere requires the other set. The troposphere lies between sea level and 11,000 meters (36,089 feet). The ISA model assumes a linear temperature drop with increasing altitude in the troposphere. The lower stratosphere ranges between 11,000 meters (36,089 feet) and 20,000 meters (65,617 feet). The ISA models the lower stratosphere by assuming that the temperature remains constant.
Variation of Sound Speed and Air Density with Altitude

The following equations define the troposphere.
![]()
![]()
![]()
![]()
The following equations define the lower stratosphere.
![]()
![]()
![]()
![]()
The symbols are defined as follows:
|
| Absolute temperature at mean sea level in kelvin (K) |
|
| Air density at mean sea level in kg/m3 |
|
| Static pressure at mean sea level in N/m2 |
|
| Altitude in m |
|
| Height of the troposphere in m |
|
| Absolute temperature at altitude h in kelvin (K) |
| ρ | Air density at altitude h in kg/m3 |
|
| Static pressure at altitude h in N/m2 |
|
| Speed of sound at altitude h in m/s2 |
|
| Temperature lapse rate in K/m |
|
| Characteristic gas constant J/kg-K |
|
| Ratio of specific heats |
|
| Acceleration due to gravity in m/s2 |
You can look under the mask of the ISA Atmosphere Model block to see how these equations are implemented.
The Aerodynamics & Equations of Motion subsystem generates the forces and moments applied to the missile in the body axes and integrates the equations of motion that define the linear and angular motion of the airframe. The aerodynamic coefficients are stored in data sets. During the simulation, the value at the current operating condition is determined by interpolation using the Interpolation (n-D) using PreLook-Up blocks.

These are the three-degrees-of-freedom body axis equations of motion, which are defined in the 3DoF (Body Axes) block.
![]()
![]()
![]()
![]()
These are the aerodynamic forces and moments equations, which are defined in the Aerodynamics subsystem.
![]()
![]()
![]()
![]()
These are the stability axes variables, which are calculated in the Incidence & Airspeed block.
![]()
![]()
The symbols are defined as follows:
|
| Attitude in radians |
|
| Body rotation rate in rad/s |
|
| Missile mass in kg |
|
| Acceleration due to gravity in m/s2 |
|
| Moment of inertia about the y-axis in kg-m2 |
|
| Acceleration in the Z body axis in m/s2 |
|
| Change in body rotation rate in rad/s2 |
|
| Thrust in the X body axis in N |
|
| Air density in kg/m3 |
|
| Reference area in m2 |
|
| Coefficient of aerodynamic force in the X body axis |
|
| Coefficient of aerodynamic force in the Z body axis |
|
| Coefficient of aerodynamic moment about the Y body axis |
|
| Reference length in m |
|
| Fin angle in rad |
|
| Aerodynamic force in the X body axis in N |
|
| Aerodynamic force in the Z body axis in N |
|
| Aerodynamic moment along the Y body axis |
|
| Dynamic pressure in Pa |
|
| Airspeed in m/s |
|
| Incidence in rad |
|
| Velocity in the X body axis in m/s |
|
| Velocity in the Z body axis in m/s |
The missile autopilot controls the acceleration normal to the missile body. The autopilot structure of this case study is a three-loop design using measurements from an accelerometer located ahead of the missile's center of gravity and from a rate gyro to provide additional damping. The controller gains are scheduled on incidence and Mach number and tuned for robust performance at an altitude of 3,050 meters (10,000 feet).
Classical Autopilot

Designing an autopilot requires the following:
Trimming and Linearizing an Airframe Model explains how to model the airframe pitch dynamics for several trimmed flight conditions.
Autopilot Design summarizes the autopilot design process.
Designing the autopilot with classical design techniques requires linear models of the airframe pitch dynamics for several trimmed flight conditions. The MATLAB software can determine the trim conditions and derive linear state-space models directly from the nonlinear Simulink® model. This step saves time and helps to validate the model. The functions provided by Simulink Control Design or Control System Toolbox allow you to visualize the behavior of the airframe in terms of open-loop frequency or time response.
The airframe trim demos show how to trim and linearize an airframe model.
To run the demo based on the Control System Toolbox™ product, enter asbguidance_trimlinearize_cst. The results of this demo are displayed as a Bode diagram in the LTI Viewer.
The alternative demo, asbguidance_trimlinearize, uses the Simulink® Control Design™ product instead and produces identical results.

Autopilot design can begin after the missile airframe has been linearized at a number of flight conditions. Autopilot designs are typically carried out on a number of linear airframe models derived at varying flight conditions across the expected flight envelope. Implementing the autopilot in the nonlinear model involves storing the autopilot gains in two-dimensional lookup tables and incorporating an antiwindup gain to prevent integrator windup when the fin demands exceed the maximum limits. Testing the autopilot in the nonlinear model is the best way to demonstrate satisfactory performance in the presence of nonlinearities, such as actuator fin and rate limits and dynamically changing gains.
The Autopilot subsystem is an implementation of the classical three-loop autopilot design.

The complete homing guidance loop consists of these two subsystems:
The Guidance Subsystem generates the normal acceleration demands that are passed to the autopilot and uses the Stateflow software.
The Seeker/Tracker Subsystem returns measurements of the relative motion between the missile and the target.
The autopilot is part of an inner loop within the overall homing guidance system. Consult reference [4] for information on different types of guidance systems and on the analysis techniques that are used to quantify guidance loop performance.

Initially, the Guidance subsystem searches to locate the target's position and then generates demands during closed-loop tracking. A Stateflow chart controls the transfer between the different modes of these operations. The Stateflow product is the ideal tool for rapidly defining all the operational modes, both during normal operation and during unusual situations.

Guidance Processor State Chart. Mode switching is triggered by events generated in the Simulink software or in the Stateflow chart. The variable Mode is passed to the Simulink software and is used to control the Simulink model's behavior and response. For example, the Guidance Processor state chart, which is part of the Guidance subsystem, shows how the system reacts in response to either losing the target lock or failing to acquire the target's position during the target search.
During the target search, this Stateflow state chart controls the tracker directly by sending demands to the seeker gimbals (Sigma_d). Target acquisition is flagged by the tracker once the target lies within the beam width of the seeker (Acquire) and, after a short delay, closed-loop guidance begins.

Proportional Navigation Guidance. Once the seeker has acquired the target, a proportional navigation guidance (PNG) law guides the missile until impact. This form of guidance law is the most basic, used in guided missiles since the 1940s, and can be applied to radar-, infrared-, or television-guided missiles. The navigation law requires measurements of the closing velocity between the missile and target, which for a radar-guided missile can be obtained with a Doppler tracking device, and an estimate for the rate of change of the inertial sight line angle.
Proportional Navigation Guidance Measurements

The diagram symbols are defined as follows:
| λ | Navigation gain (> 2) |
| Vc | Closing velocity |
| Θb | Body attitude |
|
| Sight line rate |
| σg | Gimbal angle |
| σL | Look angle |
| σd | Dish angle |
| az_dem = λVc
| Demanded normal acceleration |
The Seeker/Tracker subsystem controls the seeker gimbals to keep the seeker dish aligned with the target and provides the guidance law with an estimate of the sight line rate.
![]()
Tracker and Sightline Rate Estimator. The Tracker and Sightline Rate Estimator is the most elaborate subsystem of the Seeker/Tracker subsystem because of its complex error modeling.
The subsystem contains a number of feedback loops, estimated parameters, and parasitic effects for the homing guidance.
The tracker loop time constant tors is set to 0.05 second, a compromise between maximizing speed of response and keeping the noise transmission within acceptable levels.
The stabilization loop compensates for body rotation rates. The gain Ks, which is the loop crossover frequency, is set as high as possible subject to the limitations of the stabilizing rate gyro's bandwidth.
The sight line rate estimate is a filtered value of the sum of the rate of change of the dish angle measured by the stabilizing rate gyro and an estimated value for the rate of change of the angular tracking error (e) measured by the receiver. In this model, the bandwidth of the estimator filter is set to half that of the bandwidth of the autopilot.

Radome Aberration. The Tracker and Sightline Rate Estimator subsystem also models the radome aberration.
Radome aberration is a parasitic feedback effect commonly modeled in radar-guided missile designs and occurs because the shape of the protective covering over the seeker distorts the returning signal and gives a false reading of the look angle to the target. The distortion is, in general, a nonlinear function of the current gimbal angle. A common approximation is to assume a linear relationship between the gimbal angle and the magnitude of the distortion. The approximation is valid for a limited range of angle. Other parasitic effects, such as sensitivity to normal acceleration in the rate gyros, are often modeled as well to test the robustness of the target tracker and estimator filters.

Running the guidance simulation demonstrates the performance of the overall system. The target is defined to be traveling at a constant speed of 328 m/s on a reciprocal course to the initial missile heading and 500 meters above the initial missile position. The data, shown in the following figure, can be used to determine if the missile can withstand the flight demands and complete the mission to target.

Target acquisition occurs 0.69 second after search initiation, with closed-loop guidance starting after 0.89 second. Impact with the target occurs at 3.46 seconds, with the range to target at the point of closest approach calculated to be 0.26 meter.

Modeling the airframe and guidance loop in a single plane is only the start of the design process. Extending the model to a full six-degrees-of-freedom representation requires the implementation of the full equations of motion for a rigid body.
Six degrees of freedom can be represented using a quaternion or Euler angles.
The first implementation uses a quaternion to represent the angular orientation of the body in space. The quaternion is appropriate when the standard Euler angle definitions become singular as the pitch attitude tends to ±90 degrees.
The second implementation uses the standard Euler angle equations of motion. Euler angles are appropriate when obtaining trim conditions and modeling linear airframes. This model contains one of the six-degrees-of-freedom equations of motion blocks.

[1] Bennani, S., D. M. C. Willemsen, and C. W. Scherer, "Robust LPV control with bounded parameter rates," AIAA-97-3641, August 1997.
[2] Mracek, C. P. and J. R. Cloutier, "Full Envelope Missile Longitudinal Autopilot Design Using the State-Dependent Riccati Equation Method," AIAA-97-3767, August 1997.
[3] Shamma, J. S. and J. R. Cloutier, "Gain-Scheduled Missile Autopilot Design Using Linear Parameter Varying Transformations," Journal of Guidance, Control and Dynamics, Vol. 16, No. 2, March-April 1993.
[4] Lin, Ching-Fang, Modern Navigation, Guidance, and Control Processing, Vol. 2, Prentice Hall, 1991.
![]() | NASA HL-20 Lifting Body Airframe | Block Reference | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |