riemann_pattern_compressible_object Derived Type

type, public, abstract, extends(riemann_pattern_object) :: riemann_pattern_compressible_object

type~~riemann_pattern_compressible_object~~InheritsGraph type~riemann_pattern_compressible_object riemann_pattern_compressible_object type~eos_compressible eos_compressible type~eos_compressible->type~riemann_pattern_compressible_object eos_1, eos_4 type~eos_object eos_object type~eos_object->type~eos_compressible type~riemann_pattern_object riemann_pattern_object type~riemann_pattern_object->type~riemann_pattern_compressible_object
Help


Compressible Riemann (states) pattern object class.

This pattern is generated after the breaking of the initial discontinuity of the Riemann Problem. For the ideal compressible fluid the pattern generated is constituted by 3-waves: 2 genuinely non-linear acoustic waves and 1 linear-degener contact discontinuity.

   t ^                                .
     |     S1 _       S2 _            .      _ S=u23   _ S3       _ S4
     |       |\_        |\_           .      /|      __/|       __/|
     |          \__        \_     U2  .     /  U3  _/       ___/
     |             \___      \_       .    /    __/     ___/
     |                 \____   \_     .   /   _/    ___/
     |                      \___ \_   .  / __/  ___/
     |          UL=U1           \__\_ . /_/____/          UR=U4
     |                              \\.///
  ---+--------------------------------o--------------------------------->
     |                                xo                                x

Inherited By

type~~riemann_pattern_compressible_object~~InheritedByGraph type~riemann_pattern_compressible_object riemann_pattern_compressible_object type~riemann_pattern_compressible_pvl riemann_pattern_compressible_pvl type~riemann_pattern_compressible_object->type~riemann_pattern_compressible_pvl
Help

Components

TypeVisibility AttributesNameInitial
real(kind=R8P), public :: a_1 =0._R8P

Speed of sound of state 1.

real(kind=R8P), public :: a_2 =0._R8P

Speed of sound of state 2.

real(kind=R8P), public :: a_3 =0._R8P

Speed of sound of state 3.

real(kind=R8P), public :: a_4 =0._R8P

Speed of sound of state 4.

type(eos_compressible), public :: eos_1

Equation of state 1.

type(eos_compressible), public :: eos_4

Equation of state 4.

real(kind=R8P), public :: p23 =0._R8P

Pressure of intermediate states.

real(kind=R8P), public :: p_1 =0._R8P

Pressure of state 1.

real(kind=R8P), public :: p_4 =0._R8P

Pressure of state 4.

real(kind=R8P), public :: r_1 =0._R8P

Density of state 1.

real(kind=R8P), public :: r_2 =0._R8P

Density of state 2.

real(kind=R8P), public :: r_3 =0._R8P

Density of state 3.

real(kind=R8P), public :: r_4 =0._R8P

Density of state 4.

real(kind=R8P), public :: s_1 =0._R8P

Left-front of left wave.

real(kind=R8P), public :: s_2 =0._R8P

Right-front of left wave.

real(kind=R8P), public :: s_3 =0._R8P

Left-front of right wave.

real(kind=R8P), public :: s_4 =0._R8P

Right-front of right wave.

real(kind=R8P), public :: u23 =0._R8P

Velocity (normal) of intermediate states.

real(kind=R8P), public :: u_1 =0._R8P

Velocity (normal) of state 1.

real(kind=R8P), public :: u_4 =0._R8P

Velocity (normal) of state 4.


Type-Bound Procedures

generic, public :: assignment(=) => rpat_assign_rpat

Overload =.

procedure, public, pass(self) :: compute_fluxes

Compute fluxes at interface x=xo.

  • private elemental subroutine compute_fluxes(self, normal, fluxes)

    Compute fluxes at initial discontinuity interface.

    Arguments

    Type IntentOptional AttributesName
    class(riemann_pattern_compressible_object), intent(in) :: self

    Riemann (states) pattern solution.

    type(vector), intent(in) :: normal

    Normal (versor) of face where fluxes are given.

    class(conservative_object), intent(inout) :: fluxes

    Fluxes at initial discontinuity interface.

procedure, public, pass(self) :: compute_states23_from_u23

Compute interstates 2 and 3 given veloctiy S=u23.

  • private elemental subroutine compute_states23_from_u23(self, p_2, p_3)

    Compute interstates 2 and 3 given (an approximation of) veloctiy S=u23.

    Arguments

    Type IntentOptional AttributesName
    class(riemann_pattern_compressible_object), intent(inout) :: self

    Riemann (states) pattern solution.

    real(kind=R8P), intent(out) :: p_2

    Pressure of state 2.

    real(kind=R8P), intent(out) :: p_3

    Pressure of state 3.

procedure(compute_waves_interface), public, deferred, pass(self) :: compute_waves

Compute waves speed.

  • pure subroutine compute_waves_interface(self) Prototype

    Compute fluxes at initial discontinuity interface.

    Arguments

    Type IntentOptional AttributesName
    class(riemann_pattern_object), intent(inout) :: self

    Riemann (states) pattern solution.

procedure, public, pass(self) :: description

Return pretty-printed object description.

  • private pure function description(self, prefix) result(desc)

    Return a pretty-formatted object description.

    Arguments

    Type IntentOptional AttributesName
    class(riemann_pattern_compressible_object), intent(in) :: self

    Riemann pattern.

    character(len=*), intent(in), optional :: prefix

    Prefixing string.

    Return Value character(len=:), allocatable

    Description.

procedure, public, pass(self) :: initialize

Initialize pattern with left and right states.

  • private elemental subroutine initialize(self, eos_left, state_left, eos_right, state_right, normal)

    Initialize pattern with left and right states.

    Arguments

    Type IntentOptional AttributesName
    class(riemann_pattern_compressible_object), intent(inout) :: self

    Riemann (states) pattern solution.

    class(eos_object), intent(in) :: eos_left

    Equation of state for left state.

    class(conservative_object), intent(in) :: state_left

    Left Riemann state.

    class(eos_object), intent(in) :: eos_right

    Equation of state for right state.

    class(conservative_object), intent(in) :: state_right

    Right Riemann state.

    type(vector), intent(in) :: normal

    Normal (versor) of face where fluxes are given.

procedure, public, pass(lhs) :: rpat_assign_rpat

Operator =.

Source Code

type, extends(riemann_pattern_object), abstract :: riemann_pattern_compressible_object
   !< Compressible Riemann (states) pattern object class.
   !<
   !< This pattern is generated after the breaking of the initial discontinuity of the Riemann Problem. For the
   !< ideal compressible fluid the pattern generated is constituted by 3-waves: 2 genuinely non-linear acoustic
   !< waves and 1 linear-degener contact discontinuity.
   !<
   !<```
   !<   t ^                                .
   !<     |     S1 _       S2 _            .      _ S=u23   _ S3       _ S4
   !<     |       |\_        |\_           .      /|      __/|       __/|
   !<     |          \__        \_     U2  .     /  U3  _/       ___/
   !<     |             \___      \_       .    /    __/     ___/
   !<     |                 \____   \_     .   /   _/    ___/
   !<     |                      \___ \_   .  / __/  ___/
   !<     |          UL=U1           \__\_ . /_/____/          UR=U4
   !<     |                              \\.///
   !<  ---+--------------------------------o--------------------------------->
   !<     |                                xo                                x
   !<```
   type(eos_compressible) :: eos_1      !< Equation of state 1.
   real(R8P)              :: r_1=0._R8P !< Density of state 1.
   real(R8P)              :: u_1=0._R8P !< Velocity (normal) of state 1.
   real(R8P)              :: p_1=0._R8P !< Pressure of state 1.
   real(R8P)              :: a_1=0._R8P !< Speed of sound of state 1.
   type(eos_compressible) :: eos_4      !< Equation of state 4.
   real(R8P)              :: r_4=0._R8P !< Density of state 4.
   real(R8P)              :: u_4=0._R8P !< Velocity (normal) of state 4.
   real(R8P)              :: p_4=0._R8P !< Pressure of state 4.
   real(R8P)              :: a_4=0._R8P !< Speed of sound of state 4.
   real(R8P)              :: u23=0._R8P !< Velocity (normal) of intermediate states.
   real(R8P)              :: p23=0._R8P !< Pressure of intermediate states.
   real(R8P)              :: r_2=0._R8P !< Density of state 2.
   real(R8P)              :: a_2=0._R8P !< Speed of sound of state 2.
   real(R8P)              :: r_3=0._R8P !< Density of state 3.
   real(R8P)              :: a_3=0._R8P !< Speed of sound of state 3.
   real(R8P)              :: s_1=0._R8P !< Left-front of left wave.
   real(R8P)              :: s_2=0._R8P !< Right-front of left wave.
   real(R8P)              :: s_3=0._R8P !< Left-front of right wave.
   real(R8P)              :: s_4=0._R8P !< Right-front of right wave.
   contains
      ! deferred methods
      procedure, pass(self) :: compute_fluxes   !< Compute fluxes at interface `x=xo`.
      procedure, pass(self) :: description      !< Return pretty-printed object description.
      procedure, pass(self) :: initialize       !< Initialize pattern with left and right states.
      procedure, pass(lhs)  :: rpat_assign_rpat !< Operator `=`.
      ! public methods
      procedure, pass(self) :: compute_states23_from_u23 !< Compute interstates 2 and 3 given veloctiy `S=u23`.
endtype riemann_pattern_compressible_object