Spitzer Documentation & Tools
get_irac_ptg_offsets

Purpose: IDL routine to determine row and column offsets for IRAC target position in Spot for a source to be on a given pixel position in the specified channel. If /ROWCOL is set, then return x, y BCD pixel position for input row and column offsets for specified channel.

Author: Sean Carey (SSC/IPAC)
Date Contributed: 01 Oct 2008
System Requirements: IDL v6.0 or higher, astrolib IDL library

Information and Download

Download get_irac_ptg_offsets.pro (PRO, 34 KB)

Use IRAC astrometric information including distortion parameters to determine pointing offsets for given pixel coordinates, or provide pixel coordinates for a given pointing offset. The pixel coordinates are in BCD orientation, refer to the centers of the pixels and start at (1,1). The procedure uses a set of IRAC BCD FITS headers oriented without rotation in Equatorial coordinates and centered such that the IRAC pointing center is the coordinate origin. As a result, the sky coordinates are the angular offsets from the pointing centers. The standard astrolib procedures are used to calculate sky to pixel and pixel to sky transformations from the image headers. The approximation that the longitude is in units of arc is used as it is practically true for the latitude range (+/- 2.5 arcminutes) covered.

This software is not considered part of the pipeline and no installation support from IRSA should be expected. We are however very interested in your feedback in order to improve or replace the algorithm and are glad to work with you in test cases and analysis. Questions and comments should be directed to the Helpdesk.

CALLING SEQUENCE

GET_IRAC_PTG_OFFSETS, CHANNEL, X, Y, ROW, COL[, /SUB]
--- or ---
GET_IRAC_PTG_OFFSETS, CHANNEL, ROW, COL, X, Y, /ROWCOL_TO_PIXEL, /SUB

INPUTS

CHANNEL: IRAC channel number 1-4
X: Scalar or array of x positions on the array in BCD coordinates. Pixel (1,1) is center of lower left hand corner of array.
Y: Scalar of array of y positions on the array in BCD coordinates

--- or if /ROWCOL is set ---

ROW: Offset for input pixel position in arcseconds in row direction as defined in Spot
COL: Offset in arcseconds in column direction

/ROWCOL: If set, then inputs are ROW and COL and outputs are X and Y
/SUB: If set, then X and Y are relative to the subarray rather than the full array. Full arrays are 256x256 pixels centered on (128.5,128.5). The subarrays are 32x32 pixels with centers located at:

Channel X Y
1 24 232
2 24 232
3 24 24
4 24 24

relative to the full array.

OUTPUTS

ROW: Offset for input pixel position in arcseconds in row direction as defined in Spot
COL: Offset in arcseconds in column direction

--- or if /ROWCOL is set ---

X: Scalar or array of x positions on the array in BCD coordinates. Pixel (1,1) is center of lower left hand corner of array.
Y: Scalar of array of y positions on the array in BCD coordinates.