From bb4083f57007256db6c1cb718aeb7d52c529cc3f Mon Sep 17 00:00:00 2001 From: asanaz Date: Thu, 13 Aug 2020 15:48:12 +0200 Subject: [PATCH] optional checkTimeStep & reading virtualTimeIndex in the solver --- src/recurrence/recModel/recModel/recModel.H | 1 + .../recModel/standardRecModel/standardRecModel.C | 11 ++++++++++- .../recModel/standardRecModel/standardRecModel.H | 2 ++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/src/recurrence/recModel/recModel/recModel.H b/src/recurrence/recModel/recModel/recModel.H index 95f63797..2c652a25 100644 --- a/src/recurrence/recModel/recModel/recModel.H +++ b/src/recurrence/recModel/recModel/recModel.H @@ -224,6 +224,7 @@ public: } virtual void updateRecFields() = 0; + virtual label currentTimeIndex() const = 0; virtual void writeRecMatrix() const = 0; diff --git a/src/recurrence/recModel/standardRecModel/standardRecModel.C b/src/recurrence/recModel/standardRecModel/standardRecModel.C index e6e9fdc7..b6350356 100644 --- a/src/recurrence/recModel/standardRecModel/standardRecModel.C +++ b/src/recurrence/recModel/standardRecModel/standardRecModel.C @@ -63,6 +63,7 @@ standardRecModel::standardRecModel cumulativeNumRecFields_(), totNumRecFields_(0), storeAveragedFields_(propsDict_.lookupOrDefault("storeAveragedFields",false)), + checkTimeStep_(propsDict_.lookupOrDefault("checkTimeStep",true)), recurrenceMatrix_(1,scalar(-1.0)), timeIndexList_(), timeValueList_(), @@ -127,7 +128,11 @@ standardRecModel::standardRecModel // check if time steps in databases are consistent // if no initial number of time steps has been specified, create path for full runtime immediately - recTimeStep_ = checkTimeStep(); + if(checkTimeStep_) + { + recTimeStep_ = checkTimeStep(); + } + if(totRecSteps_ < 0) { totRecSteps_ = 1 + static_cast