The SURVEY program accepts the linear, time-invariant stability and control-effect matrices, Fmodel and Gmodel, from FLIGHT as inputs and performs a variety of analyses on them. It first provides the option of reducing these matrices into smaller models using the function LonLatDir. The function produces a single model at each call for either longitudinal or lateral-directional motions, in body, hybrid, or stability axes, and with four or six elements in the state vector. The remaining SURVEY functions operate on either the original twelve-dimensional model or on the reduced model produced by LonLatDir.
The program calculates initial-condition response, equilibrium response, control response, controllability and observability matrices, natural frequencies, damping ratios, real roots, eigenvalues and eigenvectors. It forms single-input/single-output transfer functions for all possible combinations in the model selected by the user and makes their Bode, Nyquist, and Nichols plots. A transfer function model of human-pilot neuromuscular lags can be included. SURVEY is tutorial, and the user must control program flow by making changes in the code. No explicit or implicit warranties are made regarding the accuracy or correctness of the computer code.
C.1 Main Program for Analysis and Simulation (SURVEY)
As shown, SURVEY is set up to make calculations based on the 12 x 12 Fmodel and 12 x 7 Gmodel matrices that are stored in FmodelFile.mat and GmodelFile.mat. The nominal trimmed flight condition also is stored in FmodelFile.mat. The analyses to be run are specified by flags that the user chooses. They are:
ORIG = 1;
ROM = 1;
- Show original model & eigenvalues: Yes(1) or No(0)
LON = 1;
- Original model (0) or re-ordered model (1)
DIM = 6;
- Lateral-directional (0) or longitudinal (1) model
SBA = 1;
- Re-ordered model dimension (12, 6, or 4)
NF = 1;
- Body axes (0) or stability/hybrid axes (1)
EVEC = 1;
- Natural frequencies, damping ratios, & time constants: OFF (0) or ON (1)
IC = 1;
- Eigenvalues and eigenvectors: OFF (0) or ON (1)
STEP = 1;
- Initial-condition response: OFF (0) or ON (1)
CONPR = 1;
- Step-input response: OFF (0) or ON (1)
EQUIL = 1;
- Response to time profile of control: OFF (0), ON: 0.5-sec impulse (1), or user-specified (2)
CO = 1;
- Equilibrium response to control perturbation: OFF (0) or ON (1)
TRF = 1;
- Controllability and observability: OFF (0) or ON (1)
PILOT = 1;
- Transfer functions: OFF (0) or ON (1)
BODE = 2;
- Human pilot transfer function: OFF (0), ON (1)
NYQUIST = 1;
- Bode plots: OFF (0), ON (1), with asymptotes (2)
NICHOLS = 1;
- Nyquist charts: OFF (0) or ON (1)
RLOCUS = 1;
- Nichols charts: OFF (0) or ON (1)
Asymptotes of Bode plots are shown using the function asymp.m, which can be downloaded at https://www.mathworks.com/matlabcentral/fileexchange/10183-bode-plot-with-asymptotes.
- Root locus plots: OFF (0) or ON (1)
C.2 Supporting Functions
C.2.1 Reduced-Order Models (LonLatDir)
LonLatDir accepts stability and control-effect matrices for combined longitudinal and lateral-directional dynamics as input and either passes the matrices unchanged, re-orders elements of the matrices, or generates a selected reduced-order model from them. It presents matrices for body, stability, or hybrid axes, for longitudinal or lateral-directional partitions, and for fourth- or sixth-order computations. As shown, there are twelve original state elements, four longitudinal controls, and three lateral-directional controls.
C.2.2 Natural Frequency (NatFreq)
NatFreq presents complex-valued eigenvalues, natural frequencies, damping ratios, and time constants that identify oscillations, convergence, and divergence in the system's modes of motion.
C.2.3 Stability and Modes of Motion (StabMode)
StabMode presents a diagonal matrix of eigenvalues and a modal matrix of eigenvectors. Amplitudes of the eigenvector components for both original and velocity-weighted sets identify the relative participation of each state element in each mode of motion.