Using FORTRAN code in MATLAB

Hi guys,
Would like some input on whether I could run a fortran code in MATLAB.
If so what are the requirements and I am talking about an entire code created in Fortran

 采纳的回答

Rik
Rik 2020-8-31

0 个投票

You can compile Fortran code to mex, after which you can use it in Matlab as a function. Read the documentation for the API details.

3 个评论

I checked it out. But since I am using mac, is the procedure different? Is there any link you could share if someone has worked on such a situation?
As long as you have a supported Fortran compiler, the procedure is pretty much the same. Do you have a supported Fortran compiler installed?
I can't test anything for you, since I have very limited access to MacOS.
This thread might help you out if the standard mex setup doesn't work for you. It looks like you need to install an external tool if you want to compile Fortran, see the system requirements.

请先登录,再进行评论。

更多回答(0 个)

类别

帮助中心File Exchange 中查找有关 Fortran with MATLAB 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by