From first principles
Derive a grating peak from equal phase steps
Take \(N\) equally spaced, equally illuminated grooves of pitch \(d\) under normal monochromatic illumination. Observe in the far field at angle \(\theta\) to the grating normal. Neighbouring positions produce a path difference \(d\sin\theta\). Ignoring the common single-groove envelope for the moment, each groove contributes an equal field with phase increment \(\delta\). Their sum is
The fields line up at \(\delta=2\pi m\), giving \(d\sin\theta=m\lambda\). The nearest zero requires an additional phase step of \(2\pi/N\). Convert that change to a small angle and compare with the angular separation of two neighbouring wavelengths at fixed order.
Equating the separations gives the ideal Rayleigh resolving power \(\lambda/\Delta\lambda=|m|N\) for nonzero order. It is the finite illuminated groove count that fixes the intrinsic width; optical aberrations, slit width and pixel sampling enter a measured line profile separately.
Derivation and applications
Convert an entrance-slit width into spectral broadening
An ideal grating can distinguish wavelengths separated by about \(\lambda/(mN)\) in order \(m\) with \(N\) illuminated grooves. A finite entrance slit adds another width because light from different points on the slit arrives at different incidence angles. Consider a slit of full width \(w\) in the focal plane of a collimator of focal length \(f_c\). Use small angular deviations around incidence \(\alpha\) and diffraction angle \(\beta\), both defined in the convention \(m\lambda=d(\sin\alpha+\sin\beta)\) for groove spacing \(d\). Differentiating at fixed wavelength gives
The angular interval incident on the grating is \(w/f_c\). A camera lens of focal length \(f_{\rm cam}\) converts the outgoing angular spread into a full image width \(W\) at its focal plane. Measure local displacements perpendicular to the central diffracted ray.
The second relation follows by varying wavelength at fixed incidence. Dividing the slit image width by this local dispersion gives the wavelength interval corresponding to the full geometric slit image.
The camera focal length cancels because it magnifies both the slit image and the spectrum equally. Actual recorded lines are convolutions of the projected slit, diffraction response and detector response. Their distinct width definitions must be retained when fitting line profiles.
Worked example
Identify the dominant width in a green spectrometer
Change the inputs and investigate this derivation.
For \(d=1.00\) µm, \(\alpha=0\), \(m=1\), \(f_c=100\) mm and \(w=50.0\) µm, the geometric width is 0.500 nm. At 500 nm, \(N=10{,}000\) illuminated grooves give a diffraction resolution scale of 0.0500 nm. The slit width corresponds to ten such intervals. Doubling the camera focal length would double the image width in pixels while leaving the geometric 0.500 nm wavelength interval unchanged.
Second application
Size a slit for an angled input
Change the inputs and investigate this derivation.
A separate instrument uses \(d=2.00\) µm, \(\alpha=60.0^\circ\), \(m=2\) and \(f_c=200\) mm. To obtain a full geometric spectral width of 0.100 nm, invert the result: \(w=m f_c\Delta\lambda/(d\cos\alpha)=40.0\) µm. At \(\lambda=600\) nm the grating equation gives \(\sin\beta=0.600-0.866=-0.266\), a physically accessible direction. This angle check matters when changing high orders or incidence settings.
Try it · Slit resolution
Vary the physical parameters in the derived relation. Use the units and assumptions in the readout to connect the curves to the two worked examples. A parameter study can test the forward prediction; the same relation can then be inverted to infer a parameter from a measurement.
OneSimulation laboratory
Find the dark fringes of a double slit
Start from this chapter. Treat the two slits as the two-element limit of an array. Check how changing wavelength moves its first minimum. The numerical model has two apertures throughout, so many-groove resolving power remains a separate prediction.
Compare recorded OneSimulation runs on this page. To test your own inputs, download the notebook and model files and run the model in an activated OneSimulation environment.
The numerical example drives two acoustic slits in phase. Sound pressure obeys the scalar Helmholtz equation, so the path-difference and aperture calculations transfer directly for the same \(d/\lambda\) and \(w/\lambda\). This model uses rigid acoustic walls and has no optical polarisation. Its receivers lie at a finite distance of 0.90 m. Two-slit pressure field and angular probes.
Run the notebook with its supplied ratios = [2, 3, 4] sweep, \(d=0.30\) m, \(w=0.050\) m and sound speed 343 m/s. Each frequency is a separate solve on the same mesh. Read the first minimum on the positive-angle side of the pressure-amplitude profile. Squaring the pressure magnitude gives a mean-square pressure pattern with the same minima. In a locally travelling plane wave, mean-square pressure divided by acoustic impedance gives the mean intensity.
- Baseline. At 3430 Hz, \(d=3\lambda\). Predict \(\arcsin(1/6)=9.59°\) and compare with the computed minimum.
- Lower the frequency. At \(d=2\lambda\), predict the first minimum at 14.48°. Check that the separation between the two dark fringes nearest the centre increases.
- Raise the frequency. At \(d=4\lambda\), expect 7.18°. Check all three first minima within 0.5° of the far-field estimate. Then compare the outer minima and report where the finite observation distance and the assumed uniform slit illumination begin to matter.
| Frequency and receiver radius | First dark angle (°) | Second dark angle (°) |
|---|---|---|
| 3430 Hz, 0.90 m | 9.75 | 30.50 |
| 2287 Hz, 0.90 m | 14.50 | 48.75 |
| 4573 Hz, 0.90 m | 7.25 | 22.50 |
| 2287 Hz, 0.75 m | 14.75 | 49.00 |

To test the far-field assumption independently of frequency, move the receiver arc inward from 0.90 to 0.75 m. Evaluate both the computed pressure and the Rayleigh reference on the new arc. The simple far-field angle depends only on wavelength and slit spacing, so any change in the sampled minimum tests the finite-distance approximation.
Download experiment files (ZIP) Extract the files together and opendouble_slit_diffraction.ipynb in a local OneSimulation environment.
Try it · Finite slits at the measured receiver radius
The reference uses the same 0.30 m slit spacing, 0.050 m slit widths and 0.90 m receiver radius as the OneSimulation model. Change separation/wavelength from 3 to 2 or 4, then move the receiver to 0.75 m. This is the notebook’s finite-radius, two-dimensional Rayleigh integral with uniform aperture velocity, compared with its Fraunhofer limit. The full guide-and-screen solve additionally resolves the nonuniform slit velocity, so its sampled minima can differ slightly.
Open the corresponding OneSimulation notebook, code and output
Problem sheet 4 · Infer slit spacing from a sampled angular minimum
Interference across equally spaced openings
Illuminate \(N\) identical narrow slits separated by distance \(d\) with normally incident monochromatic light. In the far field every slit produces the same single-slit envelope. At observation angle \(\theta\) adjacent contributions differ in optical path by \(d\sin\theta\), so their phases differ by \(\phi=2\pi d\sin\theta/\lambda\). The array field equals the single-slit field multiplied by a sum of \(N\) unit phasors. Taking its geometric sum and squared magnitude gives the array intensity factor
At \(\phi=2\pi m\) the expression has a removable limit \(N^2\). Those directions satisfy the grating equation \(d\sin\theta_m=m\lambda\). Each peak collects contributions from all illuminated slits in phase. Some orders can nevertheless be faint or missing if the single-slit envelope is small or zero there. Transmission efficiency into a selected order thus depends on the groove or opening profile in addition to the grating period.
Dispersion and finite width
At fixed order different wavelengths peak at different angles. Differentiate the grating equation to obtain
A large angular dispersion aids spatial separation at the detector. To assess resolution, also compute the width of each peak. The adjacent zeros of the numerator lie one phase increment \(2\pi/N\) either side of the maximum. Converting the increment back to angle gives a one-sided width \(\lambda/(Nd\cos\theta_m)\).
Choose the conventional criterion that one wavelength's peak falls on the neighbour's first zero. Equate the angular separation due to \(\Delta\lambda\) to this one-sided width and obtain \(\lambda/\Delta\lambda=|m|N\). Broad illumination of a grating therefore improves the ideal resolving power even with unchanged dispersion. The derivation assumes uniform coherent illumination, collimation, adequate detector sampling, and an entrance slit narrow enough to preserve this diffraction-limited width.
A small spectrometer
A 600-lines/mm grating has \(d=1.667\) μm. A collimated 10.0 mm beam illuminates 6000 lines. At \(\lambda=600\) nm first order occurs at \(\arcsin(0.360)=21.1^\circ\). The ideal smallest separation is
The angular dispersion is \(6.43\times10^{-4}\) rad/nm. A camera of focal length 200 mm centred on that order maps a 0.100 nm change to about \(12.9\) μm near its axis. Detector pixels that are large compared with this separation reduce the measurable resolution.
At that same angle, 300 nm light in second order has the same value of \(m\lambda\). Increasing the beam width narrows both peaks without separating their centres. An order-selecting filter can restrict the allowed band before measurement. A second grating or prism dispersing perpendicular to the first can instead separate overlapping orders into different traces. This illustrates why calibration with only one visible line cannot certify the identity of every line in a wide-band spectrum.
Test the finite-array argument with the two-slit acoustic field. For two equally excited slits the array factor has its second positive-angle zero at \(d\sin\theta=3\lambda/2\). With \(d/\lambda=3\), predict \(30.0^\circ\) and compare with the sampled \(30.50^\circ\) at receiver radius 0.90 m. At \(d/\lambda=2\) predict \(48.59^\circ\). Compare the measured angle at both receiver radii to see how the finite observation distance affects the far-field limit.
Map overlapping orders in a high-order spectrometer
Using high diffraction order increases the ideal resolving power for a fixed number of illuminated grooves. It also reduces how much spectrum belongs unambiguously to a single order. Consider a reflection grating in a geometry where incidence and diffraction are on the same side of the normal in the usual grating-angle convention. The path difference between neighbouring grooves is \(d(\sin\alpha+\sin\beta)\), so peaks obey \(m\lambda=d(\sin\alpha+\sin\beta)\). In a Littrow setting the selected diffracted beam retraces the incident direction and \(\alpha=\beta=\theta\).
At fixed angle two wavelengths overlap exactly if \(m\lambda_m=(m+1)\lambda_{m+1}\). Solving for their separation gives \(\lambda_m-\lambda_{m+1}=\lambda_m/(m+1)\), approximately \(\lambda_m/m\) at high order. This is the scale of a free spectral range in wavelength. Combined with resolving power \(mN\) for \(N\) uniformly illuminated grooves, the number of independently resolved spectral elements per order is approximately \(N\). Higher order makes each element narrower while proportionately reducing the unambiguous range at a fixed spatial coordinate.
Real echelle gratings use inclined groove facets to redirect much of the reflected power into the chosen high orders. The groove spacing sets peak positions and order overlap; the groove profile sets an efficiency envelope. A second dispersive element ordinarily separates the superposed orders along another detector coordinate. Its angular dispersion can be lower than the primary grating's because it only needs to separate different orders, not resolve the closest spectral lines within one.
Design the spectral window at one detector position
Take groove spacing \(d=31.6\) μm, order \(m=100\) and central wavelength 550 nm. The Littrow relation requires \(\sin\theta=m\lambda/(2d)=55.0/63.2=0.870\), hence \(\theta=60.5^\circ\). Illuminating 1000 grooves gives ideal wavelength resolution \(550/(100\times1000)=0.00550\) nm. The wavelength in order 101 landing at the same position is
Thus the separation between these coincident-order wavelengths is 5.45 nm, about 990 resolution intervals.
A narrow-band filter passing 548 to 552 nm would reject that particular neighbouring order at the central position while retaining many resolvable lines near 550 nm. An instrument meant to record hundreds of nanometres at once needs cross-dispersion or several separate exposures. As incidence approaches grazing, simple angular-dispersion estimates can become very large, but finite beam footprint, usable groove count, diffraction efficiency and detector size limit the physical gain. Accounting for order separation, illuminated footprint and sampling is necessary before describing two nearby spectral features as resolvable in the laboratory.
A rough detector-format estimate follows directly from this example. If each independent spectral resolution interval requires at least two samples, one full free spectral range near the chosen order needs about two thousand useful pixels along the high-dispersion direction. That count ignores additional margins, optical distortion and the need to sample the entrance-slit profile adequately. The perpendicular axis must also have room for the traces of neighbouring orders and for a background estimate between them. Resolution, spectral coverage and detector format therefore impose independent constraints on what a single exposure can realistically measure.
Separate groove count from grating period
Keep the grating period and incident wavelength fixed. Adding \(N\) equal amplitudes as a geometric series gives a central peak whose first zeros occur at phase mismatch \(\pm 1/N\) in turns. Each plotted peak is normalised to its own height.

Try it · Grating
Change the inputs and compare the recalculated curves with the preceding derivation and baseline figure. The axes give the units; the numerical readout states the model assumptions and any limiting cases. Reset the inputs to return to the reference setting.
Read values from the plot
| Phase mismatch per groove (turns) | 6 illuminated grooves | 12 illuminated grooves | 24 illuminated grooves |
|---|---|---|---|
| −0.22 | 0.048737 | 0.013993 | 0.0025368 |
| −0.11 | 0.1859 | 0.043145 | 0.012387 |
| 0 | 1 | 1 | 1 |
| 0.11 | 0.1859 | 0.043145 | 0.012387 |
| 0.22 | 0.048737 | 0.013993 | 0.0025368 |