This module contains solver data type with pointers to musubi mus_scheme_type, mus_param_type, etc which are required for variable operation method data. Also contains all general routines for the variable system.
This interface describes the arguments to be used for routines that do the derivation of variables from the variable system.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(tem_varSys_op_type), | intent(in) | :: | fun |
Description of the method to obtain the variables, |
||
type(tem_varSys_type), | intent(in) | :: | varSys |
The variable system to obtain the variable from. |
||
type(tem_stencilHeader_type), | intent(in) | :: | stencil |
fluid stencil defintion |
||
integer, | intent(in) | :: | iLevel |
current level |
||
integer, | intent(in) | :: | posInState(:) |
Position of element in levelwise state array |
||
real(kind=rk), | intent(in) | :: | pdf(:) |
|
||
real(kind=rk), | intent(out) | :: | res(:) |
results |
||
integer, | intent(in) | :: | nVals |
nVals to get |
Method data container for every variable
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(mus_varSys_solverData_type), | public, | pointer | :: | solverData | |||
type(tem_pointData_list_type), | public | :: | pointData | ||||
type(tem_varSys_op_data_type), | public | :: | opData |
data array for operation or derived varibales consists the index arrys for points stored in the poingtData of input variable size is number of input variables |
Contains pointer to musubi data types required for variable operation method_data
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(mus_scheme_type), | public, | pointer | :: | scheme | => | NULL() |
scheme data type |
type(mus_physics_type), | public, | pointer | :: | physics | => | NULL() |
contains basic SI units to convert from lattice to physical and vice versa |
type(mus_geom_type), | public, | pointer | :: | geometry | => | NULL() |
Contains geometry information and definitions |
Routine to get a pointer to a new instance of mus_varSys_solverData_type to be used as method data for a variable in the variable system.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(mus_varSys_solverData_type), | intent(in), | optional, | target | :: | solver |
The prototype is used to initialize the new instance. |
Pointer to the newly created instance.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(mus_varSys_solverData_type), | intent(out) | :: | me | |||
type(mus_scheme_type), | intent(in), | target | :: | scheme | ||
type(mus_physics_type), | intent(in), | target | :: | physics | ||
type(mus_geom_type), | intent(in), | target | :: | geometry |
Routine to store musubi varSys Data in stFun variable
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(tem_varSys_solverData_evalElem_type), | intent(in) | :: | solData_evalElem |
Description on how to set the element retrieval function for stfuns. |
||
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. |
Derive variable for a given set of points using linear interpolation. This is a generic routine for any variable. Limitation: If neighbor is halo element then its not considered for interpolation, only the fluid (non-ghost) elements in the local process are used for interpolation.
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 | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | varPos |
Position of variable in varSys |
||
type(tem_varSys_type), | intent(in) | :: | varSys |
The variable system to obtain the variable from. |
||
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. |
||
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. |
||
integer, | intent(in) | :: | nPnts |
Number of values to obtain for this variable (vectorized access). |
||
type(tem_stencilHeader_type), | intent(in) | :: | stencil |
stencil definition |
||
integer, | intent(in) | :: | levelPointer(:) |
Pointer from treeIDlist entry to level-wise fluid part of total list |
||
type(tem_levelDesc_type), | intent(in) | :: | levelDesc(tree%global%minLevel:) |
level description of all levels |
||
real(kind=rk), | intent(out) | :: | res(:) |
Resulting values for the requested variable. |
Routine to get the actual value for a given array of indices for musubi derive variables The indices belong to the grwarray of points storing levelwise in Pointdata%pntLvl(iLevel). Hence this routines takes the indeices as input, can refer to the pointData and evaluate the variable and returns the values
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(tem_varSys_op_type), | intent(in) | :: | fun |
Description of the method to obtain the 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: n |
||
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). |
||
procedure(mus_derive_fromPDF), | pointer | :: | fnCalcPtr |
Function pointer to perform specific operation. |
||
real(kind=rk), | intent(out) | :: | res(:) |
Resulting values for the requested variable. |
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.
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 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. |
This routine creates srcElemInTree in pointData. It is called all in getPoint routine when first time the get point routine in called.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_pointData_type), | intent(out) | :: | pntDataMapToTree |
Contains position of source elements in Tree and weights for interpolation |
||
integer, | intent(out) | :: | posInPntData(:) |
Contains position of a point in pntDataMapToTree |
||
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. |
||
integer, | intent(in) | :: | nPnts |
Number of values to obtain for this variable (vectorized access). |
||
type(tem_stencilHeader_type), | intent(in) | :: | stencil |
stencil definition |
||
type(treelmesh_type), | intent(in) | :: | tree |
global treelm mesh info |
||
integer, | intent(in) | :: | levelPointer(:) |
Pointer from treeIDlist entry to level-wise fluid part of total list |
||
type(tem_levelDesc_type), | intent(in) | :: | levelDesc(tree%global%minLevel:) |
level description of all levels |