This bash script reads the X,Y,Ra,Dec values collected by previously scripts and derives standard WCS coefficients for the FITS image header of the input image. The WCS0 solution in the *.info of the input image is assumed to have previously been computed with wcs0. The OTW routine psfind is used to derive the image plate scale, and the OTW routine rotafind is used to derive the rotation angle. The WCS parameters are collected into a file of new header cards using the (OTW) script hcards_wcs1 and inserted into the CCD image FITS header using the OTW script headrev.
% wcs1 a.fits wcs_setup.out arg1 = name of image being calibrated arg2 = name of input [name,x,y,r,d] file (e.g. wcs_setup.out)