28 case VCS_UNITS_KCALMOL:
32 case VCS_UNITS_UNITLESS:
35 case VCS_UNITS_KELVIN:
36 Farad = Cantera::ElectronCharge * Cantera::Avogadro/ TKelvin;
39 plogf(
"vcs_nondim_Farad error: unknown units: %d\n", mu_units);
53 case VCS_UNITS_KCALMOL:
56 case VCS_UNITS_UNITLESS:
62 case VCS_UNITS_KELVIN:
69 plogf(
"vcs_nondimMult_TP error: unknown units: %d\n", mu_units);
119 if (tmole_orig < 1.0E-200 || tmole_orig > 1.0E200) {
120 plogf(
" VCS_SOLVE::vcs_nondim_TP ERROR: Total input moles , %g, is outside the range handled by vcs. exit",
125 "is outside the range handled by vcs.\n");
129 if (tmole_orig > 1.0E4) {
131 }
else if (tmole_orig < 1.0E-4) {
141 plogf(
" --- vcs_nondim_TP() called: USING A MOLE SCALE OF %g until further notice",
m_totalMoleScale);
216 switch (unitsFormat) {
217 case VCS_UNITS_KCALMOL:
220 case VCS_UNITS_UNITLESS:
221 plogf(
"dimensionless");
223 case VCS_UNITS_KJMOL:
226 case VCS_UNITS_KELVIN:
233 plogf(
"unknown units!");
std::vector< double > m_SSfeSpecies
Standard state chemical potentials for species K at the current temperature and pressure.
char m_unitsState
This specifies the current state of units for the Gibbs free energy properties in the program...
int m_debug_print_lvl
Debug printing lvl.
double m_temperature
Temperature (Kelvin)
std::vector< double > m_feSpecies_old
Free energy vector from the start of the current iteration.
int m_VCS_UnitsFormat
Units for the chemical potential data.
std::vector< double > m_deltaGRxn_new
Delta G(irxn) for the noncomponent species in the mechanism.
std::vector< double > m_elemAbundancesGoal
Element abundances vector Goals.
#define VCS_NONDIMENSIONAL_G
nondimensional
Header file for the internal object that holds the vcs equilibrium problem (see Class VCS_SOLVE and E...
Header for the object representing each phase within vcs.
#define VCS_ELEM_TYPE_ABSPOS
Normal element constraint consisting of positive coefficients for the formula matrix.
Phase information and Phase calculations for vcs.
void vcs_printChemPotUnits(int unitsFormat) const
Print the string representing the Chemical potential units.
Internal declarations for the VCSnonideal package.
std::string fp2str(const double x, const std::string &fmt)
Convert a double into a c++ string.
std::vector< double > m_molNumSpecies_old
Total moles of the species.
size_t m_numSpeciesTot
Total number of species in the problems.
double m_Faraday_dim
dimensionless value of Faraday's constant, F / RT (1/volt)
Base class for exceptions thrown by Cantera classes.
std::vector< double > m_deltaGRxn_old
Last deltag[irxn] from the previous step.
void setTotalMolesInert(const double tMolesInert)
Sets the total moles of inert in the phase.
size_t m_numElemConstraints
Number of element constraints in the problem.
std::vector< vcs_VolPhase * > m_VolPhaseList
Array of Phase Structures. Length = number of phases.
double m_totalMoleScale
Multiplier for the mole numbers within the nondimensionless formulation.
size_t m_numPhases
Number of Phases in the problem.
double vcs_nondim_Farad(int mu_units, double TKelvin) const
Returns the multiplier for electric charge terms.
#define VCS_DIMENSIONAL_G
dimensioned
void vcs_nondim_TP()
Nondimensionalize the problem data.
const doublereal Avogadro
Avogadro's Number [number/kmol].
double vcs_nondimMult_TP(int mu_units, double TKelvin) const
Returns the multiplier for the nondimensionalization of the equations.
#define plogendl()
define this Cantera function to replace cout << endl;
double vcs_tmoles()
Calculates the total number of moles of species in all phases.
void vcs_redim_TP()
Redimensionalize the problem data.
std::vector< double > TPhInertMoles
Total kmoles of inert to add to each phase.
const doublereal GasConstant
Universal Gas Constant. [J/kmol/K].
Contains declarations for string manipulation functions within Cantera.
const doublereal GasConst_cal_mol_K
Universal gas constant in cal/mol/K.
#define plogf
define this Cantera function to replace printf
std::vector< int > m_elType
Type of the element constraint.
#define VCS_SPECIES_TYPE_INTERFACIALVOLTAGE
Unknown refers to the voltage level of a phase.
std::vector< int > m_speciesUnknownType
Specifies the species unknown type.
Definitions for the classes that are thrown when Cantera experiences an error condition (also contain...