HETDEXtoy for #AstroHackWeek

Michael Gully-Santiago

Inference on the atmosphere based on sky signal

The first thing we want to know is:

  1. What is the power spectrum of atmospheric variability
  2. What is the typical HETDEX cadence?

To address question 1, look at the second line from this paper: "seconds to decades", which doesn't help because I want to have a number- a power spectrum. What is the typical timescale of variation.

To address question 2, we have from this website: 1200 seconds in 3 dithers, or about 7 minutes per exposure.

I won't pursue this question any more- times scales less than 7 minutes will be smeared out. But time scales longer than 7 minutes will not. If we think about this question in terms of atmospheric properties, 7 minutes corresponds to patches of air of kilometer sizes, depending on the prevailing wind speed and coherence of atmospheric air patches.

Now we move on to looking at the wavelength dependence of the atmosphere.

SkyCalc generates a sky spectrum for desired atmospheric properties

Copied verbatim from this website:

SkyCalc is based on the Cerro Paranal Advanced Sky Model, which was developed in particular to be used in the ESO Exposure Time Calculators, by a team of astronomers at the Institute for Astro- and Particle Physics at the University of Innsbruck, as part of an Austrian in-kind contribution to ESO.

The in-kind contribution also includes two tools to correct observations for telluric absorption and emission (Molecfit and Skycorr), which can be found here.

The citations for the Cerro Paranal Sky Model are Noll et al. (2012, A&A 543, A92) and Jones et al. (2013, A&A 560, A91).

A library of telluric transmission spectra with various resolutions and atmospheric conditions has been calculated with the Cerro Paranal Advanced Sky Model. A description of the usage of the spectra can be found in the article Moehler et al. (2014, A&A, submitted).

Admittedly this model was developed for Cerro Paranal (elevation 2635 m), but let's just assume the sky at McDonald Observatory (elevation 2070 m) looks remarkably similar to the sky in Cerro Paranal, with the proviso that seasonal differences will be flipped (winter-summer), and the typical PWV is probably higher in TX than in Chile. Luckily PWV is a tunable parameter in SkyCalc.


In [1]:
dir1 = '/Users/gully/astroML/HETDEXtoy/data/'
fn1 = 'skytable_PWV00_5mm.fits'
fn2 = 'skytable_PWV20_0mm.fits'
fn3 = 'skytable_JunJul.fits'
fn4 = 'skytable_22arcmin.fits'
from astropy.io import fits
import numpy as np
skydat = fits.open(dir1 + fn1)
skydat2 = fits.open(dir1 + fn2)
skydat3 = fits.open(dir1 + fn3)
skydat4 = fits.open(dir1 + fn4)


WARNING: AstropyDeprecationWarning: Config parameter 'enabled_record_valued_keyword_cards' in section [io.fits] of the file '/Users/gully/.astropy/config/astropy.cfg' is deprecated. Use 'enable_record_valued_keyword_cards' in section [io.fits] instead. [astropy.config.configuration]
WARNING:astropy:AstropyDeprecationWarning: Config parameter 'enabled_record_valued_keyword_cards' in section [io.fits] of the file '/Users/gully/.astropy/config/astropy.cfg' is deprecated. Use 'enable_record_valued_keyword_cards' in section [io.fits] instead.

The output spectrum inludes:

  • Molecular Emission of Lower Atmosphere
  • Emission Lines of Upper Atmosphere
  • Airglow Continuum

In [2]:
dat = skydat[1].data
dat2 = skydat2[1].data
#print dat.columns
wl = dat['lam']*1000.0
fl = dat['flux']
fl2 = dat2['flux']
fl3 = skydat3[1].data['flux']
fl4 = skydat4[1].data['flux']

In [3]:
%pylab inline 

import numpy as np
import os
from astropy.table import Table
from astropy.io import ascii
import pandas as pd
fontsize=20
matplotlib.rc('axes', titlesize=fontsize)
matplotlib.rc('axes', labelsize=fontsize)
matplotlib.rc('xtick', labelsize=fontsize)
matplotlib.rc('ytick', labelsize=fontsize)
matplotlib.rc('font', size=fontsize, family='serif',
              style='normal', variant='normal',
              stretch='normal', weight='normal')


Populating the interactive namespace from numpy and matplotlib

In [4]:
fig = plt.figure(figsize=(10, 6))



ax_Pxy = plt.axes((0.2, 0.6, 0.80, 0.80))
ax_Px = plt.axes((0.2, 0.14, 0.80, 0.4))
ax_Pxy.xaxis.set_major_formatter(NullFormatter())

ax_Pxy.plot(wl,fl, '-r', linewidth = 1, 
        label='0.5 mm PWV', drawstyle='steps')
ax_Pxy.plot(wl,fl2, '-b', linewidth = 1, 
        label='20 mm PWV',drawstyle='steps')

ax_Pxy.legend(loc = 'best', fontsize = 16)
ax_Pxy.set_xlim((350,550))
ax_Pxy.set_ylabel('$f$ (photons s$^{-1}$ m$^{-2}$ $\mu$m$^{-1}$ arcsec$^{-2}$)')

plt.axes(ax_Pxy)
ax_Px.plot(wl,fl2-fl, '-k', drawstyle='steps')


ax_Px.set_xlim((350,550))
ax_Px.set_xlabel('$\lambda$ (nm)')
ax_Px.text(355, -0.3, 'Difference', alpha = 0.5)
plt.axes(ax_Pxy)


plt.show()


Let's see how the spectrum depends on different properties.


In [5]:
fig = plt.figure(figsize=(10, 6))


ax_Pxy = plt.axes((0.2, 0.6, 0.80, 0.80))
ax_Px = plt.axes((0.2, 0.14, 0.80, 0.4))
ax_Pxy.xaxis.set_major_formatter(NullFormatter())

ax_Pxy.plot(wl,fl, '-r', linewidth = 1, 
        label='~ TX Summer', drawstyle='steps')
ax_Pxy.plot(wl,fl3, '-b', linewidth = 1, 
        label='~ TX Winter ',drawstyle='steps')

ax_Pxy.legend(loc = 'best', fontsize = 16)
ax_Pxy.set_xlim((350,550))
ax_Pxy.set_ylabel('$f$ (photons s$^{-1}$ m$^{-2}$ $\mu$m$^{-1}$ arcsec$^{-2}$)')

plt.axes(ax_Pxy)
ax_Px.plot(wl,fl3-fl, '-k', drawstyle='steps')


ax_Px.set_xlim((350,550))
ax_Px.set_xlabel('$\lambda$ (nm)')
ax_Px.text(355, 200, 'Difference', alpha = 0.5)
plt.axes(ax_Pxy)


plt.show()



In [6]:
fig = plt.figure(figsize=(10, 6))


ax_Pxy = plt.axes((0.2, 0.6, 0.80, 0.80))
ax_Px = plt.axes((0.2, 0.14, 0.80, 0.4))
ax_Pxy.xaxis.set_major_formatter(NullFormatter())

ax_Pxy.plot(wl, fl, '-r', linewidth = 1, 
        label='North of FOV', drawstyle='steps')
ax_Pxy.plot(wl, fl4, '-b', linewidth = 1, 
        label='South of FOV',drawstyle='steps')

ax_Pxy.legend(loc = 'best', fontsize = 16)
ax_Pxy.set_xlim((350,550))
ax_Pxy.set_ylabel('$f$ (photons s$^{-1}$ m$^{-2}$ $\mu$m$^{-1}$ arcsec$^{-2}$)')

plt.axes(ax_Pxy)
ax_Px.plot(wl,fl4-fl, '-k', drawstyle='steps')


ax_Px.set_xlim((350,550))
ax_Px.set_xlabel('$\lambda$ (nm)')
#ax_Px.text(355, 200, 'Difference', alpha = 0.5)
plt.axes(ax_Pxy)


plt.show()


Summary The biggest change is season-to-season in a single line. You can detect variations in the sky across the field of view due to minute airmass differences.


In [ ]: