This notebook tutorial demonstrates how to do a cone search centered on the location of a target (in this example, the star HD 209458) in the TESS Input Catalog. We will then select a subset of the returned targets based on their Luminosity Class values. Finally, we will identify the TIC object that is closest on the sky to HD 209458 as a means to determine the star's TIC number. This tutorial uses Python and the astroquery module. Information on how to install astroquery for MAST can be found on the Astroquery site.
from astroquery.mast import Catalogs import numpy as np
Let's start by defining the name of our target and our desired search radius in degrees.
target_name = "HD 209458" search_radius_deg = 0.2
We will now use the Catalogs
query_object function to do a cone search centered on HD 209458 and return the rows from the TIC catalog. The function makes use of MAST's name resolver to convert a target name (as a string) into coordinates (Right Ascension and Declination). Many types of ID's are possible, including any string that can be resolved by Simbad or NED, as well as any target in the Kepler Input Catalog, K2 EPIC Catalog, or the TESS Input Catalog. The function also can accept a search radius size (specified in degrees), and it needs to know which catalog you want to query. Catalog options are listed on this page.
In the second line, we print out the numbers of returned rows.
# Query the TESS Input Catalog centered on HD 209458 with a 0.2 degree radius. catalogTIC = Catalogs.query_object(target_name, radius=search_radius_deg, catalog="TIC") # Print out the number of returned rows. print("Number of TIC objects within %f deg of %s: %u" % (search_radius_deg, target_name, len(catalogTIC)))
Number of TIC objects within 0.200000 deg of HD 209458: 1344
Let's take a look at the table returned from the query. We see the returned object is an astropy Table. We can also examine the columns available.
# What type of objects is the returned result? print(type(catalogTIC))
# What columns are available from the TIC? print(catalogTIC.columns)
Let's select a subset of the returned objects based on the "lumclass" column. This column classifies sources in the TIC as "giant" or "dwarf". For more information on how the columns of the TIC are populated, consult the TESS Input Catalog paper and the TIC Live Release Notes.
# Identify where the luminosity class is set to "DWARF". where_dwarfs = np.where(catalogTIC['lumclass'] == 'DWARF') # Let's also find out where the luminosity class is set to "GIANT". where_giants = np.where(catalogTIC['lumclass'] == 'GIANT') # Let's print out the number of rows of each type within the returned objects from our search. print("Number of objects classified as 'DWARF' within %f deg of %s: %u" % (search_radius_deg, target_name, len(where_dwarfs))) print("Number of objects classified as 'GIANT' within %f deg of %s: %u" % (search_radius_deg, target_name, len(where_giants)))
Number of objects classified as 'DWARF' within 0.200000 deg of HD 209458: 904 Number of objects classified as 'GIANT' within 0.200000 deg of HD 209458: 28
Let's now find the star in the TESS Input Catalog that is closest to our target. The table produced by the astroquery request is sorted by the column "dstArcSec" by default. This column gives the distance in arcseconds from the requested target's position returned by the name resolver. It should be the first row if you haven't sorted the table yet, but let's not assume that and instead find the row with the smallest "dstArcSec".
where_closest = np.argmin(catalogTIC['dstArcSec']) print("Closest TIC ID to %s: TIC %s, separation of %f arcsec. and a TESS mag. of %f"% (target_name, catalogTIC['ID'][where_closest], catalogTIC['dstArcSec'][where_closest], catalogTIC['Tmag'][where_closest]))
Closest TIC ID to HD 209458: TIC 420814525, separation of 0.000001 arcsec. and a TESS mag. of 7.127400
Looks like a good match, we know that HD 209458 is a fairly bright star, and the TIC coordinate is very close to the coordinate from the name resolver.