Cantera 2.6.0
|
This file contains definitions of constants, types and terms that are used in internal routines and are unlikely to need modifying. More...
#include "config.h"
#include <cmath>
#include <cstdlib>
#include <vector>
#include <map>
#include <string>
#include <algorithm>
#include <memory>
Go to the source code of this file.
Namespaces | |
namespace | Cantera |
Namespace for the Cantera kernel. | |
Typedefs | |
typedef std::map< std::string, double > | compositionMap |
Map connecting a string name with a double. More... | |
typedef std::map< std::string, double > | Composition |
Map from string names to doubles. More... | |
typedef std::vector< double > | vector_fp |
Turn on the use of stl vectors for the basic array type within cantera Vector of doubles. More... | |
typedef std::vector< int > | vector_int |
Vector of ints. More... | |
typedef std::vector< std::vector< size_t > > | grouplist_t |
A grouplist is a vector of groups of species. More... | |
Variables | |
const double | Pi = 3.14159265358979323846 |
Pi. More... | |
const double | Sqrt2 = 1.41421356237309504880 |
Sqrt(2) More... | |
const double | SmallNumber = 1.e-300 |
smallest number to compare to zero. More... | |
const double | BigNumber = 1.e300 |
largest number to compare to inf. More... | |
const double | MaxExp = 690.775527898 |
largest x such that exp(x) is valid More... | |
const double | Undef = -999.1234 |
Fairly random number to be used to initialize variables against to see if they are subsequently defined. More... | |
const double | Tiny = 1.e-20 |
Small number to compare differences of mole fractions against. More... | |
const size_t | npos = static_cast<size_t>(-1) |
index returned by functions to indicate "no position" More... | |
Defined Constants | |
These constants are defined by CODATA to have a particular value. https://physics.nist.gov/cuu/Constants/index.html | |
const double | Avogadro = 6.02214076e26 |
Avogadro's Number \( N_{\mathrm{A}} \) [number/kmol]. More... | |
const double | Boltzmann = 1.380649e-23 |
Boltzmann constant \( k \) [J/K]. More... | |
const double | Planck = 6.62607015e-34 |
Planck constant \( h \) [J-s]. More... | |
const double | ElectronCharge = 1.602176634e-19 |
Elementary charge \( e \) [C]. More... | |
const double | lightSpeed = 299792458.0 |
Speed of Light in a vacuum \( c \) [m/s]. More... | |
const double | OneAtm = 1.01325e5 |
One atmosphere [Pa]. More... | |
const double | OneBar = 1.0E5 |
One bar [Pa]. More... | |
Measured Constants | |
These constants are measured and reported by CODATA | |
const double | fineStructureConstant = 7.2973525693e-3 |
Fine structure constant \( \alpha \) []. More... | |
const double | ElectronMass = 9.1093837015e-31 |
Electron Mass \( m_e \) [kg]. More... | |
Derived Constants | |
These constants are found from the defined and measured constants | |
const double | Planck_bar = Planck / (2 * Pi) |
Reduced Planck constant \( \hbar \) [m2-kg/s]. More... | |
const double | GasConstant = Avogadro * Boltzmann |
Universal Gas Constant \( R_u \) [J/kmol/K]. More... | |
const double | logGasConstant = std::log(GasConstant) |
const double | GasConst_cal_mol_K = GasConstant / 4184.0 |
Universal gas constant in cal/mol/K. More... | |
const double | logBoltz_Planck = std::log(Boltzmann / Planck) |
log(k_b/h) More... | |
const double | StefanBoltz = 2.0 * std::pow(Pi, 5) * std::pow(Boltzmann, 4) / (15.0 * std::pow(Planck, 3) * lightSpeed * lightSpeed) |
Stefan-Boltzmann constant \( \sigma \) [W/m2/K4]. More... | |
const double | Faraday = ElectronCharge * Avogadro |
Faraday constant \( F \) [C/kmol]. More... | |
const double | permeability_0 = 2 * fineStructureConstant * Planck / (ElectronCharge * ElectronCharge * lightSpeed) |
Permeability of free space \( \mu_0 \) [N/A2]. More... | |
const double | epsilon_0 = 1.0 / (lightSpeed * lightSpeed * permeability_0) |
Permittivity of free space \( \varepsilon_0 \) [F/m]. More... | |
Thermodynamic Equilibrium Constraints | |
Integer numbers representing pairs of thermodynamic variables which are held constant during equilibration. | |
const int | TV = 100 |
const int | HP = 101 |
const int | SP = 102 |
const int | PV = 103 |
const int | TP = 104 |
const int | UV = 105 |
const int | ST = 106 |
const int | SV = 107 |
const int | UP = 108 |
const int | VH = 109 |
const int | TH = 110 |
const int | SH = 111 |
const int | PX = 112 |
const int | TX = 113 |
const int | VT = -100 |
const int | PH = -101 |
const int | PS = -102 |
const int | VP = -103 |
const int | PT = -104 |
const int | VU = -105 |
const int | TS = -106 |
const int | VS = -107 |
const int | PU = -108 |
const int | HV = -109 |
const int | HT = -110 |
const int | HS = -111 |
const int | XP = -112 |
const int | XT = -113 |
This file contains definitions of constants, types and terms that are used in internal routines and are unlikely to need modifying.
All physical constants are stored here (see module Physical Constants).
This file is included in every file within the Cantera namespace.
Definition in file ct_defs.h.