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

How to resume a stopped simulation

Register Blogs Community New Posts Updated Threads Search

Like Tree9Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 14, 2020, 16:16
Default
  #21
Member
 
Muhammad Kashif Jawad
Join Date: Oct 2019
Location: Pakistan
Posts: 48
Rep Power: 6
mkjmalik is an unknown quantity at this point
Thanks foe your quick reply..

You mean i can copy my previous file and then i can add this to my new generated log file for plotting?
mkjmalik is offline   Reply With Quote

Old   August 14, 2020, 16:19
Default
  #22
Senior Member
 
cdegroot's Avatar
 
Chris DeGroot
Join Date: Nov 2011
Location: Canada
Posts: 414
Rep Power: 18
cdegroot is on a distinguished road
Quote:
Originally Posted by mkjmalik View Post
Thanks foe your quick reply..

You mean i can copy my previous file and then i can add this to my new generated log file for plotting?
Your original question did not mention that you were using the log file for plotting, so I didn't consider this. Probably what you can do is what I said and then combine the two files in sequence using the "cat" command in the terminal.
__________________
Chris DeGroot, PhD, PEng
CEO, Maple Key Labs
www.maplekeylabs.com
cdegroot is offline   Reply With Quote

Old   August 14, 2020, 16:21
Default
  #23
Member
 
Muhammad Kashif Jawad
Join Date: Oct 2019
Location: Pakistan
Posts: 48
Rep Power: 6
mkjmalik is an unknown quantity at this point
Sorry for this I’m actually a newbie..

I will use cat command after my simulation ends?
mkjmalik is offline   Reply With Quote

Old   August 14, 2020, 16:25
Default
  #24
Senior Member
 
cdegroot's Avatar
 
Chris DeGroot
Join Date: Nov 2011
Location: Canada
Posts: 414
Rep Power: 18
cdegroot is on a distinguished road
Quote:
Originally Posted by mkjmalik View Post
Sorry for this I’m actually a newbie..

I will use cat command after my simulation ends?
If you had two log files, e.g. log0.dat and log1.dat you could do the following to combine them:

Code:
cat log0.dat log1.dat > log.dat
This would create a combined log file called log.dat with the contents of both files in sequence. It will work as long as the data you are extracting is assumed to be printed out in sequence. The header information for both simulations will be retained in the combined file.
__________________
Chris DeGroot, PhD, PEng
CEO, Maple Key Labs
www.maplekeylabs.com
cdegroot is offline   Reply With Quote

Old   August 14, 2020, 16:27
Default
  #25
Member
 
Muhammad Kashif Jawad
Join Date: Oct 2019
Location: Pakistan
Posts: 48
Rep Power: 6
mkjmalik is an unknown quantity at this point
Thankssss alot..

Can i ask One question about paraview?
mkjmalik is offline   Reply With Quote

Old   August 14, 2020, 16:31
Default
  #26
Senior Member
 
cdegroot's Avatar
 
Chris DeGroot
Join Date: Nov 2011
Location: Canada
Posts: 414
Rep Power: 18
cdegroot is on a distinguished road
Quote:
Originally Posted by mkjmalik View Post
Thankssss alot..

Can i ask One question about paraview?
Yes, but I would suggest posting in the Paraview forum to keep the threads on-topic.
__________________
Chris DeGroot, PhD, PEng
CEO, Maple Key Labs
www.maplekeylabs.com
cdegroot is offline   Reply With Quote

Old   August 14, 2020, 16:32
Default
  #27
Member
 
Muhammad Kashif Jawad
Join Date: Oct 2019
Location: Pakistan
Posts: 48
Rep Power: 6
mkjmalik is an unknown quantity at this point
I’ve already posted there, but yet got no reply
mkjmalik is offline   Reply With Quote

Old   November 29, 2020, 19:40
Default
  #28
Senior Member
 
Join Date: Jul 2019
Posts: 148
Rep Power: 7
Bodo1993 is on a distinguished road
Hi, I use openfoam v6. I got the following error when I resume my simulations from the latest time.
Code:
[0] --> FOAM FATAL IO ERROR: 
[0] Cannot open file ""
[0] 
[0] file: 
[0] 
[0]     From function static void Foam::fileOperations::masterUncollatedFileOperation::readAndSend(const Foam::fileName&, Foam::IOstream::compressionType, const labelUList&, Foam::PstreamBuffers&)
[0]     in file global/fileOperations/masterUncollatedFileOperation/masterUncollatedFileOperation.C at line 537.
[0] 
FOAM parallel run exiting
[0]
I am wondering if anyone knows where is that file"" and how to fix this error. Just as a note: the simulation works if I resume from one of the early written times. I define my variables in a file and import the variables using the #include "file path"
Bodo1993 is offline   Reply With Quote

Old   July 26, 2021, 12:05
Default OF restart issue
  #29
Member
 
Join Date: Apr 2021
Posts: 41
Rep Power: 5
AlxB is on a distinguished road
Hello,

at the end of a parallel run I get a folder with a calculated solution, saved in a folder renamed 'ss4000' because it was a simpleFoam run up to 4000 iterations. That folder comes from the reconstructParMesh/reconstructPar process.

now I want to re-use it as a new starting point.
there is no more the 'processorsN' parallel folders.
I set 'startFrom/latestTime' in the controlDict.

The issue is that the previously calculated values are not taken in account in the new run, despite the time values looking good.

please, where could I be wrong ?

many thanks in advance

here below the controlDict:
Code:
application     simpleFoam;

startFrom       latestTime;

stopAt          endTime;
endTime         4500;
deltaT          1;

writeControl    timeStep;
writeInterval   100;
purgeWrite      1;

writeFormat     binary;
writePrecision  6;
writeCompression off;

timeFormat      general;
timePrecision   6;

runTimeModifiable true;

functions
{
...
}
here below the AllrunRestart4000 I use:
Code:
#!/bin/sh
cd ${0%/*} || exit 1    # Run from this directory

# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions

cp -r ss4000 4000
# (there is no more '0' folder)

runApplication decomposePar 
runParallel renumberMesh -overwrite
runParallel $(getApplication)
runApplication reconstructParMesh -constant
runApplication reconstructPar -latestTime
here below the start of the simpleFoam log (final Cd at it4000 was 0.43):
Code:
(...)
nProcs : 16
(...)
Create time
(...)
Create mesh for time = 4000
(...)
Starting time loop
(...)
Time = 4001

smoothSolver:  Solving for Ux, Initial residual = 0.292026, Final residual = 2.93319e-09, No Iterations 40
smoothSolver:  Solving for Uy, Initial residual = 0.407129, Final residual = 4.11164e-09, No Iterations 40
smoothSolver:  Solving for Uz, Initial residual = 0.38598, Final residual = 4.04993e-09, No Iterations 40
GAMG:  Solving for p, Initial residual = 0.919348, Final residual = 0.00593635, No Iterations 3
time step continuity errors : sum local = 4049.2, global = -2120.98, cumulative = -2120.98
smoothSolver:  Solving for nuTilda, Initial residual = 0.548782, Final residual = 4.7857e-09, No Iterations 36
bounding nuTilda, min: -0.147061 max: 0.201908 average: 0.00515289
ExecutionTime = 25.99 s  ClockTime = 26 s

forceCoeffs forceCoeffs1 execute:
    Coefficients
        Cd       : -3690.34	(pressure: -3685.81	viscous: -4.53403)
AlxB 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
How to pause a transient simulation and resume without time step advancement? aleisia Main CFD Forum 33 June 12, 2017 12:41
velocity profile export from a simulation onto another sudhirlv STAR-CCM+ 1 September 12, 2010 19:57
continue LES simulation after it stopped holand_us OpenFOAM 9 April 5, 2010 13:52
continue LES simulation after it stopped holand_us OpenFOAM Running, Solving & CFD 1 March 29, 2010 04:50
strange simulation error Ralf Schmidt FLUENT 2 May 4, 2007 14:02


All times are GMT -4. The time now is 10:22.