36 void Foam::polyTopoChange::reorder
39 DynamicList<Type>& lst
43 DynamicList<Type> oldLst(lst);
47 const label newIdx = oldToNew[i];
51 lst[newIdx] = oldLst[i];
58 void Foam::polyTopoChange::reorder
61 List<DynamicList<Type>>& lst
65 List<DynamicList<Type>> oldLst(lst);
69 const label newIdx = oldToNew[i];
73 lst[newIdx].transfer(oldLst[i]);
80 void Foam::polyTopoChange::renumberKey
86 Map<Type> newMap(map.capacity());
90 const label newKey = oldToNew[iter.key()];
94 newMap.insert(newKey, iter.val());
108 const bool syncParallel,
109 const bool orderCells,
110 const bool orderPoints
115 Pout<<
"polyTopoChange::changeMesh"
116 <<
"(autoPtr<fvMesh>&, const IOobject&, const fvMesh&"
117 <<
", const bool, const bool, const bool)"
130 label nInternalPoints;
170 oldPatchMeshPointMaps,
173 oldFaceZoneMeshPointMaps
193 std::move(newPoints),
195 std::move(faceOwner_),
196 std::move(faceNeighbour_)
199 Type& newMesh = *newMeshPtr;
203 retiredPoints_.clearStorage();
204 region_.clearStorage();
211 label nAdd, nInflate, nMerge, nRemove;
212 countMap(pointMap_, reversePointMap_, nAdd, nInflate, nMerge, nRemove);
214 <<
" added(from point):" << nAdd
215 <<
" added(from nothing):" << nInflate
216 <<
" merged(into other point):" << nMerge
217 <<
" removed:" << nRemove
220 countMap(faceMap_, reverseFaceMap_, nAdd, nInflate, nMerge, nRemove);
222 <<
" added(from face):" << nAdd
223 <<
" added(inflated):" << nInflate
224 <<
" merged(into other face):" << nMerge
225 <<
" removed:" << nRemove
228 countMap(cellMap_, reverseCellMap_, nAdd, nInflate, nMerge, nRemove);
230 <<
" added(from cell):" << nAdd
231 <<
" added(inflated):" << nInflate
232 <<
" merged(into other cell):" << nMerge
233 <<
" removed:" << nRemove
244 forAll(oldPatches, patchi)
246 newBoundary[patchi] = oldPatches[patchi].
clone
248 newMesh.boundaryMesh(),
254 newMesh.addFvPatches(newBoundary);
269 oldPointZones[i].
name(),
283 oldFaceZones[i].
name(),
297 oldCellZones[i].
name(),
304 newMesh.addZones(pZonePtrs, fZonePtrs, cZonePtrs);
313 resetZones(
mesh, newMesh, pointZoneMap, faceZoneFaceMap, cellZoneMap);
317 pointZone_.clearStorage();
318 faceZone_.clearStorage();
319 faceZoneFlip_.clearStorage();
320 cellZone_.clearStorage();
329 oldPatchMeshPointMaps,
330 newMesh.boundaryMesh(),
336 calcFaceZonePointMap(newMesh, oldFaceZoneMeshPointMaps, faceZonePointMap);