jwst.py

A Python interface for simulating time-series filter photometry with the James Webb Space Telescope (JWST).

class planetplanet.detect.jwst.Filter(name=None, wl=None, throughput=None, dwl=None, eff_wl=None, eff_dwl=None)

A photometruc filter class. This is an interface for filter photometry calculations.

Parameters:
  • name (str) – Name of the filter
  • wl (array_like) – Wavelength grid for filter [\(\mu \mathrm{m}\)]
  • throughput (array_like) – Filter throughput
  • dwl (array_like) – Wavelength width grid for filter [\(\mu \mathrm{m}\)]
  • eff_wl (float) – Effective filter wavelenth [\(\mu \mathrm{m}\)]
  • eff_dwl (float) – Effective filter width [\(\mu \mathrm{m}\)]
compute_lightcurve(time, flux, continuum, lam, stack=1, atel=25.0, thermal=True, time_hr=None, flux_hr=None, quiet=False)

Computes an observed lightcurve in the Filter().

Parameters:
  • time (array_like) – Time grid [days]
  • flux (array_like) – Observed flux grid (time by lam) [\(\mathrm{W/m}^2 / \mu \mathrm{m}\)]
  • continuum (array_like) – Observed continuum flux grid (no occultations, shape time by lam) [\(\mathrm{W/m}^2 / \mu \mathrm{m}\)]
  • lam (array_like) – Wavelength [\(\mu \mathrm{m}\)]
  • stack (int) – Number of exposures to stack. Default 1
  • atel (float) – Telescope collecting area [\(\mathrm{m}^2\)]. Default 25
  • thermal (bool) – Compute thermal noise. Default True
  • time_hr (array_like) – High-res time grid [Days]. Default None
  • flux_hr (array_like) – High-res flux grid. Default None
convolve(lam, flux)

Convolve flux with normalized filter throughput.

Parameters:
  • lam (array_like) – High-res wavelength grid [\(\mu \mathrm{m}\)]
  • flux (array_like) – High-res flux grid [\(\mathrm{W/m}^2 / \mu \mathrm{m}\)]
Returns array_like F:
 

Flux convolved with normalized throughput

photon_rate(lam, flux, atel=25.0, dlam=None)

Compute the photon count rate registered by the detector.

Parameters:
  • lam (array_like) – High-res wavelengths [\(\mu \mathrm{m}\)]
  • flux (array_like) – Spectral flux density [\(\mathrm{W/m}^2 / \mu \mathrm{m}\)]
  • atel (float) – Telescope collecting area [\(\mathrm{m}^2\)]. Default is 25
  • dlam (array_like) – Delta-wavelength grid. Default is None and is calculated
Returns array_like cphot:
 

Photon count rate [\(\mathrm{s}^{-1}\)]

plot(ax=None)

Plots the filter throughput curve.

Parameters:ax (axis) – An axis instance
planetplanet.detect.jwst.estimate_eclipse_snr(tint=2184.0, nout=4.0, lammin=1.0, lammax=30.0, Nlam=10000, Tstar=2560.0, Tplan=400.0, Rs=0.12, Rp=1.086, d=12.2, atel=25.0, verbose=True, plot=True, thermal=True, filters='MIRI')

Estimate the signal-to-noise on the detection of secondary eclipses in JWST/MIRI photometric filters.

Parameters:
  • tint (float) – Exposure time [s]. Default 36.4*60.
  • nout (float) – Out-of-transit time observed [transit durations]. Default 4
  • lammin (float) – Wavelength minimum [\(\mu \mathrm{m}\)]. Default 1.0
  • lammax (float) – Wavelength maximum [\(\mu \mathrm{m}\)]. Default 30.0
  • Nlam (int) – Number of wavelengths. Default 10000
  • Tstar (float) – Stellar effective temperature [K]. Default 2560
  • Tplan (float) – Planet equilibrium temperature [K]. Default 400
  • Rs (float) – Stellar radius [solar radii]. Default 0.12
  • Rp (float) – Planet radius [Earth radii]. Default 1.086
  • d (float) – System distance [pc]. Default 12.2
  • atel (float) – Telescope collecting area [\(\mathrm{m}^2\)]. Default 25
  • verbose – Print things. Default True
  • plot – Make a plot. Detault True
  • thermal – Include thermal noise. Default True
  • filters (str or list of Filter() objects) – User provided filter names or list of filters. Default MIRI
planetplanet.detect.jwst.create_tophat_filter(lammin, lammax, dlam=0.1, Tput=0.3, name='custom')

Create a tophat Filter()

Parameters:
  • lammin (float) – Wavelength minimum [\(\mu \mathrm{m}\)]
  • lammax (float) – Wavelength maximum [\(\mu \mathrm{m}\)]
  • dlam (float) – Wavelength resolution [\(\mu \mathrm{m}\)]. Default 0.1
  • Tput (float) – Filter throughput. Default 0.3
  • name (str) – Name of filter. Default “custom”
Returns filt:

New custom tophat Filter() object

planetplanet.detect.jwst.get_spitzer_filter_wheel(warm=True)

Read-in and instantiate list of Spitzer IRAC filters as Filter() objects

Parameters:warm (bool) – If True uses only Warm Spitzer filters
Returns:A list of Filter() objects
planetplanet.detect.jwst.get_miri_filter_wheel()

Create a list of MIRI Filter() objects

Returns list wheel:
 list of MIRI Filter() objects