The variable system allows the description of arbitrary quantities and their relations.
Its meant to enable the extraction of most of the data in the solver, but also to describe additional quantities to be used by the solvers.
initialize the dynamic array
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type), | intent(out) | :: | me | |||
integer, | intent(in), | optional | :: | length |
truncate the array, meaning cut off the trailing empty entries
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me |
empty the entries without changing arrays
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me |
destroy the dynamic array
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type), | intent(inout) | :: | me |
insert an element at a given position
adds the value to a given position inside the growing array.
if the requested position is outside the current array bounds, the array will be resized accordingly. if it is inside the current array bounds, the element at the requested position will be replaced.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val | |||
integer, | intent(in) | :: | pos | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
adds the values starting from a given position inside the growing array.
if the requested position is outside the current array bounds, the array
will be resized accordingly. if it is inside the current array bounds, the
elements starting from the requested position will be replaced up to
the element at position pos + size(val) - 1
.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val(:) | |||
integer, | intent(in) | :: | pos | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
append a value to the dynamic array and return its position.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val(:) | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
increase the size of the container for the array.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
integer, | intent(in), | optional | :: | pos | ||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
Load variable system(s) from a lua file
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(out), | allocatable | :: | me(:) |
The variable system to read in |
|
type(flu_State) | :: | conf |
Lua handle connected to the script to read the table from |
|||
integer, | intent(in), | optional | :: | parent |
A parent table handle in which to look the current variables up |
|
character(len=*), | intent(in), | optional | :: | key |
load from this key |
load varSys from lua file. Required for harvester to load varSys from tracking or restart header file.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(out) | :: | me |
varSys to read from the Lua script(conf) and fill |
||
type(flu_State) | :: | conf |
Lua handle connected to the script to read the table from |
|||
integer, | intent(in), | optional | :: | parent |
A parent table handle in which to look the current variable up |
|
character(len=*), | intent(in), | optional | :: | key |
load varsys from this key |
|
logical, | intent(in), | optional | :: | openTable |
Dumps array of varSys to given unit
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me(:) |
variable to write into the lua file |
||
integer, | intent(inout) | :: | outUnit |
unit to write to |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
Dump single varSys to given unit
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me |
variable to write into the lua file |
||
integer, | intent(inout) | :: | outUnit |
unit to write to |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
Allows the output of array of varSys to lua out
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me(:) |
variable to write into the lua file |
||
type(aot_out_type), | intent(inout) | :: | conf |
aotus type handling the output to the file in lua format |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
Write the system of variables description into a Lua file. use the aotus_out functions for doing so, in order to obtain a neatly formatted lua file
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me |
Variable system to write out |
||
type(aot_out_type), | intent(inout) | :: | conf |
Aotus type handling the output to the file in lua format |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
|
integer, | intent(in), | optional | :: | level |
to dump varSys with key or without key |
This function provides the assignment operator of tem_varSys_op_type
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_op_type), | intent(out) | :: | left |
varSys op to copy to |
||
type(tem_varSys_op_type), | intent(in) | :: | right |
varSys op to copy from |
Interface description for a variable access method (single point).
To obtain values of a given variable, it is necessary to state the space and time at which the variable should be evaluated. The interface is vectorized and provides n values at n different space locations at the same time. Of course the variable system itself also needs to be passed in, to allow the computation of other derived quantities as needed. The method description itself is passed in automatically, and has not to be provided explicitly.
Type | Intent | Optional | 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. |
||
real(kind=rk), | intent(in) | :: | point(:,:) |
Three-dimensional coordinates at which the variable should be evaluated. Only useful for variables provided as space-time functions. |
||
type(tem_time_type), | intent(in) | :: | time |
Point in time at which to evaluate the variable. |
||
type(treelmesh_type), | intent(in) | :: | tree |
global treelm mesh info |
||
integer, | intent(in) | :: | nPnts |
Number of values to obtain for this variable (vectorized access). |
||
real(kind=rk), | intent(out) | :: | res(:) |
Resulting values for the requested variable. Dimension: n requested entries x nComponents of this variable Access: (iElem-1)*fun%nComponents + iComp |
Interface description for a variable access method (complete element).
To obtain values of a given variable, it is necessary to state the treeID and time at which the variable should be evaluated. The interface is nDofs values to cover the all degrees of freedoms in the element. Of course the variable system itself also needs to be passed in, to allow the computation of other derived quantities as needed. The method description itself is passed in automatically, and has not to be provided explicitly.
Type | Intent | Optional | 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 element in tree%treeID to get the variable for. |
||
type(tem_time_type), | intent(in) | :: | time |
Point in time at which to evaluate the variable. |
||
type(treelmesh_type), | intent(in) | :: | tree |
global treelm mesh info |
||
integer, | intent(in) | :: | nElems |
Number of elements to obtain for this variable (vectorized access). |
||
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: (nComponents of resulting variable) x (nDegrees of freedom) x (nElems) Access: (iElem-1)fun%nComponentsnDofs + (iDof-1)*fun%nComponents + iComp |
Interface description for a variable to set parameter in data type stored in method_data.
To set the parameter, provide a string (recommended in lua format). Depends on variable procedure, input string will be processed and information will be store in method_data. For operation variable, pass the information down to its input_variable.
Type | Intent | Optional | 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. |
||
character(len=*), | intent(in) | :: | instring |
Input string with parameter to set in method_data |
Interface description for a variable to get parameter in data type stored in method_data.
To get the parameter, provide requested parameter via instring (recommended in lua format) and routine returns the parameter via outstring in lua format. For operation variable, pass the information down to its input_variable.
Type | Intent | Optional | 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. |
||
character(len=*), | intent(in) | :: | instring |
Input string with parameter to set in method_data |
||
character(len=*), | intent(out) | :: | outstring |
Output string with requested parameter value from method_data |
Interface description for a variable to setup point sets and return indices of points in the 1D growing array.
Before setupIndices, use setParams to set information about boundary or sources in the spacetime function type. Points are stored in the 1D growing array for each dimension in the level wise list in the method_data. offset_bit is required for each point on boundaries so the remote domain can use this offset to identify rank for the point. If offset_bit is not present then default is set to element center i.e offset_bit = achar(1+4+16).
For state variable, this routine will also compute elemPos in the given level and local_coord for every point. Elempos and local_coord are stored in same place as growing array of points.
For spacetime function variable, if function is time independent then values are computed and stored level wise after all points are added to spacetime function.
Type | Intent | Optional | 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. |
||
real(kind=rk), | intent(in) | :: | point(:,:) |
List of space coordinate points to store as growing array in method_data |
||
character, | intent(in), | optional | :: | offset_bit(:) |
Offset bit encoded as character for every point. Offset integer coord(3) is converted into a character with offset_bit = achar( (coord(1)+1) + (coord(2)+1)4 + (coord(3)+1)16 ) Backward transformation form character to 3 integer: coord(1) = mod(ichar(offset_bit),4) - 1 coord(2) = mod(ichar(offset_bit),16)/4 - 1 coord(3) = ichar(offset_bit)/16 - 1 If not present default is to center i.e offset_bit = achar(1+4+16) |
|
integer, | intent(in) | :: | iLevel |
Level to which input points belong to |
||
type(treelmesh_type), | intent(in) | :: | tree |
global treelm mesh info |
||
integer, | intent(in) | :: | nPnts |
Number of points to add in method_data of this variable |
||
integer, | intent(out) | :: | idx(:) |
Index of points in the growing array and variable val array. Size: n This must be stored in boundary or source depends on who calls this routine. This index is required to return a value using getValOfIndex. |
Interface description for a variable to return a value at the given index position in the growing array points set stored in method_data.
For spacetime function, if value is pre-stored, it will return a value at given index else if will evaluate a variable at index of a point for a given time and return a value.
If index is not present and first is present then index is computed from first and number of return value (n).
Type | Intent | Optional | 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. |
||
type(tem_time_type), | intent(in) | :: | time |
Point in time at which to evaluate the variable. |
||
integer, | intent(in) | :: | iLevel |
Level on which values are requested |
||
integer, | intent(in) | :: | idx(:) |
Index of points in the growing array and variable val array to return. Size: most times nVals, if contiguous arrays are used it depends on the number of first indices |
||
integer, | intent(in), | optional | :: | idxLen(:) |
With idx as start index in contiguous memory, idxLength defines length of each contiguous memory Size: dependes on number of first index for contiguous array, but the sum of all idxLen is equal to nVals |
|
integer, | intent(in) | :: | nVals |
Number of values to obtain for this variable (vectorized access). |
||
real(kind=rk), | intent(out) | :: | res(:) |
Resulting values for the requested variable. Dimension: n requested entries x nComponents of this variable Access: (iElem-1)*fun%nComponents + iComp |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(tem_varSys_solverData_evalElem_type), | intent(in) | :: | set_elem_eval |
Description on how to set the element retrieval function for stfuns. and solver specific operation variables |
||
type(tem_varSys_op_type), | intent(inout) | :: | 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. |
Description of the method how to obtain a variable
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | public | :: | mypos |
Position of this variable in the variable system. |
|||
integer, | public, | allocatable | :: | state_varPos(:) |
Position of state variable in the state array Currently used only in MUSUBI to access one dimensional state array |
||
integer, | public, | allocatable | :: | auxField_varPos(:) |
Position of auxiliary variable in the auxilied field array Currently used only in MUSUBI to access one dimensional auxiliary array In Musubi, auxField vars are conserved macroscopic quantities computed from PDF state |
||
integer, | public | :: | nComponents |
Number of components for this variable. |
|||
integer, | public | :: | nInputs |
Number of variables, that are needed as input for the operation to obtain the variable. |
|||
integer, | public, | allocatable | :: | input_varPos(:) |
Position of the input variables in the variable system. |
||
integer, | public, | allocatable | :: | input_varIndex(:) |
Component index of the input variable in the variable system. It is used only when there is only one input variable. Index values must not be zero and > nComponents of input variable |
||
type(c_ptr), | public | :: | method_data |
Data that is required by the get method. |
|||
character(len=labelLen), | public | :: | operType |
Operation type |
|||
procedure(tem_varSys_proc_point), | public, | pointer | :: | get_point | => | null() |
Function to actually obtain the variable at a given point. |
procedure(tem_varSys_proc_element), | public, | pointer | :: | get_element | => | null() |
Function to actually obtain the variable in a given element. |
procedure(tem_varSys_proc_setParams), | public, | pointer | :: | set_params | => | null() |
Function to set parameter in the data_type stored in method_data. |
procedure(tem_varSys_proc_getParams), | public, | pointer | :: | get_params | => | null() |
Function to get parameter in the data_type stored in method_data |
procedure(tem_varSys_proc_setupIndices), | public, | pointer | :: | setup_indices | => | null() |
Function to setup points set for boundaries and sources. Pointe set are stored in method_data level wise 1D growing array for dimension X,Y and Z. * For solver variables, points are stored in solver container. * For spacetime variables, points are stored in spacetime function. * For operation variables, points are passed down to its input_variable. |
procedure(tem_varSys_proc_getValOfIndex), | public, | pointer | :: | get_valOfIndex | => | null() |
Function to get value for point set stored in method_data for requested index in point set. This function either returns a pre-stored value or compute value depends on variable type and spacetime function. For time-independent spacetime function, values are computed in setupIndices and growing array of points are deleted |
growing array type for type(tem_varsys_op_type)
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | public | :: | nvals | = | 0 | ||
integer, | public | :: | containersize | = | 0 | ||
type(tem_varSys_op_type), | public, | allocatable | :: | val(:) |
Description of the variable system.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
character(len=LabelLen), | public | :: | SystemName |
A descriptive name for this system of variables. |
|||
integer, | public | :: | nStateVars | = | 0 |
Number of variables in the state. |
|
integer, | public | :: | nScalars | = | 0 |
Number of scalars in the state. |
|
integer, | public | :: | nAuxVars | = | 0 |
Number of auxField variables |
|
integer, | public | :: | nAuxScalars |
Number of scalars in the auxField This keeps track of the length of the auxField array |
|||
type(grw_varoparray_type), | public | :: | method |
Definition of how to obtain a variable. |
|||
type(dyn_labelarray_type), | public | :: | varname |
List of variables in the system. |
A supporting data type to define a solver specific element evaluation for stfuns.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(c_ptr), | public | :: | solver_bundle |
Data from the solver for the evaluation. |
|||
procedure(tem_varsys_set_evalelem), | public, | pointer | :: | stFun_setter | => | null() |
Callback function to set the appropriate function for stFun vars. |
procedure(tem_varsys_set_evalelem), | public, | pointer | :: | opVar_setter | => | null() |
Callback function to set the appropriate function for solver specific operation vars. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type), | intent(out) | :: | me | |||
integer, | intent(in), | optional | :: | length |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type), | intent(inout) | :: | me |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me |
adds the value to a given position inside the growing array.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val | |||
integer, | intent(in) | :: | pos | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
adds the values starting from a given position inside the growing array.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val(:) | |||
integer, | intent(in) | :: | pos | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
type(tem_varSys_op_type), | intent(in) | :: | val(:) | |||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grw_varoparray_type) | :: | me | ||||
integer, | intent(in), | optional | :: | pos | ||
integer, | intent(in), | optional | :: | length |
optional length to expand the array |
Initialize a variable system.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(out) | :: | me |
Variable system to initialize. |
||
character(len=*), | intent(in) | :: | systemName |
A descriptive name for this system of variables. |
||
integer, | intent(in), | optional | :: | length |
Initial length for the arrays used in the variable system. |
Append a new state variable to the variable system.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | me |
Variable system to append the state variable to. |
||
character(len=*), | intent(in) | :: | varname |
Variable to append to the state. |
||
integer, | intent(in) | :: | nComponents |
Number of components in this variable. |
||
type(c_ptr), | intent(in) | :: | method_data |
Data that is required by the methods to obtain the variable. |
||
procedure(tem_varSys_proc_point), | pointer | :: | get_point |
Procedure which allows the retrieval of the variable at given points. |
||
procedure(tem_varSys_proc_element), | pointer | :: | get_element |
Procedure which allows the retrieval of the variable in an element. |
||
procedure(tem_varSys_proc_setParams), | optional, | pointer | :: | set_params |
Procedure which allows to set parameter in method_data |
|
procedure(tem_varSys_proc_getParams), | optional, | pointer | :: | get_params |
Procedure which allows to get parameter in method_data |
|
procedure(tem_varSys_proc_setupIndices), | pointer | :: | setup_indices |
Procedure to setup growing array of points, variable value in method_data and return index of points set |
||
procedure(tem_varSys_proc_getValOfIndex), | pointer | :: | get_valOfIndex |
Procedure which allows to retrieval of the variable at point or val array index |
||
integer, | intent(out), | optional | :: | pos |
Position of the variable in the system. |
|
logical, | intent(out), | optional | :: | wasAdded |
Indicator, if the variable was actually added to the system. |
Append a new auxiliaryField variable to the variable system.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | me |
Variable system to append the state variable to. |
||
character(len=*), | intent(in) | :: | varname |
Variable to append to the state. |
||
integer, | intent(in) | :: | nComponents |
Number of components in this variable. |
||
type(c_ptr), | intent(in) | :: | method_data |
Data that is required by the methods to obtain the variable. |
||
procedure(tem_varSys_proc_point), | pointer | :: | get_point |
Procedure which allows the retrieval of the variable at given points. |
||
procedure(tem_varSys_proc_element), | pointer | :: | get_element |
Procedure which allows the retrieval of the variable in an element. |
||
procedure(tem_varSys_proc_setParams), | optional, | pointer | :: | set_params |
Procedure which allows to set parameter in method_data |
|
procedure(tem_varSys_proc_getParams), | optional, | pointer | :: | get_params |
Procedure which allows to get parameter in method_data |
|
procedure(tem_varSys_proc_setupIndices), | pointer | :: | setup_indices |
Procedure to setup growing array of points, variable value in method_data and return index of points set |
||
procedure(tem_varSys_proc_getValOfIndex), | pointer | :: | get_valOfIndex |
Procedure which allows to retrieval of the variable at point or val array index |
||
integer, | intent(out), | optional | :: | pos |
Position of the variable in the system. |
|
logical, | intent(out), | optional | :: | wasAdded |
Indicator, if the variable was actually added to the system. |
Append a new (non-state) variable to the variable system.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | me |
Variable system to append the state variable to. |
||
character(len=*), | intent(in) | :: | varname |
Variable to append to the state. |
||
character(len=*), | intent(in), | optional | :: | operType |
Operation type |
|
integer, | intent(in) | :: | nComponents |
Number of components in this variable. |
||
character(len=*), | intent(in), | optional | :: | input_varname(:) |
List of variable names, this variable depends on. |
|
integer, | intent(in), | optional | :: | input_varIndex(:) |
Component index to access from input variable nComponents |
|
type(c_ptr), | intent(in) | :: | method_data |
Data that is required by the methods to obtain the variable. |
||
procedure(tem_varSys_proc_point), | pointer | :: | get_point |
Procedure which allows the retrieval of the variable at given points. |
||
procedure(tem_varSys_proc_element), | pointer | :: | get_element |
Procedure which allows the retrieval of the variable in an element. |
||
procedure(tem_varSys_proc_setParams), | optional, | pointer | :: | set_params |
Procedure which allows to set parameter in method_data |
|
procedure(tem_varSys_proc_getParams), | optional, | pointer | :: | get_params |
Procedure which allows to get parameter in method_data |
|
procedure(tem_varSys_proc_setupIndices), | pointer | :: | setup_indices |
Procedure to setup growing array of points, variable value in method_data and return index of points set |
||
procedure(tem_varSys_proc_getValOfIndex), | pointer | :: | get_valOfIndex |
Procedure which allows to retrieval of the variable at point or val array index |
||
integer, | intent(out), | optional | :: | pos |
Position of the variable in the system. |
|
logical, | intent(out), | optional | :: | wasAdded |
Indicator, if the variable was actually added to the system. |
Load variable system(s) from a lua file
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(out), | allocatable | :: | me(:) |
The variable system to read in |
|
type(flu_State) | :: | conf |
Lua handle connected to the script to read the table from |
|||
integer, | intent(in), | optional | :: | parent |
A parent table handle in which to look the current variables up |
|
character(len=*), | intent(in), | optional | :: | key |
load from this key |
load varSys from lua file. Required for harvester to load varSys from tracking or restart header file.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(out) | :: | me |
varSys to read from the Lua script(conf) and fill |
||
type(flu_State) | :: | conf |
Lua handle connected to the script to read the table from |
|||
integer, | intent(in), | optional | :: | parent |
A parent table handle in which to look the current variable up |
|
character(len=*), | intent(in), | optional | :: | key |
load varsys from this key |
|
logical, | intent(in), | optional | :: | openTable |
Dumps array of varSys to given unit
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me(:) |
variable to write into the lua file |
||
integer, | intent(inout) | :: | outUnit |
unit to write to |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
Dump single varSys to given unit
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me |
variable to write into the lua file |
||
integer, | intent(inout) | :: | outUnit |
unit to write to |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
Allows the output of array of varSys to lua out
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me(:) |
variable to write into the lua file |
||
type(aot_out_type), | intent(inout) | :: | conf |
aotus type handling the output to the file in lua format |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
Write the system of variables description into a Lua file. use the aotus_out functions for doing so, in order to obtain a neatly formatted lua file
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | me |
Variable system to write out |
||
type(aot_out_type), | intent(inout) | :: | conf |
Aotus type handling the output to the file in lua format |
||
integer, | intent(in), | optional | :: | dumpVarPos(:) |
Position of variables to dump |
|
integer, | intent(in), | optional | :: | level |
to dump varSys with key or without key |
A routine to evaluate chunk of elements for given list of variables
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | varsys |
Variable system describing available data. |
||
integer, | intent(in) | :: | varPos(:) |
Position of variables to evaluate in varSys |
||
integer, | intent(in) | :: | elemPos(:) |
Position of treeID of the element to get the variable for. |
||
type(tem_time_type), | intent(in) | :: | time |
Time information for the current data. |
||
type(treelmesh_type), | intent(in) | :: | tree |
Mesh definition of the input data. |
||
integer, | intent(in) | :: | nElems |
number of elements to evaluate |
||
integer, | intent(in) | :: | nDofs |
Number of degrees of freedom. |
||
real(kind=rk), | intent(out) | :: | res(:) |
Output data size: io_buffer_size |
A routine to evaluate chunk of points for given list of variables
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(in) | :: | varsys |
Variable system describing available data. |
||
integer, | intent(in) | :: | varPos(:) |
Position of variables to evaluate in varSys |
||
real(kind=rk), | intent(in) | :: | point(:,:) |
Three-dimensional coordinates at which the variable should be evaluated. Only useful for variables provided as space-time functions. |
||
type(tem_time_type), | intent(in) | :: | time |
Time information for the current data. |
||
type(treelmesh_type), | intent(in) | :: | tree |
Mesh definition of the input data. |
||
integer, | intent(in) | :: | nPnts |
Number of values to obtain for this variable (vectorized access). |
||
real(kind=rk), | intent(out) | :: | res(:) |
Output data size: io_buffer_size |
This function provides the assignment operator of tem_varSys_op_type
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_op_type), | intent(out) | :: | left |
varSys op to copy to |
||
type(tem_varSys_op_type), | intent(in) | :: | right |
varSys op to copy from |
Free a variable description.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_op_type), | intent(inout) | :: | fun |
Variable method to free. |
Empty a variable system.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | varsys |
Variable system to empty. |
Type | Intent | Optional | 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. |
||
character(len=*), | intent(in) | :: | instring |
Input string with parameter to set in method_data |
||
character(len=*), | intent(out) | :: | outstring |
Output string with requested parameter value from method_data |
Type | Intent | Optional | 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. |
||
character(len=*), | intent(in) | :: | instring |
Input string with parameter to set in method_data |
Type | Intent | Optional | 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. |
||
real(kind=rk), | intent(in) | :: | point(:,:) |
List of space coordinate points to store as growing array in method_data |
||
character, | intent(in), | optional | :: | offset_bit(:) |
Offset bit encoded as character for every point. |
|
integer, | intent(in) | :: | iLevel |
Level to which input points belong to |
||
type(treelmesh_type), | intent(in) | :: | tree |
global treelm mesh info |
||
integer, | intent(in) | :: | nPnts |
Number of points to add in method_data of this variable |
||
integer, | intent(out) | :: | idx(:) |
Index of points in the growing array and variable val array. Size: n |
Type | Intent | Optional | 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. |
||
type(tem_time_type), | intent(in) | :: | time |
Point in time at which to evaluate the variable. |
||
integer, | intent(in) | :: | iLevel |
Level on which values are requested |
||
integer, | intent(in) | :: | idx(:) |
Index of points in the growing array and variable val array to return. Size: most times nVals, if contiguous arrays are used it depends on the number of first indices |
||
integer, | intent(in), | optional | :: | idxLen(:) |
With idx as start index in contiguous memory, idxLength defines length of each contiguous memory Size: dependes on number of first index for contiguous array, but the sum of all idxLen is equal to nVals |
|
integer, | intent(in) | :: | nVals |
Number of values to obtain for this variable (vectorized access). |
||
real(kind=rk), | intent(out) | :: | res(:) |
Resulting values for the requested variable. |
Type | Intent | Optional | 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. |
||
real(kind=rk), | intent(in) | :: | point(:,:) |
Three-dimensional coordinates at which the variable should be evaluated. Only useful for variables provided as space-time functions. |
||
type(tem_time_type), | intent(in) | :: | time |
Point in time at which to evaluate the variable. |
||
type(treelmesh_type), | intent(in) | :: | tree |
global treelm mesh info |
||
integer, | intent(in) | :: | nPnts |
Number of values to obtain for this variable (vectorized access). |
||
real(kind=rk), | intent(out) | :: | res(:) |
Resulting values for the requested variable. |
Type | Intent | Optional | 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 element in tree%treeID to get the variable for. |
||
type(tem_time_type), | intent(in) | :: | time |
Point in time at which to evaluate the variable. |
||
type(treelmesh_type), | intent(in) | :: | tree |
global treelm mesh info |
||
integer, | intent(in) | :: | nElems |
Number of elements to obtain for this variable (vectorized access). |
||
integer, | intent(in) | :: | nDofs |
Number of degrees of freedom within an element. |
||
real(kind=rk), | intent(out) | :: | res(:) |
Resulting values for the requested variable. |
Type | Intent | Optional | 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. |
||
type(tem_time_type), | intent(in) | :: | time |
Point in time at which to evaluate the variable. |
||
integer, | intent(in) | :: | iLevel |
Level on which values are requested |
||
integer, | intent(in) | :: | idx(:) |
Index of points in the growing array and variable val array to return. Size: nVals |
||
integer, | intent(in), | optional | :: | idxLen(:) |
With idx as start index in contiguous memory, idxLength defines length of each contiguous memory Size: nVals |
|
integer, | intent(in) | :: | nVals | |||
character(len=*), | intent(in) | :: | label |