CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Programming & Development (
-   -   Coupling OpenFoam with Fortran codes (

anfho January 17, 2011 12:31

Coupling OpenFoam with Fortran codes
Dear All,
I need to couple a Fortran code with OpenFoam (I am using OF 1.7.1). Has anyone done that before? It is even hard to find threads on this topic. If some of you know threads and documentation could you please share the links here? Any help is greatly appreciated.
Thanks very much. Regards, Andreas

anfho January 17, 2011 13:26

Here are some:




Apparently "fortran c++ mixing" are the key words to look for.
But I would be thankful for more information. I will specify my question more later down the road. -Andreas

foroutan_t October 29, 2015 10:38

Did you find any way or program to couple Fortran with OpenFOAM? I will be grateful if you help me.

mkraposhin October 29, 2015 15:21

Hi, yes i did it and there was nothing hard

I done it in two steps:

1) Implementation of Fortran to C interface
2) Implementation of C++ classes that can call C procedures

All times are GMT -4. The time now is 12:56.