fortran feasability [message #54876] |
Mon, 16 July 2007 05:42 |
Conor
Messages: 138 Registered: February 2007
|
Senior Member |
|
|
For a project I'm working on, I'm trying to implement in one of my
programs the pikaia minimization algorithm (http://www.hao.ucar.edu/
Public/models/pikaia/pikaia.html). It has a non-optimized IDL port
which I've used so far. My problem is that when I run it with any
reasonable number of generations, the result is REALLY slow. What
used to take half a day with other algorithims would take roughly 20
days using pikaia in IDL. Unfortunately, this algorith is simply
computationaly expensive, and I really don't think that optimizing the
IDL code is going to facilitate a 40x speed up.
The solution, I think, is to run the original fortran code and call it
from IDL. However, I've never tried such a thing and so I have a few
questions. I'll also take other suggestions, if anyone has any. My
first question is about common blocks. Implementing pikaia requires a
couple common blocks. Currently I have common blocks in IDL that
store all the necessary data. Is there a way to share common blocks
in IDL with fortran code called by IDL? Or would I have to pass all
the necessary data to fortran and then have it load it's own common
blocks?
Also, does anyone know any good tips sites or tutorials on running IDL
from fortran? I found this of course: http://www.dfanning.com/tips/fortran_linking.html
It would be nice to have some background though - I can probably
follow the steps but it would be ince to know what is going on (and
what is a DLM?). Also, any ideas if this still works? It's listed
for IDL version 5.2-5.4.
Thanks,
Conor
|
|
|