variable_list_procedures Submodule

Contains module procedures associated with the variable list class


Uses


Module Functions

pure module function getNumVars(this) result(numVars)

Returns number of variables in list

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this

Return Value integer(kind=ik)

pure module function getVarNames(this) result(names)

Getter of names

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this

Return Value type(StringArray), allocatable, dimension(:)

pure module function getVarName(this, ind) result(name)

Return variable name at index ind

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
integer(kind=ik), intent(in) :: ind

Return Value character(len=:), allocatable

pure module function getVarPriority(this, ind) result(priority)

Return priority of variable with given index

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
integer(kind=ik), intent(in) :: ind

Return Value integer(kind=ik)

pure module function isVarNameRegistered(this, name) result(reg)

Check whether variable with given name is registered

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
character(len=*), intent(in) :: name

Return Value logical

pure module function isVarDist(this, ind) result(distf)

Check whether variable with given index is a full distribution function

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
integer(kind=ik), intent(in) :: ind

Return Value logical

pure module function isVarSingleHarmonic(this, ind) result(singleH)

Check whether variable with given index is a single harmonic

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
integer(kind=ik), intent(in) :: ind

Return Value logical

pure module function isVarScalar(this, ind) result(scal)

Check whether variable with given index is a scalar

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
integer(kind=ik), intent(in) :: ind

Return Value logical

pure module function isVarOnDualGrid(this, ind) result(dual)

Check whether variable with given index is a on dual grid

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
integer(kind=ik), intent(in) :: ind

Return Value logical

pure module function isVarStationary(this, ind) result(stat)

Check whether variable with given index is stationary

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
integer(kind=ik), intent(in) :: ind

Return Value logical

pure module function getVarIndex(this, name) result(ind)

Get index of variable with given name

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
character(len=*), intent(in) :: name

Return Value integer(kind=ik)

pure module function combineWith(this, other) result(res)

Combine two lists into one

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(in) :: this
type(VariableList), intent(in) :: other

Return Value type(VariableList)


Module Subroutines

pure module subroutine initVarList(this)

Variable list initialization routine

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(inout) :: this

pure module subroutine addVar(this, name, isDist, isSingleHarmonic, isScalar, isOnDualGrid, isStationary, priority)

Add variable with given name to list; isDist determines if variable is a distribution function and is .false. by default; isSingleHarmonic sets whether a given distribution is only a single harmonic - i.e. a function of just x and v isScalar tags variable as a scalar (will be stored as a dimension 1 array) isOnDualGrid marks variable as living on the dual/staggered grid (or having staggered harmonics if it's a distribution) isStationary marks variable as having d/dt=0 priority is an integer governing operations such as variable derivation

Arguments

Type IntentOptional Attributes Name
class(VariableList), intent(inout) :: this
character(len=*), intent(in) :: name
logical, intent(in), optional :: isDist
logical, intent(in), optional :: isSingleHarmonic
logical, intent(in), optional :: isScalar
logical, intent(in), optional :: isOnDualGrid
logical, intent(in), optional :: isStationary
integer(kind=ik), intent(in), optional :: priority