Chapter 3 Statistics of astronomical images Goal-of-the-Day Understand how noise affects astronomical data and how it can be estimated. 3.1 Essential preparation Exercise 3.1 (a) Have a quick look at last week’s results webpage: http://www.astro.keele.ac.uk/astrolab/results/week02/week02.pdf 3.2 Relation between photon, electron and ADU When measuring the light from an astronomical source, what we are after is the rate at which photons of a particular energy are emitted. This cannot be measured in a straightforward manner, as it involves a few assumptions with regard to the distance of the source, the isotropy of the emission, and the extinction on its way to Earth. What is easier to measure is the rate at which photons of a particular energy from that source pass through a certain area at the top of the Earth’s atmosphere. However, there are still several steps involved between these photons and the counts in a digital image. First, the photons may experience extinction by the Earth’s atmosphere. Once the photons enter the telescope aperture or entrance pupil, they start a journey through a series of optical elements before being concentrated on some of the CCD pixels. The optical elements never transmit (or reflect) 100% of the light, which is why it is often advantageous to design instruments with as few as possible optical elements. Net throughput often ranges from less than a percent in some spectroscopic instruments to more than 50% for efficient imagers. The CCD pixel is not 100% efficient in detecting the incoming photons: the fraction of the incoming photons that release an electron which is captured within the potential well of the pixel, the Quantum Efficiency (QE) of modern CCDs is typically 80% for visual photons (wavelengths between λ ∼ 400 and 700 nm) but it drops to zero for ultra-violet (λ < 300 nm) and infra-red (λ > 1000 nm) photons. At last, the electrons in a pixel are converted into counts, or ADUs (Analogue-to-Digital conversion Units). The number of ADUs corresponding to one electron is called the gain. Image headers often contain descriptors for the inverse gain = 1/gain. It is commonly set such that 216 21 22 CHAPTER 3. STATISTICS OF ASTRONOMICAL IMAGES (=65,536) counts — i.e. the maximum value of a 16-bit integer — roughly corresponds to the saturation level of the potential well of the CCD pixel. Exercise 3.2 (a) Suppose a CCD has pixels that saturate at 120,000 electrons (e− ). What would be a reason to operate at an inverse gain of 2 e− ADU−1 ? (b) Would it be useful to operate at 1 e− ADU−1 ? And at 0.5 e− ADU−1 ? One of the most powerful properties of CCD detectors is their linearity: the Quantum Efficiency of a pixel is constant to within (much) less than 1 percent over most of the depth of the potential well. If saturation corresponds to ∼ 65, 000 counts then linearity is generally assured for counts as few as 1, up to as many as ∼ 50, 000 — i.e. more than four orders of magnitude1 . Closer to saturation, the detector response diminishes. This may be noticed by comparing the image of a bright star with that of a fainter star: the central pixel(s) of the bright star may suffer from non-linearity, causing the core of the radial light profile to look distorted when compared to that of a fainter star. Exercise 3.2 (c) Examine the radial profiles of some of the stars (Hint: use imexamine). Do they suffer from saturation? (d) Would you expect to see non-linearity, considering the counts in their central parts? 3.3 Noise and probability functions The number of counts in a pixel is affected by uncorrelated fluctuations (noise) in the rate of incoming photons, in the rate of spurious electrons, and as induced by the electronics upon read-out of the CCD. Thus the registered number of counts, x, can be seen as drawn from a probability function p(x). The likelihood that the actual mean rate of incoming photons is x0 can be estimated if the shape of the probability function is known. Often (but not always), probability functions are well described by either a Gaussian distribution for a symmetric, continuous range of values: " # 1 (x − x0 )2 √ p(x) = exp − , 2σ 2 σ 2π (3.1) or by a Poisson distribution for a positive, discrete range of values: p(x) = xx0 exp [−x0 ]. x! (3.2) Exercise 3.3 (a) Would the probability function for the rate of incoming photons be better described by a Gaussian distribution or by a Poisson distribution? (b) And the probability function of the scatter introduced by the read-out electronics? (c) Sketch Gaussian and Poisson distributions, with x0 = 4 and σ = 2, for −1≤x ≤ 9. 1 Though only at a peak QE∼ 1%, the human eye may distinguish a range in brightness levels of ∼ 109 . 3.4. MEASUREMENT OF THE READ-OUT NOISE AND GAIN 23 If N values xi are drawn from the probability function — i.e. if a certain measurement is repeated N times — then the mean expectation value, hxi, and variance, σ 2 , are: P hxi = P xi N (3.3) (xi − hxi)2 (3.4) N For a Poisson distribution, σ 2 = hxi. The variance is a measure for the expected spread of values. The standard deviation, σ, corresponds to a specific probability that the measured value will be within that deviation from the mean. Hence the noise is characterised by its distribution type (usually Gaussian or Poisson) and standard deviation. Noise may be reduced by taking more data and then combining these data. The Iraf command imcombine provides a convenient way of combining many images. 2 σ = Exercise 3.3 √ (d) For an average of n images each with standard deviation σ, show that σaverage = σ/ n; (e) Use the star* images, and choose an area free of stars. Compare the standard deviation of the pixel values in this area in the individual star images, with that in the average of the images (Hint: use imstatistics). 3.4 Measurement of the Read-Out Noise and gain The noise introduced upon read-out of the CCD — the Read-Out Noise or RON — and the gain may be estimated by comparison of the noise statistics at different count levels. The test images in our data set are suitable for this. These images were obtained by pointing the telescope at a source of uniform illumination (inside of the observatory dome, or twilight sky). The same area in the images will have different mean count levels. We will now look at the noise statistics within one such area (chosen to be free of any structure but comprising enough pixels to calculate reliable statistics). The standard deviation of the measured number of electrons in this area is then: σe = q 2 2 σRON,e + σPoisson,e , (3.5) where σRON,e arises from the read-out noise and σPoisson,e from the electrons in the pixels. Exercise 3.4 2 , depends on the read-out noise (a) Show that the measured variance of the counts, σADU in electrons, σRON,e , the mean number of counts, hxADU i, and the gain, g, as: 2 2 × g 2 + hxADU i × g = σRON,e σADU (3.6) (Hint: remember that the gain relates the number of counts to the number of electrons in each pixel.) (b) Sketch the variance of the counts as a function of the mean number of counts; (c) How does the slope of the curve relate to the gain and read-out noise? What is the variance if the exposure time were zero? (d) Use the test* images to determine the gain and read-out noise, using eq. (3.6); (Hint: choose the position and size of the measurement area with care.) (e) Compare the results with the image header information about gain and read-out noise. 24 CHAPTER 3. STATISTICS OF ASTRONOMICAL IMAGES