1 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
5 Date started: 03/11/2003
7 ------------- Copyright (C) 2003 David Culp (davidculp2@attbi.com)------------
9 This program is free software; you can redistribute it and/or modify it under
10 the terms of the GNU General Public License as published by the Free Software
11 Foundation; either version 2 of the License, or (at your option) any later
14 This program is distributed in the hope that it will be useful, but WITHOUT
15 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
16 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
19 You should have received a copy of the GNU General Public License along with
20 this program; if not, write to the Free Software Foundation, Inc., 59 Temple
21 Place - Suite 330, Boston, MA 02111-1307, USA.
23 Further information about the GNU General Public License can also be found on
24 the world wide web at http://www.gnu.org.
27 --------------------------------------------------------------------------------
28 03/11/2003 DPC Created
30 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
31 COMMENTS, REFERENCES, and NOTES
32 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
34 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
36 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
38 #ifndef FGSIMTURBINE_H
39 #define FGSIMTURBINE_H
41 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
43 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
47 #include "FGConfigFile.h"
48 #include "FGCoefficient.h"
50 #define ID_SIMTURBINE "$Id$"
52 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
54 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
58 class FGSimTurbine : public FGEngine
61 FGSimTurbine(FGFDMExec* exec, FGConfigFile* Eng_cfg);
64 double Calculate(double);
65 double CalcFuelNeed(void);
69 typedef vector<FGCoefficient*> CoeffArray;
70 CoeffArray ThrustTables;
72 double MaxMilThrust; // Maximum Rated Thrust, static @ S.L. (lbf)
73 double BypassRatio; // Bypass Ratio
74 double TSFC; // Thrust Specific Fuel Consumption (lbm/hr/lbf)
75 double ATSFC; // Augmented TSFC (lbm/hr/lbf)
76 double IdleN1; // Idle N1
77 double IdleN2; // Idle N2
78 double MaxN1; // N1 at 100% throttle
79 double MaxN2; // N2 at 100% throttle
80 double IdleFF; // Idle Fuel Flow (lbm/hr)
81 double delay; // Inverse spool-up time from idle to 100% (seconds)
82 double dt; // Simulator time slice
83 double N1_factor; // factor to tie N1 and throttle
84 double N2_factor; // factor to tie N2 and throttle
85 double ThrottleCmd; // FCS-supplied throttle position
86 double throttle; // virtual throttle position
87 int Augmented; // = 1 if augmentation installed
88 int Injected; // = 1 if water injection installed
89 int AugMethod; // = 0 if using property /engine[n]/augmentation
90 // = 1 if using last 1% of throttle movement
92 void SetDefaults(void);
93 bool Load(FGConfigFile *ENG_cfg);
98 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%