rk5 Derived Type

type, public, extends(integrator) :: rk5

A 5th order continuous explicit Runge-Kutta ODE integrator.


Inherits

type~~rk5~~InheritsGraph type~rk5 rk5 type~integrator integrator type~rk5->type~integrator type~equation_pointer equation_pointer type~integrator->type~equation_pointer eqs type~equation equation type~equation_pointer->type~equation p

Contents

Source Code

rk5

Components

TypeVisibility AttributesNameInitial
integer(kind=ip), public :: nequations

The number of equations to integrate.

class(equation_pointer), public, dimension(:), allocatable:: eqs

A 1d array of equation pointers. Will be of length nequations.

integer(kind=ip), public :: ntmp =7

7 levels of temporary storage are required.


Type-Bound Procedures

procedure, public :: ntemp => rk5_ntemp

Routine to provide information about temporary storage levels is provided by rk5_ntemp.

  • interface

    public module function rk5_ntemp(this) result(ntemp)

    Routine that reports how many temporary storage levels are needed.

    Arguments

    Type IntentOptional AttributesName
    class(rk5), intent(in) :: this

    The routine is called on this object.

    Return Value integer(kind=ip)

    The return value is the number of required temorary storage levels.

procedure, public :: init => rk5_init

Initialization routine is provided by rk5_init.

  • interface

    public module subroutine rk5_init(this, eqs)

    Routine that initializes the integrator.

    Arguments

    Type IntentOptional AttributesName
    class(rk5), intent(inout) :: this

    The routine is called on this object.

    type(equation_pointer), intent(in), dimension(:):: eqs

    A 1d-array of pointers to equations that will be integrated.

procedure, public :: step => rk5_step

Stepping routine is provided by rk5_step.

  • interface

    public module subroutine rk5_step(this)

    Routine that takes a time step.

    Arguments

    Type IntentOptional AttributesName
    class(rk5), intent(inout) :: this

    The routine is called on this object.

procedure, public :: shutdown => rk5_shutdown

Shut down routine is provided by rk5_shutdown.

  • interface

    public module subroutine rk5_shutdown(this)

    Routine that shuts downs the integrator.

    Arguments

    Type IntentOptional AttributesName
    class(rk5), intent(inout) :: this

    The routine is called on this object.

Source Code

  type, extends(integrator) :: rk5
  !! A 5th order continuous explicit Runge-Kutta ODE integrator.
    integer(ip) :: ntmp = 7
    !! 7 levels of temporary storage are required.
  contains
    procedure :: ntemp => rk5_ntemp
    !! Routine to provide information about temporary storage levels is
    !! provided by [[rk5_ntemp]].
    procedure :: init => rk5_init
    !! Initialization routine is provided by [[rk5_init]].
    procedure :: step => rk5_step
    !! Stepping routine is provided by [[rk5_step]].
    procedure :: shutdown => rk5_shutdown
    !! Shut down routine is provided by [[rk5_shutdown]].
  end type rk5