Function: PROCO Purpose: Function which does the conversion of grid to sky coordinates and vice versa. File: proco.c Author: K.G. Begeman Use: INTEGER PROCO( XIN , Input double precision YIN , Input double precision XOUT , Output double precision YOUT , Output double precision CRVAL1, Input double precision CRVAL2, Input double precision CDELT1, Input double precision CDELT2, Input double precision CROTA2, Input double precision PROSYS, Input integer MODE ) Input integer PROCO 0: successful conversion 1: unknown projection 2: unknown mode 3: CROTA2 = 90.0 for mode 1 and 2 4: CDELT1 or CDELT2 equal to zero 5: Input or internal values outside range of this projection XIN Input X coordinate (Longitude in degrees or X grids). YIN Input Y coordinate (Latitude in degrees or Y grids). XOU Output X coordinate (X grids or Longitude in degrees). YOU Output Y coordinates (Y grids or Latitude in degrees). CRVAL1 Projection centre longitude (Longitude in degrees). CRVAL2 Projection centre latitude (Latitude in degrees). CDELT1 X grid separation in degrees. CDELT2 Y grid separation in degrees. CROTA2 Rotation angle in degrees. PROSYS Type of projection: 1 AITOFF equal area projection 2 Equivalent Cylindrical projection 3 Flat projection 4 Gnomonic projection 5 Orthographic projection 6 Rectangular projection 7 Global Sinusoidal projection 8 North Celestial Pole projection 9 Stereographic projection 10 Mercator projection MODE Mode determines what type of input/output coordinates are given/wanted. MODE XIN YIN XOUT YOUT 0 LON LAT X Y 1 X LAT LON Y 2 LON Y X LAT 3 X Y LON LAT Updates: Jan 5, 1990: KGB, Document created. Sep 09, 1998: VOG, Replaced -180, 180 degrees restriction for AITOFF and RECTANGULAR (a,y) -> (x,d) projections by 0, 360 restriction. Jan 24, 2007: Changed post condition for aitoff