Cantera  2.0
Variables
Physical Constants
Global Data
Collaboration diagram for Physical Constants:

Variables

const doublereal Pi = 3.14159265358979323846
 Pi.
 
const doublereal SqrtPi = std::sqrt(Pi)
 sqrt(Pi)
 

Variations of the Gas Constant

Cantera uses the MKS system of units. The unit for moles is defined to be the kmol.

const doublereal Avogadro = 6.02214129e26
 Avogadro's Number [number/kmol].
 
const doublereal GasConstant = 8314.4621
 Universal Gas Constant. [J/kmol/K].
 
const doublereal logGasConstant = std::log(GasConstant)
 
const doublereal OneAtm = 1.01325e5
 One atmosphere [Pa].
 
const doublereal GasConst_cal_mol_K = GasConstant / 4184.0
 Universal gas constant in cal/mol/K.
 
const doublereal Boltzmann = GasConstant / Avogadro
 Boltzmann's constant [J/K].
 
const doublereal Planck = 6.62607009e-34
 Planck's constant. [J-s].
 
const doublereal Planck_bar = Planck / (2 * Pi)
 
const doublereal logBoltz_Planck = std::log(Boltzmann / Planck)
 log(k/h)
 
const doublereal StefanBoltz = 5.670373e-8
 Stefan-Boltzmann constant.
 

Electron Properties

const doublereal ElectronCharge = 1.602176565e-19
 
const doublereal ElectronMass = 9.10938291e-31
 
const doublereal Faraday = ElectronCharge * Avogadro
 

Electromagnetism

Cantera uses the MKS unit system.

const doublereal lightSpeed = 299792458.0
 Speed of Light (m/s).
 
const doublereal permeability_0 = 4.0e-7*Pi
 Permeability of free space \( \mu_0 \) in N/A^2.
 
const doublereal epsilon_0 = 1.0 / (lightSpeed*lightSpeed*permeability_0)
 Permittivity of free space \( \epsilon_0 \) in F/m.
 

Detailed Description

All physical constants are stored here.

Cantera uses the MKS system of units. The unit for moles is defined to be the kmol. All values of physical constants are consistent with the 2010 CODATA recommendations.

Variable Documentation

const doublereal Pi = 3.14159265358979323846
const doublereal SqrtPi = std::sqrt(Pi)

sqrt(Pi)

Definition at line 64 of file ct_defs.h.

Referenced by Voigt::F(), Cantera::Frot(), GaussianProfile::profile(), and Voigt::profile().

const doublereal Avogadro = 6.02214129e26

Avogadro's Number [number/kmol].

Definition at line 74 of file ct_defs.h.

Referenced by WaterProps::ADebye(), TransportFactory::fitProperties(), TransportFactory::setupMM(), Unit::Unit(), and VCS_SOLVE::vcs_nondim_Farad().

const doublereal GasConstant = 8314.4621

Universal Gas Constant. [J/kmol/K].

Definition at line 77 of file ct_defs.h.

Referenced by ThermoPhase::_RT(), MixtureFugacityTP::_updateReferenceStateThermo(), VPSSMgr_Water_ConstVol::_updateRefStateThermo(), VPSSMgr_Water_HKFT::_updateRefStateThermo(), VPSSMgr_ConstVol::_updateStandardStateThermo(), VPSSMgr_Water_ConstVol::_updateStandardStateThermo(), VPSSMgr_IdealGas::_updateStandardStateThermo(), VPSSMgr_Water_HKFT::_updateStandardStateThermo(), SurfPhase::_updateThermo(), IdealGasPhase::_updateThermo(), IdealSolidSolnPhase::_updateThermo(), vcs_VolPhase::_updateVolPM(), WaterProps::ADebye(), HMWSoln::ADebye_J(), HMWSoln::ADebye_L(), HMWSoln::ADebye_V(), InterfaceKinetics::applyButlerVolmerCorrection(), InterfaceKinetics::applyExchangeCurrentDensityFormulation(), IdealSolnGasVPSS::calcDensity(), MixtureFugacityTP::calculatePsat(), MultiPhaseEquil::computeReactionSteps(), ConstCpPoly::ConstCpPoly(), PDSS_Water::constructSet(), IdealSolnGasVPSS::cp_mole(), ConstDensityThermo::cp_mole(), StoichSubstance::cp_mole(), RedlichKwongMFTP::cp_mole(), SingleSpeciesTP::cp_mole(), PDSS_ConstVol::cp_mole(), PDSS_IdealGas::cp_mole(), PDSS_IonsFromNeutral::cp_mole(), IdealSolidSolnPhase::cp_mole(), PDSS_SSVol::cp_mole(), LatticePhase::cp_mole(), IdealGasPhase::cp_mole(), PDSS::cp_R(), PDSS_Water::cp_R_ref(), PDSS::cpDelp_mole(), IdealSolnGasVPSS::cv_mole(), RedlichKwongMFTP::cv_mole(), PDSS_IdealGas::cv_mole(), IdealGasPhase::cv_mole(), RedlichKisterVPSSTP::cv_mole(), MargulesVPSSTP::cv_mole(), MixedSolventElectrolyte::cv_mole(), PhaseCombo_Interaction::cv_mole(), PDSS_IdealGas::density(), PDSS_IonsFromNeutral::density(), WaterProps::density_T(), RedlichKwongMFTP::densityCalc(), MixtureFugacityTP::densityCalc(), RedlichKwongMFTP::dpdVCalc(), IdealSolnGasVPSS::enthalpy_mole(), ConstDensityThermo::enthalpy_mole(), PDSS_ConstVol::enthalpy_mole(), PDSS_IdealGas::enthalpy_mole(), PDSS_IonsFromNeutral::enthalpy_mole(), IdealSolidSolnPhase::enthalpy_mole(), PDSS_SSVol::enthalpy_mole(), LatticePhase::enthalpy_mole(), IdealGasPhase::enthalpy_mole(), PDSS_HKFT::enthalpy_RT(), PDSS::enthalpy_RT(), PDSS_Water::enthalpy_RT_ref(), PDSS::enthalpyDelp_mole(), IdealSolnGasVPSS::entropy_mole(), ConstDensityThermo::entropy_mole(), StoichSubstance::entropy_mole(), PDSS_ConstVol::entropy_mole(), PDSS_IdealGas::entropy_mole(), RedlichKwongMFTP::entropy_mole(), PDSS_IonsFromNeutral::entropy_mole(), IdealSolidSolnPhase::entropy_mole(), PDSS_SSVol::entropy_mole(), LatticePhase::entropy_mole(), IdealGasPhase::entropy_mole(), PDSS::entropy_R(), PDSS_Water::entropy_R_ref(), PDSS::entropyDelp_mole(), ChemEquil::equilibrate(), ChemEquil::estimateElementPotentials(), AxiStagnFlow::eval(), FreeFlame::eval(), TransportFactory::fitProperties(), FixedChemPotSSTP::FixedChemPotSSTP(), RedlichKwongMFTP::getActivityCoefficients(), Cantera::getArrhenius(), SemiconductorPhase::getChemPotentials(), ConstDensityThermo::getChemPotentials(), SurfPhase::getChemPotentials(), MolarityIonicVPSSTP::getChemPotentials(), IdealSolnGasVPSS::getChemPotentials(), IonsFromNeutralVPSSTP::getChemPotentials(), RedlichKwongMFTP::getChemPotentials(), RedlichKisterVPSSTP::getChemPotentials(), MargulesVPSSTP::getChemPotentials(), MixedSolventElectrolyte::getChemPotentials(), PhaseCombo_Interaction::getChemPotentials(), IdealSolidSolnPhase::getChemPotentials(), IdealMolalSoln::getChemPotentials(), IdealGasPhase::getChemPotentials(), LatticePhase::getChemPotentials(), DebyeHuckel::getChemPotentials(), HMWSoln::getChemPotentials(), StoichSubstance::getChemPotentials_RT(), SingleSpeciesTP::getChemPotentials_RT(), IdealSolidSolnPhase::getChemPotentials_RT(), WaterSSTP::getCp_R(), StoichSubstance::getCp_R(), SurfPhase::getCp_R(), VPSSMgr_Water_ConstVol::getCp_R_ref(), WaterSSTP::getCp_R_ref(), AqueousKinetics::getDeltaSSEnthalpy(), GasKinetics::getDeltaSSEnthalpy(), InterfaceKinetics::getDeltaSSEnthalpy(), AqueousKinetics::getDeltaSSEntropy(), GasKinetics::getDeltaSSEntropy(), InterfaceKinetics::getDeltaSSEntropy(), PhaseCombo_Interaction::getdlnActCoeffds(), MargulesVPSSTP::getdlnActCoeffds(), MixedSolventElectrolyte::getdlnActCoeffds(), ThermoPhase::getElementPotentials(), WaterSSTP::getEnthalpy_RT(), StoichSubstance::getEnthalpy_RT(), StoichSubstanceSSTP::getEnthalpy_RT(), MineralEQ3::getEnthalpy_RT(), SurfPhase::getEnthalpy_RT(), IdealSolidSolnPhase::getEnthalpy_RT(), LatticePhase::getEnthalpy_RT(), VPSSMgr_Water_ConstVol::getEnthalpy_RT_ref(), WaterSSTP::getEnthalpy_RT_ref(), WaterSSTP::getEntropy_R(), StoichSubstance::getEntropy_R(), PureFluidPhase::getEntropy_R(), SurfPhase::getEntropy_R(), VPSSMgr_Water_ConstVol::getEntropy_R_ref(), WaterSSTP::getEntropy_R_ref(), AqueousKinetics::getEquilibriumConstants(), GasKinetics::getEquilibriumConstants(), InterfaceKinetics::getEquilibriumConstants(), AqueousTransport::getFluidMobilities(), SimpleTransport::getFluidMobilities(), LiquidTransport::getFluidMobilities(), VPSSMgr_Water_HKFT::getGibbs_ref(), VPSSMgr_General::getGibbs_ref(), VPSSMgr_Water_ConstVol::getGibbs_ref(), StoichSubstance::getGibbs_ref(), PureFluidPhase::getGibbs_ref(), SingleSpeciesTP::getGibbs_ref(), VPSSMgr::getGibbs_ref(), LatticeSolidPhase::getGibbs_ref(), IdealSolidSolnPhase::getGibbs_ref(), LatticePhase::getGibbs_ref(), WaterSSTP::getGibbs_RT(), StoichSubstance::getGibbs_RT(), SurfPhase::getGibbs_RT(), VPSSMgr_Water_ConstVol::getGibbs_RT_ref(), WaterSSTP::getGibbs_RT_ref(), WaterSSTP::getIntEnergy_RT(), VPSSMgr::getIntEnergy_RT(), StoichSubstanceSSTP::getIntEnergy_RT(), MineralEQ3::getIntEnergy_RT(), IdealSolidSolnPhase::getIntEnergy_RT(), StoichSubstanceSSTP::getIntEnergy_RT_ref(), MineralEQ3::getIntEnergy_RT_ref(), MetalSHEelectrons::getIntEnergy_RT_ref(), IdealSolidSolnPhase::getIntEnergy_RT_ref(), LTI_StefanMaxwell_PPN::getMatrixTransProp(), DustyGasTransport::getMolarFluxes(), SurfPhase::getPartialMolarCp(), IdealSolnGasVPSS::getPartialMolarCp(), MolarityIonicVPSSTP::getPartialMolarCp(), SingleSpeciesTP::getPartialMolarCp(), RedlichKwongMFTP::getPartialMolarCp(), RedlichKisterVPSSTP::getPartialMolarCp(), MargulesVPSSTP::getPartialMolarCp(), MixedSolventElectrolyte::getPartialMolarCp(), PhaseCombo_Interaction::getPartialMolarCp(), IdealGasPhase::getPartialMolarCp(), IdealSolidSolnPhase::getPartialMolarCp(), IdealMolalSoln::getPartialMolarCp(), LatticePhase::getPartialMolarCp(), DebyeHuckel::getPartialMolarCp(), HMWSoln::getPartialMolarCp(), SurfPhase::getPartialMolarEnthalpies(), IdealSolnGasVPSS::getPartialMolarEnthalpies(), MolarityIonicVPSSTP::getPartialMolarEnthalpies(), SingleSpeciesTP::getPartialMolarEnthalpies(), IonsFromNeutralVPSSTP::getPartialMolarEnthalpies(), RedlichKwongMFTP::getPartialMolarEnthalpies(), RedlichKisterVPSSTP::getPartialMolarEnthalpies(), MargulesVPSSTP::getPartialMolarEnthalpies(), MixedSolventElectrolyte::getPartialMolarEnthalpies(), PhaseCombo_Interaction::getPartialMolarEnthalpies(), IdealGasPhase::getPartialMolarEnthalpies(), IdealSolidSolnPhase::getPartialMolarEnthalpies(), LatticePhase::getPartialMolarEnthalpies(), DebyeHuckel::getPartialMolarEnthalpies(), HMWSoln::getPartialMolarEnthalpies(), SurfPhase::getPartialMolarEntropies(), IdealSolnGasVPSS::getPartialMolarEntropies(), MolarityIonicVPSSTP::getPartialMolarEntropies(), SingleSpeciesTP::getPartialMolarEntropies(), IonsFromNeutralVPSSTP::getPartialMolarEntropies(), RedlichKwongMFTP::getPartialMolarEntropies(), RedlichKisterVPSSTP::getPartialMolarEntropies(), MargulesVPSSTP::getPartialMolarEntropies(), MixedSolventElectrolyte::getPartialMolarEntropies(), PhaseCombo_Interaction::getPartialMolarEntropies(), IdealGasPhase::getPartialMolarEntropies(), IdealMolalSoln::getPartialMolarEntropies(), IdealSolidSolnPhase::getPartialMolarEntropies(), LatticePhase::getPartialMolarEntropies(), DebyeHuckel::getPartialMolarEntropies(), HMWSoln::getPartialMolarEntropies(), IdealSolnGasVPSS::getPartialMolarIntEnergies(), SingleSpeciesTP::getPartialMolarIntEnergies(), RedlichKwongMFTP::getPartialMolarIntEnergies(), IdealGasPhase::getPartialMolarIntEnergies(), RedlichKwongMFTP::getPartialMolarVolumes(), DebyeHuckel::getPartialMolarVolumes(), HMWSoln::getPartialMolarVolumes(), SingleSpeciesTP::getPureGibbs(), LatticePhase::getPureGibbs(), Cantera::getRateCoefficient(), VPSSMgr::getStandardChemPotentials(), StoichSubstanceSSTP::getStandardChemPotentials(), MineralEQ3::getStandardChemPotentials(), MetalSHEelectrons::getStandardChemPotentials(), IdealGasPhase::getStandardChemPotentials(), Cantera::getStick(), MultiTransport::getThermalDiffCoeffs(), PDSS_ConstVol::gibbs_mole(), PDSS_IdealGas::gibbs_mole(), PDSS_IonsFromNeutral::gibbs_mole(), IdealSolidSolnPhase::gibbs_mole(), PDSS_SSVol::gibbs_mole(), PDSS::gibbs_RT(), PDSS_Water::gibbs_RT_ref(), PDSS::gibbsDelp_mole(), RedlichKwongMFTP::hresid(), LiquidTranInteraction::init(), GasKinetics::init(), PureFluidPhase::initThermo(), WaterSSTP::initThermoXML(), SimpleThermo::install(), ConstDensityThermo::intEnergy_mole(), StoichSubstance::intEnergy_mole(), PDSS_ConstVol::intEnergy_mole(), PDSS_IdealGas::intEnergy_mole(), PDSS_IonsFromNeutral::intEnergy_mole(), IdealSolidSolnPhase::intEnergy_mole(), PDSS_SSVol::intEnergy_mole(), LatticePhase::intEnergy_mole(), IdealGasPhase::intEnergy_mole(), IdealGasPhase::logStandardConc(), ConstCpPoly::modifyParameters(), SimpleThermo::modifyParams(), PDSS_IdealGas::molarVolume(), PDSS_IdealGas::molarVolume_ref(), MixtureFugacityTP::phaseState(), RedlichKwongMFTP::pressure(), IdealGasPhase::pressure(), MixTransport::pressure_ig(), RedlichKwongMFTP::pressureCalc(), RedlichKwongMFTP::pressureDerivatives(), Mu0Poly::processCoeffs(), HMWSoln::relative_enthalpy(), PureFluidPhase::report(), ThermoPhase::report(), ConstCpPoly::reportParameters(), Mu0Poly::reportParameters(), SimpleThermo::reportParams(), PhaseCombo_Interaction::s_update_dlnActCoeff_dlnN(), MargulesVPSSTP::s_update_dlnActCoeff_dlnN(), MixedSolventElectrolyte::s_update_dlnActCoeff_dlnN(), PhaseCombo_Interaction::s_update_dlnActCoeff_dlnN_diag(), MargulesVPSSTP::s_update_dlnActCoeff_dlnN_diag(), MixedSolventElectrolyte::s_update_dlnActCoeff_dlnN_diag(), PhaseCombo_Interaction::s_update_dlnActCoeff_dlnX_diag(), MargulesVPSSTP::s_update_dlnActCoeff_dlnX_diag(), MixedSolventElectrolyte::s_update_dlnActCoeff_dlnX_diag(), PhaseCombo_Interaction::s_update_dlnActCoeff_dT(), MargulesVPSSTP::s_update_dlnActCoeff_dT(), MixedSolventElectrolyte::s_update_dlnActCoeff_dT(), PhaseCombo_Interaction::s_update_lnActCoeff(), RedlichKisterVPSSTP::s_update_lnActCoeff(), MargulesVPSSTP::s_update_lnActCoeff(), MixedSolventElectrolyte::s_update_lnActCoeff(), ThermoPhase::setElementPotentials(), PDSS_ConstVol::setPressure(), PDSS_IdealGas::setPressure(), PDSS_SSVol::setPressure(), IdealGasPhase::setPressure(), PDSS_IdealGas::setState_TR(), PDSS_ConstVol::setTemperature(), PDSS_IdealGas::setTemperature(), PDSS_SSVol::setTemperature(), RedlichKwongMFTP::sresid(), IdealSolnGasVPSS::standardConcentration(), IdealGasPhase::standardConcentration(), AqueousTransport::stefan_maxwell_solve(), LiquidTransport::stefan_maxwell_solve(), WaterProps::thermalConductivityWater(), Unit::Unit(), ShomateThermo::update(), ShomateThermo::update_one(), SimpleTransport::updateDiff_T(), AqueousKinetics::updateKc(), GasKinetics::updateKc(), InterfaceKinetics::updateKc(), DustyGasTransport::updateKnudsenDiffCoeffs(), ShomatePoly::updatePropertiesTemp(), MultiTransport::updateThermal_T(), VCS_SOLVE::vcs_nondim_Farad(), VCS_SOLVE::vcs_nondimMult_TP(), and VCS_SOLVE::vcs_printSpeciesChemPot().

const doublereal OneAtm = 1.01325e5
const doublereal GasConst_cal_mol_K = GasConstant / 4184.0

Universal gas constant in cal/mol/K.

Definition at line 85 of file ct_defs.h.

Referenced by VCS_SOLVE::vcs_nondimMult_TP().

const doublereal Boltzmann = GasConstant / Avogadro
const doublereal Planck = 6.62607009e-34

Planck's constant. [J-s].

Definition at line 91 of file ct_defs.h.

Referenced by Cantera::wnum_to_J().

const doublereal logBoltz_Planck = std::log(Boltzmann / Planck)

log(k/h)

Definition at line 95 of file ct_defs.h.

const doublereal StefanBoltz = 5.670373e-8

Stefan-Boltzmann constant.

Definition at line 97 of file ct_defs.h.

const doublereal lightSpeed = 299792458.0

Speed of Light (m/s).

Definition at line 112 of file ct_defs.h.

Referenced by Cantera::hz_to_wnum(), and Cantera::wnum_to_J().

const doublereal permeability_0 = 4.0e-7*Pi

Permeability of free space \( \mu_0 \) in N/A^2.

Definition at line 115 of file ct_defs.h.

const doublereal epsilon_0 = 1.0 / (lightSpeed*lightSpeed*permeability_0)

Permittivity of free space \( \epsilon_0 \) in F/m.

Definition at line 118 of file ct_defs.h.

Referenced by WaterProps::ADebye().