mus_generic_fromPDF_forElement Subroutine

public recursive subroutine mus_generic_fromPDF_forElement(fun, varsys, elempos, tree, time, nVals, fnCalcPtr, ndofs, res)

This routine prepares the data for variable derivation or operators. It gathers all input variables from the variable system, calls the function with the actual calculation.

Arguments

Type IntentOptional Attributes Name
class(tem_varSys_op_type), intent(in) :: fun

description of the method to obtain the variables, here some preset values might be stored, like the space time function to use or the required variables.

type(tem_varSys_type), intent(in) :: varsys

the variable system to obtain the variable from.

integer, intent(in) :: elempos(:)

position of the treeid of the element to get the variable for in the global treeid list.

type(treelmesh_type), intent(in) :: tree

global treelm mesh info

type(tem_time_type), intent(in) :: time

point in time at which to evaluate the variable.

integer, intent(in) :: nVals

Number of values to obtain for this variable

procedure(mus_derive_fromPDF), pointer :: fnCalcPtr

Function pointer to perform specific operation.

integer, intent(in) :: ndofs

number of degrees of freedom within an element.

real(kind=rk), intent(out) :: res(:)

resulting values for the requested variable.

linearized array dimension: (n requested entries) x (ncomponents of this variable) x (ndegrees of freedom) access: (ielem-1)fun%ncomponentsndofs + (idof-1)*fun%ncomponents + icomp