Scrambler  1
EOS Module Reference

Module for dealing with equation of state. More...

List of all members.

Data Types

interface  Cons_to_prim
interface  ConvertInternalToTotalEnergy
interface  ConvertTotalToInternalEnergy
interface  prim_to_cons

Public Member Functions

subroutine, public Protectq (Info, ip, caller, lStopProtect)
 Performs protection on Info object.
REAL(KIND=qPrec) function, public Press (q, kappa, chi, DPDQ)
 Calculate pressure and return optional variables if present.
REAL(KIND=qPREC) function Temperature (q)
REAL(KIND=qPREC) function, public GetInternalEnergy (q, p)
 Returns internal energy given pressure p and conservative vector q.
subroutine, public SetPress (q, p)
 Sets energy given pressure p and conservative vector q.
subroutine SetTemp (q, t)
 Sets energy given temperature t and conservative vector q.
REAL(KIND=qPrec) function, public SoundSpeed (q)
 Calculate sound speed.
REAL(KIND=qPrec) function, public PrimSoundSpeed (q)
 Calculate sound speed.
pure REAL(KIND=qPrec) function,
public 
InternalEnergy (q)
 Calculate internal kinetic energy.
REAL(KIND=qPrec) function, public PrimPress (q, kappa, chi, DPDQ)
 Calculate pressure and return optional variables if present.
subroutine Prim_To_Cons_info (Info, mB)
 Converts region of info structure from primitive form to conservative.
subroutine Cons_To_Prim_info (Info, mB)
 Converts region of info structure from primitive form to conservative.
subroutine Cons_To_Prim_q (q)
 Converts region of info structure from primitive form to conservative.
subroutine prim_To_cons_q (q)
 Converts region of info structure from primitive form to conservative.
subroutine rprim_to_cons_Iso (w, u)
 Convert primitive variables to conservative using an isothermal eos.
subroutine f_prim_Iso (w, f)
 Calculate fluxes using primitive array.
REAL(KIND=qPrec) function fast_speed_Iso (w)
 Calculate the fast wave speed for an isothermal gas.
logical function miniscule (x)
 Function to test if abs(x) is less then 1e-100.
subroutine rprim_to_cons_MHD_Iso (w, u)
 Routine to convert from primitive to conservative with an isothermal eos and magnetic fields.
subroutine f_prim_MHD_Iso (w, f)
 Routine to calculate flux given primitive fields for an isothermal eos with magnetic fields.
REAL(KIND=qPrec) function sound_speed (w)
 Calculate the sound_speed for an ideal EOS.
REAL(KIND=qPrec) function sound_speed_Roe (w)
 Calculate the sound speed for an ideal EOS.
subroutine prim_to_roe (w, r)
 Convert from primitive form to Roe form.
subroutine prim_to_roe_MHD (w, r)
 Convert from primitive form to Roe form with magnetic fields.
REAL(KIND=qPrec) function fast_speed (w)
 Calculate the fast speed for MHD.
REAL(KIND=qPrec) function fast_speed_Roe (w)
 Calculate the fast speed for MHD.
subroutine rprim_to_cons (w, u)
 Convert from primitive to conservative for ideal EOS.
subroutine rprim_to_cons_MHD (w, u)
 Convert from primitive to conservative for ideal EOS with magnetic fields.
subroutine F_prim (w, f)
 Calculate conservative fluxes for an ideal EOS.
subroutine F_prim_MHD (w, f)
 Calculate conservative fluxes for an ideal EOS with magnetic fields.
REAL(KIND=qPREC) function, public GetMaxSpeed (q)
 Calculate sound speed.
subroutine, public PrintQ (Info, q, tnow, i, j, k)
subroutine, public calc_eigens (request_eigens, prim, req_dim, lambda, n, l, r, i, j, k, level)
 Calculate eigen system.
logical function my_small (x, y)
 Logical function that determines whether a modified approximation should be used.
logical function really_small (x, y)
 Logical function that determines whether a modified approximation should be used.
ConvertTotalToInternalEnergy
subroutine ConvertTotalToInternalEnergy0D (q)
 Converts energy component of a single cell from total energy to internal energy.
subroutine ConvertTotalToInternalEnergy1D (q)
 Converts energy component of an array of cells from total energy to internal energy.
subroutine ConvertTotalToInternalEnergy2D (q)
 Converts energy component of an array of cells from total energy to internal energy.
subroutine ConvertTotalToInternalEnergy3D (q)
 Converts energy component of an array of cells from total energy to internal energy.
ConvertInternalToTotalEnergy
subroutine ConvertInternalToTotalEnergy0D (q)
 Converts energy component of a single cell from total energy to internal energy.
subroutine ConvertInternalToTotalEnergy1D (q)
 Converts energy component of an array of cells from total energy to internal energy.
subroutine ConvertInternalToTotalEnergy2D (q)
 Converts energy component of an array of cells from total energy to internal energy.
subroutine ConvertInternalToTotalEnergy3D (q)
 Converts energy component of an array of cells from total energy to internal energy.

Detailed Description

Module for dealing with equation of state.

Definition at line 32 of file EOS.f90.


Member Function/Subroutine Documentation

subroutine, public Protectq ( TYPE(InfoDef)  Info,
INTEGER, dimension(3,2)  ip,
CHARACTER(LEN=*)  caller,
LOGICAL, optional  lStopProtect 
)

Performs protection on Info object.

Parameters:
InfoInfo object

Definition at line 63 of file EOS.f90.

subroutine ConvertTotalToInternalEnergy0D ( REAL(KIND=qPREC), dimension(:)  q)

Converts energy component of a single cell from total energy to internal energy.

Parameters:
qconservative vector

Definition at line 263 of file EOS.f90.

subroutine ConvertTotalToInternalEnergy1D ( REAL(KIND=qPREC), dimension(:,:)  q)

Converts energy component of an array of cells from total energy to internal energy.

Parameters:
qconservative vector array

Definition at line 273 of file EOS.f90.

subroutine ConvertTotalToInternalEnergy2D ( REAL(KIND=qPREC), dimension(:,:,:)  q)

Converts energy component of an array of cells from total energy to internal energy.

Parameters:
qconservative vector 2D array

Definition at line 283 of file EOS.f90.

subroutine ConvertTotalToInternalEnergy3D ( REAL(KIND=qPREC), dimension(:,:,:,:)  q)

Converts energy component of an array of cells from total energy to internal energy.

Parameters:
qconservative vector 3D array

Definition at line 293 of file EOS.f90.

subroutine ConvertInternalToTotalEnergy0D ( REAL(KIND=qPREC), dimension(:)  q)

Converts energy component of a single cell from total energy to internal energy.

Parameters:
qconservative vector

Definition at line 309 of file EOS.f90.

subroutine ConvertInternalToTotalEnergy1D ( REAL(KIND=qPREC), dimension(:,:)  q)

Converts energy component of an array of cells from total energy to internal energy.

Parameters:
qconservative vector array

Definition at line 319 of file EOS.f90.

subroutine ConvertInternalToTotalEnergy2D ( REAL(KIND=qPREC), dimension(:,:,:)  q)

Converts energy component of an array of cells from total energy to internal energy.

Parameters:
qconservative vector 2D array

Definition at line 329 of file EOS.f90.

subroutine ConvertInternalToTotalEnergy3D ( REAL(KIND=qPREC), dimension(:,:,:,:)  q)

Converts energy component of an array of cells from total energy to internal energy.

Parameters:
qconservative vector 3D array

Definition at line 339 of file EOS.f90.

REAL (KIND=qPrec) function, public Press ( REAL (KIND=qPrec), dimension(:), intent(in)  q,
REAL (KIND=qPrec), intent(out), optional  kappa,
REAL (KIND=qPrec), intent(out), optional  chi,
REAL (KIND=qPrec), dimension(:), intent(out), optional  DPDQ 
)

Calculate pressure and return optional variables if present.

Parameters:
qfluid variables (conservative form)
kappa[dP/drho]Eth
chi[dP/dEth]rho
DPDQDerivative of pressure wrt conserved variables

Definition at line 355 of file EOS.f90.

REAL(KIND=qPREC) function Temperature ( REAL(KIND=qPREC), dimension(:)  q)

Definition at line 403 of file EOS.f90.

REAL(KIND=qPREC) function, public GetInternalEnergy ( REAL(KIND=qPREC), dimension(:)  q,
REAL(KIND=qPREC)  p 
)

Returns internal energy given pressure p and conservative vector q.

Definition at line 410 of file EOS.f90.

subroutine, public SetPress ( REAL(KIND=qPREC), dimension(:)  q,
REAL(KIND=qPREC)  p 
)

Sets energy given pressure p and conservative vector q.

Definition at line 426 of file EOS.f90.

subroutine SetTemp ( REAL(KIND=qPREC), dimension(:)  q,
REAL(KIND=qPREC)  t 
)

Sets energy given temperature t and conservative vector q.

Definition at line 436 of file EOS.f90.

REAL (KIND=qPrec) function, public SoundSpeed ( REAL (KIND=qPrec), dimension(:), intent(in)  q)

Calculate sound speed.

Parameters:
qfluid variables (conservative form)

Definition at line 446 of file EOS.f90.

REAL (KIND=qPrec) function, public PrimSoundSpeed ( REAL (KIND=qPrec), dimension(:), intent(in)  q)

Calculate sound speed.

Parameters:
qfluid variables (conservative form)

Definition at line 467 of file EOS.f90.

pure REAL (KIND=qPrec) function, public InternalEnergy ( REAL (KIND=qPrec), dimension(:), intent(in)  q)

Calculate internal kinetic energy.

Parameters:
qfluid variables (conservative form)

Definition at line 486 of file EOS.f90.

REAL (KIND=qPrec) function, public PrimPress ( REAL (KIND=qPrec), dimension(:), intent(in)  q,
REAL (KIND=qPrec), intent(out), optional  kappa,
REAL (KIND=qPrec), intent(out), optional  chi,
REAL (KIND=qPrec), dimension(:), intent(out), optional  DPDQ 
)

Calculate pressure and return optional variables if present.

Parameters:
qfluid variables (primitive form - iE is internal energy not pressure)
kappa[dP/drho]Eth
chi[dP/dEth]rho
DPDQDerivative of pressure wrt conserved variables

Definition at line 506 of file EOS.f90.

subroutine Prim_To_Cons_info ( TYPE(InfoDef)  Info,
INTEGER, dimension(:,:)  mB 
)

Converts region of info structure from primitive form to conservative.

Parameters:
InfoInfo structure
mBindices defining region

Definition at line 573 of file EOS.f90.

subroutine Cons_To_Prim_info ( TYPE(InfoDef)  Info,
INTEGER, dimension(:,:)  mB 
)

Converts region of info structure from primitive form to conservative.

Parameters:
InfoInfo structure
mBindices defining region

Definition at line 597 of file EOS.f90.

subroutine Cons_To_Prim_q ( REAL(KIND=qpREC), dimension(:)  q)

Converts region of info structure from primitive form to conservative.

Parameters:
InfoInfo structure
mBindices defining region

Definition at line 619 of file EOS.f90.

subroutine prim_To_cons_q ( REAL(KIND=qpREC), dimension(:)  q)

Converts region of info structure from primitive form to conservative.

Parameters:
InfoInfo structure
mBindices defining region

Definition at line 632 of file EOS.f90.

subroutine rprim_to_cons_Iso ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  u 
)

Convert primitive variables to conservative using an isothermal eos.

Parameters:
wprimitive array
uconservative array

Definition at line 646 of file EOS.f90.

subroutine f_prim_Iso ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  f 
)

Calculate fluxes using primitive array.

Parameters:
wprimitive array
fconservative fluxes

Definition at line 655 of file EOS.f90.

REAL(KIND=qPrec) function fast_speed_Iso ( REAL(KIND=qPrec), dimension(:)  w)

Calculate the fast wave speed for an isothermal gas.

Parameters:
wprimitive array

Definition at line 669 of file EOS.f90.

logical function miniscule ( REAL(8)  x)

Function to test if abs(x) is less then 1e-100.

Definition at line 679 of file EOS.f90.

subroutine rprim_to_cons_MHD_Iso ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  u 
)

Routine to convert from primitive to conservative with an isothermal eos and magnetic fields.

Parameters:
wprimitive array
uconservative array

Definition at line 688 of file EOS.f90.

subroutine f_prim_MHD_Iso ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  f 
)

Routine to calculate flux given primitive fields for an isothermal eos with magnetic fields.

Parameters:
wprimitive array
fconservative fluxes

Definition at line 697 of file EOS.f90.

REAL(KIND=qPrec) function sound_speed ( REAL(KIND=qPrec), dimension(:)  w)

Calculate the sound_speed for an ideal EOS.

Parameters:
wprimitive array

Definition at line 717 of file EOS.f90.

REAL(KIND=qPrec) function sound_speed_Roe ( REAL(KIND=qPrec), dimension(:)  w)

Calculate the sound speed for an ideal EOS.

Parameters:
wRoe form of primitive variables

Definition at line 725 of file EOS.f90.

subroutine prim_to_roe ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  r 
)

Convert from primitive form to Roe form.

Parameters:
wprimitive array
rRoe array

Definition at line 734 of file EOS.f90.

subroutine prim_to_roe_MHD ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  r 
)

Convert from primitive form to Roe form with magnetic fields.

Parameters:
wprimitive array
rRoe array

Definition at line 743 of file EOS.f90.

REAL(KIND=qPrec) function fast_speed ( REAL(KIND=qPrec), dimension(:)  w)

Calculate the fast speed for MHD.

Parameters:
wprimitive array

Definition at line 751 of file EOS.f90.

REAL(KIND=qPrec) function fast_speed_Roe ( REAL(KIND=qPrec), dimension(:)  w)

Calculate the fast speed for MHD.

Parameters:
wRoe array

Definition at line 761 of file EOS.f90.

subroutine rprim_to_cons ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  u 
)

Convert from primitive to conservative for ideal EOS.

Parameters:
wprimitive array
uconservative array

Definition at line 773 of file EOS.f90.

subroutine rprim_to_cons_MHD ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  u 
)

Convert from primitive to conservative for ideal EOS with magnetic fields.

Parameters:
wprimitive array
uconservative array

Definition at line 783 of file EOS.f90.

subroutine F_prim ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  f 
)

Calculate conservative fluxes for an ideal EOS.

Parameters:
wprimitive array
fconservative fluxes

Definition at line 793 of file EOS.f90.

subroutine F_prim_MHD ( REAL(KIND=qPrec), dimension(:)  w,
REAL(KIND=qPrec), dimension(:)  f 
)

Calculate conservative fluxes for an ideal EOS with magnetic fields.

Parameters:
wprimitive array
fconservative fluxes

Definition at line 809 of file EOS.f90.

REAL (KIND=qPREC) function, public GetMaxSpeed ( REAL (KIND=qPrec), dimension(:,:,:,:), intent(in)  q)

Calculate sound speed.

Parameters:
qfluid variables (conservative form)

Definition at line 832 of file EOS.f90.

subroutine, public PrintQ ( TYPE(InfoDef)  Info,
REAL(KIND=qPREC), dimension(:)  q,
REAL(KIND=qPREC)  tnow,
INTEGER, optional  i,
INTEGER, optional  j,
INTEGER, optional  k 
)

Definition at line 855 of file EOS.f90.

subroutine, public calc_eigens ( LOGICAL  request_eigens,
REAL(KIND=qPrec), dimension(:)  prim,
LOGICAL, dimension(:)  req_dim,
REAL(KIND=qPrec), dimension(:,:)  lambda,
INTEGER, dimension(:)  n,
REAL(KIND=qPrec), dimension(:,:,:)  l,
REAL(KIND=qPrec), dimension(:,:,:)  r,
INTEGER  i,
INTEGER  j,
INTEGER  k,
INTEGER  level 
)

Calculate eigen system.

Parameters:
request_eigensLogical flag that returns whether or not calc_eigens was successfull
primfluid variables
req_dimLogical flag that specifies which dimensions to calculate eigen system for
lambdawave speeds
nnumber of independent waves for each system
lleft eigenvectors
rright eigenvectors
icell x-index
jcell y-index
kcell z-index

Definition at line 885 of file EOS.f90.

logical function my_small ( REAL(8)  x,
REAL(8)  y 
)

Logical function that determines whether a modified approximation should be used.

Parameters:
xvalue
yscaling value

Definition at line 1150 of file EOS.f90.

logical function really_small ( REAL(8)  x,
REAL(8)  y 
)

Logical function that determines whether a modified approximation should be used.

Parameters:
xvalue
yscaling value

Definition at line 1160 of file EOS.f90.


The documentation for this module was generated from the following file:
 All Classes Files Functions Variables