integrator_multistage_object Derived Type

type, public, abstract, extends(integrator_object) :: integrator_multistage_object

type~~integrator_multistage_object~~InheritsGraph type~integrator_multistage_object integrator_multistage_object type~integrand_object integrand_object type~integrand_object->type~integrator_multistage_object buffer, stage type~integrator_object integrator_object type~integrator_object->type~integrator_multistage_object
Help


Abstract type of FOODIE ODE integrators of the multistage family.

Inherited By

type~~integrator_multistage_object~~InheritedByGraph type~integrator_multistage_object integrator_multistage_object type~integrator_runge_kutta_lssp integrator_runge_kutta_lssp type~integrator_multistage_object->type~integrator_runge_kutta_lssp type~integrator_euler_explicit integrator_euler_explicit type~integrator_multistage_object->type~integrator_euler_explicit type~integrator_runge_kutta_ssp integrator_runge_kutta_ssp type~integrator_multistage_object->type~integrator_runge_kutta_ssp type~integrator_runge_kutta_emd integrator_runge_kutta_emd type~integrator_multistage_object->type~integrator_runge_kutta_emd type~integrator_runge_kutta_ls integrator_runge_kutta_ls type~integrator_multistage_object->type~integrator_runge_kutta_ls
Help

Components

TypeVisibility AttributesNameInitial
class(integrand_object), public, allocatable:: buffer

Buffer used for fast integration.

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

Informative description of the integrator.

integer(kind=I_P), public :: error =0

Error status code.

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

Error message, hopefully meaningful.

integer(kind=I_P), public :: registers

Number of registers used for stages.

class(integrand_object), public, allocatable:: stage(:)

Stages.

integer(kind=I_P), public :: stages

Number of stages.


Type-Bound Procedures

procedure, public, pass(self) :: allocate_integrand_members

Allocate integrand members.

procedure, public, pass(lhs) :: assign_abstract

Assign ony members of abstract integrator_object type.

procedure, public, pass(lhs) :: assign_multistage

Assign members of integrator_multistage_object and parents.

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

Overload =.

procedure, public, pass(self) :: check_error

Check for error occurrencies.

  • private subroutine check_error(self, is_severe)

    Check for error occurencies.

    Arguments

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

    Integrator.

    logical, intent(in), optional :: is_severe

    Flag to activate severe faliure, namely errors trigger a stop.

procedure(class_name_interface), public, deferred, pass(self) :: class_name

Return the class name of schemes.

  • pure function class_name_interface(self) result(class_name) Prototype

    Return the class name of schemes.

    Arguments

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

    Integrator.

    Return Value character(len=99)

    Class name.

procedure, public, pass(self) :: description

Return informative integrator description.

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

    Return informative integrator description.

    Arguments

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

    Integrator.

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

    Prefixing string.

    Return Value character(len=:), allocatable

    Description.

procedure, public, pass(self) :: destroy_abstract

Destroy only members of abstract integrator_object type.

procedure, public, pass(self) :: destroy_multistage

Destroy the integrator.

procedure(has_fast_mode_interface), public, deferred, pass(self) :: has_fast_mode

Return .true. if the integrator class has fast mode integrate.

  • elemental function has_fast_mode_interface(self) result(has_fast_mode) Prototype

    Return .true. if the integrator class has fast mode integrate.

    Arguments

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

    Integrator.

    Return Value logical

    Inquire result.

procedure(assignment_interface), public, deferred, pass(lhs) :: integr_assign_integr

Operator =.

procedure(integrate_interface), public, deferred, pass(self) :: integrate

Integrate integrand field.

  • subroutine integrate_interface(self, U, Dt, t, new_Dt) Prototype

    Integrate integrand field.

    Arguments

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

    Integrator.

    class(integrand_object), intent(inout) :: U

    Integrand.

    real(kind=R_P), intent(in) :: Dt

    Time step.

    real(kind=R_P), intent(in) :: t

    Time.

    real(kind=R_P), intent(out), optional :: new_Dt

    New adapted time step.

procedure(integrate_fast_interface), public, deferred, pass(self) :: integrate_fast

Integrate integrand field, fast mode.

  • subroutine integrate_fast_interface(self, U, Dt, t, new_Dt) Prototype

    Integrate integrand field, fast mode.

    Arguments

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

    Integrator.

    class(integrand_object), intent(inout) :: U

    Field to be integrated.

    real(kind=R_P), intent(in) :: Dt

    Time step.

    real(kind=R_P), intent(in) :: t

    Time.

    real(kind=R_P), intent(out), optional :: new_Dt

    New adapted time step.

procedure, public, pass(self) :: is_multistage

Return .true. for multistage integrator.

  • private elemental function is_multistage(self)

    Return .true. for multistage integrator.

    Arguments

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

    Integrator.

    Return Value logical

    Inquire result.

procedure, public, pass(self) :: is_multistep

Return .true. for multistep integrator.

  • private elemental function is_multistep(self)

    Return .true. for multistage integrator.

    Arguments

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

    Integrator.

    Return Value logical

    Inquire result.

procedure(is_supported_interface), public, deferred, pass(self) :: is_supported

Return .true. if the integrator class support the given scheme.

  • elemental function is_supported_interface(self, scheme) result(is_supported) Prototype

    Return .true. if the integrator class support the given scheme.

    Arguments

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

    Integrator.

    character(len=*), intent(in) :: scheme

    Queried scheme.

    Return Value logical

    Inquire result.

procedure, public, pass(self) :: stages_number

Return number of stages used.

  • private elemental function stages_number(self)

    Return number of stages used.

    Arguments

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

    Integrator.

    Return Value integer(kind=I_P)

    Number of stages used.

procedure, public, pass(self) :: steps_number

Return number of steps used.

  • private elemental function steps_number(self)

    Return number of steps used.

    Arguments

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

    Integrator.

    Return Value integer(kind=I_P)

    Number of steps used.

procedure(supported_schemes_interface), public, deferred, pass(self) :: supported_schemes

Return the list of supported schemes.

  • pure function supported_schemes_interface(self) result(schemes) Prototype

    Return the list of supported schemes.

    Arguments

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

    Integrator.

    Return Value character(len=99), allocatable, (:)

    Queried scheme.

procedure, public, pass(self) :: trigger_error

Trigger an error.

  • private subroutine trigger_error(self, error, error_message, is_severe)

    Check for error occurencies.

    Arguments

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

    Integrator.

    integer(kind=I_P), intent(in) :: error

    Error status code.

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

    Error message, hopefully meaningful.

    logical, intent(in), optional :: is_severe

    Flag to activate severe faliure, namely errors trigger a stop.

Source Code

type, extends(integrator_object), abstract :: integrator_multistage_object
   !< Abstract type of FOODIE ODE integrators of the multistage family.
   integer(I_P)                         :: registers !< Number of registers used for stages.
   integer(I_P)                         :: stages    !< Number of stages.
   class(integrand_object), allocatable :: stage(:)  !< Stages.
   class(integrand_object), allocatable :: buffer    !< Buffer used for fast integration.
   contains
      ! deferred methods
      procedure(integrate_interface),      pass(self), deferred :: integrate      !< Integrate integrand field.
      procedure(integrate_fast_interface), pass(self), deferred :: integrate_fast !< Integrate integrand field, fast mode.
      ! implemented deferred methods of parent
      procedure, pass(self) :: is_multistage !< Return .true. for multistage integrator.
      procedure, pass(self) :: is_multistep  !< Return .true. for multistep integrator.
      procedure, pass(self) :: stages_number !< Return number of stages used.
      procedure, pass(self) :: steps_number  !< Return number of steps used.
      ! public methods
      procedure, pass(self) :: allocate_integrand_members !< Allocate integrand members.
      procedure, pass(lhs)  :: assign_multistage          !< Assign members of [[integrator_multistage_object]] and parents.
      procedure, pass(self) :: destroy_multistage         !< Destroy the integrator.
endtype integrator_multistage_object