Observed to Apparent
CALL sla_OAP (TYPE, OB1, OB2, DATE, DUT, ELONGM, PHIM,
HM, XP, YP, TDK, PMB, RH, WL, TLR, RAP, DAP)
TYPE  C*(*)  type of coordinates – ‘R’, ‘H’ or ‘A’ (see below) 
 
OB1  D  observed Az, HA or RA (radians; Az is N=0, E=$9{0}^{\circ}$) 
 
OB2  D  observed zenith distance or $\delta $ (radians) 
 
DATE  D  UTC date/time (Modified Julian Date, JD$$2400000.5) 
 
DUT  D  $\Delta $UT: UT1$$UTC (UTC seconds) 
 
ELONGM  D  observer’s mean longitude (radians, east +ve) 
 
PHIM  D  observer’s mean geodetic latitude (radians) 


HM  D  observer’s height above sea level (metres) 


XP,YP  D  polar motion $\left[\phantom{\rule{0.3em}{0ex}}x,y\phantom{\rule{0.3em}{0ex}}\right]$ coordinates (radians) 


TDK  D  local ambient temperature (K; std=273.15D0) 


PMB  D  local atmospheric pressure (mb; std=1013.25D0) 


RH  D  local relative humidity (in the range 0D0 – 1D0) 


WL  D  effective wavelength ($\mu m$, e.g. 0.55D0) 


TLR  D  tropospheric lapse rate (K per metre, e.g. 0.0065D0) 
RAP,DAP  D  geocentric apparent $\left[\phantom{\rule{0.3em}{0ex}}\alpha ,\delta \phantom{\rule{0.3em}{0ex}}\right]$ 
HM=29.3D0*TSL*LOG(P/1013.25D0)
where TSL is the approximate sealevel air temperature in K (see Astrophysical Quantities, C.W.Allen, 3rd edition, §52). Similarly, if the pressure P is not known, it can be estimated from the height of the observing station, HM as follows:
P=1013.25D0*EXP(HM/(29.3D0*TSL))
Note, however, that the refraction is nearly proportional to the pressure and that an accurate P value is important for precise work.