solver_object Derived Type

type, public :: solver_object

type~~solver_object~~InheritsGraph type~solver_object solver_object type~error_object error_object type~error_object->type~solver_object error
Help


Solver object class.

Class designed to handle the general solver models parameters.

Inherited By

type~~solver_object~~InheritedByGraph type~solver_object solver_object type~simulation_object simulation_object type~solver_object->type~simulation_object solver
Help

Source Code


Components

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

Artifiical viscosity.

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

Chimera forcing coefficient.

character(len=:), public, allocatable:: convective_operator

Convective operator model: tvd, eno3, weno3(5-17)…

character(len=:), public, allocatable:: diffusive_operator

Diffusive operator model: centered2(4-10)…

type(error_object), public :: error

Errors handler.

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

Pseudo compressibility.

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

Tolerance on residuals value.

character(len=:), public, allocatable:: time_integrator

Time integrator model: euler, rk2(3-10), ab2(3-12)…

character(len=:), public, allocatable:: turbulence_model

Turbulence_model: k-e, k-w, less…


Type-Bound Procedures

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

Overload =.

procedure, public, pass(self) :: description

Return a pretty-formatted description of solver parameters.

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

    Return a pretty-formatted description of solver parameters.

    Arguments

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

    Solver object.

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

    Prefixing string.

    Return Value character(len=:), allocatable

    Description.

procedure, public, pass(self) :: destroy

Destroy solver.

  • private elemental subroutine destroy(self)

    Destroy solver.

    Arguments

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

    Solver object.

procedure, public, pass(self) :: initialize

Initialize solver.

  • private elemental subroutine initialize(self)

    Initialize solver.

    Arguments

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

    Solver object.

procedure, public, pass(self) :: load_from_file

Load from file.

  • private subroutine load_from_file(self, fini, go_on_fail)

    Load from file.

    Arguments

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

    Solver object.

    type(file_ini), intent(in) :: fini

    Simulation parameters ini file handler.

    logical, intent(in), optional :: go_on_fail

    Go on if load fails.

procedure, public, pass(self) :: save_into_file

Save into file.

  • private subroutine save_into_file(self, fini)

    Save into file.

    Arguments

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

    Solver object.

    type(file_ini), intent(inout) :: fini

    Simulation parameters ini file handler.

procedure, public, pass(lhs) :: solver_assign_solver

Operator =.

Source Code

type :: solver_object
   !< Solver object class.
   !<
   !< Class designed to handle the general solver models parameters.
   type(error_object)            :: error                         !< Errors handler.
   character(len=:), allocatable :: time_integrator               !< Time integrator model: euler, rk2(3-10), ab2(3-12)...
   character(len=:), allocatable :: convective_operator           !< Convective operator model: tvd, eno3, weno3(5-17)...
   character(len=:), allocatable :: diffusive_operator            !< Diffusive operator model: centered2(4-10)...
   character(len=:), allocatable :: turbulence_model              !< Turbulence_model: k-e, k-w, less...
   real(R8P)                     :: artificial_viscosity=0._R8P   !< Artifiical viscosity.
   real(R8P)                     :: residuals_tolerance=0._R8P    !< Tolerance on residuals value.
   real(R8P)                     :: pseudo_compressibility=0._R8P !< Pseudo compressibility.
   real(R8P)                     :: chimera_forcing=0._R8P        !< Chimera forcing coefficient.
   contains
      ! public methods
      procedure, pass(self) :: description    !< Return a pretty-formatted description of solver parameters.
      procedure, pass(self) :: destroy        !< Destroy solver.
      procedure, pass(self) :: initialize     !< Initialize solver.
      procedure, pass(self) :: load_from_file !< Load from file.
      procedure, pass(self) :: save_into_file !< Save into file.
      ! operators
      generic :: assignment(=) => solver_assign_solver !< Overload `=`.
      ! private methods
      procedure, pass(lhs) :: solver_assign_solver !< Operator `=`.
endtype solver_object