Tutorial of calling Fortran from other programming languages

Could we add to the Learn tab in the Fortran-lang website a tutorial covering how to call Fortran from other programming languages, such as Python, R, and Matlab? That would make it easier for those who want to write upstream libraries in Fortran.

1 Like

The Fortran Wiki has interoperability pages for C, C++, C#, Julia, Lua, Matlab, Perl, Python, R, and Tcl, although those are mostly collections of links, and most of the examples one finds online of (for example) R calling Fortran show how to call Fortran 77 code. It could be worthwhile to demonstrate calling modern Fortran code.

There was a book Developing Statistical Software in Fortran 95

Through detailed examples, readers are shown how to call Fortran procedures from packages including Excel, SAS, SPSS, S-PLUS, R, and MATLAB. They are even given a tutorial on creating GUIs for Fortran computational code using Visual Basic.NET.

2 Likes

@fortran4r if you would have time to write such a tutorial, that would be awesome. I agree it is needed.

1 Like

We have a tutorial on how to call Fortran routines from JS, link: How to call Fortran routines from JavaScript using Node.js

1 Like