mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: snappyHexMesh: additional checking for faceZones on processor boundaries
This commit is contained in:
@ -1248,6 +1248,12 @@ void Foam::autoRefineDriver::doRefine
|
|||||||
decomposer_,
|
decomposer_,
|
||||||
distributor_
|
distributor_
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
if (debug)
|
||||||
|
{
|
||||||
|
meshRefiner_.checkZoneFaces();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -870,6 +870,9 @@ public:
|
|||||||
const labelList& neiPatch
|
const labelList& neiPatch
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//- Debug helper: check faceZones are not on processor patches
|
||||||
|
void checkZoneFaces() const;
|
||||||
|
|
||||||
//- Create baffles for faces straddling zoned surfaces. Return
|
//- Create baffles for faces straddling zoned surfaces. Return
|
||||||
// baffles.
|
// baffles.
|
||||||
autoPtr<mapPolyMesh> createZoneBaffles
|
autoPtr<mapPolyMesh> createZoneBaffles
|
||||||
|
|||||||
@ -531,6 +531,36 @@ Foam::autoPtr<Foam::mapPolyMesh> Foam::meshRefinement::createBaffles
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void Foam::meshRefinement::checkZoneFaces() const
|
||||||
|
{
|
||||||
|
const faceZoneMesh& fZones = mesh_.faceZones();
|
||||||
|
|
||||||
|
const polyBoundaryMesh& pbm = mesh_.boundaryMesh();
|
||||||
|
|
||||||
|
forAll(pbm, patchI)
|
||||||
|
{
|
||||||
|
const polyPatch& pp = pbm[patchI];
|
||||||
|
|
||||||
|
if (isA<processorPolyPatch>(pp))
|
||||||
|
{
|
||||||
|
forAll(pp, i)
|
||||||
|
{
|
||||||
|
label faceI = pp.start()+i;
|
||||||
|
label zoneI = fZones.whichZone(faceI);
|
||||||
|
|
||||||
|
if (zoneI != -1)
|
||||||
|
{
|
||||||
|
FatalErrorIn("meshRefinement::checkZoneFaces")
|
||||||
|
<< "face:" << faceI << " on patch " << pp.name()
|
||||||
|
<< " is in zone " << fZones[zoneI].name()
|
||||||
|
<< exit(FatalError);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
Foam::autoPtr<Foam::mapPolyMesh> Foam::meshRefinement::createZoneBaffles
|
Foam::autoPtr<Foam::mapPolyMesh> Foam::meshRefinement::createZoneBaffles
|
||||||
(
|
(
|
||||||
const labelList& globalToMasterPatch,
|
const labelList& globalToMasterPatch,
|
||||||
|
|||||||
Reference in New Issue
Block a user