Cloud post-processing data not written when steady case converges using residualControl
Summary
When using clouds in steady solvers combined with case termination controls set using residualControl
in the fvSolution
file, cloud post-processing data are not written on the last iteration.
Steps to reproduce
Add residualControl
settings to a steady flow solver with cloud functionality and cloud a post-processing object, e.g. particleTracks
particleTracks
{
type particleTracks;
trackInterval 5;
maxSamples 1000000;
resetOnWrite yes;
}
and notice that the cloud post-processing data are not written
Example case
What is the current bug behaviour?
When the criteria specified in the residualControls
dictionary are achieved the solver loop calls time.writeAndEnd()
to write any objects registered with AUTO_WRITE
and exits. Operations such as cloud post-processing are currently only triggered when evolving the cloud and intercept the writeTime()
flag and are therefore missed.
What is the expected correct behavior?
Relevant logs and/or images
Environment information
- OpenFOAM version :
- Operating system :
- Hardware info :
- Compiler :
Possible fixes
Couple of options
- instead of exiting straight away, run for 1 more iteration with the
writeTime_
flag set (e.g. usingtime.writeOnce()
and exit - intercept the
write()
call to trigger other post-processing actions