Commit 3f2b57f0 authored by mattijs's avatar mattijs
Browse files

BUG: Always do topological walking to correct cellZones.

parent 0b54b4b1
......@@ -2327,9 +2327,11 @@ Foam::autoPtr<Foam::mapPolyMesh> Foam::meshRefinement::zonify
// Set using walking
// ~~~~~~~~~~~~~~~~~
if (!allowFreeStandingZoneFaces)
//if (!allowFreeStandingZoneFaces)
{
Info<< "Walking to assign cellZones." << nl << endl;
Info<< "Walking from location-in-mesh " << keepPoint
<< " to assign cellZones "
<< "- crossing a faceZone face changes cellZone" << nl << endl;
// Topological walk
findCellZoneTopo
......
......@@ -77,11 +77,22 @@ Foam::refinementSurfaces::refinementSurfaces
if (dict.found("faceZone"))
{
dict.lookup("faceZone") >> faceZoneNames_[surfI];
bool hasSide = dict.readIfPresent("zoneInside", zoneInside_[surfI]);
if (dict.readIfPresent("cellZone", cellZoneNames_[surfI]))
{
dict.lookup("zoneInside") >> zoneInside_[surfI];
if (hasSide && !allGeometry_[surfaces_[surfI]].hasVolumeType())
{
IOWarningIn
(
"refinementSurfaces::refinementSurfaces(..)",
dict
) << "Unused entry zoneInside for faceZone "
<< faceZoneNames_[surfI]
<< " since surface " << names_[surfI]
<< " is not closed." << endl;
}
}
else if (dict.found("zoneInside"))
else if (hasSide)
{
IOWarningIn("refinementSurfaces::refinementSurfaces(..)", dict)
<< "Unused entry zoneInside for faceZone "
......@@ -324,11 +335,30 @@ Foam::refinementSurfaces::refinementSurfaces
if (dict.found("faceZone"))
{
dict.lookup("faceZone") >> faceZoneNames_[surfI];
bool hasSide = dict.readIfPresent
(
"zoneInside",
zoneInside_[surfI]
);
if (dict.readIfPresent("cellZone", cellZoneNames_[surfI]))
{
dict.lookup("zoneInside") >> zoneInside_[surfI];
if
(
hasSide
&& !allGeometry_[surfaces_[surfI]].hasVolumeType()
)
{
IOWarningIn
(
"refinementSurfaces::refinementSurfaces(..)",
dict
) << "Unused entry zoneInside for faceZone "
<< faceZoneNames_[surfI]
<< " since surface " << names_[surfI]
<< " is not closed." << endl;
}
}
else if (dict.found("zoneInside"))
else if (hasSide)
{
IOWarningIn
(
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment