From 85e0d4f65e92877b5d1e7570e95171d39dadd481 Mon Sep 17 00:00:00 2001 From: Hrvoje Jasak Date: Fri, 15 Mar 2019 10:46:57 +0000 Subject: [PATCH] Improbed Marooney Maneouvre debug message --- .../immersedBoundaryPolyPatch.C | 27 +++++++++++++++---- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/src/immersedBoundary/immersedBoundary/immersedBoundaryPolyPatch/immersedBoundaryPolyPatch.C b/src/immersedBoundary/immersedBoundary/immersedBoundaryPolyPatch/immersedBoundaryPolyPatch.C index eecf13f08..8c073b32f 100644 --- a/src/immersedBoundary/immersedBoundary/immersedBoundaryPolyPatch/immersedBoundaryPolyPatch.C +++ b/src/immersedBoundary/immersedBoundary/immersedBoundaryPolyPatch/immersedBoundaryPolyPatch.C @@ -1232,6 +1232,8 @@ void Foam::immersedBoundaryPolyPatch::calcCorrectedGeometry() const const labelList& owner = mesh.faceOwner(); + label nMarooneyCells = 0; + forAll (cutCells, cutCellI) { const label ccc = cutCells[cutCellI]; @@ -1271,16 +1273,31 @@ void Foam::immersedBoundaryPolyPatch::calcCorrectedGeometry() const // if (mag(curSumSf + ibSf[cutCellI]) > 1e-6*curSumMagSf) if (mag(curSumSf + ibSf[cutCellI]) > primitiveMesh::closedThreshold_) { - Info<< "Marooney Maneouvre for cell " << ccc - << " error: " << mag(curSumSf + ibSf[cutCellI]) << " " - << " S: " << curSumMagSf - << " V: " << cutCellVolumes[cutCellI] - << " Sf: " << ibSf[cutCellI] << endl; + // Info<< "Marooney Maneouvre for cell " << ccc + // << " error: " << mag(curSumSf + ibSf[cutCellI]) << " " + // << " S: " << curSumMagSf + // << " V: " << cutCellVolumes[cutCellI] + // << " Sf: " << ibSf[cutCellI] << endl; + nMarooneyCells++; + // Create IB face to ideally close the cell ibSf[cutCellI] = -curSumSf; } } + + if (debug) + { + if (nMarooneyCells > 0) + { + InfoIn + ( + "void immersedBoundaryPolyPatch::calcCorrectedGeometry() const" + ) << "Marooney Maneouvre used for " << nMarooneyCells + << " out of " << cutCells.size() + << endl; + } + } }