|
NAMEAstro::PAL - Perl interface to Starlink PAL positional astronomy librarySYNOPSISuse PAL; use PAL qw(:constants :pal); ($ra2000, $dec2000) = palFk45z($ra, $dec, 1950.0); ($mjd, $status) = palCldj($yy, $mn, $dd); ($lst, $mjd) = lstnow($long); ($lst, $mjd) = ut2lst_tel($yy,$mn,$dd,$hh,$mm,$ss,'JCMT'); DESCRIPTIONThis modules provides a Perl interface to either the Starlink PAL positional astronomy library.Return values are returned on the stack rather than being modified in place. In addition small utility subroutines are provided that do useful tasks (from the author's point of view) - specifically routines for calculating the Local Sidereal Time. RoutinesThere are 3 distinct groups of routines that can be imported into the namespace via tags:
Each group will be discussed in turn. PALThe PAL routines directly match the C API with the caveat that returned values are returned on the perl argument stack rather than being modified directly in the call arguments. Arguments are never modified. This differs from the Astro::SLA wrapper around the SLALIB library.For example, ($xi, $eta, $j) = palDst2p( $ra, $dec, $raz, $decz ); @pv = palDmoon( $date ); ($nstrt, $fd, $j) = palDafin( $time, $nstrt ); If a routine returns an array as well as a status the status value is returned first: ($j, @iymsf) = palDjcal( $ndp, $djm ); If a routine returns multiple arrays they are returned as references: ($dvb, $dpb, $dvh, $dph) = palEvp( $date, $deqx ); @dvbarr = @$dvb; Routines that take vectors or matrices should be given references to arrays: @rmatn = palNut( $djtt ); @mposr = palDmxv( \@rmatn, \@mpos ); See the PAL or SLALIB documentation for details of the functions themselves. Anomalies
ConstantsConstants supplied by this module (note that they are implemented via the constant pragma):
Extra functionsThese are exportable using the 'funcs' tag or used directly through the Astro::PAL namespace.They directly match the Astro::SLA equivalents.
AUTHORTim Jenness >tjenness@cpan.org<REQUIREMENTSThe PAL library is available from Starlink.COPYRIGHTCopyright (C) 2014 Tim Jenness Copyright (C) 2012 Tim Jenness and the Science and Technology Facilities Council.This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful,but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place,Suite 330, Boston, MA 02111-1307, USA
Visit the GSP FreeBSD Man Page Interface. |