diff --git a/src/functionObjects/field/stabilityBlendingFactor/stabilityBlendingFactor.C b/src/functionObjects/field/stabilityBlendingFactor/stabilityBlendingFactor.C index d7c660adf0..12b05143bc 100644 --- a/src/functionObjects/field/stabilityBlendingFactor/stabilityBlendingFactor.C +++ b/src/functionObjects/field/stabilityBlendingFactor/stabilityBlendingFactor.C @@ -48,6 +48,37 @@ namespace functionObjects // * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +void Foam::functionObjects::stabilityBlendingFactor::calcStats +( + label& nCellsScheme1, + label& nCellsScheme2, + label& nCellsBlended +) const +{ + forAll(indicator_, celli) + { + scalar i = indicator_[celli]; + + if (i < tolerance_) + { + nCellsScheme2++; + } + else if (i > (1 - tolerance_)) + { + nCellsScheme1++; + } + else + { + nCellsBlended++; + } + } + + reduce(nCellsScheme1, sumOp