VariableConversion_NS Module

Compute the pressure from the state variables

Compute the pressure time derivate from the state variables and its time derivatives

Compute the temperature from the state variables

GradientValuesForQ takes the solution (Q) values and returns the quantities of which the gradients will be taken.



Variables

Type Visibility Attributes Name Initial
procedure(getVelocityGradients_f), public, pointer :: getVelocityGradients

Interfaces

public interface getTemperatureGradient

  • private pure subroutine getTemperatureGradient_0D(Q, Q_x, Q_y, Q_z, U_x, U_y, U_z, nablaT)

    Arguments

    Type IntentOptional Attributes Name
    real(kind=RP), intent(in) :: Q(NCONS)
    real(kind=RP), intent(in) :: Q_x(NGRAD)
    real(kind=RP), intent(in) :: Q_y(NGRAD)
    real(kind=RP), intent(in) :: Q_z(NGRAD)
    real(kind=RP), intent(in) :: U_x(NDIM)
    real(kind=RP), intent(in) :: U_y(NDIM)
    real(kind=RP), intent(in) :: U_z(NDIM)
    real(kind=RP), intent(out) :: nablaT(NDIM)
  • private pure subroutine getTemperatureGradient_2D(N, Q, Q_x, Q_y, Q_z, U_x, U_y, U_z, nablaT)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: N(2)
    real(kind=RP), intent(in) :: Q(NCONS,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: Q_x(NGRAD,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: Q_y(NGRAD,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: Q_z(NGRAD,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: U_x(NDIM,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: U_y(NDIM,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: U_z(NDIM,0:N(1),0:N(2))
    real(kind=RP), intent(out) :: nablaT(NDIM,0:N(1),0:N(2))
  • private pure subroutine getTemperatureGradient_3D(N, Q, Q_x, Q_y, Q_z, U_x, U_y, U_z, nablaT)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: N(NDIM)
    real(kind=RP), intent(in) :: Q(NCONS,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(in) :: Q_x(NGRAD,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(in) :: Q_y(NGRAD,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(in) :: Q_z(NGRAD,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(out) :: U_x(NDIM,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(out) :: U_y(NDIM,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(out) :: U_z(NDIM,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(out) :: nablaT(NDIM,0:N(1),0:N(2),0:N(3))

public interface getConservativeGradients

  • private pure subroutine getConservativeGradients_0D(Q, U_x, U_y, U_z, nablaT, Q_x, Q_y, Q_z)

    Arguments

    Type IntentOptional Attributes Name
    real(kind=RP), intent(in) :: Q(NCONS)
    real(kind=RP), intent(in) :: U_x(NDIM)
    real(kind=RP), intent(in) :: U_y(NDIM)
    real(kind=RP), intent(in) :: U_z(NDIM)
    real(kind=RP), intent(in) :: nablaT(NDIM)
    real(kind=RP), intent(inout) :: Q_x(NGRAD)
    real(kind=RP), intent(inout) :: Q_y(NGRAD)
    real(kind=RP), intent(inout) :: Q_z(NGRAD)
  • private pure subroutine getConservativeGradients_2D(N, Q, U_x, U_y, U_z, nablaT, Q_x, Q_y, Q_z)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: N(2)
    real(kind=RP), intent(in) :: Q(NCONS,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: U_x(NDIM,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: U_y(NDIM,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: U_z(NDIM,0:N(1),0:N(2))
    real(kind=RP), intent(in) :: nablaT(NDIM,0:N(1),0:N(2))
    real(kind=RP), intent(inout) :: Q_x(NGRAD,0:N(1),0:N(2))
    real(kind=RP), intent(inout) :: Q_y(NGRAD,0:N(1),0:N(2))
    real(kind=RP), intent(inout) :: Q_z(NGRAD,0:N(1),0:N(2))
  • private pure subroutine getConservativeGradients_3D(N, Q, U_x, U_y, U_z, nablaT, Q_x, Q_y, Q_z)

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: N(3)
    real(kind=RP), intent(in) :: Q(NCONS,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(in) :: U_x(NDIM,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(in) :: U_y(NDIM,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(in) :: U_z(NDIM,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(in) :: nablaT(NDIM,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(inout) :: Q_x(NGRAD,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(inout) :: Q_y(NGRAD,0:N(1),0:N(2),0:N(3))
    real(kind=RP), intent(inout) :: Q_z(NGRAD,0:N(1),0:N(2),0:N(3))

Functions

public pure function Pressure(Q) result(P)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in), DIMENSION(NCONS) :: Q

Return Value real(kind=RP)

public pure function PressureDot(Q, QDot) result(PDot)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in), DIMENSION(NCONS) :: Q
real(kind=RP), intent(in), DIMENSION(NCONS) :: QDot

Return Value real(kind=RP)

public pure function Temperature(Q) result(T)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in), DIMENSION(NCONS) :: Q

Return Value real(kind=RP)

public pure function TemperatureDeriv(Q) result(dTdQ)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in) :: Q(NCONS)

Return Value real(kind=RP), (NCONS)

public pure function SutherlandsLaw(T) result(mu)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in) :: T

The temperature

Return Value real(kind=RP)

The diffusivity


Subroutines

public pure subroutine GetNSViscosity(phi, mu)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in) :: phi
real(kind=RP), intent(out) :: mu

public pure subroutine get_laminar_mu_kappa(Q, mu, kappa)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in) :: Q(NCONS)
real(kind=RP), intent(out) :: mu
real(kind=RP), intent(out) :: kappa

public pure subroutine NSGradientVariables_STATE(nEqn, nGrad, Q, U, rho_)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: nEqn
integer, intent(in) :: nGrad
real(kind=RP), intent(in) :: Q(nEqn)
real(kind=RP), intent(out) :: U(nGrad)
real(kind=RP), intent(in), optional :: rho_

public pure subroutine NSGradientVariables_ENTROPY(nEqn, nGrad, Q, U, rho_)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: nEqn
integer, intent(in) :: nGrad
real(kind=RP), intent(in) :: Q(nEqn)
real(kind=RP), intent(out) :: U(nGrad)
real(kind=RP), intent(in), optional :: rho_

public pure subroutine NSGradientVariables_ENERGY(nEqn, nGrad, Q, U, rho_)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: nEqn
integer, intent(in) :: nGrad
real(kind=RP), intent(in) :: Q(nEqn)
real(kind=RP), intent(out) :: U(nGrad)
real(kind=RP), intent(in), optional :: rho_

public pure subroutine getPrimitiveVariables(U, V)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in) :: U(NCONS)
real(kind=RP), intent(out) :: V(NPRIM)

public pure subroutine getEntropyVariables(U, p, invRho, S)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in) :: U(NCONS)
real(kind=RP), intent(in) :: p
real(kind=RP), intent(in) :: invRho
real(kind=RP), intent(out) :: S(NCONS)

public pure subroutine getRoeVariables(QL, QR, VL, VR, rho, u, v, w, V2, H, a)

Arguments

Type IntentOptional Attributes Name
real(kind=RP), intent(in) :: QL(NCONS)
real(kind=RP), intent(in) :: QR(NCONS)
real(kind=RP), intent(in) :: VL(NPRIM)
real(kind=RP), intent(in) :: VR(NPRIM)
real(kind=RP), intent(out) :: rho
real(kind=RP), intent(out) :: u
real(kind=RP), intent(out) :: v
real(kind=RP), intent(out) :: w
real(kind=RP), intent(out) :: V2
real(kind=RP), intent(out) :: H
real(kind=RP), intent(out) :: a

public subroutine set_GetVelocityGradients(grad_vars_)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: grad_vars_