I try to convert J2000 RA/DEC coordinates of an object to the "observed position", i.e. topocentric RA/DEC coordinates including refraction effects. Following the docs (http://rhodesmill.org/pyephem/radec.html#how-the-three-positions-differ) I did this:
from math import pi
import ephem
from datetime import datetime
ra = 20.370473492 / 12. * pi
dec = 40.256674958 / 180. * pi
tt = datetime(2016, 07, 27, 23, 30, 0)
lowell = ephem.Observer()
lowell.lon = '-111:32.1'
lowell.lat = '35:05.8'
lowell.elevation = 2198
lowell.date = tt
lowell.pressure = 1000
bd = ephem.FixedBody()
bd._ra = ra
bd._dec = dec
bd.compute(lowell)
print "Pressure: ", lowell.pressure
print "Input: ", bd._ra, bd._dec
print "Astrometric Geocentric Position: ", bd.a_ra, bd.a_dec
print "Apparent Geocentric Position ", bd.g_ra, bd.g_dec
print "Apparent Topocentric Position: ", bd.ra, bd.dec
print "Horizontal Position: ", bd.alt, bd.az
lowell.pressure = 0
bd.compute(lowell)
print "Pressure: ", lowell.pressure
print "Input: ", bd._ra, bd._dec
print "Astrometric Geocentric Position: ", bd.a_ra, bd.a_dec
print "Apparent Geocentric Position ", bd.g_ra, bd.g_dec
print "Apparent Topocentric Position: ", bd.ra, bd.dec
print "Horizontal Position: ", bd.alt, bd.az
First notable thing is: The apparent geocentric and apparent topocentric coordinates do not differ. If corrections for parallax and refraction were made as stated in the docs, they should differ.
Second thing: If I set the pressure to zero, refraction should disappear and something should change. However, only the horizontal coordinates change (by some 11 arcminutes, that looks right), but all ra/dec coordinates stay the same.
What am I missing here?
Or in other words: Can I somehow get refraction-correction RA/DEC coordinates from pyephem?
(btw, I use the newest pyepehm version, 3.7.6.0)