matvis.conversions.equatorial_to_eci_coords

matvis.conversions.equatorial_to_eci_coords(ra, dec, obstime, location, unit='rad', frame='icrs')[source]

Convert RA and Dec coordinates into the ECI system used by matvis.

Convert RA and Dec coordinates into the ECI (Earth-Centered Inertial) system used by matvis. This ECI system is aligned with the celestial pole, not the Earth’s axis.

To ensure that all corrections are properly taken into account, this function uses Astropy to find the Alt/Az positions of the coordinates at a specified reference time and location. These are then transformed back to ENU (East-North-Up) coordinates, and then to Cartesian ECI coordinates, using the inverses of the same transforms that are used to do the forward transforms when running `` matvis``. The ECI coordinates are then finally converted back into adjusted RA and Dec coordinates in the ECI system.

While the time-dependent corrections are determined for the reference time, the adjusted coordinates are expected to yield a good approximation to the true Azimuth and Zenith angle of the sources at other times (but the same location) when passed into the `` matvis`` function via the crd_eq array and then converted using the standard conversions within `` matvis``.

The following example code shows how to set up the Astropy Time and EarthLocation objects that are required by this function:

# HERA location
location = EarthLocation.from_geodetic(lat=-30.7215,
                                       lon=21.4283,
                                       height=1073.)
# Observation time
obstime = Time('2018-08-31T04:02:30.11', format='isot', scale='utc')
Parameters:
  • ra (array_like) – Input RA and Dec positions. The units and reference frame of these positions can be set using the unit and frame kwargs.

  • dec (array_like) – Input RA and Dec positions. The units and reference frame of these positions can be set using the unit and frame kwargs.

  • obstime (astropy.Time object) – Time object specifying the time of the reference observation.

  • location (astropy.EarthLocation) – EarthLocation object specifying the location of the reference observation.

  • unit (str, optional) – Which units the input RA and Dec values are in, using names intelligible to astropy.SkyCoord. Default: ‘rad’.

  • frame (str, optional) – Which frame that input RA and Dec positions are specified in. Any system recognized by astropy.SkyCoord can be used. Default: ‘icrs’.

Returns:

eci_ra, eci_dec – Arrays of RA and Dec coordinates with respect to the ECI system used by matvis.

Return type:

array_like