Public Member Functions

OpenTissue::sph::IdealGas< real_type > Class Template Reference

#include <sph_idealgas.h>

List of all members.

Public Member Functions

real_type mol (real_type P, real_type V, real_type T) const
real_type mol (real_type V, real_type molar_volume) const
real_type molekyles (real_type P, real_type V, real_type T) const
real_type mass (real_type mol, real_type molar_mass) const
real_type celsius (real_type K) const
real_type kelvin (real_type C) const
real_type bar (real_type Pa) const
real_type Pa (real_type bar) const
real_type kPa (real_type Pa) const
real_type molar_mass (real_type rho, real_type V, real_type mol) const

Detailed Description

template<typename real_type>
class OpenTissue::sph::IdealGas< real_type >

Implements the Ideal Gas. Govering equation is:

P V = n R T

Some numbers:

Molare volume of water: V_m = 0.000055 m^3 / mol Molar mass of water: m_m = 0.018 Kg/mol

Some units:

Newton: N = Kg m/s^2 (Unit of force mass-acceleration) Joule: J = Kg m^2 / s^2 = N m (The energy equivalent to dragging a one kilogram mass a distance of one meter). Pascal : Pa = N/m^2


Member Function Documentation

template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::bar ( real_type  Pa  )  const [inline]

Unit conversion Bar to Pascal

template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::celsius ( real_type  K  )  const [inline]

Temparature unit-conversion.

Parameters:
K temparture in Kelvin
Returns:
temparature in Celsius
template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::kelvin ( real_type  C  )  const [inline]

Temparature unit-conversion.

Parameters:
C temparture in Celsius
Returns:
temparature in Kelvin
template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::kPa ( real_type  Pa  )  const [inline]

Unit conversion Pa to kPa

template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::mass ( real_type  mol,
real_type  molar_mass 
) const [inline]

Compute Mass

Parameters:
mol The number of mol.
molar_mass The molar mass of the gas (Kg/mol).
Returns:
The total mass (Kg)
template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::mol ( real_type  P,
real_type  V,
real_type  T 
) const [inline]

Compute mol.

Solves

P V n = ------- R T

Parameters:
P Pressure (N/m^2)
V Volume (m^3)
T Temparature (K)
Returns:
The number of mol.

< Gas constant 8.314510 (J /mol K)

template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::mol ( real_type  V,
real_type  molar_volume 
) const [inline]

Compute mol.

Parameters:
V Volume (m^3)
Vm Molar volume (m^3/mol)
Returns:
The number of mol.
template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::molar_mass ( real_type  rho,
real_type  V,
real_type  mol 
) const [inline]

Compute molar mass.

Parameters:
rho Density (Kg/m^3)
V Volume (m^3)
mol mol

return The molar mass (Kg/mol)

template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::molekyles ( real_type  P,
real_type  V,
real_type  T 
) const [inline]

Compute Molekyles

Parameters:
P Pressure (N/m^2)
V Volume (m^3)
T Temparature (K)
Returns:
The number of molekyles.

< Avogadros number 6.0221367 10^23 1/mol, number of molecyles per mol.

template<typename real_type>
real_type OpenTissue::sph::IdealGas< real_type >::Pa ( real_type  bar  )  const [inline]

Unit conversion Bar to Pascal


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