Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(out), | allocatable | :: | levelPointer(:) |
Pointer from original treeID list to level wise fluid list |
|
type(treelmesh_type), | intent(in) | :: | tree |
the global tree |
||
type(tem_levelDesc_type), | intent(in) | :: | levelDesc(tree%global%minlevel:) |
the level descriptor to be filled |
subroutine tem_build_levelPointer( levelPointer, tree, levelDesc ) ! --------------------------------------------------------------------------- !> Pointer from original treeID list to level wise fluid list integer, allocatable, intent(out) :: levelPointer(:) !> the global tree type(treelmesh_type), intent(in) :: tree !> the level descriptor to be filled type(tem_levelDesc_type), intent(in) :: levelDesc(tree%global%minlevel:) ! --------------------------------------------------------------------------- integer :: iLevel, iElem ! --------------------------------------------------------------------------- ! KM: NOTE: scheme independent levelPointer is build for each scheme ! if ( allocated( levelPointer ) ) then deallocate( levelPointer ) allocate( levelPointer( tree%nElems )) do iElem = 1, tree%nElems iLevel = tem_levelOf( tree%treeID( iElem )) levelPointer( iElem ) = tem_PositionInSorted( & & me = levelDesc( iLevel )%total, & & val = tree%treeID( iElem ), & & upper = levelDesc( iLevel )%elem%nElems( eT_fluid ) ) end do end subroutine tem_build_levelPointer