Cantera  2.1.2
Public Member Functions | Private Member Functions | Private Attributes | List of all members
FtnTransport Class Reference

A class that calls external Fortran functions to evaluate transport properties. More...

#include <FtnTransport.h>

Inheritance diagram for FtnTransport:
[legend]
Collaboration diagram for FtnTransport:
[legend]

Public Member Functions

 FtnTransport (int model, thermo_t *thermo)
 
virtual int model ()
 
virtual doublereal viscosity ()
 
virtual doublereal bulkViscosity ()
 The bulk viscosity in Pa-s. More...
 
virtual doublereal thermalConductivity ()
 Returns the mixture thermal conductivity in W/m/K. More...
 
virtual doublereal electricalConductivity ()
 
virtual void getMobilities (doublereal *mobil)
 Get the Electrical mobilities (m^2/V/s). More...
 
virtual void getThermalDiffCoeffs (doublereal *dt)
 Return a vector of Thermal diffusion coefficients [kg/m/sec]. More...
 
virtual void getBinaryDiffCoeffs (int ld, doublereal *d)
 
virtual void getMultiDiffCoeffs (int ld, doublereal *d)
 
virtual void getMixDiffCoeffs (doublereal *d)
 Returns a vector of mixture averaged diffusion coefficients. More...
 
- Public Member Functions inherited from Transport
 Transport (thermo_t *thermo=0, size_t ndim=1)
 Constructor. More...
 
 Transport (const Transport &right)
 
Transportoperator= (const Transport &right)
 
virtual TransportduplMyselfAsTransport () const
 Duplication routine for objects which inherit from Transport. More...
 
virtual int model () const
 Transport model. More...
 
thermo_tthermo ()
 
bool ready ()
 
void setNDim (const int ndim)
 Set the number of dimensions to be expected in flux expressions. More...
 
size_t nDim () const
 Return the number of dimensions in flux expressions. More...
 
void checkSpeciesIndex (size_t k) const
 Check that the specified species index is in range Throws an exception if k is greater than nSpecies() More...
 
void checkSpeciesArraySize (size_t kk) const
 Check that an array size is at least nSpecies() Throws an exception if kk is less than nSpecies(). More...
 
virtual doublereal getElectricConduct ()
 Compute the mixture electrical conductivity (S m-1) at the current conditions of the phase (Siemens m-1) More...
 
virtual void getElectricCurrent (int ndim, const doublereal *grad_T, int ldx, const doublereal *grad_X, int ldf, const doublereal *grad_V, doublereal *current)
 Compute the electric current density in A/m^2. More...
 
virtual void getSpeciesFluxes (size_t ndim, const doublereal *const grad_T, size_t ldx, const doublereal *const grad_X, size_t ldf, doublereal *const fluxes)
 Get the species diffusive mass fluxes wrt to the specified solution averaged velocity, given the gradients in mole fraction and temperature. More...
 
virtual void getSpeciesFluxesES (size_t ndim, const doublereal *grad_T, size_t ldx, const doublereal *grad_X, size_t ldf, const doublereal *grad_Phi, doublereal *fluxes)
 Get the species diffusive mass fluxes wrt to the mass averaged velocity, given the gradients in mole fraction, temperature and electrostatic potential. More...
 
virtual void getSpeciesVdiff (size_t ndim, const doublereal *grad_T, int ldx, const doublereal *grad_X, int ldf, doublereal *Vdiff)
 Get the species diffusive velocities wrt to the mass averaged velocity, given the gradients in mole fraction and temperature. More...
 
virtual void getSpeciesVdiffES (size_t ndim, const doublereal *grad_T, int ldx, const doublereal *grad_X, int ldf, const doublereal *grad_Phi, doublereal *Vdiff)
 Get the species diffusive velocities wrt to the mass averaged velocity, given the gradients in mole fraction, temperature, and electrostatic potential. More...
 
virtual void getMolarFluxes (const doublereal *const state1, const doublereal *const state2, const doublereal delta, doublereal *const cfluxes)
 Get the molar fluxes [kmol/m^2/s], given the thermodynamic state at two nearby points. More...
 
virtual void getMassFluxes (const doublereal *state1, const doublereal *state2, doublereal delta, doublereal *mfluxes)
 Get the mass fluxes [kg/m^2/s], given the thermodynamic state at two nearby points. More...
 
virtual void getBinaryDiffCoeffs (const size_t ld, doublereal *const d)
 Returns the matrix of binary diffusion coefficients [m^2/s]. More...
 
virtual void getMultiDiffCoeffs (const size_t ld, doublereal *const d)
 Return the Multicomponent diffusion coefficients. Units: [m^2/s]. More...
 
virtual void getMixDiffCoeffsMole (doublereal *const d)
 Returns a vector of mixture averaged diffusion coefficients. More...
 
virtual void getMixDiffCoeffsMass (doublereal *const d)
 Returns a vector of mixture averaged diffusion coefficients. More...
 
virtual void setParameters (const int type, const int k, const doublereal *const p)
 Set model parameters for derived classes. More...
 
void setVelocityBasis (VelocityBasis ivb)
 Sets the velocity basis. More...
 
VelocityBasis getVelocityBasis () const
 Gets the velocity basis. More...
 
virtual void getSpeciesViscosities (doublereal *const visc)
 Returns the pure species viscosities. More...
 
virtual doublereal ionConductivity ()
 The ionic conductivity in 1/ohm/m. More...
 
virtual void getSpeciesIonConductivity (doublereal *const ionCond)
 Returns the pure species ionic conductivity. More...
 
virtual void mobilityRatio (double *mobRat)
 Returns the pointer to the mobility ratios of the species in the phase. More...
 
virtual void getSpeciesMobilityRatio (double **mobRat)
 Returns the pure species limit of the mobility ratios. More...
 
virtual void selfDiffusion (doublereal *const selfDiff)
 Returns the self diffusion coefficients of the species in the phase. More...
 
virtual void getSpeciesSelfDiffusion (double **selfDiff)
 Returns the pure species self diffusion in solution of each species. More...
 
virtual void getFluidMobilities (doublereal *const mobil_f)
 Get the fluid mobilities (s kmol/kg). More...
 
virtual bool initSolid (SolidTransportData &tr)
 Called by TransportFactory to set parameters. More...
 
virtual void setThermo (thermo_t &thermo)
 Specifies the ThermoPhase object. More...
 

Private Member Functions

void updateTPX ()
 

Private Attributes

doublereal m_temp
 
doublereal m_pres
 
vector_fp m_x
 
int m_model
 

Additional Inherited Members

- Protected Member Functions inherited from Transport
virtual bool initGas (GasTransportParams &tr)
 Called by TransportFactory to set parameters. More...
 
virtual bool initLiquid (LiquidTransportParams &tr)
 Called by TransportFactory to set parameters. More...
 
void finalize ()
 Enable the transport object for use. More...
 
- Protected Attributes inherited from Transport
thermo_tm_thermo
 pointer to the object representing the phase More...
 
bool m_ready
 true if finalize has been called More...
 
size_t m_nsp
 Number of species. More...
 
size_t m_nDim
 Number of dimensions used in flux expressions. More...
 
int m_velocityBasis
 Velocity basis from which diffusion velocities are computed. More...
 

Detailed Description

A class that calls external Fortran functions to evaluate transport properties.

Deprecated:
Broken and unused

Definition at line 66 of file FtnTransport.h.

Member Function Documentation

virtual doublereal viscosity ( )
inlinevirtual

The viscosity in Pa-s.

Reimplemented from Transport.

Definition at line 82 of file FtnTransport.h.

References __VISC__.

virtual doublereal bulkViscosity ( )
inlinevirtual

The bulk viscosity in Pa-s.

The bulk viscosity is only non-zero in rare cases. Most transport managers either overload this method to return zero, or do not implement it, in which case an exception is thrown if called.

Reimplemented from Transport.

Definition at line 87 of file FtnTransport.h.

virtual doublereal thermalConductivity ( )
inlinevirtual

Returns the mixture thermal conductivity in W/m/K.

Units are in W / m K or equivalently kg m / s3 K

Returns
returns thermal conductivity in W/m/K.

Reimplemented from Transport.

Definition at line 92 of file FtnTransport.h.

virtual doublereal electricalConductivity ( )
inlinevirtual

The electrical conductivity (Siemens/m).

Reimplemented from Transport.

Definition at line 97 of file FtnTransport.h.

virtual void getMobilities ( doublereal *  mobil_e)
inlinevirtual

Get the Electrical mobilities (m^2/V/s).

This function returns the mobilities. In some formulations this is equal to the normal mobility multiplied by faraday's constant.

Frequently, but not always, the mobility is calculated from the diffusion coefficient using the Einstein relation

\[ \mu^e_k = \frac{F D_k}{R T} \]

Parameters
mobil_eReturns the mobilities of the species in array mobil_e. The array must be dimensioned at least as large as the number of species.

Reimplemented from Transport.

Definition at line 102 of file FtnTransport.h.

virtual void getThermalDiffCoeffs ( doublereal *  dt)
inlinevirtual

Return a vector of Thermal diffusion coefficients [kg/m/sec].

The thermal diffusion coefficient \( D^T_k \) is defined so that the diffusive mass flux of species k induced by the local temperature gradient is given by the following formula:

\[ M_k J_k = -D^T_k \nabla \ln T. \]

The thermal diffusion coefficient can be either positive or negative.

Parameters
dtOn return, dt will contain the species thermal diffusion coefficients. Dimension dt at least as large as the number of species. Units are kg/m/s.

Reimplemented from Transport.

Definition at line 108 of file FtnTransport.h.

virtual void getMixDiffCoeffs ( doublereal *  d)
inlinevirtual

Returns a vector of mixture averaged diffusion coefficients.

Mixture-averaged diffusion coefficients [m^2/s]. If the transport manager implements a mixture-averaged diffusion model, then this method returns the array of mixture-averaged diffusion coefficients. Otherwise it throws an exception.

Parameters
dReturn vector of mixture averaged diffusion coefficients Units = m2/s. Length = n_sp

Reimplemented from Transport.

Definition at line 125 of file FtnTransport.h.


The documentation for this class was generated from the following file: