BookNotesSlidesP-sets Syllabusdraft · v0.2.49.1
💬Comments welcome. To leave a note, select any text and click the note / highlight button that pops up — or open the panel with the tab at the top-right (‹). Notes are visible only inside our private review group.
Computational Photography, an AI-powered Slopendium — 22 Compound lenses, and aberration correction
expand to📖 Full book outline1 parts · 12 chapters · 57 sections · 54 figures embedded · 7 placeholders · double-click a figure to enlarge
▸Part 22 COMPOUND LENSES, AND ABERRATION CORRECTION⧉
<!--uid: compound-lenses-and-aberration-correction-->
▸22.1 Aberrations and optical challenges⧉
⬜ figure not yet created
`fig-single-element-limit` (one element: spherical aberration + color blur, rays missing the point) fig-single-element-limit
fig-doublet-triplet-gauss
fig-doublet-triplet-gauss · cross-sections of three classic designs as stacked glass elements — achromatic doublet (2), Cooke triplet (3, + − +), double-Gauss (6, ≈symmetric about the stop); each labels element count and the aperture stop ✅
fig-double-gauss
fig-double-gauss · a labeled double-Gauss cross-section: 6 elements ≈symmetric about the central aperture stop, parallel ray bundle traced to the focal plane; notes near-mirror symmetry cancels odd aberrations (coma, distortion, lateral color) ✅
fig-telephoto-vs-retrofocus
fig-telephoto-vs-retrofocus · two two-group schematics — telephoto (+ then −, principal plane H′ pushed in front → physical length < f) vs retrofocus/inverted-telephoto (− then +, long back-focal distance to clear the SLR mirror); marks f vs physical length, H′, F′ ✅
fig-zoom-mechanism
fig-zoom-mechanism · a zoom at two focal lengths (short-f/wide vs long-f/tele): moving variator + compensator groups slide along the axis to change f while the focal plane (sensor) stays fixed; motion arrows between states ✅
fig-principal-planes-pupils
fig-principal-planes-pupils · a thick-lens cardinal-points diagram: principal planes H, H′, nodal points N, N′, entrance & exit pupils (the stop imaged by front/rear groups), focal points F, F′; f measured from H′ via the H→H′ equivalent-thin-lens construction ✅
equations
thick-lens / system focal length via the two principal planes (FUNDAMENTALS' $1/f=1/u+1/v$ holds when $u,v$ are measured from $H, H'$)
f-number from the **entrance-pupil** diameter $N = f/D_{\text{EP}}$ (not the front element)
T-stop $T = N/\sqrt{\tau}$ (transmittance $\tau<1$)
effective vs back focal length.
▸22.2 Aberrations correction⧉
fig-achromat-doublet
fig-achromat-doublet · an achromatic doublet: positive crown cemented to negative flint; singlet panel (red & blue split = chromatic aberration) vs doublet panel (red = blue at a common focus); labels crown/flint, low/high dispersion ✅
⬜ figure not yet created
the dispersion cancels)
fig-lens-profile-correction
fig-lens-profile-correction · computational lens correction: a real window-grid facade degraded (barrel + vignette + lateral CA) → a measured profile's three radial maps (warp / gain / per-channel rescale) → corrected; note: geometric defects only, not blur (Aberrations correction) ✅
fig-psf-deconvolution
fig-psf-deconvolution · non-blind deconvolution by the measured PSF: a real crop convolved with a comatic PSF (inset) + noise → Wiener deconvolution (sharper) → under-regularized (noise amplified); image = scene ∗ PSF (Aberrations correction) ✅
fig-radial-distortion-correction
fig-radial-distortion-correction ·
equations
**achromat condition** $\phi_1/V_1 + \phi_2/V_2 = 0$ (powers weighted by dispersion cancel the chromatic term — Abbe number $V_d=(n_d-1)/(n_F-n_C)$ from the challenges chapter)
image = scene $*$ **PSF** $\to$ correction = **deconvolution** by the *measured, spatially-varying* PSF (cross-ref Wiener $\hat X = \overline K Y/(|K|^2+\mathrm{SNR}^{-1})$).
22.2.5 Aberration data in the DNG, and the limits of per-copy correction⧉
▸22.3 Measuring lens quality⧉
fig-mtf-curves
fig-mtf-curves ·
fig-slanted-edge-sfr
fig-slanted-edge-sfr ·
fig-mtf-through-focus
fig-mtf-through-focus ·
fig-mtf-field
fig-mtf-field ·
fig-spot-diagram
fig-spot-diagram · spot diagram = the lens's PSF sampled by rays: 3 field positions (on-axis tight → corner comatic smear), RMS spot µm under each, dashed Airy (diffraction) circle (Lens optimization) ✅
• the bridge from the previous chapter: *Aberrations and optical challenges* told you **what** can go wrong; this chapter tells you **how well** a given lens actually does, in numbers — the scorecard that *Lens optimization* minimizes and *Aberrations correction* inverts. You cannot optimize, target a spec, or computationally correct what you have not measured.
equations
$\text{MTF}(\nu) = |\text{OTF}(\nu)|$, $\text{OTF}=\mathcal F\{\text{PSF}\}$
**MTF50** (frequency where contrast = 0.5) and **limiting resolution** (MTF → a low cutoff, in **lp/mm**)
diffraction-limited cutoff $\nu_c = 1/(\lambda N)$
SFR chain $\text{edge}\to\text{ESF}\to\text{LSF}=\mathrm d(\text{ESF})/\mathrm dx \to \text{MTF}=|\mathcal F\{\text{LSF}\}|$
relative illumination / vignetting falloff
distortion % vs field.
▸22.4 Lens optimization⧉
fig-spot-diagram
fig-spot-diagram · spot diagram = the lens's PSF sampled by rays: 3 field positions (on-axis tight → corner comatic smear), RMS spot µm under each, dashed Airy (diffraction) circle (Lens optimization) ✅
⬜ figure not yet created
before/after optimization) fig-wb-before-after
fig-merit-function-loop
fig-merit-function-loop · lens design as optimization, a closed loop: parameters → ray-trace (fields × wavelengths × pupil zones) → merit function Φ (weighted spot/wavefront + constraints) → damped-least-squares step → repeat; the book's forward-model+loss+optimizer pattern (Lens optimization) ✅
fig-lens-design-tradeoff
fig-lens-design-tradeoff · lens-design Pareto cartoon as a 6-axis radar (sharpness, speed, size, weight, cost, distortion): fast pro prime vs compact phone lens overlaid, plus a dashed polygon showing where software correction shifts the phone lens (Lens optimization) ✅
fig-rms-spot-vs-field
fig-rms-spot-vs-field · RMS spot radius (µm) vs field (center→corner) for 3 wavelengths, rising toward the edge, with the Airy diffraction limit as a shaded dashed floor (Lens optimization) ✅
• the move: add elements → add **surfaces, glasses, and air gaps** → add free parameters to *trade off* aberrations against each other. The art is doing it with as few elements as the quality target allows (cost, weight, flare).
equations
ray-trace forward model — apply Snell's law $n_1\sin\theta_1=n_2\sin\theta_2$ surface-by-surface (no paraxial approximation)
merit function $\Phi = \sum_{\text{fields}}\sum_{\lambda}\sum_{\text{pupil rays}} w_i\,\lVert (x_i,y_i) - (\bar x,\bar y)\rVert^2 \
+\
(\text{constraints on } f, \text{length, edge thickness}\dots)$ — a weighted sum of squared transverse ray errors plus penalties
damped-least-squares (Levenberg–Marquardt-style) update on the parameter vector.
▸22.5 A short bestiary of classic designs⧉
• **achromatic doublet**: a positive crown + negative flint, usually cemented; the *minimum* system that corrects color (two wavelengths) and is also used to tame spherical aberration. (Full treatment in *Aberrations correction*.) [`fig-doublet-triplet-gauss`]
• **Cooke triplet**: three elements (+ − +) — the smallest design with enough freedom to correct **all** the primary (Seidel) aberrations *and* color; the ancestor of most simple lenses. [`fig-doublet-triplet-gauss`]
• **double-Gauss (Planar)**: roughly **symmetric about the aperture stop**, 6–7 elements; symmetry automatically cancels the *odd* aberrations (coma, distortion, lateral color), which is why it dominates fast normal lenses ($f$/2 and faster). [`fig-double-gauss`]
• **telephoto vs. retrofocus** — two ways to decouple physical length from focal length: [`fig-telephoto-vs-retrofocus`]
• **telephoto** (positive group then negative): the rear negative group pushes the rear principal plane *forward*, so a long-focal-length lens is **physically shorter** than its $f$.
• **retrofocus / inverted telephoto** (negative then positive): pushes the rear principal plane *back*, giving a long **back-focal distance** — needed so a wide-angle lens clears the SLR mirror box (and historically why mirrorless can go wider/smaller).
• **zoom**: a variable-focal-length system — groups slide so $f$ changes (the *variator*) while a *compensator* group keeps the image plane fixed; many elements, many compromises, the hardest thing to optimize. [`fig-zoom-mechanism`]
▸22.6 Scaling laws in optics⧉
fig-optics-scaling-law
fig-optics-scaling-law ·
fig-monocentric-multiscale
fig-monocentric-multiscale ·
fig-gigapixel-mosaic
fig-gigapixel-mosaic ·
---
22.6.1 Lohmann's scaling laws: why a good lens is heavy⧉
22.6.2 The gigapixel barrier for a single lens⧉
22.6.3 The escape: monocentric multiscale optics⧉
22.6.4 Capture everything, crop later: the spatial cousin of the light field⧉
▸22.7 Special optics⧉
fig-scheimpflug-tilt
fig-scheimpflug-tilt · the Scheimpflug principle: tilting the lens makes the lens plane, image plane & plane of focus meet in a common line → the focus plane tilts into a wedge of sharpness; contrasted with the parallel (untilted) case ✅
fig-fisheye-projection
fig-fisheye-projection · projection mappings — image radius r vs incidence angle θ for rectilinear (r=f·tanθ, blows up near 90°), equidistant (r=f·θ) and equisolid (r=2f·sin(θ/2)); why fisheye reaches ~180° where rectilinear can't ✅
fig-seidel-aberrations
fig-seidel-aberrations · the five monochromatic (Seidel) aberrations at a glance — spherical, coma, astigmatism, field curvature, distortion — each a tiny ray/spot icon + a one-line "what it looks like" note ✅
fig-catadioptric-mirror-lens
fig-catadioptric-mirror-lens · a mirror (catadioptric) lens: light folds via primary + secondary mirror (Cassegrain); central obstruction → ring-shaped (doughnut) bokeh — folded path + doughnut-highlight inset ✅
fig-anamorphic-squeeze
fig-anamorphic-squeeze · anamorphic optics: 2× horizontal squeeze at capture → de-squeeze in post; a circle → vertical oval on sensor → restored; oval bokeh + horizontal flares noted ✅
fig-fresnel-zones
fig-fresnel-zones · a Fresnel lens: collapse a thick convex lens into concentric ring "zones" that keep the local surface slope but drop the bulk; cross-section of a normal lens vs its Fresnel equivalent ✅
fig-grin-vs-metalens
fig-grin-vs-metalens · three ways to bend light: shaped bulk lens (refraction), a GRIN rod (curved ray through a varying-index medium, flat faces), and a metalens (flat surface, sub-wavelength nanostructures setting a phase profile); "keep the phase, drop the thickness" ✅
fig-tilt-shift-perspective
fig-tilt-shift-perspective · the *shift* movement (not tilt): tilting the camera up keystones a building (converging verticals) vs. keeping the sensor vertical/parallel and raising the lens within a large image circle, so verticals stay parallel — architectural perspective control ✅
fig-telescope-types
fig-telescope-types · refractor (doublet objective → focus) vs. reflectors — Newtonian (concave primary + flat 45° secondary → side focus) and Cassegrain (primary + convex secondary → focus through a hole behind the primary); glass vs. mirrors to a focus ✅
fig-microscope-objective
fig-microscope-objective · high-NA objective at a short working distance: finite (fixed tube length, objective forms the image directly) vs. infinity-corrected (subject at front focus → parallel "infinity space" → separate tube lens forms the image) ✅
fig-soft-focus
fig-soft-focus · a soft-focus portrait lens: under-corrected spherical aberration (marginal rays cross nearer than paraxial → halo at the paraxial plane) and the resulting PSF — a sharp core inside a broad glow vs. a well-corrected lens; a *wanted* aberration ✅
fig-apodization-pupil
fig-apodization-pupil · an apodizing filter: pupil transmission profile (hard-edged plain aperture vs. radially graded) → the defocus disk each makes (flat disk with a hard ring vs. a smoothly fading disk, no ring) — shaping the bokeh PSF in hardware ✅
equations
**Scheimpflug condition** (lens plane, image plane, focus plane meet in one line) + the **Hinge rule** for where the focal wedge pivots
fisheye projection laws $r = f\theta$ (equidistant), $r = 2f\sin(\theta/2)$ (equisolid-angle) vs. rectilinear $r = f\tan\theta$
anamorphic squeeze factor (typ. 2×)
Fresnel = local surface slope preserved, bulk removed.
22.7.8 Teleconverters⧉
▸22.8 Focus⧉
fig-focus-conjugate-move
fig-focus-conjugate-move · focusing geometry: as subject distance u changes the image distance v must change (1/f=1/u+1/v); the lens slides to keep the image plane on the fixed sensor — near vs far focus (lens extends vs retracts) ✅
fig-compound-focusing
fig-compound-focusing · **interactive** (10.8 Focus): 2-D ray trace of a two-group lens on a fixed sensor; mode selector unit / front-cell / internal focusing + a focus-distance slider (∞→0.25 m); highlights which group moves, its travel, and the focus-breathing tradeoff ✅
fig-xkcd-1855
fig-xkcd-1855 ·
equations
focus error → sensor shift via $1/f=1/u+1/v$ (differentiate to get sensor move per diopter — of order $f^2$)
focus breathing = effective $f$ drift with the focusing group's motion.
▸22.9 Autofocus⧉
fig-contrast-af-curve
fig-contrast-af-curve · contrast-detect AF: high-frequency contrast (sharpness) vs focus position, peaked at best focus; hill-climb arrows that must overshoot past the peak then step back (no direction cue) ✅
⬜ figure not yet created
hunting to find it)
fig-pdaf-principle
fig-pdaf-principle · phase-detect AF: a separator splits the beam to two line sensors; the signed phase (separation) of the two profiles gives direction + amount of defocus ("stereo in the lens"); in-focus vs front/back-focus ✅
fig-autofocus-demo
fig-autofocus-demo · **interactive** autofocus (9.6 Focus, autofocus): CDAF tab — sharpness ∑‖∇I‖² vs focus, hill-climb with hunting + low-light failure; PDAF tab — two half-pupil line signals, signed disparity → one-shot focus ✅
fig-dual-pixel-af
fig-dual-pixel-af · on-sensor / dual-pixel AF: a photodiode split into L/R halves under one microlens; the L vs R images give per-pixel disparity → defocus; split-pixel cross-section + the two readout images ✅
fig-depth-from-defocus
fig-depth-from-defocus · depth from defocus: the blur-disk diameter grows with distance from the focus plane; two shots at different focus/aperture → estimate depth from the relative blur ✅
equations
contrast metric (sum of squared gradients / high-pass energy) maximized
phase-detect: **disparity between the two pupil half-images is proportional to defocus** (it is stereo with a baseline = the pupil split — ties to FUNDAMENTALS $Z=fB/d$)
defocus blur radius $\propto$ distance from focus and aperture (from *Depth of field*).
22.9.5 Where to focus: saliency, faces, and eyes⧉
▸22.10 Glare suppression⧉
fig-lens-flare-ghosting
fig-lens-flare-ghosting · stray light: a bright source, a ray reflecting off two internal lens surfaces → a "ghost" landing displaced on the sensor, plus a veiling-glare wash; ghost vs flare labeled ✅
fig-dr-clip-vs-noise
fig-dr-clip-vs-noise · one exposure's two walls — clipping at full-well above, the noise floor below — shading the narrow band of scene contrast that fits between them 🟨
fig-ar-coating-interference
fig-ar-coating-interference · anti-reflection coating: a quarter-wave film cancels the front-surface reflection by destructive interference (top-surface reflection vs film–glass reflection, extra path λ/2 → out of phase); two emergent wavelets summing to ~0 + design rules $n_c=\sqrt{n_1 n_2}$, $d=\lambda/4n_c$ ✅
fig-lens-hood-baffles
fig-lens-hood-baffles · lens hood + internal blackened baffles: an off-axis source (sun outside the frame) is blocked by the hood; stray light that sneaks in is trapped/absorbed by baffles; wanted image-forming rays (within the angle of view) pass through to the sensor ✅
fig-veiling-glare-psf
fig-veiling-glare-psf · a PSF with a bright core + a broad low-level skirt (veiling glare) on a log-radial profile; second panel shows the integrated veil lifting blacks / reducing contrast ✅
equations
Fresnel reflectance at an interface $R=\left(\frac{n_1-n_2}{n_1+n_2}\right)^2$ (~4%/surface for air–glass → why an uncoated multi-element lens loses huge contrast)
**quarter-wave AR condition** — coating index $n_c=\sqrt{n_1 n_2}$ and thickness $\lambda/4$ for destructive interference
veiling glare modeled as the image $*$ a **broad glare PSF** → deconvolution.
▸22.11 Optical stabilization⧉
fig-handshake-motion-blur
fig-handshake-motion-blur · hand-shake motion blur: a small angular shake $\Delta\theta$ over the exposure smears a point into a streak of length $\approx f\,\Delta\theta$ on the sensor (lens as pivot, focal length $f$); the $t<1/f$ shutter rule of thumb ✅
fig-ois-vs-ibis
fig-ois-vs-ibis · two stabilization strategies side-by-side: lens-shift OIS (floating lens group moves) vs sensor-shift IBIS (sensor moves on a magnetic stage), moving element highlighted, same gyro/IMU input ✅
fig-gyro-feedback-loop
fig-gyro-feedback-loop · the stabilization control loop as a block diagram: gyro/IMU senses angular rate → controller → actuator moves the lens group/sensor → position sensor feeds residual error back (sense→control→actuate→measure, ~kHz) ✅
fig-digital-vs-optical-stab
fig-digital-vs-optical-stab · optical (in lens/sensor, before capture, full resolution & FOV) vs digital/electronic IS (crop-and-warp in software after capture): the EIS safety-margin crop + warp costing resolution/field of view vs the optical in-lens/sensor correction ✅
equations
image-plane shift for a camera rotation $\Delta\theta$ is $\approx f\,\Delta\theta$ (so **longer $f$ ⇒ more blur ⇒ more correction needed**)
stabilization benefit quoted in **stops** = $\log_2$ of the shutter-time ratio it allows
the actuator must move the element/sensor to make the **net image displacement ≈ 0** over the exposure.
▸22.12 The eye as an optical instrument: vision and its correction⧉
fig-eye-as-camera
fig-eye-as-camera · the eye as a camera: cornea + crystalline lens = objective, iris/pupil = aperture, retina = sensor (fovea), accommodation = autofocus — labeled cross-section ✅
fig-refractive-errors
fig-refractive-errors · the four refractive errors — myopia / hyperopia / astigmatism / presbyopia — where the image focuses vs the retina and the correcting (negative / positive / cylindrical / add) lens ✅
⬜ figure not yet created
bifocal vs progressive vs AF-glasses focal zones [schem] fig-bifocal-progressive-af
22.12.3 Measuring the eye's optics⧉