This document describes the basics of reducing CCD data to produce colour images.

Review the pipeline process first.

To take colour images, you need to use the ccd (either one) to obtain images of an object through three filters. In the example below, we use the B, V and R filters for this, but in principle any three filters can be used. Before following this thread, you need to have taken flats and darks. A set of flats is needed for every filter used. For every exposure duration of the flats, you need a set of darks. The flats should already been processed. Review the Processing Flats thread.

For this thread, I have the following files:
Dark-200s-1.fits
Dark-200s-2.fits
Dark-200s-3.fits
NGC7217-200s-B-1.fits
NGC7217-200s-B-2.fits
NGC7217-200s-B-3.fits
NGC7217-200s-R-1.fits
NGC7217-200s-R-2.fits
NGC7217-200s-R-3.fits
NGC7217-200s-V-1.fits
NGC7217-200s-V-2.fits
NGC7217-200s-V-3.fits
Flat-B.fits Flat-R.fits Flat-V.fits

Processing frames to produce colour images is essentially identical to processing monochrome frames, except the process is looped over all colours. Please read Monochrome Images for details on the process.

The Matlab script ProcessColour.m is based on ProcessMonochrome.m, but with the require loop over all colours added.

Edit ProcessColour.m to suit your data. In particular:

  1. Select a star for registering as outlined in Processing Monochrome Images.
  2. Set the name of your object

Running the ProcessColour.m script will produce the following files:
NGC7217-B.fits
NGC7217-R.fits
NGC7217-V.fits

Combining Frames into a Colour Image

This document will describe two ways to create colour images from three-band data:

  1. RGB reconstruction.
  2. LRGB reconstruction.

Each method has its advantages and disadvantages which are discussed below.

RGB reconstruction

In an RGB image, there are three image planes: one for each colour red, green, and blue. Each image plane is simply an intensity map. The brighter the pixel in the plane, the more of that colour in the combined image.

To convert three-band (three-filter) data into an RGB inage, simply assign the colour red to one band, green to another, and blue to the remaining. The bands themselves don't have to actually correspond in reality to those colours. If they don't, the final RGB image is a false-colour image.

When data are taken at the telescope through the R, V, & B filters, we can use those for the R, G, & B image planes to produce an approximately true-colour image.

The only trick is determining how much each band should contribute to it's plane. The CCD is much more sensitive to the R band than the B band. Hence, we need to compensate for the differential sensitivity in each band.

The easiest way to compensate for the differential sensitivity is to simply rescale each of the R, V, & B frames. But by how much? The correct method is to use a star in the field for which you know it's true R, V, & B magnitudes. Without this information, one is left to scaling them interactively until a reasonable colour balance is achieved. Figure 1 was produced by this method.

Use the Matlab script PlotImage_RGB.m as a guideline. You will need to edit the file to change the base name of the files and the scaling values.

Figure 1 (click to examine in detail)
An RGB image of NGC 7217.

Pros

  • Easy to implement.
  • Retains the information from the bands, so is more correct.

    Cons

  • The noise from the B channel often dominates, giving unpleasant results.
  • The B, V, & R filters don't correspond precisely to the R, G, and B wavelength bands.
  • Difficult to put the image on anything but a linear scale.

    LRGB reconstruction

    Luminosity-RGB reconstruction. It differs from RGB reconstruction in that one channel sets the luminosity, while three channels are used to reconstruct the colour.

    Take the final product from RGB reconstruction. Now divide each pixel by the maximum of the R, G, and B elements of that pixel. That creates a colour frame that contains only the colour of each pixel, not the luminosity. Multiply this [NxM,3] frame by the [NxM] luminosity frame to create the final image.

    The advantage of this method is that colour is often a smoothly-varying parameter compared with luminosity. So the RGB channels can be smoothed to reduce the noise (particularly helpful for the blue channel) while an unfiltered luminosity image provides the high S/N for the high-resolution detail.

    Use the Matlab script PlotImage_LRGB.m as a guideline. You will need to edit the file to change the base name of the files and the scaling values.

    Figure 1 (click to examine in detail)
    An LRGB image of NGC 7217. The luminosity is log-scale.

    Pros

  • Aesthetically pleasing results
  • Doesn't waste light since you can expose the high S/N luminosity image unfiltered.
  • Can set the L-band to any scale: linear, log, sqrt, hist-eq, etc.

    Cons

  • Misleading results. Suppose you have a portion of the image that is bright in IR and no other band. It will appear in the L-band and be given a colour derived from the R, V, & B bands to which it does not contribute information.
  • High resolution L-band information, but low resolutions colour information.