chime-experiment / ch_util

CHIME utilities
https://chime-experiment.github.io/ch_util
MIT License
2 stars 3 forks source link

feat(ephemeris): add convert ICRS to beam-model XY #44

Closed rikvl closed 3 months ago

rikvl commented 1 year ago

Add function to convert ICRS equatorial coordinates to CHIME/FRB beam-model XY coordinates

Should do the same as the CHIME/FRB beam-model utility get_position_from_equatorial: https://github.com/CHIMEFRB/beam-model/blob/068e410a99bfb18e469a878e659c26393278874f/beam_model/utils.py#L122

rikvl commented 10 months ago

@jrs65 , @arashcosmology This PR can be reviewed.

The PR now also contains helper functions to convert between beam-model XY and CIRS hour angle and declination (in both directions). I could still add tests.

Manually I did the following tests:

The latter passes when going from HA, Dec to beam-model X, Y: all differences < 10^-10 arcsec. However, when going from beam-model X, Y to HA, Dec, there are big remaining differences for inputs below the horizon (see graph). I added a warning for inputs below the horizon, and I'm inclined to let this be -- but let me know what you think.

diff-ha-dec

rikvl commented 3 months ago

Thanks Don!

I added driftscan to the dependencies.

Regarding the different functions: