From e2bffde2aaa85208a5a77d66ed871b8e6087ba9d Mon Sep 17 00:00:00 2001 From: Hrvoje Jasak Date: Mon, 1 Jul 2019 18:13:23 +0100 Subject: [PATCH] Improved initial deltaT controls --- .../cfdTools/general/include/setInitialDeltaT.H | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/finiteVolume/cfdTools/general/include/setInitialDeltaT.H b/src/finiteVolume/cfdTools/general/include/setInitialDeltaT.H index 199bd2d1f..05157927c 100644 --- a/src/finiteVolume/cfdTools/general/include/setInitialDeltaT.H +++ b/src/finiteVolume/cfdTools/general/include/setInitialDeltaT.H @@ -36,10 +36,14 @@ if (adjustTimeStep) { runTime.setDeltaT ( - min + Foam::min ( - maxCo*runTime.deltaT().value()/CoNum, - maxDeltaT + runTime.deltaT().value(), + Foam::min + ( + maxCo*runTime.deltaT().value()/CoNum, + maxDeltaT + ) ) ); }