Subroutine to create element index list for constant and non-constant material parameters.
To create the two lists, one list with elements with constant material parameters and one list with elements with variable material parameters, we have to follow several steps split into separate phases: Phase 1: Determine variable and constant elements 1. Loop over all materials 1.1. Loop over all spacetime functions 1.1.1 Determine whether the element is variable or not and add it to the according list. Phase 2: Determine the levelwise element lists 2. Loop over all elements. 2.1. Determine the element's level. 2.2. Add them to intermediate lists. Phase 3: Create the result 3. Copy intermediate lists into result type.
Phase 2: Determine the levelwise element lists Phase 3: Create the result
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(treelmesh_type), | intent(in) | :: | tree | Mesh data in treelmesh format. |
||
integer, | intent(in) | :: | levelPointer(:) | The levelPointer contains the indizes on the levelwise fluid list for all treeID entries. |
||
type(atl_material_type), | intent(inout) | :: | material_list(tree%global%minLevel:tree%global%maxLevel) | The description of the material properties. This routine fills the compute lists in the material description. |
||
type(tem_varSys_type), | intent(in) | :: | varSys | global variable system to which lua variables are to be appended |
||
character(len=labelLen), | intent(in) | :: | materials(:) | The list of the variables that should be used as materials. The indizes of variables in the global varSys that are used as material's, penalization's or whatever's data sources. This data is needed to calculate the number of total material components. |
||
type(atl_materialFun_type), | intent(inout) | :: | materialFun |
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | private | :: | iLevel | ||||
integer, | private | :: | iElem | ||||
integer, | private | :: | iStFun | ||||
integer, | private | :: | iMat | ||||
integer, | private | :: | iIndex | ||||
integer, | private | :: | level | ||||
integer, | private | :: | nElemsConst | ||||
integer, | private | :: | nElemsVar | ||||
integer, | private | :: | matPos | ||||
integer, | private | :: | inVarPos | ||||
logical, | private | :: | allElemsAffected | ||||
integer, | private | :: | sortedIndex | The position of an element according to the sorted array. |
|||
logical, | private | :: | elemHasVarMat | Indicates that an element has variable material. |
|||
type(dyn_intarray_type), | private | :: | variableElements | ||||
type(dyn_intarray_type), | private | :: | variableElementsPerLevel(tree%global%minLevel:tree%global%maxLevel) | ||||
type(dyn_intarray_type), | private | :: | constantElementsPerLevel(tree%global%minLevel:tree%global%maxLevel) | ||||
type(tem_st_fun_listElem_type), | private, | pointer | :: | stFunList | Phase 1: Determine variable and constant elements this variable should be false if no material is there |