Skip to content
Snippets Groups Projects
Commit a71172b6 authored by mattijs's avatar mattijs
Browse files

ENH: cyclicPeriodic: add some printing

parent 604166a2
No related branches found
No related tags found
No related merge requests found
...@@ -535,8 +535,36 @@ void Foam::cyclicPeriodicAMIPolyPatch::resetAMI ...@@ -535,8 +535,36 @@ void Foam::cyclicPeriodicAMIPolyPatch::resetAMI
<< endl; << endl;
} }
// Normalise the weights // Normalise the weights. Disable printing since weights are
// still areas.
AMIPtr_->normaliseWeights(true, false); AMIPtr_->normaliseWeights(true, false);
// Print some statistics
const label nFace = returnReduce(size(), sumOp<label>());
if (nFace)
{
scalarField srcWghtSum(size(), 0);
scalarField tgtWghtSum(size(), 0);
forAll(*this, faceI)
{
srcWghtSum[faceI] = sum(AMIPtr_->srcWeights()[faceI]);
tgtWghtSum[faceI] = sum(AMIPtr_->tgtWeights()[faceI]);
}
Info<< indent
<< "AMI: Patch " << name()
<< " sum(weights) min/max/average = "
<< gMin(srcWghtSum) << ", "
<< gMax(srcWghtSum) << ", "
<< gAverage(srcWghtSum) << endl;
Info<< indent
<< "AMI: Patch " << neighbPatch().name()
<< " sum(weights) min/max/average = "
<< gMin(tgtWghtSum) << ", "
<< gMax(tgtWghtSum) << ", "
<< gAverage(tgtWghtSum) << endl;
}
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment