# It’s Right! It’s Wrong! It’s Approximate! SpectroClick President Alex Scheeline

We here at SpectroClick know a thing or two about diffraction gratings. They are a component in the SpectroClick Kit, and you look through two of them in a SpectroBurst™ Viewer. The particular arrangement we use in the AAH-300 spectrometer is its “secret sauce”. Your intrepid blogger has been using diffraction gratings for three quarters of his life. What actually happens when light goes through, or transits, a grating? Lately, I’ve been obsessed with modeling the path the light takes.

The interference pattern consequent to light interacting with a structure having periodic variations of distance d results in light appearing at an angle β when

n λ = d(sinα + sinβ)   (1) Reflection grating schematic

Figure 1. Reflection grating, showing ruling spacing d, entrance angle from the normal α, and three diffraction angles βblue, βgreen, and βred for three wavelengths. Positive angles are measured counterclockwise from the grating normal.

Here, n is an integer, λ (Greek letter lambda) is the wavelength, d is the spacing of grating rulings, α (Greek letter alpha) is the angle of incidence between the normal to the grating (the normal is perpendicular to the plane of the grating), and β (Greek letter beta) is the angle between the normal and the exiting, visible beam. Even if you don’t know any trigonometry, you can punch the “sine” key on your calculator to compute the sine of α and the sine of β. To keep this blog entry from going on interminably, if you want to know what sines are, go check them out at https://www.mathsisfun.com/sine-cosine-tangent.html or some other website.

If n=0, a reflection grating acts like a mirror. Mirrors have the property that the angle of incidence (α) equals the angle of reflection (β). A first look at equation 1 seems to contradict what “everyone knows” about mirrors. But be careful about signs (aren’t you glad you’re reading this? Sine and sign are homonyms.). The magnitude of α and β are the same, but their signs are opposite. Since sin(-x) = -sin(x), equation 1 works provided all angles are measured in the same direction. Thus if α =+10°, β = – 10° or +350°. There’s a riddle for you: “When does -10 = + 350? When you’re measuring angles.”

What happens with transmission gratings? When we published the instruction book for the SpectroClick Kit, in the discussion at the top of P. 10 we went through three versions. The first version was correct, but we didn’t recognize it as such. The second version was a pretty good approximation, but we didn’t immediately see that it was an approximation, and the third version (what we now have uploaded to the site at https://www.spectroclick.com/wp-content/uploads/2018/02/SPECTROCLICK-KIT_Instr_02_13_18.pdf) gets it right. So let’s look at the three versions.

Version 1. Transmission grating and rotated transmission grating Transmission grating geometry

Figure 2. Transmission grating analog to Figure 1. Vagueness in the drawing reflects the author’s intentional fuzziness at the time the first Kit instruction booklet was issued. “β” applies to each of the colored rays. The variable θ does not appear in the figure; it is the angle between the entering ray (heaviest black line) and the grating normal.

In the original manual about the SpectroClick Kit, we wrote down the grating equation as

n λ = d(sinα – sinβ)   (2)

I figured that sign conventions were a nuisance to students and being able to say “in zero order,
α = β” seemed like an easy short-cut. What if the grating was rotated so that the incoming ray was not normal to the grating plane? I recalled the derivation of how a Czerny-Turner plane grating spectrograph works. There, when the grating is operating in zero order, the incidence angle is η (Greek letter eta), and as the grating is rotated to an angle θ, the wavelength visible at the exit slit of the spectrometer is

n λ = 2d sinθ cosη   (3)

I figured if anyone cared to rotate the grating, they’d see something that looked approximately like equation 3, didn’t think the trigonometric derivation was worth the time, and moved on.

Version 2. Rotated transmission grating ignoring out-of-plane behavior

I then looked at a grating that I rotated. Rather than scanning the diffracting pattern, moving away from θ = 0 showed that the diffraction pattern stretched. The steeper the rotation angle, the wider the diffraction angle. That seemed curious, and I tried to see if there was a simple explanation. I put my hand in front of my face with my fingers pointing up and my palm perpendicular to my line of sight. The fingers were analogous to the grooves of the grating and the plane of my palm served to show the plane of the grating. As I rotated my hand, I could see the fingers, projected onto the plane on which they were originally located, seemed to move closer together. In a flash, I saw:

dapparent = d cosθ   (4)

I did a quick experiment in the lab, and to a decent approximation, that looked good. So the second version was published saying

n λ = d cosθ sinβ   (5)

For small rotation angles, this worked well. I didn’t worry about large angles. The diffraction angle β was not measured from the grating normal – it was measured from where the normal is when θ = 0.

Version 3. Transmission grating with our signs straight

The professional instrument being developed by SpectroClick is the AAH-300. It uses a stack of diffraction gratings, and so rays that are diffracted by the first grating are rediffracted by the second grating. For that grating stack to be accurately calibrated, one must be able to handle rays that arrive at the grating at an off-axis angle. This is completely analogous to rotating the grating. The best calibration approach we have used to date was cited in a paper we published in 2016:

Scheeline, A., and Bui, T. A. (2016). “Stacked, Mutually-rotated Diffraction Gratings as Enablers of Portable Visible Spectrometry.” Appl. Spectrosc., 70(5), 766–777.

Therein, we cite an elegant approach to describing grating operation (primarily reflecting gratings) when they are illuminated at any off-axis angle:

Harvey, J., and Vernold, C. L. (1998). “Description of Diffraction Grating Behavior in Direction Cosine Space.” Appl. Opt., 37(34), 8158–8160.

In the Harvey and Vernold article, the authors state that behavior is non-linear for large diffraction angles. This led me to think about how to deal with transmission gratings. Along the way, Prof. Harvey was kind enough to send me some draft book chapters that expanded on the above cited article and explicitly dealt with transmission gratings. Suddenly, it became clear to me that “0°” was the normal to the grating on the side where the beam exits. That means that if the entering beam is normal to the grating plane, it is not at 0° inbound, it is at 180°! That means that when the grating is rotated, we have to choose whether we measure the angles α and β from the grating normal or from the original direction the beam was traveling. We can do either, because the light beam has no clue what reference axis we’re choosing. To keep from having to use subscripts, let’s continue to measure α and β from the grating normal, θ from the normal to the grating when that normal aligns with the incoming/outgoing light axis in zero order, and then define a diffraction angle γ (Greek gamma) which is the angle the diffracted ray takes vs. the entering ray. If θ=0, then γ = β while α = 0. Keeping the signs straight, as per equation 1,

n λ = d(sinα + sinβ)   (6)
= d(sin(180° – θ) + sinβ) Transmission grating with angles referenced to zero order

Figure 3. Transmission grating with grating rotated. θ + α = 180°. θ and γ are identified with orange lines, while β is shown with a violet line. α is identified with an arc from the grating normal to the incident ray.

“Where’s γ? Where’s cosθ?” I’m glad you asked – but we’re not there yet! We need to use some trigonometric identities to get there.

First, use the sine of a sum rule:

sin(a+b) = sin a cos b + cos a sin b   (7)
sin(ab) = sin a cos b – cos a sin b
sin(180° – θ) = sin 180° cosθ – cos180° sinθ = 0 cosθ – (-1) sinθ = sinθ   (8)

We simplify equation 6 to read

n λ = d(sinθ + sinβ)   (9)

Now comes The Trick! When we rotate the grating, γ no longer is the same as β. In fact,

β = γ + θ   (10)
n λ = d(sinθ + sin(γ + θ))   (11)

We use the sine sum equations again.

n λ = d(sinθ + sin γ cosθ + cosγ sinθ)   (12)
= d cosθ sinγ + d sinθ(1 + cosγ)

The first term on the right side of the second line in equation 12 has exactly the form of equation 5, the equation that appeared in the second version of the SpectroClick Kit manual. What about the second term? For small angles, cos(angle) ~ 1, so the term is ~2dsinθ. If θ is small, so is the second term, and at least for small values of γ, nearly independent of wavelength. Thus, to a close approximation, equation 5 is descriptive, but it’s not perfect. How big is the error? With the 500 line per mm grating in the SpectroClick Kit (d = (1/500) mm = 2 μm = 2000 nm), using the blue 460 nm wavelength of the bright blue spike, let’s tabulate how far off equation 5 is. For first order,

 θ (degrees) β from eq. 9 (degrees) γ from eq. 10 (degrees) β from eq. 5 (should equal γ) (degrees) Approximate/Exact γ 0 13.30 13.30 13.30 1.000 10 3.23 13.23 13.51 1.021 20 -6.43 13.57 14.17 1.044 30 -15.66 14.34 15.40 1.074 45 -28.50 16.50 18.98 1.150

If we are looking at the spectrum with a camera or by eye, γ is the most natural way to look at the information because we can see where γ=0 occurs (zero order). If we use eq. 5, it’s not exact but up to θ=45°, it’s accurate within 15%. How accurately can you measure an angle? Can you see an error of ½ degree? Probably not. Can you see an error of 2.5 degrees? Maybe. The trend that bigger θ gives a bigger diffraction angle is consistent throughout.

As I write this, I think about the video we posted concerning nonidealities of the SpectroClick Kit, SPECTROMETER NONIDEALITIES, Part 1, SPECTROMETER NONIDEALITIES, Part 2. We show equation 5 there. Now we all know that equation 5 is inexact. Should we revise the video? Are the calculations so much more complicated for the exact approach that an inexact but approximate relationship is better for beginning students than a more exact but complex approach? Are we perpetuating misconceptions if we leave things alone? These are interesting and important pedagogical issues.