perfectGas< Specie > Class Template Reference

Perfect gas equation of state: More...

Inheritance diagram for perfectGas< Specie >:
Collaboration diagram for perfectGas< Specie >:

Public Member Functions

 perfectGas (const Specie &sp)
 Construct from components. More...
 
 perfectGas (const word &name, const dictionary &dict)
 Construct from name and dictionary. More...
 
 perfectGas (const word &name, const perfectGas &)
 Construct as named copy. More...
 
autoPtr< perfectGasclone () const
 Construct and return a clone. More...
 
scalar rho (scalar p, scalar T) const
 Return density [kg/m^3]. More...
 
scalar H (const scalar p, const scalar T) const
 Return enthalpy contribution [J/kg]. More...
 
scalar Cp (scalar p, scalar T) const
 Return Cp contribution [J/(kg K]. More...
 
scalar E (const scalar p, const scalar T) const
 Return internal energy contribution [J/kg]. More...
 
scalar Cv (scalar p, scalar T) const
 Return Cv contribution [J/(kg K]. More...
 
scalar Sp (const scalar p, const scalar T) const
 Return entropy contribution to the integral of Cp/T [J/kg/K]. More...
 
scalar Sv (const scalar p, const scalar T) const
 Return entropy contribution to the integral of Cv/T [J/kg/K]. More...
 
scalar psi (scalar p, scalar T) const
 Return compressibility [s^2/m^2]. More...
 
scalar Z (scalar p, scalar T) const
 Return compression factor []. More...
 
scalar CpMCv (scalar p, scalar T) const
 Return (Cp - Cv) [J/(kg K]. More...
 
scalar alphav (const scalar p, const scalar T) const
 Return volumetric coefficient of thermal expansion [1/T]. More...
 
void write (Ostream &os) const
 Write to Ostream. More...
 
void operator+= (const perfectGas &)
 
void operator*= (const scalar)
 

Static Public Member Functions

static word typeName ()
 Return the instantiated type name. More...
 

Static Public Attributes

static const bool incompressible = false
 Is the equation of state is incompressible i.e. rho != f(p) More...
 
static const bool isochoric = false
 Is the equation of state is isochoric i.e. rho = const. More...
 

Friends

perfectGas operator+ (const perfectGas &, const perfectGas &)
 
perfectGas operator* (const scalar s, const perfectGas &)
 
perfectGas operator== (const perfectGas &, const perfectGas &)
 
Ostreamoperator (Ostream &, const perfectGas &)
 

Detailed Description

template<class Specie>
class Foam::perfectGas< Specie >

Perfect gas equation of state:

    rho = p/(R*T)
Usage
The gas constant R used by the perfect gas equation of state is obtained directly from the specie or mixture molecular weight so there is no need to provide an equation of equationOfState enry in the mixture specification.
Source files

Definition at line 93 of file perfectGas.H.

Constructor & Destructor Documentation

◆ perfectGas() [1/3]

perfectGas ( const Specie &  sp)
inline

Construct from components.

Definition at line 31 of file perfectGasI.H.

◆ perfectGas() [2/3]

perfectGas ( const word name,
const dictionary dict 
)

Construct from name and dictionary.

Definition at line 32 of file perfectGas.C.

◆ perfectGas() [3/3]

perfectGas ( const word name,
const perfectGas< Specie > &   
)
inline

Construct as named copy.

Member Function Documentation

◆ clone()

Foam::autoPtr< Foam::perfectGas< Specie > > clone
inline

Construct and return a clone.

Definition at line 50 of file perfectGasI.H.

◆ typeName()

static word typeName ( )
inlinestatic

Return the instantiated type name.

Definition at line 118 of file perfectGas.H.

◆ rho()

Foam::scalar rho ( scalar  p,
scalar  T 
) const
inline

Return density [kg/m^3].

Definition at line 59 of file perfectGasI.H.

References p, Foam::R(), and Foam::T().

Here is the call graph for this function:

◆ H()

Foam::scalar H ( const scalar  p,
const scalar  T 
) const
inline

Return enthalpy contribution [J/kg].

Definition at line 66 of file perfectGasI.H.

◆ Cp()

Foam::scalar Cp ( scalar  p,
scalar  T 
) const
inline

Return Cp contribution [J/(kg K].

Definition at line 73 of file perfectGasI.H.

◆ E()

Foam::scalar E ( const scalar  p,
const scalar  T 
) const
inline

Return internal energy contribution [J/kg].

Definition at line 80 of file perfectGasI.H.

◆ Cv()

Foam::scalar Cv ( scalar  p,
scalar  T 
) const
inline

Return Cv contribution [J/(kg K].

Definition at line 87 of file perfectGasI.H.

◆ Sp()

Foam::scalar Sp ( const scalar  p,
const scalar  T 
) const
inline

Return entropy contribution to the integral of Cp/T [J/kg/K].

Definition at line 94 of file perfectGasI.H.

References Foam::log(), Foam::constant::standard::Pstd, and Foam::R().

Here is the call graph for this function:

◆ Sv()

Foam::scalar Sv ( const scalar  p,
const scalar  T 
) const
inline

Return entropy contribution to the integral of Cv/T [J/kg/K].

Definition at line 101 of file perfectGasI.H.

References NotImplemented.

◆ psi()

Foam::scalar psi ( scalar  p,
scalar  T 
) const
inline

Return compressibility [s^2/m^2].

Definition at line 109 of file perfectGasI.H.

References Foam::R(), and Foam::T().

Here is the call graph for this function:

◆ Z()

Foam::scalar Z ( scalar  p,
scalar  T 
) const
inline

Return compression factor [].

Definition at line 116 of file perfectGasI.H.

◆ CpMCv()

Foam::scalar CpMCv ( scalar  p,
scalar  T 
) const
inline

Return (Cp - Cv) [J/(kg K].

Definition at line 123 of file perfectGasI.H.

References Foam::R().

Here is the call graph for this function:

◆ alphav()

Foam::scalar alphav ( const scalar  p,
const scalar  T 
) const
inline

Return volumetric coefficient of thermal expansion [1/T].

Definition at line 130 of file perfectGasI.H.

References Foam::T().

Here is the call graph for this function:

◆ write()

void write ( Ostream os) const

Write to Ostream.

Definition at line 41 of file perfectGas.C.

References Foam::vtkWriteOps::write().

Here is the call graph for this function:

◆ operator+=()

void operator+= ( const perfectGas< Specie > &  )
inline

Definition at line 139 of file perfectGasI.H.

◆ operator*=()

void operator*= ( const scalar  s)
inline

Definition at line 146 of file perfectGasI.H.

References s().

Here is the call graph for this function:

Friends And Related Function Documentation

◆ operator+

perfectGas operator+ ( const perfectGas< Specie > &  ,
const perfectGas< Specie > &   
)
friend

◆ operator*

perfectGas operator* ( const scalar  s,
const perfectGas< Specie > &   
)
friend

◆ operator==

perfectGas operator== ( const perfectGas< Specie > &  ,
const perfectGas< Specie > &   
)
friend

◆ operator

Ostream& operator ( Ostream ,
const perfectGas< Specie > &   
)
friend

Member Data Documentation

◆ incompressible

const bool incompressible = false
static

Is the equation of state is incompressible i.e. rho != f(p)

Definition at line 127 of file perfectGas.H.

◆ isochoric

const bool isochoric = false
static

Is the equation of state is isochoric i.e. rho = const.

Definition at line 130 of file perfectGas.H.


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