plot of residuals
I am solving a set of equations which are coupled with he (U, V) momentum. The equations are solved in an implicit manner, i.e. in each time step all the equations are solved couple of times (~ 18). So, as you might expect, for each time step my final log file includes residuals at all the the iterations (~18 residual for each time step). Do you have any idea how I can filter this file to get the final residuals at each time step?
Just Follow the steps:
step1. start calculation and make it write out a log-file.
e.g: icoFoam > log &
step2: If desired you can open a new console window of the main case folder (when your case is runniong) and Follow the text -output by the command tail -f log
To stop reading the file constantly just use ctrl-c
step3: By using gnuplot with in the main case folder you have to put a text file with a name "Residuals" having
then you can get residuals plot.
Thanks for your answer, but I have already tried it. It gives me a plot of all the residuals and not the plot of final residual (residual of the final iteration) at each time step.
You can run
$ foamLog log
which creates a new directory 'logs' in which you can find all residuals (initial, final, etc.) in separate files for all variables. You can make a plot of the residuals in function of the iteration number or in function of the simulated time. Suppose you want to make a plot of the final residual of Ux, the gnuplot command will look like:
* In function of the simulated time:
You can also use pyFoam: http://openfoamwiki.net/index.php/Co...mPlotRunner.py
Thanks for your wonderful comments. I will try it very soon.
The reason that I want to see this plot is that, in my final velocity contours, I have some flow into the wall, which I defiantly because of relatively low residuals (Right???). So, I want to see these plots to make sure my solution has acceptable level of convergence. If you have better ideas, i would love to hear.
|All times are GMT -4. The time now is 07:23.|