rd2sex

Convert RA,DEC in floating point to sexigecimal format.


% rd2sex.sh
rd2sex.sh 12.34566 h -33.3909 
arg1 - RA floating fpoint value 
arg2 - RA units, h=hours d=degrees 
arg3 - DEC floating fpoint value 


% rd2sex.sh 12.34566 h -33.3909
12:20:44.3768 -33:23:27.239

% rd2sex.sh 12.0000 h -0.001
12:00:00.0000 -00:00:03.600

% rd2sex.sh 350.000 d +60.0000
23:20:00.0023 +60:00:00.000

The "h" and "d" unit specifications are cumbersome, but this does reduce the amount of source code needed for yet another stupid-ass astronomy convention.




Back to SCO CODES page