mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: AMI - added optional normailisation flag/function
This commit is contained in:
@ -241,17 +241,16 @@ Foam::label Foam::AMIMethod<SourcePatch, TargetPatch>::findTargetFace
|
||||
|
||||
pointIndexHit sample = treePtr_->findNearest(srcPt, 10.0*srcFaceArea);
|
||||
|
||||
|
||||
if (debug)
|
||||
{
|
||||
Pout<< "Source point = " << srcPt << ", Sample point = "
|
||||
<< sample.hitPoint() << ", Sample index = " << sample.index()
|
||||
<< endl;
|
||||
}
|
||||
|
||||
if (sample.hit())
|
||||
{
|
||||
targetFaceI = sample.index();
|
||||
|
||||
if (debug)
|
||||
{
|
||||
Pout<< "Source point = " << srcPt << ", Sample point = "
|
||||
<< sample.hitPoint() << ", Sample index = " << sample.index()
|
||||
<< endl;
|
||||
}
|
||||
}
|
||||
|
||||
return targetFaceI;
|
||||
@ -352,4 +351,13 @@ Foam::AMIMethod<SourcePatch, TargetPatch>::~AMIMethod()
|
||||
{}
|
||||
|
||||
|
||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||
|
||||
template<class SourcePatch, class TargetPatch>
|
||||
bool Foam::AMIMethod<SourcePatch, TargetPatch>::normalise() const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -207,6 +207,9 @@ public:
|
||||
// Note: this should be empty for correct functioning
|
||||
inline const labelList& srcNonOverlap() const;
|
||||
|
||||
//- Flag to indicate that weights should be normalised
|
||||
virtual bool normalise() const;
|
||||
|
||||
|
||||
// Manipulation
|
||||
|
||||
|
||||
Reference in New Issue
Block a user