Jonathan Thomson's web journal

Determining the System Function March 28, 2011


The colored filters that cover a digital camera’s CCD let light of certain colors (wavelengths) pass while blocking others. These filters enable the camera to capture color images, but cause distortion in the spectrographs it records and the spectrograms derived from them. This distortion, along with other sources of distortion such as the CCD’s quantum efficiency, can be removed by deconvolving the spectrometer’s system function from its spectrograms. Once these effects have been removed the resulting spectrum will have a linear relationship with the intensity of the light source. The system function can be found by inputting a reference light source with a known shape, and if the reference’s irradiance is known all the other spectrums can be radiometrically calibrated against. The system function is also known as the transfer function or spectral response.


Deconvolution Illustrated
Since the diffraction grating decomposes light by wavelength and the light source is held constant, the data recorded by the spectrometer is in the wavelength domain. This means that the spectrometer’s system function can be determined by capturing a spectrograph of a light source with a flat spectrum (i.e. truly white light) and that the distortion caused by the colored filters, quantum efficiency, and other effects can be removed by division. Unfortunately, a light source with a completely flat spectrum is hard to obtain; however, a fine alternative is a light source with a non-flat but mathematically well-defined spectrum. The illustrations below demonstrates this.

The 100 W tungsten incandescent bulb’s spectrum is denoted by X and unknown. The spectrometer’s system function is denoted by H and unknown. The spectrometer’s response to the 100 W bulb is denoted by Y and is known.



Unfortunately, since X is unknown it cannot be deconvolved from Y by division to get H. However, X can be modeled as a black body using Planck’s law with corrections for tungsten’s emissivity. X’ is the model for X. Therefore, H’ = Y/X’. If X’ is a good model for X, then H’ should be a good substitution for H. For the remainder of this article no distinction is made between X and X’ as well as H and H’.



Modeling X and Determining H
The spectrum of the light produced by heating the tungsten filament of a 100 W light bulb to incandescence is very similar to an ideal black-body radiator. Therefore, the bulb’s spectrum can be mathematically modeled using Planck’s law with corrections for tungsten’s emissivity. Since a CCD counts photons, spectral photon irradiance is used.

In the equation below for spectral photon radiance of a tungsten emissivity corrected black body the variable λ is in nm and the parameter T is in K. The emissivity function ε was interpolated from the table given in Absolute Optical Calibration using a Simple Tungsten Bulb

Irradiance is used in the calibration procedure because it allows the various light sources of interest to be different distances from the entrance slit. Therefore a weak source can be placed near the slit where its light is easily detected and a strong source can be placed further back so that it does not saturate the CCD. Spectral photon radiance can be converted to spectral photon irradiance by treating the incandescent bulb as an isotropic source:

Where omega is the number of steradians covered, which is 4*pi. The emitting area of the filament is represented by Af. The area of the sphere with a radius equal to the distance from filament to slit is denoted with Asphere.


The temperature of the filament determines the shape of the spectrum the incandescent lamp produces. This temperature can be calculated by first measuring the filament’s resistance while it is at room temperature and then when power is applied to it. The hot resistance is obtained indirectly by measuring the voltage across and the current through the filament.

Therefore to find the spectrometer’s system function:
1) take a spectrograph of a CFL and use it to derive a calibrated wavelength scale, λ.
2) take a spectrograph of a 100 W incandescent bulb and measure the resistance of the filament.
3) convert the incandescent spectrograph to a spectrogram, Y(λ).
4) compute a mathematical representation of the incandescent lamp’s irradiance spectrum undistorted by the spectrometer, X(λ)
5) find H(λ) by dividing Y(λ) by X(λ).


Representing the Spectrometer Mathematically
The mathematics presented in this section aren’t required to determine the spectrometer’s system function. However, it might help you to better understand the process. X(λ) represents the number of photons per second per wavelength that cross a unit area. Therefore the number of photons per second entering the spectrometer is equal to Aslit*X(λ). The terms Trb(λ) and Tother(λ) represent the filtering out of some of the photons by absorption, reflection, etc. QE(λ) represents the fact that not all of the photons will be absorbed by the CCD and converted to electrons. The term texp is the camera’s exposure time.

The diffraction grating spreads a light source’s spectrum across the pixels of the CCD in such a way that only a narrow band of wavelengths from the spectrum fall on any particular pixel and which band of wavelengths changes based on the pixels horizontal position. When a photon of one wavelength strikes the semiconductor material inside of a pixel it creates a free electron which is indistinguishable from a free electron created by a photon of a different wavelength or even from a free electron generated by heat. Because they are indistinguishable, electrons in a pixel can only be counted or summed up (i.e. integrated) like pebbles dropped into a cup. Therefore, if we assume the number of electrons created per wavelength in a pixel is constant over the narrow band of wavelengths that shine on it, then Y(λ) = g*Δλ*V(λ).

H(λ) represents the transformation of the spectral photon irradiance to a counts. Now if, for instance, we have an LED with an actual spectrum denoted by U(λ) while the spectrum which is captured by the spectrometer is called Z(λ), then Z(λ) = H(λ)*U(λ). Since U(λ) is desired and H(λ) and Z(λ) are known then U(λ) is simply equal Z(λ)/H(λ). Keep in mind that λ was translated from a discrete set of pixel numbers, therefore Y(λ) and V(λ) are point-series not continuous functions.


Radiometric scaling
Unfortunately, an incandescent bulb is not an isotropic source. Therefore, while X has the correct shape it is off by a scaling factor. To determine this scaling factor it’s necessary to use an irradiance sensor that is placed next to the spectrometer’s slit. The TSL230 family of irradiance sensors measure total irradiance. This measurement, X, and TSL230_fO_to_irradiance() can be used to scale X so that it represents the actual spectral irradiance at the slit and not just the shape of the spectral irradiance at the slit. Thus, the spectrometer will be radiometrically calibrated and dividing a spectrogram by H will result in data that is radiometrically accurate.


Given the temperature of the filament and lambda, the function generate_Wbb_spectrum() outputs the emissivity corrected spectrum of the incandescent tungsten filament bulb. Once you have the spectrometer’s system function you can remove its effects on your other spectrograms by dividing it out of them.


Radiometry and Photometry FAQ

Radiometry and Photometry

Spectral Power Distribution Curves of Different GE Lamps

Spectral Response of Some Cameras

More Spectral Responses

Measuring System Gain (aka CCD Gain) and Noise

Measuring CCD Gain (counts/electron)

CCD Measurements

Quantum Efficiency


Continue Reading

>>>Next — Radiometric Calibration>>>

<<<Previous — Convert Spectrographs to Spectrograms<<<



3 Responses to “Determining the System Function”

  1. Andrej Says:

    Hi Jonathan, I see we have very similar interests! Arduino, Spectrometry. Do you have any more suggestions for “light source with a non-flat but mathematically well-defined spectrum” ? I am particularly interested in miniature packages. Does it have to cover a certain wavelength region to minimize the error below certain thresholds?

    The link is dead: “The emissivity function ε was interpolated from the table given in Absolute Optical Calibration using a Simple Tungsten Bulb

    And don`t forget to check our Arduino USB UV/VIS Spectrophotometer, any comments are greatly appreciated!

    • jethomson Says:

      That link works for me. I suppose it was down temporarily. I don’t know of any light source other than a tungsten filament incandescent bulb that covers a wide range of wavelengths and can be easily modeled. When you take into account the spectral emissivity of the filament which varies from bulb to bulb, even using an incandescent bulb becomes complicated. There are a wide variety of small incandescent lamps with a tungsten filament. If you want to get information about the camera’s response in a certain band of wavelengths then your probing stimulus must output enough photons in that band such that the camera is able to capture plenty of signal to overcome the camera’s noise.

  2. Harish Chockalingam Says:

    Hello I am a student at the University of Illinois at Chicago. We have a Nicolet Magna IR 560 Spectrometer; the spectrums produced by the machine are convoluted and I would like to deconvolute them. How can I determine the spectrometer’s system function?

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s