polyTopoChange: Removed remnants of unused and deprecated cell and face inflation
The concept of cell and face inflation proved unworkable in general and has been replaced by the more flexible and robust cell-splitting combined with conservative interpolative mapping and mesh morphing as appropriate.
This commit is contained in:
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2024 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -100,8 +100,6 @@ void modifyOrAddFace
|
||||
f, // modified face
|
||||
own, // owner
|
||||
-1, // neighbour
|
||||
-1, // master point
|
||||
-1, // master edge
|
||||
facei, // master face
|
||||
flipFaceFlux, // face flip
|
||||
newPatchi, // patch for face
|
||||
@ -496,8 +494,6 @@ void createBaffles
|
||||
f.reverseFace(), // modified face
|
||||
mesh.faceNeighbour()[facei],// owner
|
||||
-1, // neighbour
|
||||
-1, // masterPointID
|
||||
-1, // masterEdgeID
|
||||
facei, // masterFaceID,
|
||||
false, // face flip
|
||||
wantedPatch[facei], // patch for face
|
||||
@ -1053,9 +1049,8 @@ int main(int argc, char *argv[])
|
||||
runTime++;
|
||||
}
|
||||
|
||||
// Change the mesh. Change points directly (no inflation).
|
||||
autoPtr<polyTopoChangeMap> map =
|
||||
meshMod.changeMesh(subsetter.subMesh(), false);
|
||||
// Change the mesh. Change points directly
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(subsetter.subMesh());
|
||||
|
||||
// Update fields
|
||||
subsetter.subMesh().topoChange(map);
|
||||
@ -1124,13 +1119,6 @@ int main(int argc, char *argv[])
|
||||
Zero
|
||||
);
|
||||
|
||||
|
||||
// Move mesh (since morphing might not do this)
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
subsetter.subMesh().setPoints(map().preMotionPoints());
|
||||
}
|
||||
|
||||
Info<< "Writing mesh with split blockedFaces to time "
|
||||
<< runTime.userTimeName() << endl;
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2024 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -512,12 +512,7 @@ void subsetMesh
|
||||
|
||||
const Time& runTime = mesh.time();
|
||||
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh, false);
|
||||
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh);
|
||||
|
||||
// Update topology on cellRemover
|
||||
cellRemover.topoChange(map());
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2024 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -172,7 +172,7 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
polyTopoChange meshMod(newMesh());
|
||||
|
||||
meshMod.changeMesh(mesh, false);
|
||||
meshMod.changeMesh(mesh);
|
||||
|
||||
polyMeshFilter::copySets(newMesh(), mesh);
|
||||
}
|
||||
@ -196,7 +196,7 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
polyTopoChange meshMod(newMesh);
|
||||
|
||||
meshMod.changeMesh(mesh, false);
|
||||
meshMod.changeMesh(mesh);
|
||||
|
||||
polyMeshFilter::copySets(newMesh(), mesh);
|
||||
}
|
||||
@ -220,7 +220,7 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
polyTopoChange meshMod(newMesh);
|
||||
|
||||
meshMod.changeMesh(mesh, false);
|
||||
meshMod.changeMesh(mesh);
|
||||
|
||||
polyMeshFilter::copySets(newMesh(), mesh);
|
||||
}
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2024 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -101,22 +101,14 @@ label mergePatchFaces
|
||||
// Merge all faces of a set into the first face of the set.
|
||||
faceCombiner.setRefinement(allFaceSets, meshMod);
|
||||
|
||||
// Change the mesh (no inflation)
|
||||
map = meshMod.changeMesh(mesh, false, true);
|
||||
// Change the mesh
|
||||
map = meshMod.changeMesh(mesh, true);
|
||||
|
||||
// Update fields
|
||||
mesh.topoChange(map);
|
||||
|
||||
// Move mesh (since morphing does not do this)
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
else
|
||||
{
|
||||
// Delete mesh volumes. No other way to do this?
|
||||
mesh.clearOut();
|
||||
}
|
||||
// Delete mesh volumes. No other way to do this?
|
||||
mesh.clearOut();
|
||||
}
|
||||
|
||||
|
||||
@ -239,8 +231,6 @@ label mergePatchFaces
|
||||
setFaceVerts[i], // vertices
|
||||
own, // owner,
|
||||
-1, // neighbour,
|
||||
-1, // masterPointID,
|
||||
-1, // masterEdgeID,
|
||||
newMasterI, // masterFaceID,
|
||||
false, // flipFaceFlux,
|
||||
patchID, // patchID,
|
||||
@ -250,22 +240,14 @@ label mergePatchFaces
|
||||
}
|
||||
}
|
||||
|
||||
// Change the mesh (no inflation)
|
||||
map = meshMod.changeMesh(mesh, false, true);
|
||||
// Change the mesh
|
||||
map = meshMod.changeMesh(mesh, true);
|
||||
|
||||
// Update fields
|
||||
mesh.topoChange(map);
|
||||
|
||||
// Move mesh (since morphing does not do this)
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
else
|
||||
{
|
||||
// Delete mesh volumes. No other way to do this?
|
||||
mesh.clearOut();
|
||||
}
|
||||
// Delete mesh volumes. No other way to do this?
|
||||
mesh.clearOut();
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -303,22 +285,14 @@ label mergeEdges(const scalar minCos, polyMesh& mesh)
|
||||
|
||||
pointRemover.setRefinement(pointCanBeDeleted, meshMod);
|
||||
|
||||
// Change the mesh (no inflation)
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh, false, true);
|
||||
// Change the mesh
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh);
|
||||
|
||||
// Update fields
|
||||
mesh.topoChange(map);
|
||||
|
||||
// Move mesh (since morphing does not do this)
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
else
|
||||
{
|
||||
// Delete mesh volumes. No other way to do this?
|
||||
mesh.clearOut();
|
||||
}
|
||||
// Delete mesh volumes. No other way to do this?
|
||||
mesh.clearOut();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -139,7 +139,7 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
// Create mesh, return map from old to new mesh.
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh, false);
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh);
|
||||
|
||||
// Update fields
|
||||
mesh.topoChange(map);
|
||||
@ -147,12 +147,6 @@ int main(int argc, char *argv[])
|
||||
// Update numbering of cells/vertices.
|
||||
meshCutter.topoChange(map);
|
||||
|
||||
// Optionally inflate mesh
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
|
||||
Info<< "Refined from " << returnReduce(map().nOldCells(), sumOp<label>())
|
||||
<< " to " << mesh.globalData().nTotalCells() << " cells." << nl << endl;
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2024 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -239,12 +239,7 @@ int main(int argc, char *argv[])
|
||||
runTime++;
|
||||
}
|
||||
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh, false);
|
||||
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh);
|
||||
|
||||
// Update stored labels on meshCutter.
|
||||
cutter.topoChange(map());
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2024 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -135,16 +135,10 @@ int main(int argc, char *argv[])
|
||||
meshMod
|
||||
);
|
||||
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh, false);
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh);
|
||||
|
||||
mesh.topoChange(map);
|
||||
|
||||
// Move mesh (since morphing does not do this)
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
|
||||
// Update numbering of cells/vertices.
|
||||
faceRemover.topoChange(map);
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Copyright (C) 2011-2023 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2024 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -683,12 +683,7 @@ int main(int argc, char *argv[])
|
||||
runTime++;
|
||||
}
|
||||
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh, false);
|
||||
|
||||
if (map().hasMotionPoints())
|
||||
{
|
||||
mesh.setPoints(map().preMotionPoints());
|
||||
}
|
||||
autoPtr<polyTopoChangeMap> map = meshMod.changeMesh(mesh);
|
||||
|
||||
// Update stored labels on meshCutter
|
||||
cutter.topoChange(map());
|
||||
|
||||
Reference in New Issue
Block a user