Cantera 2.6.0

VPStandardStateTP.cpp
Go to the documentation of this file.
1/**
2 * @file VPStandardStateTP.cpp
3 * Definition file for a derived class of ThermoPhase that handles
4 * variable pressure standard state methods for calculating
5 * thermodynamic properties (see \ref thermoprops and
6 * class \link Cantera::VPStandardStateTP VPStandardStateTP\endlink).
7 */
8
9// This file is part of Cantera. See License.txt in the top-level directory or
10// at https://cantera.org/license.txt for license and copyright information.
11
12#include "cantera/thermo/VPStandardStateTP.h"
13#include "cantera/thermo/PDSS.h"
14#include "cantera/thermo/Species.h"
15#include "cantera/base/utilities.h"
16
17 using namespace std;
18
19 namespace Cantera
20{
21
22 VPStandardStateTP::VPStandardStateTP() :
23 m_Pcurrent(OneAtm),
24 m_minTemp(0.0),
25 m_maxTemp(BigNumber),
26 m_Tlast_ss(-1.0),
27 m_Plast_ss(-1.0)
28{
29}
30
31VPStandardStateTP::~VPStandardStateTP()
32{
33}
34
35 int VPStandardStateTP::standardStateConvention() const
36{
37 return cSS_CONVENTION_VPSS;
38}
39
40 void VPStandardStateTP::getChemPotentials_RT(doublereal* muRT) const
41{
42 getChemPotentials(muRT);
43 for (size_t k = 0; k < m_kk; k++) {
44 muRT[k] *= 1.0 / RT();
45 }
46}
47
48// ----- Thermodynamic Values for the Species Standard States States ----
49
50 void VPStandardStateTP::getStandardChemPotentials(doublereal* g) const
51{
52 getGibbs_RT(g);
53 for (size_t k = 0; k < m_kk; k++) {
54 g[k] *= RT();
55 }
56}
57
58 void VPStandardStateTP::getEnthalpy_RT(doublereal* hrt) const
59{
60 updateStandardStateThermo();
61 std::copy(m_hss_RT.begin(), m_hss_RT.end(), hrt);
62}
63
64 void VPStandardStateTP::getEntropy_R(doublereal* sr) const
65{
66 updateStandardStateThermo();
67 std::copy(m_sss_R.begin(), m_sss_R.end(), sr);
68}
69
70 void VPStandardStateTP::getGibbs_RT(doublereal* grt) const
71{
72 updateStandardStateThermo();
73 std::copy(m_gss_RT.begin(), m_gss_RT.end(), grt);
74}
75
76 void VPStandardStateTP::getPureGibbs(doublereal* g) const
77{
78 updateStandardStateThermo();
79 std::copy(m_gss_RT.begin(), m_gss_RT.end(), g);
80 scale(g, g+m_kk, g, RT());
81}
82
83 void VPStandardStateTP::getIntEnergy_RT(doublereal* urt) const
84{
85 updateStandardStateThermo();
86 std::copy(m_hss_RT.begin(), m_hss_RT.end(), urt);
87 for (size_t k = 0; k < m_kk; k++) {
88 urt[k] -= m_Plast_ss / RT() * m_Vss[k];
89 }
90}
91
92 void VPStandardStateTP::getCp_R(doublereal* cpr) const
93{
94 updateStandardStateThermo();
95 std::copy(m_cpss_R.begin(), m_cpss_R.end(), cpr);
96}
97
98 void VPStandardStateTP::getStandardVolumes(doublereal* vol) const
99{
100 updateStandardStateThermo();
101 std::copy(m_Vss.begin(), m_Vss.end(), vol);
102}
103 const vector_fp& VPStandardStateTP::getStandardVolumes() const
104{
105 updateStandardStateThermo();
106 return m_Vss;
107}
108
109// ----- Thermodynamic Values for the Species Reference States ----
110
111 void VPStandardStateTP::getEnthalpy_RT_ref(doublereal* hrt) const
112{
113 updateStandardStateThermo();
114 std::copy(m_h0_RT.begin(), m_h0_RT.end(), hrt);
115}
116
117 void VPStandardStateTP::getGibbs_RT_ref(doublereal* grt) const
118{
119 updateStandardStateThermo();
120 std::copy(m_g0_RT.begin(), m_g0_RT.end(), grt);
121}
122
123 void VPStandardStateTP::getGibbs_ref(doublereal* g) const
124{
125 updateStandardStateThermo();
126 std::copy(m_g0_RT.begin(), m_g0_RT.end(), g);
127 scale(g, g+m_kk, g, RT());
128}
129
130 const vector_fp& VPStandardStateTP::Gibbs_RT_ref() const
131{
132 updateStandardStateThermo();
133 return m_g0_RT;
134}
135
136 void VPStandardStateTP::getEntropy_R_ref(doublereal* sr) const
137{
138 updateStandardStateThermo();
139 std::copy(m_s0_R.begin(), m_s0_R.end(), sr);
140}
141
142 void VPStandardStateTP::getCp_R_ref(doublereal* cpr) const
143{
144 updateStandardStateThermo();
145 std::copy(m_cp0_R.begin(), m_cp0_R.end(), cpr);
146}
147
148 void VPStandardStateTP::getStandardVolumes_ref(doublereal* vol) const
149{
150 updateStandardStateThermo();
151 std::copy(m_Vss.begin(), m_Vss.end(), vol);
152}
153
154 void VPStandardStateTP::initThermo()
155{
156 ThermoPhase::initThermo();
157 for (size_t k = 0; k < m_kk; k++) {
158 PDSS* kPDSS = m_PDSS_storage[k].get();
159 if (kPDSS == 0) {
160 throw CanteraError("VPStandardStateTP::initThermo",
161 "No PDSS object for species {}", k);
162 }
163 kPDSS->initThermo();
164 }
165}
166
167 void VPStandardStateTP::getSpeciesParameters(const std::string& name,
168 AnyMap& speciesNode) const
169{
170 AnyMap eos;
171 providePDSS(speciesIndex(name))->getParameters(eos);
172 speciesNode["equation-of-state"].getMapWhere(
173 "model", eos.getString("model", ""), true) = std::move(eos);
174}
175
176 bool VPStandardStateTP::addSpecies(shared_ptr<Species> spec)
177{
178 // Specifically skip ThermoPhase::addSpecies since the Species object
179 // doesn't have an associated SpeciesThermoInterpType object
180 bool added = Phase::addSpecies(spec);
181 if (!added) {
182 return false;
183 }
184
185 // VPStandardState does not use m_spthermo - install a dummy object
186 m_spthermo.install_STIT(m_kk-1, make_shared<SpeciesThermoInterpType>());
187 m_h0_RT.push_back(0.0);
188 m_cp0_R.push_back(0.0);
189 m_g0_RT.push_back(0.0);
190 m_s0_R.push_back(0.0);
191 m_V0.push_back(0.0);
192 m_hss_RT.push_back(0.0);
193 m_cpss_R.push_back(0.0);
194 m_gss_RT.push_back(0.0);
195 m_sss_R.push_back(0.0);
196 m_Vss.push_back(0.0);
197 return true;
198}
199
200 void VPStandardStateTP::setTemperature(const doublereal temp)
201{
202 setState_TP(temp, m_Pcurrent);
203 updateStandardStateThermo();
204}
205
206 void VPStandardStateTP::setPressure(doublereal p)
207{
208 setState_TP(temperature(), p);
209 updateStandardStateThermo();
210}
211
212 void VPStandardStateTP::calcDensity()
213{
214 throw NotImplementedError("VPStandardStateTP::calcDensity");
215}
216
217 void VPStandardStateTP::setState_TP(doublereal t, doublereal pres)
218{
219 // A pretty tricky algorithm is needed here, due to problems involving
220 // standard states of real fluids. For those cases you need to combine the T
221 // and P specification for the standard state, or else you may venture into
222 // the forbidden zone, especially when nearing the triple point. Therefore,
223 // we need to do the standard state thermo calc with the (t, pres) combo.
224 Phase::setTemperature(t);
225 m_Pcurrent = pres;
226 updateStandardStateThermo();
227
228 // Now, we still need to do the calculations for general ThermoPhase
229 // objects. So, we switch back to a virtual function call, setTemperature,
230 // and setPressure to recalculate stuff for child ThermoPhase objects of the
231 // VPStandardStateTP object. At this point, we haven't touched m_tlast or
232 // m_plast, so some calculations may still need to be done at the
233 // ThermoPhase object level.
234 calcDensity();
235}
236
237 void VPStandardStateTP::installPDSS(size_t k, unique_ptr<PDSS>&& pdss)
238{
239 pdss->setParent(this, k);
240 pdss->setMolecularWeight(molecularWeight(k));
241 Species& spec = *species(k);
242 if (spec.thermo) {
243 pdss->setReferenceThermo(spec.thermo);
244 spec.thermo->validate(spec.name);
245 }
246 m_minTemp = std::max(m_minTemp, pdss->minTemp());
247 m_maxTemp = std::min(m_maxTemp, pdss->maxTemp());
248
249 if (m_PDSS_storage.size() < k+1) {
250 m_PDSS_storage.resize(k+1);
251 }
252 m_PDSS_storage[k].swap(pdss);
253}
254
255 PDSS* VPStandardStateTP::providePDSS(size_t k)
256{
257 return m_PDSS_storage[k].get();
258}
259
260 const PDSS* VPStandardStateTP::providePDSS(size_t k) const
261{
262 return m_PDSS_storage[k].get();
263}
264
265 void VPStandardStateTP::invalidateCache()
266{
267 ThermoPhase::invalidateCache();
268 m_Tlast_ss += 0.0001234;
269}
270
271 void VPStandardStateTP::_updateStandardStateThermo() const
272{
273 double Tnow = temperature();
274 for (size_t k = 0; k < m_kk; k++) {
275 PDSS* kPDSS = m_PDSS_storage[k].get();
276 kPDSS->setState_TP(Tnow, m_Pcurrent);
277 // reference state thermo
278 if (Tnow != m_tlast) {
279 m_h0_RT[k] = kPDSS->enthalpy_RT_ref();
280 m_s0_R[k] = kPDSS->entropy_R_ref();
281 m_g0_RT[k] = m_h0_RT[k] - m_s0_R[k];
282 m_cp0_R[k] = kPDSS->cp_R_ref();
283 m_V0[k] = kPDSS->molarVolume_ref();
284 }
285 // standard state thermo
286 m_hss_RT[k] = kPDSS->enthalpy_RT();
287 m_sss_R[k] = kPDSS->entropy_R();
288 m_gss_RT[k] = m_hss_RT[k] - m_sss_R[k];
289 m_cpss_R[k] = kPDSS->cp_R();
290 m_Vss[k] = kPDSS->molarVolume();
291 }
292 m_Plast_ss = m_Pcurrent;
293 m_Tlast_ss = Tnow;
294 m_tlast = Tnow;
295}
296
297 void VPStandardStateTP::updateStandardStateThermo() const
298{
299 double Tnow = temperature();
300 if (Tnow != m_Tlast_ss || Tnow != m_tlast || m_Pcurrent != m_Plast_ss) {
301 _updateStandardStateThermo();
302 }
303}
304
305 double VPStandardStateTP::minTemp(size_t k) const
306{
307 if (k == npos) {
308 return m_minTemp;
309 } else {
310 return m_PDSS_storage.at(k)->minTemp();
311 }
312}
313
314 double VPStandardStateTP::maxTemp(size_t k) const
315{
316 if (k == npos) {
317 return m_maxTemp;
318 } else {
319 return m_PDSS_storage.at(k)->maxTemp();
320 }
321}
322
323}
PDSS.h
Declarations for the virtual base class PDSS (pressure dependent standard state) which handles calcul...
Species.h
Declaration for class Cantera::Species.
VPStandardStateTP.h
Header file for a derived class of ThermoPhase that handles variable pressure standard state methods ...
Cantera::AnyMap
A map of string keys to values whose type can vary at runtime.
Definition: AnyMap.h:399
Cantera::AnyMap::getString
const std::string & getString(const std::string &key, const std::string &default_) const
If key exists, return it as a string, otherwise return default_.
Definition: AnyMap.cpp:1502
Cantera::CanteraError
Base class for exceptions thrown by Cantera classes.
Definition: ctexceptions.h:61
Cantera::MultiSpeciesThermo::install_STIT
virtual void install_STIT(size_t index, shared_ptr< SpeciesThermoInterpType > stit)
Install a new species thermodynamic property parameterization for one species.
Definition: MultiSpeciesThermo.cpp:26
Cantera::NotImplementedError
An error indicating that an unimplemented function has been called.
Definition: ctexceptions.h:187
Cantera::PDSS
Virtual base class for a species with a pressure dependent standard state.
Definition: PDSS.h:148
Cantera::PDSS::initThermo
virtual void initThermo()
Initialization routine.
Definition: PDSS.h:415
Cantera::PDSS::cp_R_ref
virtual doublereal cp_R_ref() const
Return the molar heat capacity divided by R at reference pressure.
Definition: PDSS.cpp:102
Cantera::PDSS::entropy_R
virtual doublereal entropy_R() const
Return the standard state entropy divided by RT.
Definition: PDSS.cpp:47
Cantera::PDSS::setState_TP
virtual void setState_TP(doublereal temp, doublereal pres)
Set the internal temperature and pressure.
Definition: PDSS.cpp:181
Cantera::PDSS::enthalpy_RT
virtual doublereal enthalpy_RT() const
Return the standard state molar enthalpy divided by RT.
Definition: PDSS.cpp:32
Cantera::PDSS::cp_R
virtual doublereal cp_R() const
Return the molar const pressure heat capacity divided by RT.
Definition: PDSS.cpp:67
Cantera::PDSS::molarVolume_ref
virtual doublereal molarVolume_ref() const
Return the molar volume at reference pressure.
Definition: PDSS.cpp:107
Cantera::PDSS::molarVolume
virtual doublereal molarVolume() const
Return the molar volume at standard state.
Definition: PDSS.cpp:72
Cantera::PDSS::enthalpy_RT_ref
virtual doublereal enthalpy_RT_ref() const
Return the molar enthalpy divided by RT at reference pressure.
Definition: PDSS.cpp:92
Cantera::PDSS::entropy_R_ref
virtual doublereal entropy_R_ref() const
Return the molar entropy divided by R at reference pressure.
Definition: PDSS.cpp:97
Cantera::PDSS::getParameters
virtual void getParameters(AnyMap &eosNode) const
Store the parameters needed to reconstruct a copy of this PDSS object.
Definition: PDSS.h:424
Cantera::Phase::addSpecies
virtual bool addSpecies(shared_ptr< Species > spec)
Add a Species to this Phase.
Definition: Phase.cpp:803
Cantera::Phase::name
std::string name() const
Return the name of the phase.
Definition: Phase.cpp:70
Cantera::Phase::m_kk
size_t m_kk
Number of species in the phase.
Definition: Phase.h:943
Cantera::Phase::molecularWeight
doublereal molecularWeight(size_t k) const
Molecular weight of species k.
Definition: Phase.cpp:492
Cantera::Phase::temperature
doublereal temperature() const
Temperature (K).
Definition: Phase.h:654
Cantera::Phase::setTemperature
virtual void setTemperature(double temp)
Set the internally stored temperature of the phase (K).
Definition: Phase.h:719
Cantera::Phase::speciesIndex
size_t speciesIndex(const std::string &name) const
Returns the index of a species named 'name' within the Phase object.
Definition: Phase.cpp:187
Cantera::Phase::species
shared_ptr< Species > species(const std::string &name) const
Return the Species object for the named species.
Definition: Phase.cpp:950
Cantera::Species
Contains data about a single chemical species.
Definition: Species.h:26
Cantera::Species::name
std::string name
The name of the species.
Definition: Species.h:42
Cantera::Species::thermo
shared_ptr< SpeciesThermoInterpType > thermo
Thermodynamic data for the species.
Definition: Species.h:58
Cantera::ThermoPhase::RT
doublereal RT() const
Return the Gas Constant multiplied by the current temperature.
Definition: ThermoPhase.h:782
Cantera::ThermoPhase::m_tlast
doublereal m_tlast
last value of the temperature processed by reference state
Definition: ThermoPhase.h:1928
Cantera::ThermoPhase::getChemPotentials
virtual void getChemPotentials(doublereal *mu) const
Get the species chemical potentials. Units: J/kmol.
Definition: ThermoPhase.h:495
Cantera::ThermoPhase::initThermo
virtual void initThermo()
Initialize the ThermoPhase object after all species have been set up.
Definition: ThermoPhase.cpp:1102
Cantera::ThermoPhase::m_spthermo
MultiSpeciesThermo m_spthermo
Pointer to the calculation manager for species reference-state thermodynamic properties.
Definition: ThermoPhase.h:1894
Cantera::ThermoPhase::invalidateCache
virtual void invalidateCache()
Invalidate any cached values which are normally updated only when a change in state is detected.
Definition: ThermoPhase.cpp:1303
Cantera::VPStandardStateTP::m_g0_RT
vector_fp m_g0_RT
Vector containing the species reference Gibbs functions at T = m_tlast and P = p_ref.
Definition: VPStandardStateTP.h:306
Cantera::VPStandardStateTP::m_cp0_R
vector_fp m_cp0_R
Vector containing the species reference constant pressure heat capacities at T = m_tlast and P = p_re...
Definition: VPStandardStateTP.h:302
Cantera::VPStandardStateTP::addSpecies
virtual bool addSpecies(shared_ptr< Species > spec)
Definition: VPStandardStateTP.cpp:176
Cantera::VPStandardStateTP::getGibbs_RT_ref
virtual void getGibbs_RT_ref(doublereal *grt) const
Returns the vector of nondimensional Gibbs Free Energies of the reference state at the current temper...
Definition: VPStandardStateTP.cpp:117
Cantera::VPStandardStateTP::getGibbs_RT
virtual void getGibbs_RT(doublereal *grt) const
Get the nondimensional Gibbs functions for the species in their standard states at the current T and ...
Definition: VPStandardStateTP.cpp:70
Cantera::VPStandardStateTP::m_Tlast_ss
doublereal m_Tlast_ss
The last temperature at which the standard state thermodynamic properties were calculated at.
Definition: VPStandardStateTP.h:283
Cantera::VPStandardStateTP::_updateStandardStateThermo
virtual void _updateStandardStateThermo() const
Updates the standard state thermodynamic functions at the current T and P of the solution.
Definition: VPStandardStateTP.cpp:271
Cantera::VPStandardStateTP::m_h0_RT
vector_fp m_h0_RT
Vector containing the species reference enthalpies at T = m_tlast and P = p_ref.
Definition: VPStandardStateTP.h:298
Cantera::VPStandardStateTP::m_Plast_ss
doublereal m_Plast_ss
The last pressure at which the Standard State thermodynamic properties were calculated at.
Definition: VPStandardStateTP.h:287
Cantera::VPStandardStateTP::setState_TP
virtual void setState_TP(doublereal T, doublereal pres)
Set the temperature and pressure at the same time.
Definition: VPStandardStateTP.cpp:217
Cantera::VPStandardStateTP::m_s0_R
vector_fp m_s0_R
Vector containing the species reference entropies at T = m_tlast and P = p_ref.
Definition: VPStandardStateTP.h:310
Cantera::VPStandardStateTP::getCp_R
virtual void getCp_R(doublereal *cpr) const
Get the nondimensional Heat Capacities at constant pressure for the species standard states at the cu...
Definition: VPStandardStateTP.cpp:92
Cantera::VPStandardStateTP::m_Vss
vector_fp m_Vss
Vector containing the species standard state volumes at T = m_tlast and P = m_plast.
Definition: VPStandardStateTP.h:333
Cantera::VPStandardStateTP::getEntropy_R
virtual void getEntropy_R(doublereal *sr) const
Get the array of nondimensional Entropy functions for the standard state species at the current T and...
Definition: VPStandardStateTP.cpp:64
Cantera::VPStandardStateTP::setPressure
virtual void setPressure(doublereal p)
Set the internally stored pressure (Pa) at constant temperature and composition.
Definition: VPStandardStateTP.cpp:206
Cantera::VPStandardStateTP::installPDSS
void installPDSS(size_t k, std::unique_ptr< PDSS > &&pdss)
Install a PDSS object for species k
Definition: VPStandardStateTP.cpp:237
Cantera::VPStandardStateTP::initThermo
virtual void initThermo()
Definition: VPStandardStateTP.cpp:154
Cantera::VPStandardStateTP::m_maxTemp
double m_maxTemp
The maximum temperature at which data for all species is valid.
Definition: VPStandardStateTP.h:279
Cantera::VPStandardStateTP::minTemp
virtual double minTemp(size_t k=npos) const
Minimum temperature for which the thermodynamic data for the species or phase are valid.
Definition: VPStandardStateTP.cpp:305
Cantera::VPStandardStateTP::m_minTemp
double m_minTemp
The minimum temperature at which data for all species is valid.
Definition: VPStandardStateTP.h:276
Cantera::VPStandardStateTP::standardStateConvention
virtual int standardStateConvention() const
This method returns the convention used in specification of the standard state, of which there are cu...
Definition: VPStandardStateTP.cpp:35
Cantera::VPStandardStateTP::getEntropy_R_ref
virtual void getEntropy_R_ref(doublereal *er) const
Returns the vector of nondimensional entropies of the reference state at the current temperature of t...
Definition: VPStandardStateTP.cpp:136
Cantera::VPStandardStateTP::m_sss_R
vector_fp m_sss_R
Vector containing the species Standard State entropies at T = m_tlast and P = m_plast.
Definition: VPStandardStateTP.h:329
Cantera::VPStandardStateTP::m_cpss_R
vector_fp m_cpss_R
Vector containing the species Standard State constant pressure heat capacities at T = m_tlast and P =...
Definition: VPStandardStateTP.h:321
Cantera::VPStandardStateTP::getIntEnergy_RT
virtual void getIntEnergy_RT(doublereal *urt) const
Returns the vector of nondimensional Internal Energies of the standard state species at the current T...
Definition: VPStandardStateTP.cpp:83
Cantera::VPStandardStateTP::setTemperature
virtual void setTemperature(const doublereal temp)
Set the temperature of the phase.
Definition: VPStandardStateTP.cpp:200
Cantera::VPStandardStateTP::m_Pcurrent
doublereal m_Pcurrent
Current value of the pressure - state variable.
Definition: VPStandardStateTP.h:273
Cantera::VPStandardStateTP::getCp_R_ref
virtual void getCp_R_ref(doublereal *cprt) const
Returns the vector of nondimensional constant pressure heat capacities of the reference state at the ...
Definition: VPStandardStateTP.cpp:142
Cantera::VPStandardStateTP::getSpeciesParameters
virtual void getSpeciesParameters(const std::string &name, AnyMap &speciesNode) const
Get phase-specific parameters of a Species object such that an identical one could be reconstructed a...
Definition: VPStandardStateTP.cpp:167
Cantera::VPStandardStateTP::getStandardChemPotentials
virtual void getStandardChemPotentials(doublereal *mu) const
Get the array of chemical potentials at unit activity for the species at their standard states at the...
Definition: VPStandardStateTP.cpp:50
Cantera::VPStandardStateTP::getStandardVolumes_ref
virtual void getStandardVolumes_ref(doublereal *vol) const
Get the molar volumes of the species reference states at the current T and P_ref of the solution.
Definition: VPStandardStateTP.cpp:148
Cantera::VPStandardStateTP::maxTemp
virtual double maxTemp(size_t k=npos) const
Maximum temperature for which the thermodynamic data for the species are valid.
Definition: VPStandardStateTP.cpp:314
Cantera::VPStandardStateTP::getChemPotentials_RT
virtual void getChemPotentials_RT(doublereal *mu) const
Get the array of non-dimensional species chemical potentials.
Definition: VPStandardStateTP.cpp:40
Cantera::VPStandardStateTP::m_gss_RT
vector_fp m_gss_RT
Vector containing the species Standard State Gibbs functions at T = m_tlast and P = m_plast.
Definition: VPStandardStateTP.h:325
Cantera::VPStandardStateTP::m_V0
vector_fp m_V0
Vector containing the species reference molar volumes.
Definition: VPStandardStateTP.h:313
Cantera::VPStandardStateTP::updateStandardStateThermo
virtual void updateStandardStateThermo() const
Updates the standard state thermodynamic functions at the current T and P of the solution.
Definition: VPStandardStateTP.cpp:297
Cantera::VPStandardStateTP::VPStandardStateTP
VPStandardStateTP()
Constructor.
Definition: VPStandardStateTP.cpp:22
Cantera::VPStandardStateTP::getGibbs_ref
virtual void getGibbs_ref(doublereal *g) const
Returns the vector of the Gibbs function of the reference state at the current temperature of the sol...
Definition: VPStandardStateTP.cpp:123
Cantera::VPStandardStateTP::invalidateCache
virtual void invalidateCache()
Invalidate any cached values which are normally updated only when a change in state is detected.
Definition: VPStandardStateTP.cpp:265
Cantera::VPStandardStateTP::m_hss_RT
vector_fp m_hss_RT
Vector containing the species Standard State enthalpies at T = m_tlast and P = m_plast.
Definition: VPStandardStateTP.h:317
Cantera::VPStandardStateTP::getEnthalpy_RT
virtual void getEnthalpy_RT(doublereal *hrt) const
Get the nondimensional Enthalpy functions for the species at their standard states at the current T a...
Definition: VPStandardStateTP.cpp:58
Cantera::VPStandardStateTP::m_PDSS_storage
std::vector< std::unique_ptr< PDSS > > m_PDSS_storage
Storage for the PDSS objects for the species.
Definition: VPStandardStateTP.h:294
Cantera::VPStandardStateTP::getPureGibbs
virtual void getPureGibbs(doublereal *gpure) const
Get the Gibbs functions for the standard state of the species at the current T and P of the solution.
Definition: VPStandardStateTP.cpp:76
Cantera::VPStandardStateTP::getEnthalpy_RT_ref
virtual void getEnthalpy_RT_ref(doublereal *hrt) const
Definition: VPStandardStateTP.cpp:111
Cantera::VPStandardStateTP::calcDensity
virtual void calcDensity()
Calculate the density of the mixture using the partial molar volumes and mole fractions as input.
Definition: VPStandardStateTP.cpp:212
Cantera
Namespace for the Cantera kernel.
Definition: AnyMap.cpp:557
Cantera::npos
const size_t npos
index returned by functions to indicate "no position"
Definition: ct_defs.h:192
Cantera::cSS_CONVENTION_VPSS
const int cSS_CONVENTION_VPSS
Standard state uses the molality convention.
Definition: ThermoPhase.h:39
Cantera::OneAtm
const double OneAtm
One atmosphere [Pa].
Definition: ct_defs.h:81
Cantera::vector_fp
std::vector< double > vector_fp
Turn on the use of stl vectors for the basic array type within cantera Vector of doubles.
Definition: ct_defs.h:184
Cantera::BigNumber
const double BigNumber
largest number to compare to inf.
Definition: ct_defs.h:155
Cantera::scale
void scale(InputIter begin, InputIter end, OutputIter out, S scale_factor)
Multiply elements of an array by a scale factor.
Definition: utilities.h:100
utilities.h
Various templated functions that carry out common vector operations (see Templated Utility Functions)...