IDL to Matlab/Scilab translator (IDL2Matlab)

Version 1.5 [Jan 21st 2009]

Purpose: Automatic translation from an IDL program into Matlab and Scilab code

IDL <> and Matlab <> are two major numerical languages for scientists. Additionally, Scilab <> is a free Matlab-like software, which integrates a high compatibility (syntax, functions, graphics, user interfaces).
Many IDL programs have been developed in large facilities studying astrophysics, geology,medicine, particle and nuclear physics.
On the other hand, Matlab is widely used in smaller laboratories (universities, national scientific agencies, ...). In order to extend the portability of such IDL programs, we are developing an automatic translator from IDL to Matlab and Scilab.

This translator works as follow:

1. analyze and formalize the IDL grammar
2. use lex/yacc to parse the original IDL source code to translate
3. generate a translated equivalent program, using Matlab grammar (and all variable types)
4. use a hash table for library functions.

The translation also performs an IDL syntax check, and reports possible warnings and errors into a Log.
This library is quite big, and covers the most useful IDL/Matlab functions, particularly mathematical functions, basic plotting functions, widgets/uicontrols


This project is hosted at Download it at <> Logo
The utility man page is available here at <idl2matlab.html>

IDL2Matlab works on all systems (Unix/Linux/Windows). It is built upon lex/yacc and programmed in C. Compilation of the translator does not require lex/yacc.
The usage of the translator is done through the command line.

Unix/Linux/MacOSX systems: (you need a C compiler such as gcc)

Installation is done through the usual
./configure; make; sudo make install
procedure on Unix/Linux/MacOSX systems.
Executable is then installed in e.g. /usr/local/bin and libraries in /usr/local/lib/idl2matlab.

If you do not have super user rights, execute e.g. (your name is 'joe'):
./configure --prefix=/home/joe; make; make install
Executable is then installed in e.g. /home/joe/bin and libraries in /home/joe/lib/idl2matlab.

For Windows systems: (you need a C compiler such as Dev-Cpp/MinGW gcc)

Execute the install.bat script.
This will install binaries and libraries in e.g. C:\idl2matlab.

Current status of the project:
The project was started October 2001. It became operational on Autumn 2002. The translator is not perfect, and may fail for unsupported IDL grammar. Some functions are not translated.
However, the translator works already very well.
Limitations: object translation, and most complex plotting routines are not supported.

Coordinators: Didier Richard <richard(at)> and Emmanuel Farhi <farhi(at)>
Team 2: BOURTEMBOURG Reynald, CORTINA Stephane, SZCZUCZAK Nadege

ILL neutrons for scienceE. Farhi - Nov 2007 - ILL/DS/CS