CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

Change writeIntervall during simulation

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 2 Post By Zbynek

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 8, 2017, 03:17
Default Change writeIntervall during simulation
  #1
New Member
 
Join Date: Apr 2014
Posts: 8
Rep Power: 12
Christian86 is on a distinguished road
hi there,

i want to write out my fields in logarithmic timesteps. Since now, i´m restarting my simulation after a decade with an new writeIntervall.
Is there a possiblity to change the writeIntervall during the simulation?

Regards

Christian
Christian86 is offline   Reply With Quote

Old   February 9, 2017, 04:20
Default
  #2
Senior Member
 
Joachim Herb
Join Date: Sep 2010
Posts: 650
Rep Power: 21
jherb is on a distinguished road
The system/controlDict file is read after each time step (if you set runTimeModifiable to yes). So you can change it during the simulation and it will use the new settings for the next time step.

Of course this is not automatic. So perhaps, you can write a shell/Python script, which continuously reads the log file and modifies the controlDict, if a certain time step has been reached.
jherb is offline   Reply With Quote

Old   February 10, 2017, 05:07
Default
  #3
Member
 
Join Date: Jun 2016
Posts: 66
Rep Power: 10
Zbynek is on a distinguished road
You can automate the procedure using timeActivatedFileUpdate utility. It allows you to specify a number of files (controlDict in your case) that are read at specified time steps. So if you will not have too many changes in the writeInterval, you can simply create a few controlDict versions and specify in timeActivatedFileUpdate file at which time they should be used.
Christian86 and dhblyy like this.
Zbynek is offline   Reply With Quote

Old   February 10, 2017, 05:10
Default
  #4
New Member
 
Join Date: Apr 2014
Posts: 8
Rep Power: 12
Christian86 is on a distinguished road
Thanks for your replys.

The solution by Zbynek seems to be very comfortable, so i´ll look for this one.
Christian86 is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Heat pipe simulation with phase change mecman OpenFOAM Running, Solving & CFD 10 May 8, 2020 03:42
How to use "translation" in solidBodyMotionFunction in OpenFOAM rupesh_w OpenFOAM Running, Solving & CFD 5 August 16, 2016 04:27
Phase change from liquid to vapor in a nozzle SebastianSchuster CFX 6 September 28, 2015 22:02
restarting paused transient simulation using reactingFoam JMDag2004 OpenFOAM Running, Solving & CFD 1 August 10, 2015 10:15
How to change orientation of body in boat simulation?? sanjay STAR-CCM+ 7 January 15, 2012 00:24


All times are GMT -4. The time now is 16:56.