CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Running, Solving & CFD (
-   -   Mapping fields between different programs (

batta31 February 25, 2013 05:04

Mapping fields between different programs
Hi guys, I have this question:
I have to import the velocity and pressure field from another program (STAR CCM+), and I need to use these fields as inlet condition on my case, which has the same geometry (in terms of body and patches) of the case run in STAR, but a different volume mesh (which is made with ANSA). Is there a way to interpolate those fields in order to use them with OpenFOAM?

I heard about the utility mapFields, to be used with different solvers inside OF, but I don't know if it can be used also between different programs.

Thank you for your replies!

deepsterblue February 25, 2013 09:52

You may want to take a look at MPCCI - not sure how relevant it is, though

wyldckat February 25, 2013 18:56

Greetings to all!

I'll quote myself from the other day, because it seems to fit quite nicely:

Originally Posted by wyldckat (Post 409838)
I believe what you're looking for is exemplified in the tutorial "incompressible/simpleFoam/pitzDailyExptInlet", in particular inside the folder "constant/boundaryData/inlet/".
There isn't much more I know of this tutorial, so I can only suggest you study it and do tell us if you have problems with it!

In essence: you need to export the inlet data you want to use, to CSV or something else, on Star-CCM+. Then refurbish the CSV data to the format in the example I quoted and there you have it! :D

Best regards,

batta31 February 26, 2013 03:41

Thanks for your answer Bruno, it's a starting point for sure. But I have (maybe) a little problem, which is linked to the fact that also the inlet patch from which I extract the data in STAR has a different grid (and so different nodes) with respect to the one that will be used in ANSA. The file "points" in your example has generic coordinates or maybe those points are exactly the nodes of the inlet? This could be the answer..

wyldckat February 26, 2013 05:16

You could probe/sample/interpolate the points on the original mesh...

All times are GMT -4. The time now is 01:28.