|
[Sponsors] |
October 6, 2014, 08:46 |
Plot residuals to observe convergens
|
#1 |
New Member
Peter Rosén
Join Date: Sep 2014
Posts: 12
Rep Power: 12 |
Hello!
I am using CAELinux2013. Is there an easy way to see (Plot) the residuals while calculation is running ? I would like to know if the residual is steady or unsteady without manually reading the log file. Regards, Peter |
|
October 6, 2014, 17:01 |
pyFoam is what you need
|
#2 |
Senior Member
Alex
Join Date: Oct 2013
Posts: 337
Rep Power: 22 |
Hello Peter,
In order to be able to view residuals plotted on the fly I recomend you to install PyFoam. Regards, Alex
__________________
Web site where I present my Master's Thesis: foamingtime.wordpress.com The case I talk about in this site was solved with chtMultiRegionSimpleFoam solver and involves radiation. Some basic tutorials are also resolved step by step in the web. If you are interested in these matters, you are invited to come in! |
|
October 7, 2014, 02:49 |
|
#3 |
New Member
Peter Rosén
Join Date: Sep 2014
Posts: 12
Rep Power: 12 |
Hello and Thank you!
Installed and done! But now comes the question, how do i run it? to i have to use foamjob? Or can i look at the residual from my log file named listing made from Code-Saturn? How would i run that in terminal if i for instance want to use pyFoamPlotWatcher ? I have manage to run python shell in terminal, what is the next step? regards, peter |
|
October 7, 2014, 12:17 |
|
#4 |
Senior Member
Alex
Join Date: Oct 2013
Posts: 337
Rep Power: 22 |
There's no need to use foamJob, Peter. Just type pyFoamPlotWatcher.py <log file name> and enjoy your foaming!
regards, alex
__________________
Web site where I present my Master's Thesis: foamingtime.wordpress.com The case I talk about in this site was solved with chtMultiRegionSimpleFoam solver and involves radiation. Some basic tutorials are also resolved step by step in the web. If you are interested in these matters, you are invited to come in! |
|
October 8, 2014, 05:40 |
Hello
|
#5 |
New Member
Peter Rosén
Join Date: Sep 2014
Posts: 12
Rep Power: 12 |
Hello and thank you!
when i am in the logg file directrory i type, python pyFoamPlotWacher.py listing (have tried pyFoamPlotWacher.py <listing>) and i get "SyntaxError: invalid syntax File"<stdin>", line1" what am i doing wrong? regard, Peter |
|
October 8, 2014, 08:26 |
|
#6 |
Senior Member
Alex
Join Date: Oct 2013
Posts: 337
Rep Power: 22 |
Well I see what your problem is. You don't really need to enter the python shell, pyFoam applications work without that. I will try to explain more accurately the steps to create the residuals plot (more plots will be created).
Imagine you are running a case using icoFoam solver. You proceed this way to create the log file: Code:
icoFoam > log.icoFoam 2>&1 Code:
pyFoamPlotWatcher.py log.icoFoam EDIT: Remember, if in doubt you can always invoke an application with the -help flag to see all its options and modes of use. Hope it helps. Regards, Alex
__________________
Web site where I present my Master's Thesis: foamingtime.wordpress.com The case I talk about in this site was solved with chtMultiRegionSimpleFoam solver and involves radiation. Some basic tutorials are also resolved step by step in the web. If you are interested in these matters, you are invited to come in! Last edited by zfaraday; October 8, 2014 at 08:29. Reason: in red |
|
October 8, 2014, 11:55 |
Thank you!
|
#7 |
New Member
Peter Rosén
Join Date: Sep 2014
Posts: 12
Rep Power: 12 |
Hi again, and thank you for your instructions it feels like i am getting closer.
I am using simpleFoam and therefor tried, simpleFoam > log.simpleFoam 2>& I attach my log file below, The directory, that simpleFoam is trying to find does not exist. I can not find much in simpleFoam -help regards, /*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.1.1 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ Build : 2.1.1-221db2718bbb Exec : simpleFoam Date : Oct 08 2014 Time : 16:29:59 Host : "peter-VirtualBox" PID : 12775 Case : /home/peter/Project/Skyware/Parabol_0deg/PARABOL_CGNS/RUN1/RESU/20141008-1618 nProcs : 1 sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). fileModificationChecking : Monitoring run-time modified files using timeStampMaster allowSystemOperations : Disallowing user-supplied system call operations // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time --> FOAM FATAL IO ERROR: cannot find file file: /home/peter/Project/Skyware/Parabol_0deg/PARABOL_CGNS/RUN1/RESU/20141008-1618/system/controlDict at line 0. From function regIOobject::readStream() in file db/regIOobject/regIOobjectRead.C at line 73. FOAM exiting |
|
October 8, 2014, 13:30 |
|
#8 |
Senior Member
Alex
Join Date: Oct 2013
Posts: 337
Rep Power: 22 |
As per what the message says there is no controlDict file in the system directory of your case "20141008-1618". If this is not the name of your case maybe you are executing the solver in the wrong directory... If this is your case directory, then you missed the controlDict file within the system directory.
__________________
Web site where I present my Master's Thesis: foamingtime.wordpress.com The case I talk about in this site was solved with chtMultiRegionSimpleFoam solver and involves radiation. Some basic tutorials are also resolved step by step in the web. If you are interested in these matters, you are invited to come in! |
|
November 19, 2014, 08:50 |
I get a strange error message and no plot. What about openFoam version?
|
#9 |
New Member
Peter Rosén
Join Date: Sep 2014
Posts: 12
Rep Power: 12 |
peter@peter-Sigma:~/OpenFOAM/peter-2.3.x/run/Skyware$ pyFoamPlotWatcher.py log
PyFoam WARNING on line 235 of file /home/peter/OpenFOAM/PyFoam-0.6.2/lib/python2.7/site-packages/PyFoam/Applications/PyFoamApplication.py : $WM_PROJECT_VERSION unset. PyFoam will not be able to determine the OpenFOAM-version and behave strangely gnuplot> set terminal x11 ^ line 0: unknown or ambiguous terminal type; type just 'set terminal' for a list gnuplot> set terminal x11 noraise ^ line 0: unknown or ambiguous terminal type; type just 'set terminal' fo |
|
November 19, 2014, 09:03 |
|
#10 |
Senior Member
|
Hi,
http://www.cfd-online.com/Forums/ope...-problems.html (there's Search functionality, you know) About $WM_PROJECT_VERSION: are you sure your environment was set up? What's the output of Code:
$ export | grep WM_ |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Tutorials] Tutorial of how to plot residuals ! | wolle1982 | OpenFOAM Community Contributions | 171 | February 20, 2024 03:55 |
plot residuals in multiregion solver | val46 | OpenFOAM | 4 | December 12, 2016 07:06 |
[swak4Foam] Foam warnings - related to swak4Foam | Salam-H | OpenFOAM Community Contributions | 20 | August 2, 2015 16:40 |
How to plot residuals of all iterations in Fluent | FJSJ | FLUENT | 4 | September 20, 2013 10:47 |
Residuals Plot | kamalipour | FLUENT | 2 | December 15, 2011 04:44 |