ENH: AMI - improved output messages

This commit is contained in:
andy
2014-01-20 13:15:10 +00:00
parent 2b47fbca8f
commit b1e7c00952
2 changed files with 20 additions and 17 deletions

View File

@ -247,15 +247,18 @@ void Foam::AMIInterpolation<SourcePatch, TargetPatch>::normaliseWeights
<< gMin(wghtSum) << ", " << gMin(wghtSum) << ", "
<< gMax(wghtSum) << ", " << gMax(wghtSum) << ", "
<< gAverage(wghtSum) << endl; << gAverage(wghtSum) << endl;
}
}
if (debug && nLowWeight) const label nLow = returnReduce(nLowWeight, sumOp<label>());
if (nLow)
{ {
Pout<< "AMI: Identified " << nLowWeight IInfo<< "AMI: Patch " << patchName
<< " identified " << nLow
<< " faces with weights less than " << lowWeightTol << " faces with weights less than " << lowWeightTol
<< endl; << endl;
} }
}
}
} }
@ -784,6 +787,14 @@ void Foam::AMIInterpolation<SourcePatch, TargetPatch>::update
const TargetPatch& tgtPatch const TargetPatch& tgtPatch
) )
{ {
label srcTotalSize = returnReduce(srcPatch.size(), sumOp<label>());
label tgtTotalSize = returnReduce(tgtPatch.size(), sumOp<label>());
IInfo<< "AMI: Creating addressing and weights between "
<< srcTotalSize << " source faces and "
<< tgtTotalSize << " target faces"
<< endl;
// Calculate face areas // Calculate face areas
srcMagSf_.setSize(srcPatch.size()); srcMagSf_.setSize(srcPatch.size());
forAll(srcMagSf_, faceI) forAll(srcMagSf_, faceI)
@ -956,7 +967,6 @@ void Foam::AMIInterpolation<SourcePatch, TargetPatch>::update
} }
else else
{ {
// calculate AMI interpolation // calculate AMI interpolation
autoPtr<AMIMethod<SourcePatch, TargetPatch> > AMIPtr autoPtr<AMIMethod<SourcePatch, TargetPatch> > AMIPtr
( (

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | \\ / O peration |
\\ / A nd | Copyright (C) 2013 OpenFOAM Foundation \\ / A nd | Copyright (C) 2013-2014 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -337,14 +337,7 @@ Foam::AMIMethod<SourcePatch, TargetPatch>::AMIMethod
tgtMagSf_(tgtMagSf), tgtMagSf_(tgtMagSf),
srcNonOverlap_(), srcNonOverlap_(),
triMode_(triMode) triMode_(triMode)
{ {}
label srcSize = returnReduce(srcPatch_.size(), sumOp<label>());
label tgtSize = returnReduce(tgtPatch_.size(), sumOp<label>());
IInfo<< "AMI: Creating addressing and weights between "
<< srcSize << " source faces and " << tgtSize << " target faces"
<< endl;
}
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //