Better debug data for ggi and regionCouple
This commit is contained in:
parent
18de725d8f
commit
c8cd512a24
2 changed files with 85 additions and 26 deletions
|
@ -1113,7 +1113,7 @@ void Foam::ggiPolyPatch::updateMesh()
|
||||||
|
|
||||||
void Foam::ggiPolyPatch::calcTransforms() const
|
void Foam::ggiPolyPatch::calcTransforms() const
|
||||||
{
|
{
|
||||||
// Simplest mixing plane: no transform or separation. HJ, 24/Oct/2008
|
// Simplest interface: no transform or separation. HJ, 24/Oct/2008
|
||||||
forwardT_.setSize(0);
|
forwardT_.setSize(0);
|
||||||
reverseT_.setSize(0);
|
reverseT_.setSize(0);
|
||||||
separation_.setSize(0);
|
separation_.setSize(0);
|
||||||
|
@ -1167,6 +1167,7 @@ void Foam::ggiPolyPatch::calcTransforms() const
|
||||||
<< patchToPatch().uncoveredSlaveFaces().size()
|
<< patchToPatch().uncoveredSlaveFaces().size()
|
||||||
<< " shadow().localPoints(): " << shadow().localPoints().size()
|
<< " shadow().localPoints(): " << shadow().localPoints().size()
|
||||||
<< endl;
|
<< endl;
|
||||||
|
|
||||||
indirectPrimitivePatch::writeVTK
|
indirectPrimitivePatch::writeVTK
|
||||||
(
|
(
|
||||||
fvPath/fileName("uncoveredGgiFaces" + shadowName()),
|
fvPath/fileName("uncoveredGgiFaces" + shadowName()),
|
||||||
|
@ -1180,31 +1181,7 @@ void Foam::ggiPolyPatch::calcTransforms() const
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check for bridge overlap
|
// Check for bridge overlap
|
||||||
if (!bridgeOverlap())
|
if (bridgeOverlap())
|
||||||
{
|
|
||||||
if
|
|
||||||
(
|
|
||||||
(
|
|
||||||
patchToPatch().uncoveredMasterFaces().size() > 0
|
|
||||||
&& !empty()
|
|
||||||
)
|
|
||||||
|| (
|
|
||||||
!shadow().empty()
|
|
||||||
&& patchToPatch().uncoveredSlaveFaces().size() > 0
|
|
||||||
)
|
|
||||||
)
|
|
||||||
{
|
|
||||||
FatalErrorIn("label ggiPolyPatch::calcTransforms() const")
|
|
||||||
<< "ggi patch " << name() << " with shadow "
|
|
||||||
<< shadowName() << " has "
|
|
||||||
<< patchToPatch().uncoveredMasterFaces().size()
|
|
||||||
<< " uncovered master faces and "
|
|
||||||
<< patchToPatch().uncoveredSlaveFaces().size()
|
|
||||||
<< " uncovered slave faces. Bridging is switched off. "
|
|
||||||
<< abort(FatalError);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
{
|
||||||
InfoIn("label ggiPolyPatch::calcTransforms() const")
|
InfoIn("label ggiPolyPatch::calcTransforms() const")
|
||||||
<< "ggi patch " << name() << " with shadow "
|
<< "ggi patch " << name() << " with shadow "
|
||||||
|
|
|
@ -35,6 +35,7 @@ Author
|
||||||
#include "polyPatchID.H"
|
#include "polyPatchID.H"
|
||||||
#include "ZoneIDs.H"
|
#include "ZoneIDs.H"
|
||||||
#include "objectRegistry.H"
|
#include "objectRegistry.H"
|
||||||
|
#include "indirectPrimitivePatch.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
@ -1207,6 +1208,87 @@ void Foam::regionCouplePolyPatch::calcTransforms() const
|
||||||
forwardT_.setSize(0);
|
forwardT_.setSize(0);
|
||||||
reverseT_.setSize(0);
|
reverseT_.setSize(0);
|
||||||
separation_.setSize(0);
|
separation_.setSize(0);
|
||||||
|
|
||||||
|
if (debug > 1 && master())
|
||||||
|
{
|
||||||
|
if
|
||||||
|
(
|
||||||
|
!empty()
|
||||||
|
&& patchToPatch().uncoveredMasterFaces().size() > 0
|
||||||
|
)
|
||||||
|
{
|
||||||
|
// Write uncovered master faces
|
||||||
|
Info<< "Writing uncovered master faces for patch "
|
||||||
|
<< name() << " as VTK." << endl;
|
||||||
|
|
||||||
|
const polyMesh& mesh = boundaryMesh().mesh();
|
||||||
|
|
||||||
|
fileName fvPath(mesh.time().path()/"VTK");
|
||||||
|
mkDir(fvPath);
|
||||||
|
|
||||||
|
indirectPrimitivePatch::writeVTK
|
||||||
|
(
|
||||||
|
fvPath/fileName("uncoveredRegionCoupleFaces" + name()),
|
||||||
|
IndirectList<face>
|
||||||
|
(
|
||||||
|
localFaces(),
|
||||||
|
patchToPatch().uncoveredMasterFaces()
|
||||||
|
),
|
||||||
|
localPoints()
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
if
|
||||||
|
(
|
||||||
|
!shadow().empty()
|
||||||
|
&& patchToPatch().uncoveredSlaveFaces().size() > 0
|
||||||
|
)
|
||||||
|
{
|
||||||
|
// Write uncovered master faces
|
||||||
|
Info<< "Writing uncovered shadow faces for patch "
|
||||||
|
<< shadowPatchName() << " as VTK." << endl;
|
||||||
|
|
||||||
|
const polyMesh& mesh = boundaryMesh().mesh();
|
||||||
|
|
||||||
|
fileName fvPath(mesh.time().path()/"VTK");
|
||||||
|
mkDir(fvPath);
|
||||||
|
Pout<< "Patch " << name()
|
||||||
|
<< " shadow().localFaces(): " << shadow().localFaces().size()
|
||||||
|
<< " patchToPatch().uncoveredSlaveFaces().size(): "
|
||||||
|
<< patchToPatch().uncoveredSlaveFaces().size()
|
||||||
|
<< " shadow().localPoints(): " << shadow().localPoints().size()
|
||||||
|
<< endl;
|
||||||
|
|
||||||
|
indirectPrimitivePatch::writeVTK
|
||||||
|
(
|
||||||
|
fvPath/fileName
|
||||||
|
(
|
||||||
|
"uncoveredRegionCoupleFaces"
|
||||||
|
+ shadowPatchName()
|
||||||
|
),
|
||||||
|
IndirectList<face>
|
||||||
|
(
|
||||||
|
shadow().localFaces(),
|
||||||
|
patchToPatch().uncoveredSlaveFaces()
|
||||||
|
),
|
||||||
|
shadow().localPoints()
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Check for bridge overlap
|
||||||
|
if (bridgeOverlap())
|
||||||
|
{
|
||||||
|
InfoInFunction
|
||||||
|
<< "regionCouple patch " << name() << " with shadow "
|
||||||
|
<< shadowPatchName() << " on region " << shadowRegionName()
|
||||||
|
<< " has "
|
||||||
|
<< patchToPatch().uncoveredMasterFaces().size()
|
||||||
|
<< " uncovered master faces and "
|
||||||
|
<< patchToPatch().uncoveredSlaveFaces().size()
|
||||||
|
<< " uncovered slave faces. Bridging is switched on. "
|
||||||
|
<< endl;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Reference in a new issue