simple_derivation_class Module

Houses simple derivation class handling derivations of the form constproduct(variables*powers)


Used by


Interfaces

interface

  • private module function calculateSimple(this, inputArray, indices) result(output)

    Arguments

    Type IntentOptional Attributes Name
    class(SimpleDerivation), intent(inout) :: this
    type(RealArray), intent(in), dimension(:) :: inputArray
    integer(kind=ik), intent(in), dimension(:) :: indices

    Return Value real(kind=rk), allocatable, dimension(:)

interface

  • private module subroutine initSimpleDeriv(this, varPowers, multConst)

    Initialize simple derivation object

    Arguments

    Type IntentOptional Attributes Name
    class(SimpleDerivation), intent(inout) :: this
    real(kind=rk), intent(in), dimension(:) :: varPowers
    real(kind=rk), intent(in), optional :: multConst

Derived Types

type, public, extends(Derivation) ::  SimpleDerivation

Simple derivation object assuming all variables are confroming. Just multiplies the input array entries and raises them to set powers. Optionally multiplies the result with a constant.

Components

Type Visibility Attributes Name Initial
logical, public :: userDefined = .false.

True only if user explicitly sets it to true

real(kind=rk), private, allocatable, dimension(:) :: varPowers

Powers corresponding to each variable - indices in calculate must conform to this

real(kind=rk), private :: multConst

Multiplicative constant - default 1

Type-Bound Procedures

procedure, public :: isDefined => isDefinedObject
procedure, public :: makeDefined => makeDefinedObject
procedure, public :: makeUndefined => makeUndefinedObject
procedure, public :: init => initSimpleDeriv
procedure, public :: calculate => calculateSimple