Repository of the treelm library. Now found at https://github.com/apes-suite/treelm
修訂 | 8aca305fea8e602394938ead8df5c74c437b4923 (tree) |
---|---|
時間 | 2022-04-20 21:47:59 |
作者 | Kannan Masilamani <kannan.masilamani@dlr....> |
Commiter | Kannan Masilamani |
Added second layer of ghostFromFiner
@@ -1036,6 +1036,25 @@ | ||
1036 | 1036 | & proc = proc ) |
1037 | 1037 | |
1038 | 1038 | end if ! ghostFromCoarser? |
1039 | + | |
1040 | + !KM 20220420 Add second layer of ghostFromFiner | |
1041 | + if ( levelDesc( neighLevel )%elem%eType%val( elemPos ) & | |
1042 | + & == eT_ghostFromFiner ) then | |
1043 | + if (nesting < nestingLimit) then | |
1044 | + ! Create the direct neighbors of the ghostFromCoarser | |
1045 | + ! identify all the compute neighbors of the current element | |
1046 | + call identify_stencilNeigh( iElem = elemPos, & | |
1047 | + & iLevel = neighLevel, & | |
1048 | + & tree = tree, & | |
1049 | + & iStencil = 1, & | |
1050 | + & pathFirst = pathFirst, & | |
1051 | + & pathLast = pathLast, & | |
1052 | + & levelDesc = levelDesc, & | |
1053 | + & proc = proc, & | |
1054 | + & stencil = Stencil, & | |
1055 | + & nesting = nestingLimit ) | |
1056 | + end if | |
1057 | + end if | |
1039 | 1058 | end if ! updated? |
1040 | 1059 | |
1041 | 1060 | else if ( nDepProcs > 1 ) then |
@@ -1408,7 +1427,7 @@ | ||
1408 | 1427 | ! adding neighs of neighs for interpolation at ML |
1409 | 1428 | ! this is for the stencil of the fine ghost, composed by coarse fluid |
1410 | 1429 | do iStencilElem = 1, stencil%QQN |
1411 | - | |
1430 | + | |
1412 | 1431 | neighIDpos = levelDesc(coarserLevel)%elem%stencil%val(cPos) & |
1413 | 1432 | & %val(1)%tIDpos(iStencilElem) |
1414 | 1433 | if( neighIDpos > 0 ) then |
@@ -2091,8 +2110,6 @@ | ||
2091 | 2110 | logical :: wasAdded, childUpdated |
2092 | 2111 | integer :: childPos(8) |
2093 | 2112 | type(tem_path_type) :: childPath |
2094 | - integer :: iStencilElem, neighIDpos, addedPos | |
2095 | - integer(kind=long_k) :: neighID | |
2096 | 2113 | ! -------------------------------------------------------------------- ! |
2097 | 2114 | ! Set as not updated by default |
2098 | 2115 | updated = .false. |
@@ -2155,25 +2172,6 @@ | ||
2155 | 2172 | & levelDesc = levelDesc, & |
2156 | 2173 | & minLevel = minLevel, & |
2157 | 2174 | & stencil = stencil ) |
2158 | - | |
2159 | - ! KM: adding neighs of coarser ghost to compute auxField on coarser | |
2160 | - ! ghost with FETCH macro. | |
2161 | - do iStencilElem = 1, stencil%QQN | |
2162 | - neighIDpos = levelDesc(level)%elem%stencil%val(foundPos) & | |
2163 | - & %val(1)%tIDpos(iStencilElem) | |
2164 | - if( neighIDpos > 0 ) then | |
2165 | - neighID = & | |
2166 | - & levelDesc( level )%elem%neighID%val(foundPos)%val(neighIDpos) | |
2167 | - ! This call might add new halo elements | |
2168 | - if ( neighID > 0_long_k ) then | |
2169 | - call append( me = levelDesc( level )%require, & | |
2170 | - & val = neighID, & | |
2171 | - & pos = addedPos ) | |
2172 | - end if | |
2173 | - end if ! neighIDpos > 0 | |
2174 | - enddo | |
2175 | - | |
2176 | - | |
2177 | 2175 | else |
2178 | 2176 | ! ghostFromFiner element was not added |
2179 | 2177 | ! Hence, we found available information which now has to be returned |