solver_interfaces Module

Defines the three abstract interfaces used for the reconstruction and flux dispatch pointers that live in @p solver_state_t:

reconstructor_iface — satisfied by every reconstruction subroutine flux_splitter_iface — satisfied by every FVS flux-splitting subroutine fds_iface — satisfied by every FDS approximate Riemann solver

Also exports two compile-time upper bounds used by the solver core:

max_stencil_width — widest reconstruction stencil width supported. max_coupling_radius — widest residual/Jacobian coupling radius.

spatial_discretization uses @p max_stencil_width to size local stencil arrays as fixed-size rather than allocatable. time_integration uses

This module is a dependency-free leaf: it imports nothing except the working-precision kind. Placing the interfaces here breaks the circular dependency that would otherwise arise from storing proc-pointer components in solver_state_t while reconstruction and euler_physics modules themselves use solver_state. Abstract interface satisfied by every reconstruction subroutine. Abstract interface satisfied by every cell-level flux-splitting procedure. @p gam is passed explicitly so that implementations are free of global state. Abstract interface for fused FVS routines that return F^+ and F^- in one call. Extracts primitives once, avoiding the redundant call overhead of two separate flux_splitter_iface calls per cell. Abstract interface satisfied by every FDS approximate Riemann solver. Takes separate left and right conserved states and returns the face flux. @p gam is passed explicitly so that implementations are free of global state.


Uses


Variables

Type Visibility Attributes Name Initial
integer, public, parameter :: max_stencil_width = 11

Maximum reconstruction stencil width across all supported schemes. WENO11-JS uses the widest stencil at 11 points.

integer, public, parameter :: max_coupling_radius = 6

Maximum cell-to-cell coupling radius across all supported schemes. WENO11-JS yields the widest residual/Jacobian dependence radius at 6 cells.


Abstract Interfaces

abstract interface

  • public pure subroutine reconstructor_iface(f_stencil, f_hat)

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in) :: f_stencil(:,:)
    real(kind=wp), intent(out) :: f_hat(:)

abstract interface

  • public pure subroutine flux_splitter_iface(q, flux, sign, gam)

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in) :: q(:)
    real(kind=wp), intent(out) :: flux(:)
    integer, intent(in) :: sign
    real(kind=wp), intent(in) :: gam

abstract interface

  • public pure subroutine flux_splitter_both_iface(q, fp, fm, gam)

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in) :: q(:)
    real(kind=wp), intent(out) :: fp(:)
    real(kind=wp), intent(out) :: fm(:)
    real(kind=wp), intent(in) :: gam

abstract interface

  • public pure subroutine fds_iface(q_L, q_R, flux, gam)

    Arguments

    Type IntentOptional Attributes Name
    real(kind=wp), intent(in) :: q_L(:)
    real(kind=wp), intent(in) :: q_R(:)
    real(kind=wp), intent(out) :: flux(:)
    real(kind=wp), intent(in) :: gam