View Issue Details

IDProjectCategoryView StatusLast Update
0004106OpenFOAMBugpublic2024-07-02 14:38
Reportercgoessni Assigned Towill  
PrioritylowSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Versiondev 
Fixed in Versiondev 
Summary0004106: stopAtTimeStep does not convert input from userTime to real time
DescriptionWhen using stopAtTimeStep function object, we see unexpected stops when having userUnit engine in place, since stopAtTimeStep misses a conversion from userTime to real time.
Additional InformationThis diff solves the issue for us:

diff --git a/src/functionObjects/utilities/stopAt/stopAtTimeStep/stopAtTimeStep.C b/src/functionObjects/utilities/stopAt/stopAtTimeStep/stopAtTimeStep.C
index 8ca4fc7..c920b77 100644
--- a/src/functionObjects/utilities/stopAt/stopAtTimeStep/stopAtTimeStep.C
+++ b/src/functionObjects/utilities/stopAt/stopAtTimeStep/stopAtTimeStep.C
@@ -81,7 +81,7 @@ Foam::functionObjects::stopAtTimeStep::~stopAtTimeStep()
 bool Foam::functionObjects::stopAtTimeStep::read(const dictionary& dict)
 {
     stopAt::read(dict);
- dict.lookup("minDeltaT") >> minDeltaT_;
+ minDeltaT_ = dict.lookup<scalar>("minDeltaT", time_.userUnits());

     return true;
 }
TagsNo tags attached.

Activities

cgoessni

2024-07-01 15:33

reporter   ~0013290

I meant userTime engine, not userTime.

will

2024-07-02 14:38

manager   ~0013299

Thanks. Resolved here:

https://github.com/OpenFOAM/OpenFOAM-dev/commit/51a233771829cc35b3c31e69486ee29b8c051eaa

Issue History

Date Modified Username Field Change
2024-07-01 10:29 cgoessni New Issue
2024-07-01 15:33 cgoessni Note Added: 0013290
2024-07-02 14:38 will Assigned To => will
2024-07-02 14:38 will Status new => resolved
2024-07-02 14:38 will Resolution open => fixed
2024-07-02 14:38 will Fixed in Version => dev
2024-07-02 14:38 will Note Added: 0013299