Signal versus Noise

Astronomical Laboratory 29:137, Fall 2013
by Philip Kaaret

Reading

Introduction

In this lab, you will calculate the signal to noise ratio of a stellar brightness measurement made with a CCD cameras.

Equipment


Signal and Noise

A ideal imaging detector for astronomy would record the number of photons striking each pixel and nothing else - no counts due to read noise or dark current.  As you found in the previous lab, the measurements produced by a CCD will also have contributions due to noise associated with the electronics that amplifies and digitizes the charge signal in the CCD readout (read noise) and due to electrons released by thermal fluctuations in the silicon (dark current).  In order to measure the brightness of a star these contributions must be measured and subtracted off.  However, since the read noise and dark current arise due to random process, they will fluctuate and it will never be possible to subtract them off exactly.

Steps in CCD Data Reduction

The standard steps in the 'reduction' of an astronomical image are as follows:

  1. Subtract a mean dark frame from the object frame
  2. Divide the resulting frame by a dark subtracted mean flat field frame

One then ends up with a 'reduced' object image that has been corrected for the CCD effects of bias and dark current and for variations in the quantum efficiency across the field of the CCD and telescope. 

To do photometry on a star, one then draws a circle around the star and sums up the counts inside the circle.  Since the night sky is not perfectly dark, one also draws an annulus centered on the star and excluding any other stars and then subtracts the contribution from the sky background.  The radius of the circle enclosing the star should be selected to include most of the counts from the star, but not be so large that it includes too much sky background.  The inner radius of the annulus should be large enough that it does not include any counts from the star.  The total area of the annulus should be a few times larger than that of the circle.


CCD Signal to Noise Equation

The signal, S, from the star is the total number of net electrons, N*, recorded by the CCD from the star after subtraction of the bias, dark current, and sky background.  The generation of each electron is a random process and if we take repeated measurements of the star the value of NT will fluctuate according to a Poisson distribution (note that we use NT instead of N* as in the textbook).  In the limit of large NT (acutally N* > 25 is enough), the Poisson distribution is well approximated by a Gaussian distribution and we can describe the fluctuations in NT in terms of a standard deviation equal to sqrt( NT).  This is true even with an ideal CCD and telescope and with zero sky background.  These instrinsic fluctations contribute a limiting noise term σ* = sqrt( N*).  A 'bright' source is defined as one where the intrinsic noise dominates and, thus, the signal to noise ratio, S/N, for a measurement of the source is

S/N = N*/sqrt( N*) = 1/sqrt( N*)


The number of electrons recorded by the CCD from the dark current and the sky background are also Poisson distributed and fluctuate in the same way.  Let's look at each pixel individually, we write the number of dark current electrons per pixel as ND.  Even though we subtract off an estimate of this number, the fluctuations in the number of dark current electrons remains and adds noise per pixel, σD = sqrt(ND).  The same is true for electrons produced by the sky background.  The number of electrons per pixel from sky background is NS and each adds noise, σS = sqrt(NS).

The read noise, σR, is the noise associated with the electronics that amplifies and digitizes the charge signal in the CCD readout.  Read noise is present even for zero signal and is usually assumed to be independent of the magnitude of the signal.  Read noise will arise for each pixel in the star image, so one needs to sum up the read noise for all the pixels in the source extraction region.

We are then led to the question of how to add these various noise contributions.  The key point is that the noise distributions are well described by Gaussian probability distributions.  To combine two probability distributions, one performs a convolution.  The convolution of f and g is written fg. It is defined as the integral of the product of the two functions after one is reversed and shifted:

http://upload.wikimedia.org/math/1/8/5/185ff6a342b3ec1719643396613151e2.png \stackrel{\mathrm{def}}{=}\
        \int_{-\infty}^\infty f(\tau)\, g(t - \tau)\, d\tau

The wikipedia page on convolution, http://en.wikipedia.org/wiki/Convolution, has a good explanation with some nice graphics to help you get some intuition about what convolution means and does to functions.

The convolution of two Gaussians is another Gaussian.  If the width (standard deviation) of the initial Gaussians are σ1 and σ2, then their convolution has a width σ2 = σ12 + σ2 2.   This sort of addition is called "root of sum of squares" or "addition in quadrature".   Noting that  we need to sum up the noise contributions from dark current, sky background, and read noise for each pixel in the circle containing the star, i.e. for npix pixels, the total noise is then:

σ2 = σT2 + npix × (σS 2 + σD 2 + σR 2)  = sqrt[NT + npix × (NS + ND + σR2)]

Contrary to what is stated in the textbook, the reason that the read noise term appears with a square, unlike the other terms in the expression on the right, is simply because it is a directly measured noise, while the other terms are estimates of noise derived from a number of electrons, e.g. σS = sqrt(NS).  Note that the noise terms are uniformly treated in the center expression.  (Also, note that 'shot noise' is another name for 'Poisson noise', so the footnote on page 74 actually makes no sense.)  The signal to noise equation for CCDs or the "CCD equation" is then:

S/N = N*/sqrt[NT + npix × (NS + ND + σR2)]

In the previous lab, you measured the read noise of the SBIG ST-402 and how the dark current depends on temperature and exposure time.  In this lab, you will use the images that you obtained of Vega to estimate the sky background and the signal level from stars and you will use the dark frames to estimate the dark current.  Using this information, you will then plot how the S/N depends on various parameters.


Measuring Counts from Vega, the Sky, and the Dark Current

The goal in this section is to use the images that you obtained while observing Lyra on the roof to measure the counts from a selected star, the sky background, and the dark current.  Note that you need a sky image that does not have a dark frame subtracted, a dark frame with the same exposure time and temperature, and a bias frame (dark frame with 0.040 second exposure) at the same temperature.


Calculating the Signal to Noise Ratio

Now let's calculate the S/N of your detection of your selected star.  You just calculated values for NT , NS, and ND in counts.  Recall that you need to convert these to electrons.  Use the gain of the CCD (that you can readoff using CCDOps or get from your write-up of the last lab) to do this conversion.  In choosing the radius of the circle that you used to extract counts for the star, you picked npix .   Use your value for the read noise, σR2, from the previous lab.  Record your calculations and your results in your lab notebook.  Which component of the noise dominates? 

Go back to your sky image and change the radius of the circle to be 1, 2, 3, 4, and 6 physical pixels (if your original radius was not less than 6 pixels, see the instructor before picking the set of radii).  In each case, record the sum of counts and number of pixels in the circle for the each image.  Writes a short Python program that takes these values in arrays and makes 1) a plot of the net counts for the star versus extraction radius, and 2) a plot of S/N versus extraction radius.  Note that you don't need to repeat the measurements for the annulus (as long as its inner radius is large).  You don't need to repeat the annulus calculations each time

Now inspect your sky image and find a much dimmer star, one of the dimmest that you can see.  Repeat the process above, ending up with a pair of plots (as above) for the dimmer star. 

Put printouts of your four plots in your lab notenook and write some discussion comparing them with figure 5.6 and the upper panel of figure 5.7 in the textbook.