; ;========================================================================== ; ; FILE: uflatitude.pro ; ; USAGE: result = UFlatitude(ufbuf) ; ARGUMENT ufbuf Buffer of UF words for a dwell of radar data ; ; ABSTRACT: Return the latitude in degrees for the radar from the Mandatory ; header ; For EDOP, this is the ER-2 hybrid latitude at the current dwell ; ; AUTHOR: I. Jeff Caylor ; Science Systems and Applications, Inc. ; 5900 Princess Garden Parkway, Suite 300 ; Lanham, MD 20706 ; ; at: NASA Goddard Space Flight Center ; Code 912 ; Greenbelt, MD 20771 ; Voice: (301) 286-3767 ; Fax: (301) 286-1762 ; Email: jeff.caylor@gsfc.nasa.gov ; ; CREATED: 7 April 1995 ; ; MODIFIED: 13 March 1996 - IJC ; Bug fix for indexing dwell ; 26 March 1996 - IJC ; Added code for testing sign of deg/minute/second ; ;========================================================================== ; ; ; Return the site latitude in degrees ; FUNCTION UFlatitude, dwell deg = float(dwell(19)) IF dwell(19) LT 0.0 AND dwell(20) GT 0.0 AND dwell(21) GT 0.0 THEN BEGIN deg = deg - float(dwell(20)) / 60.0 deg = deg - float(dwell(21)) / 230400.0 ENDIF ELSE BEGIN deg = deg + float(dwell(20)) / 60.0 deg = deg + float(dwell(21)) / 230400.0 ENDELSE RETURN, deg END