This module provides all possible 'pure variables' (= no prefixes) for a given kind of simulation.
IMPORTANT NOTE: When you create a new variable, do not forget to add this variable name into mus_append_auxField, mus_store_derVarPos and also in mus_store_bcVarPos routine.
Build global variable system for Musubi
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | varSys |
global variable system |
||
type(mus_varSys_solverData_type), | intent(in), | target | :: | solverData |
Contains pointer to solver data types |
|
type(mus_scheme_header_type), | intent(in) | :: | schemeHeader |
identifier of the scheme |
||
type(tem_stencilHeader_type), | intent(in) | :: | stencil |
Compute stencil header |
||
integer, | intent(in) | :: | nFields |
number of fields |
||
type(mus_derVarPos_type), | intent(out), | allocatable | :: | derVarPos(:) |
store position of each variable for each field and mixture size: nFields+1 |
|
type(tem_variable_type), | intent(in), | allocatable | :: | luaVar(:) |
additional variable defined in the lua file. Function pointer for this variables depends on its varType. |
|
type(mus_field_type), | intent(inout) | :: | field(:) |
Field contains sources and boundary infos |
||
type(mus_source_type), | intent(inout) | :: | globSrc |
global source |
||
type(tem_possible_variable_type), | intent(in) | :: | poss_srcVar |
possible source variables |
||
type(tem_st_fun_linkedList_type), | intent(out) | :: | st_funList |
contains spacetime functions of all variables |
Append variable read from restart file as state variables
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | varSys |
global variable system |
||
logical, | intent(out) | :: | readVarIsPdf |
Is true if read_varSys has pdf variable |
||
type(tem_varSys_type), | intent(in) | :: | read_varSys |
Variable system loaded from restart header file |
||
type(tem_varMap_type), | intent(out) | :: | stateVarMap |
Store position of state variable in global varSys |
||
type(mus_varSys_solverData_type), | intent(in), | target | :: | solverData |
Contains pointer to solver data types |
|
integer, | intent(in) | :: | nFields |
number of fields |
||
character(len=*), | intent(in) | :: | fldLabel(:) |
array of field label prefix. Size=nFields |
Append state variable depends on the scheme kind
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | varSys |
global variable system |
||
type(tem_varMap_type), | intent(out) | :: | stateVarMap |
Store position of state variable in global varSys |
||
type(mus_varSys_solverData_type), | intent(in), | target | :: | solverData |
Contains pointer to solver data types |
|
type(mus_scheme_header_type), | intent(in) | :: | schemeHeader |
identifier of the scheme |
||
type(tem_stencilHeader_type), | intent(in) | :: | stencil |
compute stencil defintion |
||
integer, | intent(in) | :: | nFields |
number of fields |
||
character(len=*), | intent(in) | :: | fldLabel(:) |
array of field label prefix. Size=nFields |
Append auxiliary variables which are computed from state and stored in auxField array using calcAuxField function
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_varSys_type), | intent(inout) | :: | varSys |
global variable system |
||
type(mus_varSys_solverData_type), | intent(in), | target | :: | solverData |
Contains pointer to solver data types |
|
type(mus_scheme_header_type), | intent(in) | :: | schemeHeader |
identifier of the scheme |
||
integer, | intent(in) | :: | nFields |
number of fields |
||
character(len=*), | intent(in) | :: | fldLabel(:) |
array of field label prefix. Size=nFields |
||
type(grw_labelarray_type), | intent(inout) | :: | derVarName |
array of derive physical variables |
Store the position of each variable in the global system in the derVarPos This function is also called in Harvester.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(mus_derVarPos_type), | intent(inout) | :: | derVarPos(:) |
Position of derived variables |
||
type(grw_labelarray_type), | intent(in) | :: | derVarName |
array of derive physical variables |
||
type(tem_varSys_type), | intent(in) | :: | varSys |
global variable system |
||
integer, | intent(in) | :: | nFields |
number of fields |
||
character(len=*), | intent(in) | :: | fldLabel(:) |
array of field label prefix. Size=nFields |
Build a variable system of all possible source terms for the given schemeKind
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(mus_source_type), | intent(inout) | :: | me |
Contains source function pointer, source variable definition from lua and mapping of source variable in global varSys |
||
type(mus_varSys_solverData_type), | intent(in), | target | :: | solverData |
Contains pointer to solver data types |
|
type(mus_scheme_header_type), | intent(in) | :: | schemeHeader |
Identifier of the scheme |
||
type(tem_varSys_type), | intent(inout) | :: | varSys |
Global variable system |
||
integer, | intent(in) | :: | nFields |
number of fields |
||
type(tem_stencilHeader_type), | intent(in) | :: | stencil |
compute stencil defintion |
||
type(tem_possible_variable_type), | intent(in) | :: | poss_srcVar |
possible source variables |
||
character(len=*), | intent(in), | optional | :: | fldLabel |
array of field label prefix required only for field source. If not present, it is assumed as global source |
Store the position of each boundary variable in the global varSys
in the field%bc%varPos%
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(mus_field_type), | intent(inout) | :: | field(:) |
Field containing boundary infos |
||
integer, | intent(in) | :: | nFields |
number of fields |
||
type(tem_varSys_type), | intent(in) | :: | varSys |
global variable system |
This function runs over all variable loaded from restart file check if variables loaded are pdf variable or derive variable
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
logical, | intent(out) | :: | readVarIsPdf |
return true if variable read from restart file has pdf |
||
type(tem_varSys_type), | intent(in) | :: | varSys |
variable system loaded from restart file |
||
integer, | intent(in) | :: | nFields |
number of fields |
||
character(len=*), | intent(in) | :: | fldLabel(:) |
array of field label prefix. Size=nFields |