Version | Author | Date | PypeIt |
---|---|---|---|
1.0 | Joe Hennawi | 25 Jan 2021 | 1.1.1 |
The sensitivity function in PypeIt is defined to be the function S_\lambda satisfying
S_\lambda = \frac{F_\lambda}{N_\lambda} with units of [{\rm erg/cm^2/photons}],
where
F_\lambda is the specific energy flux in units of [{\rm erg/s/cm^2/\mathrm{\mathring{A}}}],
N_\lambda is the specific photon flux with units [{\rm photons/s/\mathrm{\mathring{A}}}],
PypeIt spec1d files contain N_{\rm pix} with units [{\rm photons/pixel}]. To generate flux calibrated spectra F_\lambda, S_\lambda must be computed from a spectro-photometric standard star observations (insert hyperlink to discussion below and fluxing.rst).
N_{\lambda} must be determined from N_{\rm pix}
via
N_\lambda = \frac{N_{\rm pix}}{\frac{d\lambda}{d{\rm pix} \Delta t}},
where \Delta t is the exposure time and \frac{d\lambda}{d{\rm pix}} is the wavelength spacing per pixel, which is in general not a constant since PypeIt spec1d spectra (i.e. N_{\rm pix}) are extracted on an irregularly spaced wavelength grid.
After flux calibration, flux calibrated spectra (i.e. F_\lambda) are reported in the spec1d
files as e.g. OPT_FLAM
and BOX_FLAM
for optimal and boxcar extractions, respectively, in units of
[10^{-17} {\rm erg/s/cm^2/\mathrm{\mathring{A}}}]. See :ref:`fluxing` for additional details.
Flux calibration of PypeIt spectra is expressed via the "spectroscopic zeropoint", which, by analogy with the imaging zeropoint, is defined to be:
{\rm Zeropoint} \equiv -2.5 \log_{10}{\left[\frac{\frac{\lambda^2}{c}S_\lambda}{\left(\frac{3631 {\rm Jy}}{{\rm photons}/ {\rm s} / \mathrm{\mathring{A}}}\right)}\right]}
With this definition we see that an astronomical source with a flat spectrum in frequency \nu, i.e. F_\nu = {\rm const} and AB magnitude equal to the Zeropoint will produce N_\lambda = 1 {\rm photon/s/\mathrm{\mathring{A}}} on the detector, that is sum of the N_{\rm pix} photons per pixel over all pixels corresponding to a \Delta \lambda = 1 \mathrm{\mathring{A}} interval will be equal to unity.
From the definition of the spectroscopic zeropoint above, it follows that
\left(\frac{F_\lambda}{10^{-17} {\rm erg/s/cm^2/\mathrm{\mathring{A}}}}\right) = 10^{-0.4({\rm Zeropoint - ZPCONST})} \left(\frac{N_\lambda}{\rm photons/s/\mathrm{\mathring{A}}}\right)\left(\frac{\lambda}{\mathrm{\mathring{A}}}\right)^2
where ZPCONST = 40.09 is a dimensionless number defined by
{\rm ZPCONST}\equiv \frac{\frac{\mathrm{\mathring{A}}^2}{c}\times 10^{-17}{\rm erg/s/cm^2/\mathrm{\mathring{A}}}}{3631 {\rm Jy}}.
In practice PypeIt fits and stores the spectroscopic zerpoints and uses the equation above to compute F_\lambda from N_\lambda and vice-versa.
The sensitivity function script :ref:`pypeit_sensfunc` produces a QA plot showing the the zeropoint fit, as shown below. For echelle observations this zeropoint QA is shown for each order.
The zeropoint is closely related to the spectroscopic throughput. The number of counts per pixel in a spectrum of an object with flux F_\lambda
N_{\rm pix} = A T(\lambda){\rm Atm}(\lambda)\frac{d\lambda}{d_{\rm pix}}\frac{F_\lambda}{h\nu}\Delta t,
where A is the effective aperture of the telescope, T(\lambda) is the spectroscopic throughput, {\rm Atm(\lambda)} is the attenuation caused by the Earth's atmosphere, \frac{d\lambda}{d_{\rm pix}} is the number of \mathrm{\mathring{A}} per pixel defined above, h\nu is the photon energy, and \Delta t is the exposure time.
Based on this equation and the definintions above it follows that the spectroscopic throughput can be written
T(\lambda) = \frac{h\nu}{A S_\lambda},
Note T(\lambda) is clearly dimensionless given the units of S_\lambda: [{\rm erg/cm^2/photons}]. As S_\lambda is specified by the zeropoint, throughput curves can be computed once the zeropoints given the effective aperture of the telescope.
In addition to the zeropoint QA shown above, the sensitivity function script pypeit_sensfunc
also produces a QA plot
showing throughput curve(s), computed directly from the spectroscopic zeropoints.
Note that we have defined the spectroscopic throughput above to be that of the telescope + instrument system, but
NOT include the attenuation caused by the Earth's atmosphere. Also, the zeropoints, sensitivity functions, and PypeIt
flux calibration algorithms in general do not attempt to remove the impact of slit losses. In the limit where your standard
star observations and science observations have exactly the same seeing, the flux calibration will be perfect. In the more
realistic scenario where they differ, this will manifest as a wavelength dependent systematic error in the flux calibration,
with the direction of the error depending on the relative seeing between the standard star and science observations. In future
versions we hope to implement a better treatment of slit losses. For the time being we recommend that users that require
very accurate flux calibration force PypeIt flux calibrated spectra to agree with photometry. This can be done using the
filter parameter option for 1D coadding (see :ref:`coadd1dpar`), which can be set in the
.coadd1d file which is used to guide 1D coaddition with the pypeit_coadd1d
script (see :ref:`coadd1d`).