Cantera
3.0.0
|
Class IonGasTransport implements Stockmayer-(n,6,4) model for transport of ions. More...
#include <IonGasTransport.h>
Class IonGasTransport implements Stockmayer-(n,6,4) model for transport of ions.
As implemented here, only binary transport between neutrals and ions is considered for calculating mixture-average diffusion coefficients and mobilities. When polarizability is not provide for an ion, LJ model is used instead of n64 model. Only neutral species are considered for thermal conductivity and viscosity.
References for Stockmayer-(n,6,4) model: Selle and Riedel [36], [37]; Han et al. [11]; Chiflikian [4]; and Viehland et al. [46].
Stockmayer-(n,6,4) model is not suitable for collision between O2/O2- due to resonant charge transfer. Therefore, an experimental collision data is used instead.
Data taken from [34].
Definition at line 34 of file IonGasTransport.h.
Public Member Functions | |
string | transportModel () const override |
Identifies the model represented by this Transport object. | |
void | init (ThermoPhase *thermo, int mode, int log_level) override |
Initialize a transport manager. | |
double | viscosity () override |
Viscosity of the mixture (kg/m/s). | |
double | thermalConductivity () override |
Returns the mixture thermal conductivity (W/m/K). | |
void | getMobilities (double *const mobi) override |
The mobilities for ions in gas. | |
void | getMixDiffCoeffs (double *const d) override |
The mixture transport for ionized gas. | |
double | electricalConductivity () override |
The electrical conductivity (Siemens/m). | |
Public Member Functions inherited from MixTransport | |
MixTransport ()=default | |
Default constructor. | |
string | transportModel () const override |
Identifies the model represented by this Transport object. | |
void | getThermalDiffCoeffs (double *const dt) override |
Return the thermal diffusion coefficients. | |
double | thermalConductivity () override |
Returns the mixture thermal conductivity (W/m /K) | |
void | getMobilities (double *const mobil) override |
Get the Electrical mobilities (m^2/V/s). | |
void | update_T () override |
Update the internal parameters whenever the temperature has changed. | |
void | update_C () override |
Update the internal parameters whenever the concentrations have changed. | |
void | getSpeciesFluxes (size_t ndim, const double *const grad_T, size_t ldx, const double *const grad_X, size_t ldf, double *const fluxes) override |
Get the species diffusive mass fluxes wrt to the mass averaged velocity, given the gradients in mole fraction and temperature. | |
void | init (ThermoPhase *thermo, int mode=0, int log_level=0) override |
Initialize a transport manager. | |
Public Member Functions inherited from GasTransport | |
double | viscosity () override |
Viscosity of the mixture (kg /m /s) | |
void | getSpeciesViscosities (double *const visc) override |
Get the pure-species viscosities. | |
void | getBinaryDiffCoeffs (const size_t ld, double *const d) override |
Returns the matrix of binary diffusion coefficients. | |
void | getMixDiffCoeffs (double *const d) override |
Returns the Mixture-averaged diffusion coefficients [m^2/s]. | |
void | getMixDiffCoeffsMole (double *const d) override |
Returns the mixture-averaged diffusion coefficients [m^2/s]. | |
void | getMixDiffCoeffsMass (double *const d) override |
Returns the mixture-averaged diffusion coefficients [m^2/s]. | |
void | getViscosityPolynomial (size_t i, double *coeffs) const override |
Return the polynomial fits to the viscosity of species i. | |
void | getConductivityPolynomial (size_t i, double *coeffs) const override |
Return the temperature fits of the heat conductivity of species i. | |
void | getBinDiffusivityPolynomial (size_t i, size_t j, double *coeffs) const override |
Return the polynomial fits to the binary diffusivity of species pair (i, j) | |
void | getCollisionIntegralPolynomial (size_t i, size_t j, double *astar_coeffs, double *bstar_coeffs, double *cstar_coeffs) const override |
Return the polynomial fits to the collision integral of species pair (i, j) | |
void | setViscosityPolynomial (size_t i, double *coeffs) override |
Modify the polynomial fits to the viscosity of species i. | |
void | setConductivityPolynomial (size_t i, double *coeffs) override |
Modify the temperature fits of the heat conductivity of species i. | |
void | setBinDiffusivityPolynomial (size_t i, size_t j, double *coeffs) override |
Modify the polynomial fits to the binary diffusivity of species pair (i, j) | |
void | setCollisionIntegralPolynomial (size_t i, size_t j, double *astar_coeffs, double *bstar_coeffs, double *cstar_coeffs, bool actualT) override |
Modify the polynomial fits to the collision integral of species pair (i, j) | |
void | init (ThermoPhase *thermo, int mode=0, int log_level=0) override |
Initialize a transport manager. | |
bool | CKMode () const override |
Boolean indicating the form of the transport properties polynomial fits. | |
Public Member Functions inherited from Transport | |
Transport (ThermoPhase *thermo=0, size_t ndim=npos) | |
Constructor. | |
Transport (const Transport &)=delete | |
Transport & | operator= (const Transport &)=delete |
virtual string | transportModel () const |
Identifies the model represented by this Transport object. | |
string | transportType () const |
Identifies the Transport object type. | |
ThermoPhase & | thermo () |
Phase object. | |
bool | ready () |
Returns true if the transport manager is ready for use. | |
void | setNDim (const int ndim) |
Set the number of dimensions to be expected in flux expressions. | |
size_t | nDim () const |
Return the number of dimensions in flux expressions. | |
void | checkSpeciesIndex (size_t k) const |
Check that the specified species index is in range. | |
void | checkSpeciesArraySize (size_t kk) const |
Check that an array size is at least nSpecies(). | |
virtual double | getElectricConduct () |
Compute the mixture electrical conductivity (S m-1) at the current conditions of the phase (Siemens m-1) | |
virtual void | getElectricCurrent (int ndim, const double *grad_T, int ldx, const double *grad_X, int ldf, const double *grad_V, double *current) |
Compute the electric current density in A/m^2. | |
virtual void | getSpeciesFluxes (size_t ndim, const double *const grad_T, size_t ldx, const double *const grad_X, size_t ldf, double *const fluxes) |
Get the species diffusive mass fluxes wrt to the specified solution averaged velocity, given the gradients in mole fraction and temperature. | |
virtual void | getSpeciesFluxesES (size_t ndim, const double *grad_T, size_t ldx, const double *grad_X, size_t ldf, const double *grad_Phi, double *fluxes) |
Get the species diffusive mass fluxes wrt to the mass averaged velocity, given the gradients in mole fraction, temperature and electrostatic potential. | |
virtual void | getSpeciesVdiff (size_t ndim, const double *grad_T, int ldx, const double *grad_X, int ldf, double *Vdiff) |
Get the species diffusive velocities wrt to the mass averaged velocity, given the gradients in mole fraction and temperature. | |
virtual void | getSpeciesVdiffES (size_t ndim, const double *grad_T, int ldx, const double *grad_X, int ldf, const double *grad_Phi, double *Vdiff) |
Get the species diffusive velocities wrt to the mass averaged velocity, given the gradients in mole fraction, temperature, and electrostatic potential. | |
virtual void | getMolarFluxes (const double *const state1, const double *const state2, const double delta, double *const cfluxes) |
Get the molar fluxes [kmol/m^2/s], given the thermodynamic state at two nearby points. | |
virtual void | getMassFluxes (const double *state1, const double *state2, double delta, double *mfluxes) |
Get the mass fluxes [kg/m^2/s], given the thermodynamic state at two nearby points. | |
virtual void | getThermalDiffCoeffs (double *const dt) |
Return a vector of Thermal diffusion coefficients [kg/m/sec]. | |
virtual void | getBinaryDiffCoeffs (const size_t ld, double *const d) |
Returns the matrix of binary diffusion coefficients [m^2/s]. | |
virtual void | getMultiDiffCoeffs (const size_t ld, double *const d) |
Return the Multicomponent diffusion coefficients. Units: [m^2/s]. | |
virtual void | getMixDiffCoeffs (double *const d) |
Returns a vector of mixture averaged diffusion coefficients. | |
virtual void | getMixDiffCoeffsMole (double *const d) |
Returns a vector of mixture averaged diffusion coefficients. | |
virtual void | getMixDiffCoeffsMass (double *const d) |
Returns a vector of mixture averaged diffusion coefficients. | |
virtual void | getViscosityPolynomial (size_t i, double *coeffs) const |
Return the polynomial fits to the viscosity of species i. | |
virtual void | getConductivityPolynomial (size_t i, double *coeffs) const |
Return the temperature fits of the heat conductivity of species i. | |
virtual void | getBinDiffusivityPolynomial (size_t i, size_t j, double *coeffs) const |
Return the polynomial fits to the binary diffusivity of species pair (i, j) | |
virtual void | getCollisionIntegralPolynomial (size_t i, size_t j, double *astar_coeffs, double *bstar_coeffs, double *cstar_coeffs) const |
Return the polynomial fits to the collision integral of species pair (i, j) | |
virtual void | setViscosityPolynomial (size_t i, double *coeffs) |
Modify the polynomial fits to the viscosity of species i. | |
virtual void | setConductivityPolynomial (size_t i, double *coeffs) |
Modify the temperature fits of the heat conductivity of species i. | |
virtual void | setBinDiffusivityPolynomial (size_t i, size_t j, double *coeffs) |
Modify the polynomial fits to the binary diffusivity of species pair (i, j) | |
virtual void | setCollisionIntegralPolynomial (size_t i, size_t j, double *astar_coeffs, double *bstar_coeffs, double *cstar_coeffs, bool flag) |
Modify the polynomial fits to the collision integral of species pair (i, j) | |
virtual void | setParameters (const int type, const int k, const double *const p) |
Set model parameters for derived classes. | |
AnyMap | parameters () const |
Return the parameters for a phase definition which are needed to reconstruct an identical object using the newTransport function. | |
void | setVelocityBasis (VelocityBasis ivb) |
Sets the velocity basis. | |
VelocityBasis | getVelocityBasis () const |
Gets the velocity basis. | |
virtual double | bulkViscosity () |
The bulk viscosity in Pa-s. | |
virtual double | ionConductivity () |
The ionic conductivity in 1/ohm/m. | |
virtual void | getSpeciesIonConductivity (double *const ionCond) |
Returns the pure species ionic conductivity. | |
virtual void | mobilityRatio (double *mobRat) |
Returns the pointer to the mobility ratios of the species in the phase. | |
virtual void | getSpeciesMobilityRatio (double **mobRat) |
Returns the pure species limit of the mobility ratios. | |
virtual void | getFluidMobilities (double *const mobil_f) |
Get the fluid mobilities (s kmol/kg). | |
virtual void | setThermo (ThermoPhase &thermo) |
Specifies the ThermoPhase object. | |
virtual void | setRoot (shared_ptr< Solution > root) |
Set root Solution holding all phase information. | |
Protected Member Functions | |
void | setupN64 () |
setup parameters for n64 model | |
void | fitDiffCoeffs (MMCollisionInt &integrals) override |
Generate polynomial fits to the binary diffusion coefficients. | |
double | omega11_n64 (const double tstar, const double gamma) |
Collision integral of omega11 of n64 collision model. | |
Protected Member Functions inherited from MixTransport | |
void | updateCond_T () |
Update the temperature dependent parts of the species thermal conductivities. | |
Protected Member Functions inherited from GasTransport | |
GasTransport (ThermoPhase *thermo=0) | |
virtual void | update_T () |
virtual void | update_C ()=0 |
virtual void | updateViscosity_T () |
Update the temperature-dependent viscosity terms. | |
virtual void | updateSpeciesViscosities () |
Update the pure-species viscosities. | |
virtual void | updateDiff_T () |
Update the binary diffusion coefficients. | |
virtual void | setupCollisionParameters () |
Setup parameters for a new kinetic-theory-based transport manager for low-density gases. | |
void | setupCollisionIntegral () |
Setup range for polynomial fits to collision integrals of Monchick & Mason [27]. | |
void | getTransportData () |
Read the transport database. | |
void | makePolarCorrections (size_t i, size_t j, double &f_eps, double &f_sigma) |
Corrections for polar-nonpolar binary diffusion coefficients. | |
void | fitCollisionIntegrals (MMCollisionInt &integrals) |
Generate polynomial fits to collision integrals. | |
virtual void | fitProperties (MMCollisionInt &integrals) |
Generate polynomial fits to the viscosity \( \eta \) and conductivity \( \lambda \). | |
void | getBinDiffCorrection (double t, MMCollisionInt &integrals, size_t k, size_t j, double xk, double xj, double &fkj, double &fjk) |
Second-order correction to the binary diffusion coefficients. | |
Protected Member Functions inherited from Transport | |
void | finalize () |
Enable the transport object for use. | |
Protected Attributes | |
vector< double > | m_speciesCharge |
electrical properties | |
vector< size_t > | m_kIon |
index of ions (exclude electron.) | |
vector< size_t > | m_kNeutral |
index of neutral species | |
size_t | m_kElectron = npos |
index of electron | |
DenseMatrix | m_gamma |
parameter of omega11 of n64 | |
vector< double > | m_om11_O2 |
polynomial of the collision integral for O2/O2- | |
Protected Attributes inherited from MixTransport | |
vector< double > | m_cond |
vector of species thermal conductivities (W/m /K) | |
double | m_lambda = 0.0 |
Internal storage for the calculated mixture thermal conductivity. | |
bool | m_spcond_ok = false |
Update boolean for the species thermal conductivities. | |
bool | m_condmix_ok = false |
Update boolean for the mixture rule for the mixture thermal conductivity. | |
Protected Attributes inherited from GasTransport | |
vector< double > | m_molefracs |
Vector of species mole fractions. | |
double | m_viscmix = 0.0 |
Internal storage for the viscosity of the mixture (kg /m /s) | |
bool | m_visc_ok = false |
Update boolean for mixture rule for the mixture viscosity. | |
bool | m_viscwt_ok = false |
Update boolean for the weighting factors for the mixture viscosity. | |
bool | m_spvisc_ok = false |
Update boolean for the species viscosities. | |
bool | m_bindiff_ok = false |
Update boolean for the binary diffusivities at unit pressure. | |
int | m_mode = 0 |
Type of the polynomial fits to temperature. | |
DenseMatrix | m_phi |
m_phi is a Viscosity Weighting Function. size = m_nsp * n_nsp | |
vector< double > | m_spwork |
work space length = m_kk | |
vector< double > | m_visc |
vector of species viscosities (kg /m /s). | |
vector< vector< double > > | m_visccoeffs |
Polynomial fits to the viscosity of each species. | |
vector< double > | m_mw |
Local copy of the species molecular weights. | |
DenseMatrix | m_wratjk |
Holds square roots of molecular weight ratios. | |
DenseMatrix | m_wratkj1 |
Holds square roots of molecular weight ratios. | |
vector< double > | m_sqvisc |
vector of square root of species viscosities sqrt(kg /m /s). | |
vector< double > | m_polytempvec |
Powers of the ln temperature, up to fourth order. | |
double | m_temp = -1.0 |
Current value of the temperature at which the properties in this object are calculated (Kelvin). | |
double | m_kbt = 0.0 |
Current value of Boltzmann constant times the temperature (Joules) | |
double | m_sqrt_t = 0.0 |
current value of temperature to 1/2 power | |
double | m_logt = 0.0 |
Current value of the log of the temperature. | |
double | m_t14 = 0.0 |
Current value of temperature to 1/4 power. | |
vector< vector< double > > | m_diffcoeffs |
Polynomial fits to the binary diffusivity of each species. | |
DenseMatrix | m_bdiff |
Matrix of binary diffusion coefficients at the reference pressure and the current temperature Size is nsp x nsp. | |
vector< vector< double > > | m_condcoeffs |
temperature fits of the heat conduction | |
vector< vector< int > > | m_poly |
Indices for the (i,j) interaction in collision integral fits. | |
vector< vector< double > > | m_omega22_poly |
Fit for omega22 collision integral. | |
vector< vector< int > > | m_star_poly_uses_actualT |
Flag to indicate for which (i,j) interaction pairs the actual temperature is used instead of the reduced temperature. | |
vector< vector< double > > | m_astar_poly |
Fit for astar collision integral. | |
vector< vector< double > > | m_bstar_poly |
Fit for bstar collision integral. | |
vector< vector< double > > | m_cstar_poly |
Fit for cstar collision integral. | |
vector< double > | m_zrot |
Rotational relaxation number for each species. | |
vector< double > | m_crot |
Dimensionless rotational heat capacity of each species. | |
vector< bool > | m_polar |
Vector of booleans indicating whether a species is a polar molecule. | |
vector< double > | m_alpha |
Polarizability of each species in the phase. | |
vector< double > | m_eps |
Lennard-Jones well-depth of the species in the current phase. | |
vector< double > | m_sigma |
Lennard-Jones diameter of the species in the current phase. | |
DenseMatrix | m_reducedMass |
This is the reduced mass of the interaction between species i and j. | |
DenseMatrix | m_diam |
hard-sphere diameter for (i,j) collision | |
DenseMatrix | m_epsilon |
The effective well depth for (i,j) collisions. | |
DenseMatrix | m_dipole |
The effective dipole moment for (i,j) collisions. | |
DenseMatrix | m_delta |
Reduced dipole moment of the interaction between two species. | |
vector< double > | m_w_ac |
Pitzer acentric factor. | |
vector< double > | m_disp |
Dispersion coefficient. | |
vector< double > | m_quad_polar |
Quadrupole polarizability. | |
int | m_log_level = 0 |
Level of verbose printing during initialization. | |
Protected Attributes inherited from Transport | |
ThermoPhase * | m_thermo |
pointer to the object representing the phase | |
bool | m_ready = false |
true if finalize has been called | |
size_t | m_nsp = 0 |
Number of species. | |
size_t | m_nDim |
Number of dimensions used in flux expressions. | |
int | m_velocityBasis = VB_MASSAVG |
Velocity basis from which diffusion velocities are computed. | |
std::weak_ptr< Solution > | m_root |
reference to Solution | |
|
inlineoverridevirtual |
Identifies the model represented by this Transport object.
Each derived class should override this method to return a meaningful identifier.
Reimplemented from Transport.
Definition at line 39 of file IonGasTransport.h.
|
overridevirtual |
Initialize a transport manager.
This routine sets up a transport manager. It calculates the collision integrals and populates species-dependent data structures.
thermo | Pointer to the ThermoPhase object |
mode | Chemkin compatible mode or not. This alters the specification of the collision integrals. defaults to no. |
log_level | Defaults to zero, no logging |
Reimplemented from GasTransport.
Definition at line 17 of file IonGasTransport.cpp.
|
overridevirtual |
Viscosity of the mixture (kg/m/s).
Only Neutral species contribute to Viscosity.
Reimplemented from GasTransport.
Definition at line 96 of file IonGasTransport.cpp.
|
overridevirtual |
Returns the mixture thermal conductivity (W/m/K).
Only Neutral species contribute to thermal conductivity.
Reimplemented from Transport.
Definition at line 120 of file IonGasTransport.cpp.
|
overridevirtual |
The mobilities for ions in gas.
The ion mobilities are calculated by Blanc's law.
Reimplemented from Transport.
Definition at line 382 of file IonGasTransport.cpp.
|
overridevirtual |
The mixture transport for ionized gas.
The binary transport between two charged species is neglected.
Reimplemented from GasTransport.
Definition at line 347 of file IonGasTransport.cpp.
|
overridevirtual |
The electrical conductivity (Siemens/m).
\[ \sigma = \sum_k{\left|C_k\right| \mu_k \frac{X_k P}{k_b T}} \]
Reimplemented from Transport.
Definition at line 139 of file IonGasTransport.cpp.
|
protected |
setup parameters for n64 model
Definition at line 247 of file IonGasTransport.cpp.
|
overrideprotectedvirtual |
Generate polynomial fits to the binary diffusion coefficients.
Use Stockmayer-(n,6,4) model for collision between charged and neutral species.
Reimplemented from GasTransport.
Definition at line 156 of file IonGasTransport.cpp.
|
protected |
Collision integral of omega11 of n64 collision model.
The collision integral was fitted by Han et al. using the table by Viehlan et al. Note: Han release the range to 1000, but Selle suggested that a high temperature model is needed for T* > 10.
Definition at line 315 of file IonGasTransport.cpp.
|
protected |
electrical properties
Definition at line 87 of file IonGasTransport.h.
|
protected |
index of ions (exclude electron.)
Definition at line 90 of file IonGasTransport.h.
|
protected |
index of neutral species
Definition at line 93 of file IonGasTransport.h.
|
protected |
index of electron
Definition at line 96 of file IonGasTransport.h.
|
protected |
parameter of omega11 of n64
Definition at line 99 of file IonGasTransport.h.
|
protected |
polynomial of the collision integral for O2/O2-
Definition at line 102 of file IonGasTransport.h.