1 /*******************************************************************************
5 Implementation of 1959 Standard Atmosphere added by Tony Peden
8 ------------- Copyright (C) 1999 Jon S. Berndt (jsb@hal-pc.org) -------------
10 This program is free software; you can redistribute it and/or modify it under
11 the terms of the GNU General Public License as published by the Free Software
12 Foundation; either version 2 of the License, or (at your option) any later
15 This program is distributed in the hope that it will be useful, but WITHOUT
16 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
17 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
20 You should have received a copy of the GNU General Public License along with
21 this program; if not, write to the Free Software Foundation, Inc., 59 Temple
22 Place - Suite 330, Boston, MA 02111-1307, USA.
24 Further information about the GNU General Public License can also be found on
25 the world wide web at http://www.gnu.org.
28 --------------------------------------------------------------------------------
30 07/23/99 TP Added implementation of 1959 Standard Atmosphere
31 Moved calculation of Mach number to FGTranslation
34 ********************************************************************************
36 *******************************************************************************/
38 #ifndef FGAtmosphere_H
39 #define FGAtmosphere_H
41 /*******************************************************************************
43 *******************************************************************************/
47 /*******************************************************************************
48 COMMENTS, REFERENCES, and NOTES
49 ********************************************************************************
51 [1] Anderson, John D. "Introduction to Flight, Third Edition", McGraw-Hill,
52 1989, ISBN 0-07-001641-0
54 *******************************************************************************
56 *******************************************************************************/
61 class FGAtmosphere : public FGModel
65 FGAtmosphere(FGFDMExec*);
69 inline float Getrho(void) {return rho;}
70 float CalcRho(float altitude);
72 inline float GetTemperature(void){return temperature;}
73 inline float GetDensity(void) {return density;} // use only after Run() has been called
74 inline float GetPressure(void) {return pressure;}
75 inline float GetSoundSpeed(void) {return soundspeed;}
77 float GetTemperature(float altitude); //Rankine, altitude in feet
78 float GetDensity(float altitude); //slugs/ft^3
79 float GetPressure(float altitude); //lbs/ft^2
80 float GetSoundSpeed(float altitude); //ft/s
97 /******************************************************************************/