astropy/astropy — pull request #551 by astrofrog (2012-12-10 23:15:45+00:00)
Title: Implemented e-term corrections

**Note** this is not yet ready to merge, but I just want to put what I have so far in case there are already comments.

This implements the e-terms correction for the FK4 coordinate system, by introducing a new class, ``FK4NoETermCoordinates``, which represents FK4 coordinates with no e-terms included, and a special FK4 (no e-terms) <-> FK4 functional transform.

Remaining to-dos:

* Ensure that input/output equinoxes are correct for the FK4/FK5 conversion. RIght now it assumes B1950 <-> J2000, e.g. in ``fk4_no_e_to_fk5`` - but technically speaking, the input equinox could be different, so we need to pre-precess to B1950 or J2000 depending on the conversion.

* Check that the output equinox is correct - for example, the ``fk4_no_e_to_fk5`` function changes the equinox, so this needs to be reflected in the output coordinates.

* Implement more accurate e-terms correction - e.g. Kapteyn uses time-dependent corrections, but I don't have access to the appropriate references today, I will check tomorrow.

@eteq - anything else you can think of for now? Does this look ok so far?

Performance wise, this could be improved in future (and for other transformations too) by only converting once to and back from cartesian coordinates. I think all transformations will ultimately work in cartesian coordinates (this is what kapteyn does too).