TransFlow  0.1.0
A transient pipeline flow simulation library
constants.hpp
1 #pragma once
2 
3 #include <cmath>
4 
8 namespace constants
9 {
11  static const double pi = 4.0*std::atan(1.0);
12 
14  static const double kelvin = 273.15;
15 
17  static const double standardAtmosphere = 101325;
18 
20  static const double kelvinToRankine = 9.0/5.0;
21 
24  static const double standardTemperature = kelvin + 15;
25 
28  static const double standardPressure = 101325;
29 
31  static const double gasConstant = 8.3144598; // [J/mol K] == [m3 Pa /mol K]
32 
34  static const double gasConstantBTU = 1.98588;
35 
37  static const double pascalToPoundForcePerSquareFoot = 0.3048*0.3048/4.4482216152605; // 4.448.. is lbf to Newton, 0.3048 is foot to meter
38 
40  static const double footPoundForce = 1.355817948; // joule
42  static const double slug = 14.5939; // kg
44  static const double rankine = 5.0/9.0; // Kelvin
46  static const double footPoundForcePerSlugRankine = footPoundForce/(slug*rankine); // J/(kg K)
47 
50  static const double molarMassOfAir = 28.967; // [g/mol] reference for calculating specific gravity
51 }
constants
Definition: constants.hpp:8