|
[Sponsors] | |||||
|
|
|
#1 |
|
Member
Albert Tong
Join Date: Dec 2010
Location: Perth, WA, Australia
Posts: 56
Blog Entries: 1
Rep Power: 4 ![]() |
Hi OFers,
The pressure over a line has been sampled in the sets directory distributed in many time directories. I would like to plot the changes of the pressure over time on the fixed line. Is there any tool to do this? Thanks a lot.
__________________
Kind regards, Albert |
|
|
|
|
|
|
|
|
#2 | |
|
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 3,133
Rep Power: 30 ![]() ![]() |
Quote:
Actually. It doesn't plot. It only generates the commands for gnuplot. But that is not a problem as you've only got to pipe the output into gnuplot ("pyFoamSamplePlot.py .... | gnuplot") to get a bunch of pictures. These you can animate with "animate" or encode them into a video
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
|
|
|
||
|
|
|
#3 |
|
Member
Albert Tong
Join Date: Dec 2010
Location: Perth, WA, Australia
Posts: 56
Blog Entries: 1
Rep Power: 4 ![]() |
Thanks Bernhard, for your quick reply and tips on how to use gnuplot. As I want to plot a 2D picture with x being time, y being the line and pressure in the 2D area, so I am trying to combine all the files in sets/ together.
__________________
Kind regards, Albert |
|
|
|
|
|
|
|
|
#4 |
|
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 3,133
Rep Power: 30 ![]() ![]() |
Ah. I thought you were going for an animation of the line. So you want a surface plot with the pressure going in z-direction, right? That is something the utility can't do yet
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
|
|
|
|
|
|
|
|
#5 | |
|
Member
Albert Tong
Join Date: Dec 2010
Location: Perth, WA, Australia
Posts: 56
Blog Entries: 1
Rep Power: 4 ![]() |
Quote:
Yes, Bernhard, I want to plot the temporal evolution of the pressure over a line. I have just solved the problem by combining all the files together, then use tecplot. Thanks for your attention.
__________________
Kind regards, Albert |
||
|
|
|
||
|
|
|
#6 | |
|
Member
Jamal
Join Date: May 2012
Location: Freiburg
Posts: 41
Rep Power: 3 ![]() |
Dear
The temperatur over a line has been sampled in the sets directory distributed in many time directories. I would like to plot the changes of the temperature over time on the fixed line. Quote:
I am using this command pyFoamSamplePlot.py sets/timeDirectory/lineX1_.gplt and in result it gives following lines Traceback (most recent call last): File "/opt/OpenFOAM/adin-2.1.0/lib/PyFoam-0.5.7/bin/pyFoamSamplePlot.py", line 5, in <module> SamplePlot() File "/opt/OpenFOAM/adin-2.1.0/lib/PyFoam-0.5.7/lib/python2.6/site-packages/PyFoam/Applications/SamplePlot.py", line 31, in __init__ interspersed=True) File "/opt/OpenFOAM/adin-2.1.0/lib/PyFoam-0.5.7/lib/python2.6/site-packages/PyFoam/Applications/PyFoamApplication.py", line 213, in __init__ result=self.run() File "/opt/OpenFOAM/adin-2.1.0/lib/PyFoam-0.5.7/lib/python2.6/site-packages/PyFoam/Applications/SamplePlot.py", line 288, in run prefixes=self.opts.fieldPrefix) File "/opt/OpenFOAM/adin-2.1.0/lib/PyFoam-0.5.7/lib/python2.6/site-packages/PyFoam/RunDictionary/SampleDirectory.py", line 32, in __init__ for d in listdir(self.dir): OSError: [Errno 20] Not a directory: 'sets/4320/lineX1_T.gplt/samples' Thanks |
||
|
|
|
||
|
|
|
#7 | |
|
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 3,133
Rep Power: 30 ![]() ![]() |
Quote:
Anyway. Like all other pyFoam-utilities the option --help gives you the basic usage and the options. In your case something like pyFoamSamplePlot.py . --dir=sets --field=T should work
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
|
|
|
||
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| High Courant Number @ icoFoam | Artex85 | OpenFOAM Running, Solving & CFD | 9 | January 3, 2012 08:06 |
| mesh airfoil NACA0012 | anand_30 | OpenFOAM Meshing & Mesh Conversion | 12 | December 12, 2011 04:16 |
| boundaries with gmshToFoam | ouafa | Open Source Meshers: Gmsh, Netgen, CGNS, ... | 7 | May 21, 2010 12:43 |
| Problem with Gmsh | nishant_hull | Open Source Meshers: Gmsh, Netgen, CGNS, ... | 17 | December 7, 2007 01:33 |
| error while compiling the USER Sub routine | CFD user | CFX | 3 | November 25, 2002 15:16 |