Commit 9331bd89 authored by mattijs's avatar mattijs
Browse files

ENH: motionSmoother: allow certain tolerance when comparing coupled data

parent 322ccff4
......@@ -774,7 +774,8 @@ Foam::tmp<Foam::scalarField> Foam::motionSmoother::movePoints
newPoints,
minEqOp<point>(), // combine op
vector(GREAT,GREAT,GREAT), // null
true // separation
true, // separation
1E-6*mesh_.bounds().mag()
);
}
......@@ -925,7 +926,8 @@ bool Foam::motionSmoother::scaleMesh
totalDisplacement,
maxMagEqOp(),
vector::zero, // null value
false // separation
false, // separation
1E-6*mesh_.bounds().mag()
);
}
......
......@@ -208,7 +208,8 @@ class motionSmoother
const Field<Type>&,
const CombineOp& cop,
const Type& zero,
const bool separation
const bool separation,
const scalar maxMag
) const;
//- Assemble tensors for multi-patch constraints
......
......@@ -293,6 +293,7 @@ void Foam::motionSmoother::testSyncField
const CombineOp& cop,
const Type& zero,
const bool separation
const scalar maxMag
) const
{
if (debug)
......@@ -315,6 +316,7 @@ void Foam::motionSmoother::testSyncField
forAll(syncedFld, i)
{
if (syncedFld[i] != fld[i])
if (mag(syncedFld[i] - fld[i]) > maxMag)
{
FatalErrorIn
(
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment