Accessing the SLALIB routines
H.J. van Heerden wrote on Oct 12, 2010
Hi
I want to correct some MJD values for light arrival - i.e. correct to Barycentre.
To do this I need to access some of the SLALIB routine.
I used refer and help to identify the specific routine to use - the Q is:
What is the easiest way to access/call the routines. I know cl scripting (do not want to waste to much time learning SPP). How would I go about it.
Please advise.
Regards
Pat
I want to correct some MJD values for light arrival - i.e. correct to Barycentre.
To do this I need to access some of the SLALIB routine.
I used refer and help to identify the specific routine to use - the Q is:
What is the easiest way to access/call the routines. I know cl scripting (do not want to waste to much time learning SPP). How would I go about it.
Please advise.
Regards
Pat
Mike Fitzpatrick wrote on Oct 12, 2010
The SLALIB routines are available as a library to compiled code only, the procedures don't have script complements. There is of course the RVCORRECT task that will compute a Barycentric velocity correction, but for time corrections the closest I could find is the DELAYTIME task in the STSDAS.SOBSOLETE.TIMESERIES package.
You might try Googling for other possibiities, a good start might be http://astroutils.astronomy.ohio-state.edu/time/bjd_explanation.html
You might try Googling for other possibiities, a good start might be http://astroutils.astronomy.ohio-state.edu/time/bjd_explanation.html
H.J. van Heerden wrote on Oct 12, 2010
OK
Did some research. Easiest for me would be to write some FORTRAN programs using the SLALIB subfunctions (just have to link properly to the SLALIB lib).
So - Q: Is it possible to link/call said FORTRAN program from within IRAF. I would like to include the BJD corrector program in the Boyden Package that we are still actively developing.
Regards
Pat
Did some research. Easiest for me would be to write some FORTRAN programs using the SLALIB subfunctions (just have to link properly to the SLALIB lib).
So - Q: Is it possible to link/call said FORTRAN program from within IRAF. I would like to include the BJD corrector program in the Boyden Package that we are still actively developing.
Regards
Pat
Mike Fitzpatrick wrote on Oct 12, 2010
You can declare host programs as 'foreign' tasks assuming they are commands somewhere in your normal search environment, e.g.
This is roughly the same as doing e.g. "cl> !foo" from the command line.
As part of a package you do something similar but need to resolve the package name, e.g.
where 'pkgbin' is the logical variable to your package bin directory. You can use an explicit path, however this is more general.
task $foo = $foreignThis is roughly the same as doing e.g. "cl> !foo" from the command line.
As part of a package you do something similar but need to resolve the package name, e.g.
printf("$task $foo = $%s/foo\nkeep\n", osfn("pkgbin$")) | cl()where 'pkgbin' is the logical variable to your package bin directory. You can use an explicit path, however this is more general.
Last post on Oct 12, 2010