1 /**********************************************************************
3 FILENAME: uiuc_coef_pitch.cpp
5 ----------------------------------------------------------------------
7 DESCRIPTION: computes aggregated aerodynamic pitch coefficient
9 ----------------------------------------------------------------------
13 ----------------------------------------------------------------------
15 REFERENCES: Roskam, Jan. Airplane Flight Dynamics and Automatic
16 Flight Controls, Part I. Lawrence, KS: DARcorporation,
19 ----------------------------------------------------------------------
21 HISTORY: 04/15/2000 initial release
23 ----------------------------------------------------------------------
25 AUTHOR(S): Bipin Sehgal <bsehgal@uiuc.edu>
26 Jeff Scott <jscott@mail.com>
28 ----------------------------------------------------------------------
32 ----------------------------------------------------------------------
36 -pitch coefficient components
40 ----------------------------------------------------------------------
44 ----------------------------------------------------------------------
46 CALLED BY: uiuc_coefficients.cpp
48 ----------------------------------------------------------------------
50 CALLS TO: uiuc_1Dinterpolation
54 ----------------------------------------------------------------------
56 COPYRIGHT: (C) 2000 by Michael Selig
58 This program is free software; you can redistribute it and/or
59 modify it under the terms of the GNU General Public License
60 as published by the Free Software Foundation.
62 This program is distributed in the hope that it will be useful,
63 but WITHOUT ANY WARRANTY; without even the implied warranty of
64 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
65 GNU General Public License for more details.
67 You should have received a copy of the GNU General Public License
68 along with this program; if not, write to the Free Software
69 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
70 USA or view http://www.gnu.org/copyleft/gpl.html.
72 **********************************************************************/
74 #include "uiuc_coef_pitch.h"
77 void uiuc_coef_pitch()
83 command_list = aeroPitchParts -> getCommands();
85 for (LIST command_line = command_list.begin(); command_line!=command_list.end(); ++command_line)
87 linetoken1 = aeroPitchParts -> getToken(*command_line, 1);
88 linetoken2 = aeroPitchParts -> getToken(*command_line, 2);
90 switch(Cm_map[linetoken2])
96 Cmo = uiuc_ice_filter(Cmo_clean,kCmo);
105 Cm_a = uiuc_ice_filter(Cm_a_clean,kCm_a);
114 Cm_a2 = uiuc_ice_filter(Cm_a2_clean,kCm_a2);
116 Cm += Cm_a2 * Alpha * Alpha;
123 Cm_adot = uiuc_ice_filter(Cm_adot_clean,kCm_adot);
125 /* Cm_adot must be mulitplied by cbar/2U
126 (see Roskam Control book, Part 1, pg. 147) */
127 Cm += Cm_adot * Alpha_dot * cbar_2U;
134 Cm_q = uiuc_ice_filter(Cm_q_clean,kCm_q);
136 /* Cm_q must be mulitplied by cbar/2U
137 (see Roskam Control book, Part 1, pg. 147) */
138 Cm += Cm_q * Q_body * cbar_2U;
150 Cm_de = uiuc_ice_filter(Cm_de_clean,kCm_de);
152 Cm += Cm_de * elevator;
159 Cm_b2 = uiuc_ice_filter(Cm_b2_clean,kCm_b2);
161 Cm += Cm_b2 * Beta * Beta;
168 Cm_r = uiuc_ice_filter(Cm_r_clean,kCm_r);
170 Cm += Cm_r * R_body * b_2U;
177 Cm_df = uiuc_ice_filter(Cm_df_clean,kCm_df);
184 CmfaI = uiuc_1Dinterpolation(Cmfa_aArray,
193 CmfadeI = uiuc_2Dinterpolation(Cmfade_aArray,
205 CmfdfI = uiuc_1Dinterpolation(Cmfdf_dfArray,
214 CmfadfI = uiuc_2Dinterpolation(Cmfadf_aArray,
230 // end uiuc_coef_pitch.cpp