|AHELP for CIAO 4.2||
Convert from the Focal Plane (FPC) to Chip coordinate system.
(Integer_Type chip_id, Array_Type pos ) = pix_fpc_to_chip( Double_Type x, Double_Type y )
This routine converts a position in the Focal Plane coordinate (FPC) system to the matching position in the Chip coordinate system, using the current settings of the pixlib module. The FPC system corresponds to the ( DETX, DETY ) columns of a Chandra event file.
The inputs (x,y) are the position in the FPC system. Two values are returned: the first one is the chip ID (the ccd_id value for ACIS and chip_id value for HRC data) and the second (pos) is a two-element array which gives the chip coordinates in pixels.
The pixlib module is not available by default; to use it in a S-Lang program, it must be loaded using the S-Lang require() function:
slsh> require( "pixlib" ); slsh> pix_init_pixlib; slsh> ( id, chip ) = pix_fpc_to_chip( 4580, 4730 ); slsh> print( id ); 3 slsh> print( chip ); 512.362 508.892
Using the default settings of the pixlib module (i.e. the detector is ACIS with the aimpoint on ACIS-I1), we find that the FPC location (4580, 4730) corresponds to the chip position (512.362, 508.892) on ACIS-3 (i.e. ACIS-I3).
See the bugs page for the pixlib library on the CIAO website for an up-to-date listing of known bugs.