A few days back colleague of mine needed a help in calling Fortran from matlab. At that time I knew about the call system command.
But as we tried solving his problem, I learnt about Mex. I knew Mex was matlab executable but had never explored them or used or created them.
My colleague’s problem was solved once we got matlab and the c compiler. That day and few days after, I continued exploring the dark alleys of Mex.
Learnt a lot. Here’s the list of links that were great at explaining the meshing of fortran and c with matlab with Mex.
- Creating, compiling and linking mex files with fortran and c
- Creating Fortran MEX files from Mathworks
- Writing C Functions in MATLAB (MEX-Files)
- Writing Matlab MEX files using Fortran 90 / 95 (and the Intel Fortran Compiler)
- Interfacing Fortran routines from matlab in a simple and efficient way [pdf]
Perhaps someday I will use them in some project, but till then let them be kept here.