Procedures and functions not found while executing GDL commands

994 views Asked by At

I've installed GDL recently, since I don't have a license for IDL.

I was trying to run and IDL (.pro) script for simulate exoplanetary transit (with exomoon) and I got some issues:

GDL> .reset_session                                                 

(gdl:16530): Gtk-WARNING **: gtk_disable_setlocale() must be called before gtk_init()
GDL> 
GDL> restore, 'paramk63.save', /v
% Procedure not found: RESTORE
% Execution halted at: $MAIN$          
GDL> 
GDL> Per = PER
GDL> ap = A
% Variable is undefined: A
% Execution halted at: $MAIN$          
GDL> Rplan = RP
% Variable is undefined: RP
% Execution halted at: $MAIN$          
GDL> inc = INC
GDL> Pm = 1
GDL> Rmoon = 0.03
GDL> dmoon = 4.0
GDL> tetam0 = 0.0
GDL> dt = 1.0
GDL> wl = WL
GDL> 
GDL> eclipse_moon,Per,ap,Rplan,inc,Pm,Rmoon,dmoon,tetam0,dt,wl,/plot
% Compiled module: ECLIPSE_MOON.
% ECLIPSE_MOON: Ambiguous: Variable is undefined: MEAN or: Function not found: MEAN
% Execution halted at: ECLIPSE_MOON        23 /home/fabian/Downloads/eclipse_moon.pro
%                      $MAIN$          
GDL> 0:45 / 9:10
% ECLIPSE_MOON: Parser syntax error: unexpected token: 0
GDL> 

I ran this same code on linux with IDL installed and it was perfectly fine.

It seems I have to install some more stuff. Is that right?

1

There are 1 answers

3
veda905 On BEST ANSWER

Looks like it couldn't find a function called MEAN. Make sure it is in your !path and that you are calling it properly. When IDL (or GDL) runs a function or program, it searches all of the directories in the variable !path to find it. If it is found, IDL will load the function and continue compiling. In this case I expect that the function ECLIPSE_MOON calls MEAN on line 23. But MEAN (which is usually built in in IDL) is not found in GDL. So you need to make sure it can be found.

To check what your path, in a GDL session type print,!path and make sure the function MEAN is in one of those directories.