This is a python script (python/coords/RadCon.py) that takes as input a field size and the name of the unit this size is given in. The result (to standard out) is the size in arcsec, arcmin, degrees.
% RadCon.py 20.0 arcsec 20.000000000 0.333333 0.006 % RadCon.py 20.0 arcmin 1200.000000000 20.000000 0.333 % RadCon.py 20.0 deg 72000.000000000 1200.000000 20.000 % RadCon.py 20 gog 0.000000000 0.000000 0.000 Using RadCon.py in a script I typically redirect the output to a file (ptools.2) that I can then read to set variables within the bash script: RadCon.py $3 arcmin >ptools.2 read Rsec Rmin Rdeg < ptools.2 N.B. In this case arg3 is the field radius in arcminutes.In the final example above, the shell variables read from ptools.2 (Rsec,Rmin,Rdeg) can be used by a variety of other scripts.