From 57f924feefebaac72cc28433b3c8e7b287ed2dd0 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Thu, 12 Mar 2020 08:21:12 +0000 Subject: [PATCH] turbulenceModels/laminar::Maxwell: Updated handling of single mode A single mode may now be specified either with the 'modes' list containing a single entry: // Example 1-mode specification modes ( { lambda 0.01; } ); or by specifying the 'lambda' entry without 'modes' // Single mode coefficient lambda 0.03; If both are provided the 'modes' entry will be used and a warning about the unused 'lambda' entry printed. --- .../turbulenceModels/laminar/Maxwell/Maxwell.C | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/TurbulenceModels/turbulenceModels/laminar/Maxwell/Maxwell.C b/src/TurbulenceModels/turbulenceModels/laminar/Maxwell/Maxwell.C index 905c440c27..24f88348b8 100644 --- a/src/TurbulenceModels/turbulenceModels/laminar/Maxwell/Maxwell.C +++ b/src/TurbulenceModels/turbulenceModels/laminar/Maxwell/Maxwell.C @@ -46,12 +46,12 @@ Maxwell::readModeCoefficients { PtrList modeCoeffs(nModes_); - if (nModes_ > 1) + if (modeCoefficients_.size()) { if (this->coeffDict().found(name)) { IOWarningInFunction(this->coeffDict()) - << "For multi-mode entry '" << name << "' will be ignored." + << "Using 'modes' list, '" << name << "' entry will be ignored." << endl; } @@ -71,12 +71,6 @@ Maxwell::readModeCoefficients } else { - if (modeCoefficients_.size() == 1) - { - IOWarningInFunction(this->coeffDict()) - << "For single mode 'modes' entry will be ignored." << endl; - } - modeCoeffs.set ( 0,