CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Paraview & paraFoam (
-   -   Probe Multiple Points in ParaView and Output as CSV (

eric.m.tridas November 28, 2011 16:15

Probe Multiple Points in ParaView and Output as CSV
Hey Foamers,

I am attempting to take data from a simulation performed with an unstructured grid in OpenFOAM and use the probe feature in ParaView to obtain interpolated values at points uniformly spaced over the domain. I wish to have the velocity, pressure and temperature values at these points saved as a *.csv file to be imported into another software.

I have a list of all of the coordinates I wish to sample from but want to automate this process as there are ~100k points. I believe this is possible with python scripting but am not sure where to start and am not familiar at all with python. I was hoping that someone may have needed to perform something similar and could give some advice on where to begin or some way of solving this problem in an easy manner.

Thanks in advance.


Bernhard November 29, 2011 03:06

Did you consider to use the sample utility?

If you have 100k points, maybe it is an option to just use a coarse mesh and the mapFields utility?

In any case, I would use the FOAM framework for this issue.

eric.m.tridas November 29, 2011 14:01


Thanks for your reply. I've considered using the sample utility but I I do not think it can sample the data in the way I want it (although I could be wrong about this).

I think I was slightly unclear about my problem. The dataset I have is coarser than the dataset I wish to create. I've considered mapping the fields to my desired mesh but it would be quite a task to recreate the finer mesh.

I would be very interested in using the OF framework to program something to do this task but have no experience with using it to create new utilities. If you have any good starting points on performing a task like this your advice would be appreciated. I have considered writing something in C++/Matlab to perform the task but would rather learn how to do some advanced data manipulation with OF.

Thanks again.


Bernhard November 29, 2011 14:22

I don't see a point in doing this? What are you trying to reach here?

eric.m.tridas November 29, 2011 14:30

I am mapping the results of the CFD simulation to an electrostatic simulation that uses uniform cube elements to make the mesh. I need to get velocity, pressure and temperature data at every point in the electrostatic mesh. The electrostatic simulation software uses some proprietary mesh that does not convert into other mesh formats. I can however output a *.csv file that will give me the coordinates of every point on the electrostatic simulation mesh. I was thinking I could take these points and use them as sample points of the OF simulation results.

All times are GMT -4. The time now is 04:14.