4

Click here to load reader

Mathematical Model and Six-Degree-Of-Freedom Simulation of Two Business Jet Aircraft

Embed Size (px)

DESCRIPTION

model

Citation preview

Page 1: Mathematical Model and Six-Degree-Of-Freedom Simulation of Two Business Jet Aircraft

20/10/15, 7:46 AMMathematical Model and Six-Degree-of-Freedom Simulation of Two Business Jet Aircraft

Page 1 of 4http://www.princeton.edu/~stengel/FDcodeB.html

Appendix B. Mathematical Model andSix-Degree-of-Freedom Simulation of aBusiness Jet AircraftSupplement for Flight Dynamics, a book by RobertF. Stengel

A number of the examples in this book are based on the dynamic characteristics of a generic business jetaircraft. The mathematical models given below are motivated by full-scale aircraft; however, they shouldnot be construed as accurate representations of any specific aircraft, as considerable liberties have beentaken in the derivation of the mathematical models. Specifically, Mach effects are estimated using themethods of Section 2.4, rotary derivatives are calculated with the equations of Section 3.4, power effectsare limited to a simple model of thrust (with no modeling of associated aerodynamic effects), andmoments and products of inertia are estimated using simplified mass distributions.

The aircraft dynamic models are presented as MATLAB functions that are called by the programFLIGHT. FLIGHT illustrates the essential features of flight analysis and simulation using a modularframework. Aircraft characteristics are described in the AeroModel function.

FLIGHT is a tutorial program, heavily commented to make interpretation easy. It provides a full six-degree-of-freedom simulation of an aircraft, as well as trimming calculations and the generation of alinearized model at any flight condition chosen by the user. Changes to aircraft control histories, initialconditions, flag settings, and other program control actions are made by changing the numbers containedin the code; there is no separate user interface. The code has been designed for simplicity and clarity notfor speed of execution, leaving a challenge to the reader to find ways to make the program run faster.Numerous additions could be made to the code, including implementation of feedback control logic,simulation of random turbulence or microburst wind shear, and interfaces for real-time execution. Noexplicit or implicit warranties are made regarding the accuracy or correctness of the computer code.

B.1 Main Program for Analysis and Simulation (FLIGHT)

Download FLIGHT.m

FLIGHT is the executive file (or script) that calls program functions. Initial conditions are defined here,the three primary features (trim, linearization, and simulation) are enabled, and output is generated. Initialperturbations to trim state and control allow transient effects to be simulated. As shown, trimming forsteady, level flight is accomplished by first defining a cost function, J, that contains elements of the staterate, then minimizing the cost using the Downhill Simplex (Nelder-Mead) algorithm contained infminsearch. The longitudinal trimming parameters are stabilator angle, throttle setting, and pitch angle.The linear model is generated by numjac, a numerical evaluation of the Jacobian matrices associated withthe equations of motion. The linear model is saved to disk files in the variables Fmodel and Gmodel.MATLAB's ode23, ode45, or ode15s integrate the equations of motion to produce the state history. Thestate history is displayed in time plots, with angles converted from the radians used in calculation todegrees. The reader can readily change the units of plotted quantities or add additional plots through

Page 2: Mathematical Model and Six-Degree-Of-Freedom Simulation of Two Business Jet Aircraft

20/10/15, 7:46 AMMathematical Model and Six-Degree-of-Freedom Simulation of Two Business Jet Aircraft

Page 2 of 4http://www.princeton.edu/~stengel/FDcodeB.html

minor modifications to the code. Any result (e.g., numerical values of the state history) can be displayedin the MATLAB Command Window simply by removing the semi-colon at the end of the line. The flagMODEL selects either the low-angle-of-attack, Mach-dependent model for BizJet A or the high-angle-of-attack, low-subsonic model for Bizjet B.

B.2 Low-Angle-of-Attack, Mach-Dependent Model for BizJet A(AeroModel)

Download Mach-dependent AeroModelMach.m

This version of AeroModel uses aerodynamic and dimensional data contained in Ref. B-1 with estimatesof inertial properties of the generic business jet. Details of the configuration, such as sweep and aspectratio of the wing and tail, are used in the estimates of Mach effects. Wind tunnel results were reviewed forall test conditions and control settings, then reduced to simple linear and quadratic coefficients thatdescribe significant aerodynamics for low angles of attack and sideslip (within about +/-8 degrees ofzero). Increments for landing gear, symmetric spoilers, and flaps are added, as appropriate. Estimates ofMach effects are based on the Prandtl factor (Section 2.4) or the modified Helmbold equation (eq. 2.4-9).Thrust available is assumed to be proportional to the air density ratio raised to a power that fits both staticthrust at sea level and the thrust required for flight at maximum Mach number (0.81) at an altitude of13,720 m (45,000 ft).

B.3 High-Angle-of-Attack, Low-Subsonic Model for Bizjet B(AeroModel)

The model for BizJet B is derived using handbook methods for estimating geometric, inertial, andaerodynamic characteristics (Sec. 2.4, 2.5, 3.4, and 3.5). The model is first built using GeoMassAero.m,which saves three .mat files describing the airplane: InerGeo.mat, DataTable.mat, and RotCont.mat.

Download GeoMassAero.m

AeroModelAlpha.m loads the .mat files for use in FLIGHT.m:

Download angle-of-attack-dependent AeroModelAlpha.m

The angle-of attack range extends from -10 to 90 deg based on conventional low-alpha and Newtonianhigh-alpha estimates. Linear interpolation is used between tabulated data points. No Mach, landing gear,spoiler, or flap effects are considered.

B.4 Supporting Functions

B.4.1 Equations of Motion (EoM)

Download EoM.m

Download event.m

The equations of motion for function EoM are written using the flat-earth assumption, as described inSection 3.2. Linear and translational rates are expressed in body axes, linear position is expressed in earth-relative axes, and the Euler angles describe the orientation of the body frame with respect to the earthframe. The lift and drag coefficients produced by AeroModel are transformed to body-axis coefficients;the remaining coefficients and thrust produced by the function are expressed in body axes. Effects of thewind and control settings are calculated by WindField and ControlSystem prior to calling AeroModel;

Page 3: Mathematical Model and Six-Degree-Of-Freedom Simulation of Two Business Jet Aircraft

20/10/15, 7:46 AMMathematical Model and Six-Degree-of-Freedom Simulation of Two Business Jet Aircraft

Page 3 of 4http://www.princeton.edu/~stengel/FDcodeB.html

hence, they are accounted for in the aerodynamic calculations. An ad hoc limit on the cosine of the pitchangle is imposed to prevent singular calculations in near-vertical flight. This expediency introduces asmall error when the pitch angle is near +/-90 deg. The function event.m specifies a stopping conditionthat terminates the simulation before the final time if the altitude goes below zero.

B.4.2 Cost Function for Aerodynamic Trim (TrimCost)

Download TrimCost.m

Trim control settings are calculated by minimizing the quadratic function of longitudinal accelerations(i.e., rates of change of axial velocity, normal velocity, and pitch rate) contained in TrimCost. As shown,equal weight is given to each component in the cost function, J, because the defining matrix, R, is anidentity matrix. The parameters that are adjusted to minimize J are the stabilator angle, the throttle setting,and the pitch angle (which equals the angle of attack in steady, level flight). TrimCost calls EoM togenerate the needed accelerations. x1 and x3 are varied to maintain constant airspeed with varying angleof attack.

B.4.3 Direction Cosine Matrix (DCM)

Download DCM.m

The direction-cosine (or rotation) matrix given by eq. 2.1-11 is implemented in the function DCM. Thematrix transforms vectors from the earth-relative frame of reference to the body-axis frame.

B.4.4 Linear System Matrices (LinModel)

Download LinModel.m

The function LinModel calls function EoM to generate f(x,u) and appends seven dummy elements toaccount for the controls. Thus, xdotj is a function of [xT uT], and numjac calculates the Jacobian matrixevaluated at the nominal values of state and control. The stability matrix, F, is contained in the upper-left(12 x 12) partition, and the control-effect matrix, G, is contained in the upper-right (12 x 7) partition of theJacobian.

B.4.5 Wind Field (WindField)

Download WindField.m

WindField produces a three-component wind vector as a function of altitude, with linear interpolationbetween tabulated points. The first point is tabulated at negative altitude to assure that no computationalproblems occur at zero altitude. The wind vector is rotated to body axes for application in FLIGHT andEoM.

B.4.6 Atmospheric State (Atmos)

Download Atmos.m

1976 U.S. Standard Atmosphere air density, air pressure, air temperature, and sound speed are generatedas functions of altitude by Atmos. The first point is tabulated at negative altitude to assure that no

Page 4: Mathematical Model and Six-Degree-Of-Freedom Simulation of Two Business Jet Aircraft

20/10/15, 7:46 AMMathematical Model and Six-Degree-of-Freedom Simulation of Two Business Jet Aircraft

Page 4 of 4http://www.princeton.edu/~stengel/FDcodeB.html

computational problems occur at zero altitude.

Reference

B-1 Soderman, P. T., and Aiken, T. N., "Full-Scale Wind-Tunnel Tests of a Small Unpowered Jet Aircraftwith a T-Tail," NASA TN D-6573, Washington, DC, Nov. 1971.

Flight Dynamics.

http://www.princeton.edu/~stengel/FDcodeB.htmlLast updated on June 12, 2015. Copyright 2015 (c) by Robert F. Stengel. All rights reserved.