comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » calling Fortran from IDL
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
calling Fortran from IDL [message #26435] Mon, 27 August 2001 09:47 Go to next message
snert13 is currently offline  snert13
Messages: 1
Registered: August 2001
Junior Member
I have (unsuccessfully) tried to call F77 numerical recipes routines
from within
IDL. I used Stein Vidar Hagfors Haugan's perl script to produce a
C-wrapper but couldn't compile it. I'm running RedHat 6.2 (IDL 5.3).
Some of the errors I get are "IDL_MEMINT' undeclared (first use in
this function)"; "`N_' undeclared (first use in this function)" -
since I know no
C at all I have no idea how to fix the above.

My goal is to use some of the numerical recipes ordinary differential
equation routines (e.g. odeint) and I need to do this rather quickly.
Any help would be very much appreciated.
Re: Calling FORTRAN from IDL [message #41456 is a reply to message #26435] Fri, 29 October 2004 04:54 Go to previous message
Haje Korth is currently offline  Haje Korth
Messages: 651
Registered: May 1997
Senior Member
Aarthi,
for beginners I recommend to stick with CALL_EXTERNAL. Besides the external
development guide, you can also look in C:\RSI\IDL61\external\call_external
for some examples ready to compile. If you are on Windows and want to use
cygwin to compile, look at the recent tech tips on the RSI web site. I bit
my nails out on that one and never got it to work until I started using the
M$ C compiler.

Have fun,
Haje


"Aarthi" <aarthi.arunkumar@colorado.edu> wrote in message
news:ac6d0b32.0410281434.7d0a7686@posting.google.com...
> Hi,
> How can I call a FORTRAN routine from an IDL program?
> Thanks,
> Aarthi
Re: Calling FORTRAN from IDL [message #41460 is a reply to message #26435] Thu, 28 October 2004 17:00 Go to previous message
Randall  Skelton is currently offline  Randall Skelton
Messages: 31
Registered: October 2004
Member
You can use CALL_EXTERNAL or write a Dynamically Linked Module (DLM) in
C that calls your Fortran routine. A simple example is given in the
IDL External Development Guide (edg.pdf) under the section,
CALL_EXTERNAL (chapter 9, p. 219 for version 6.1).

Cheers,
Randall
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Concatenate arrays
Next Topic: Re: Concatenate arrays

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 18:38:35 PDT 2025

Total time taken to generate the page: 0.00487 seconds