I have a star unic identifier/designation in the Gaia catalogue. How can I find, if exits, its corresponding identifier in the Hipparcos catalogue using AstroPy?
For example, for the Gaia identifier designation=“DR3 4345775217221821312”, I would like to get the Hipparcos identifier HIP=79672. These two unique identifiers correspond to the same star, present in both catalogues.
This sounds like a case for astroquery. If a cross-identification exists on Simbad, you could use its name query to get all known catalogue IDs:
from astroquery.simbad import Simbad
tab = Simbad.query_objectids('Gaia DR3 4345775217221821312')
print([id for id in tab['ID'] if id.startswith('HIP')])
Otherwise you might try a cone search based on the result tables and coordinates you could directly access from Gaia using its Gaia TAP+ module.
Hi, Derek. Thank you for the answer.
Could you give me a link where I can better understand how the match is done by the astroquery below?
Explaining my curiosity better:
I know that Hipparcos’ mean epoch is 1991.25 and Gaia’s is 2016.0. The reference/equinox is 2000.0 for both catalogs. My curiosity is how astropy matches the coordinates of the catalogues, which have different mean epochs.
Hi, in the above example astroquery is not doing any coordinate match itself, as it simply returns the list of identifiers stored for that Gaia source in Simbad (basically what you’d also get by manually opening Gaia DR3 4345775217221821312).
For searches by region as described e.g. on SIMBAD Queries (astroquery.simbad) — astroquery v0.4.6
you are passing an astropy SkyCoord, which includes the information on equinox and epoch for translating to a different epoch when e.g. using the SkyCoord.separation method.
Coming from the Gaia identifier you could probably also use the cross-match function vs. the Hipparcos catalogue: Gaia TAP+ (astroquery.gaia) — astroquery v0.4.6
but maybe someone more familiar with astroquery (or studying the docs) could give more advice on that.