Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
28555 Discussions

Installing Fortran compiler on Matlab

ghandour
Beginner
418 Views
hey,
I am trying to couple matlab with fortran. I am using matlab R2010b, and Microsoft visual studio 2008, and I beleive I am using " Intel fortran XE " and I am working on windows 7.
I am following the steps on the Mathworks site " MEX-Files Guide" .. trying to install the cfortran compiler .
I do the first step "mex - setup" and then chose this compiler ( which I am not sure if it the correct one or not):
[3] Intel Visual Fortran 11.1 (with Microsoft Visual C++ 2008 Shell linker)
then i use the testing command : "mex -v yprimef.F "
and I get the following error message :
Error: Could not find the compiler "ifort" on the DOS path.
Use mex -setup to configure your environment properly.
C:\\PROGRA~1\\MATLAB\\R2010B\\BIN\\MEX.PL: Error: Unable to locate compiler.
??? Error using ==> mex at 208
Unable to complete successfully.
Error: Could not find the compiler "ifort" on the DOS path. Use mex -setup to configure your environment properly. C:\\PROGRA~1\\MATLAB\\R2010B\\BIN\\MEX.PL: Error: Unable to locate compiler.??? Error using ==> mex at 208Unable to complete successfully.

So can you please help me to fix this compiler problem so i can move forward with my work ??

thanks a lot

Ahmed
0 Kudos
1 Reply
TimP
Honored Contributor III
418 Views
I suppose you need to combine the mathworks and ifort command prompt environments.
If your ifort installation is correct, you will be able to open a window with ifort environment set on
start>all programs>intel....>command prompt>intel fortran >...
If you can open that window and start the mathworks environment there, it should take care of you.
If you must start the mathworks command window first, you can use the properties of the ifort shortcut to start the ifort environment in the mathworks window.
The 32-bit "ia32" and 64-bit "intel64" compilers have separate command window shortcuts; you must use the one which matches your mathworks.
0 Kudos
Reply