Fermat Principle and the Eikonal Equation

Here is where geometrical optics stops being a convenient fiction and earns a derivation. Rays, wavefronts, Fermat's principle — the whole apparatus of lenses and mirrors — are not fundamental; they are what Maxwell's electromagnetic waves look like when the wavelength is far smaller than anything the light passes through. This chapter takes the debt geometry owes to wave physics and pays it, by extracting the ray from the wave in a single controlled limit. The tool is an old one, borrowed from mechanics. Write a monochromatic field as a slowly varying amplitude riding on a rapidly spinning phase, U=A eik0SU=A\,\mathrm{e}^{ik_0 S}, and feed it to the wave equation. Sort the result by powers of the vacuum wavenumber k0=2π/λ0k_0=2\pi/\lambda_0. As k0→∞k_0\to\infty — the short-wavelength limit — the leading term is a clean statement about the phase alone, ∣∇S∣2=n2|\nabla S|^2=n^2: the eikonal equation. Its level surfaces S=constS=\text{const} are the wavefronts; their perpendiculars are the rays. Everything geometrical follows. This is the exact optical twin of a move made in classical mechanics, where the short-wavelength limit of the Schrödinger equation is the Hamilton–Jacobi equation and the "rays" are particle trajectories. We take that correspondence by name from mechanics rather than re-deriving it, and use it as a compass: the eikonal SS is the optical action, the index nn is the optical momentum, and λ0→0\lambda_0\to0 is the optical ℏ→0\hbar\to0. From the eikonal equation we recover the ray equation, Snell's law, the law of reflection, and Fermat's stationary optical path — three faces of one limit. We also learn exactly where the ray picture must fail: at foci, edges, and caustics, where the amplitude varies on the scale of a wavelength and the neglected diffraction term roars back.

Key takeaways
  • Geometrical optics is the short-wavelength limit of wave optics. Insert U=A eik0SU=A\,\mathrm{e}^{ik_0S} into the Helmholtz equation and keep the leading power of k0k_0: the phase obeys the eikonal equation ∣∇S∣2=n2|\nabla S|^2=n^2.
  • The eikonal S(r)S(\mathbf r) is the optical path length; surfaces S=constS=\text{const} are wavefronts and their normals s^=∇S/n\hat{\mathbf s}=\nabla S/n are the rays.
  • Differentiating along a ray turns the eikonal equation into the ray equation dds ⁣(ndrds)=∇n\frac{\mathrm d}{\mathrm ds}\!\left(n\frac{\mathrm d\mathbf r}{\mathrm ds}\right)=\nabla n — a Newton-like law with ∇n\nabla n as the force, so rays bend toward higher index.
  • Matching the tangential part of ∇S\nabla S across an interface gives Snell's law and the law of reflection; the variational form of the same limit is Fermat's principle δ ⁣∫n ds=0\delta\!\int n\,\mathrm ds=0.
  • The equation is formally the Hamilton–Jacobi equation of mechanics under the optical–mechanical analogy, so λ0→0\lambda_0\to0 mirrors the classical ℏ→0\hbar\to0 limit — recalled by name from mechanics, not re-derived.
  • The neglected term scales as (λ/L)2(\lambda/L)^2; geometrical optics fails near foci, caustics, and edges, where a predicted infinite intensity signals the breakdown.
  • Key idea: write the field as A eik0SA\,\mathrm e^{ik_0S} and send λ0→0\lambda_0\to0; the wave equation collapses to ∣∇S∣2=n2|\nabla S|^2=n^2, whose constant-phase surfaces are wavefronts and whose normals are rays — geometrical optics is wave optics with the wavelength sent to zero.
The core insight

Write a monochromatic field as U=A(r) eik0S(r)U=A(\mathbf r)\,\mathrm e^{ik_0 S(\mathbf r)} and take the short-wavelength limit k0→∞k_0\to\infty. The wave equation collapses to the eikonal equation ∣∇S∣2=n2|\nabla S|^2=n^2: the eikonal SS is the optical path length, its level surfaces S=constS=\text{const} are the wavefronts, and their orthogonal trajectories s^=∇S/n\hat{\mathbf s}=\nabla S/n are the rays. All of geometrical optics — the ray equation, Snell's law, Fermat's principle — is the leading term of this one limit.

Where this lives today

The eikonal equation is the quiet engine behind any computation that turns waves into rays. Every optical-design program traces rays by integrating the ray equation surface to surface, and the same equation — now with n(r)=c/v(r)n(\mathbf r)=c/v(\mathbf r) — is the basis of seismic travel-time tomography, imaging the Earth's interior from the least-time paths of earthquake waves, and of the fast-marching and level-set solvers that compute first-arrival times in ultrasound, sonar, and radar. In photonics the parabolic-profile result designs GRIN lenses, fibre collimators, and endoscope relays, while the mirage, the flattened setting Sun, and the day-lengthening horizon refraction are the atmosphere solving the same equation for free. Its deepest modern echo is conceptual: because the eikonal equation is the Hamilton–Jacobi equation in disguise, the WKB approximation of quantum mechanics — semiclassical quantization, tunnelling exponents, the classical limit itself — is the eikonal method wearing an ℏ\hbar instead of a λ\lambda, exactly the correspondence Hamilton foresaw and Schrödinger exploited.

The physical picture

Picture a wavefront as a rank of marchers, all abreast, and the eikonal SS as the distance each has marched measured in optical path. Where the index is larger the local phase speed c/nc/n is smaller, so that stretch of the rank lags and the front tilts. The marching direction — perpendicular to the front — is the ray, and it swings toward the slow, high-index side. That single sentence is the ray equation before any calculus.

Figure
Wavefronts S = const (blue) and their perpendicular rays (red): the ray direction is ŝ = ∇S ⁄ n, and where n rises the wavefronts crowd together and the rays bend toward the high-index side
n₁ = 1.0 (fast) n₂ = 1.5 (slow — fronts crowd) ray ŝ = ∇S ⁄ n ⟂ wavefront S = const surfaces (wavefronts) · optical path S counts wavelengths, |∇S| = n

The parameter that decides whether this cartoon is exact is the ratio of the wavelength λ\lambda to the scale LL over which the index or the amplitude changes. When λ≪L\lambda\ll L, a single wavelength barely notices the variation: the wave marches locally like a plane wave with a well-defined direction, and geometry is exact. Diffraction is the leading correction, of relative size (λ/L)2(\lambda/L)^2. Now the punchline — what the ray equation does when the index varies smoothly.

Figure
Punchline — a ray in a graded-index fibre n(r) = n₀(1 − ½α²r²) oscillates sinusoidally with pitch Λ = 2π ⁄ α; for n₀ = 1.5, α = 0.5 mm⁻¹ the full period is Λ ≈ 12.57 mm and a collimated ray focuses at the quarter-pitch Λ⁄4 ≈ 3.14 mm
z index high on axis, falling with r — rays are trapped Λ⁄4 ≈ 3.14 mm (focus) Λ⁄2 ≈ 6.28 mm full pitch Λ = 2π ⁄ α ≈ 12.57 mm (α = 0.5 mm⁻¹) r″ = −α² r ⟹ sinusoid on-axis launch

The graded core does with a smooth index what a lens does with curved glass: a ray launched off-axis is pulled back, overshoots, and oscillates, its path a sinusoid of pitch Λ=2π/α\Lambda=2\pi/\alpha set entirely by the index profile. A collimated ray reaches the axis after a quarter pitch — the graded rod is a lens with flat faces. Mirages, the flattened setting Sun, and self-focusing fibres are all this one figure with a different gradient.

The core equations

The starting point is the wave equation for a single frequency. For a monochromatic field U(r) e−iωtU(\mathbf r)\,\mathrm e^{-i\omega t} in a medium of slowly varying index n(r)n(\mathbf r), the vector wave equation reduces (component by component, when nn varies little over a wavelength) to the scalar Helmholtz equation:

∇2U+k02 n2(r) U=0(1)\nabla^2 U + k_0^2\,n^2(\mathbf r)\,U = 0 \qquad (1)

where: UU — one Cartesian component of the complex field amplitude; k0=ω/c=2π/λ0k_0=\omega/c=2\pi/\lambda_0 — the vacuum wavenumber; n(r)n(\mathbf r) — local refractive index. The whole content of monochromatic wave optics sits in (1)(1); geometrical optics is one limit of it. The controlled step is to separate the fast phase from the slow amplitude. Because the phase advances by 2π2\pi every wavelength while the amplitude drifts on the scale L≫λL\gg\lambda, we posit the eikonal ansatz with AA and SS both real:

U(r)=A(r) e ik0S(r)(2)U(\mathbf r) = A(\mathbf r)\,\mathrm e^{\,i k_0 S(\mathbf r)} \qquad (2)

where: A(r)A(\mathbf r) — real, slowly varying amplitude; S(r)S(\mathbf r) — the real eikonal, an optical path length (units of metres). This is the optical version of the WKB ansatz of mechanics; the large parameter that will order the expansion is k0k_0. Substituting (2)(2) into (1)(1) and demanding that the leading power of k0k_0 vanish gives the eikonal equation (Derivation 1):

∣∇S∣2=n2(3)|\nabla S|^2 = n^2 \qquad (3)

where: ∇S\nabla S — gradient of the eikonal, whose magnitude equals the local index. This first-order nonlinear equation for SS alone is geometrical optics: it contains no wavelength, which is exactly why the ray picture is scale-invariant and blind to diffraction. Its geometric content is read off directly. The ray direction is the unit normal to the wavefronts:

s^=∇Sn,s^⋅s^=1(4)\hat{\mathbf s}=\frac{\nabla S}{n},\qquad \hat{\mathbf s}\cdot\hat{\mathbf s}=1 \qquad (4)

where: s^\hat{\mathbf s} — unit tangent to the ray, perpendicular to the surfaces S=constS=\text{const}; the normalization is just the eikonal equation (3)(3) divided by n2n^2. Rays are the orthogonal trajectories of the wavefronts. Differentiating (4)(4) along the ray converts the algebra of (3)(3) into the ray equation (Derivation 2), a second-order law of motion for the ray path r(s)\mathbf r(s):

dds ⁣(n drds)=∇n(5)\frac{\mathrm d}{\mathrm ds}\!\left(n\,\frac{\mathrm d\mathbf r}{\mathrm ds}\right)=\nabla n \qquad (5)

where: ss — arc length along the ray; dr/ds=s^\mathrm d\mathbf r/\mathrm ds=\hat{\mathbf s}; ∇n\nabla n — the index gradient, playing the role of a force. Set ∇n=0\nabla n=0 and rays are straight; let nn vary and rays curve toward higher index. The next power of k0k_0 — the term we dropped — is not zero but small; setting it to zero gives the transport equation ∇ ⁣⋅(A2∇S)=0\nabla\!\cdot(A^2\nabla S)=0, which says the energy flux A2s^A^2\hat{\mathbf s} is conserved within a tube of rays. It is the first correction, and its blow-up at a focus is the tell-tale that geometry is failing there. Finally, integrating (3)(3) along a ray shows the eikonal difference is the optical path length, so δ ⁣∫n ds=0\delta\!\int n\,\mathrm ds=0 — Fermat's principle — is the variational shadow of the eikonal equation. This family of ideas is not confined to optics, and the link is exact rather than poetic. Under the optical–mechanical analogy, the refractive index n(r)n(\mathbf r) plays the role a particle's momentum plays in mechanics and an optical ray maps onto a mechanical trajectory; the eikonal SS is the optical twin of Hamilton's principal function, so the eikonal equation ∣∇S∣2=n2|\nabla S|^2=n^2 is precisely the geometrical-optics image of the Hamilton–Jacobi equation. Both limits hold for one and the same reason: geometrical optics is the short-wavelength limit of wave optics exactly as classical mechanics is the classical (ℏ→0\hbar\to0) limit of quantum mechanics — the content of the WKB / eikonal connection. We take these three statements by name from mechanics and do not re-derive them here.

Derivation AThe eikonal equation from the Helmholtz equation

This is the structural heart of the article: we extract geometrical optics from wave optics by inserting the eikonal ansatz into the Helmholtz equation and keeping only the leading power of the large wavenumber k0k_0. The strategy is a bookkeeping one — compute the Laplacian of A eik0SA\,\mathrm e^{ik_0S}, sort the resulting terms into powers k02k_0^2, k01k_0^1, k00k_0^0, and recognise that as k0→∞k_0\to\infty the k02k_0^2 term alone must balance the source term k02n2Uk_0^2n^2U. That balance is a statement about the phase only, and it is the eikonal equation.

Step 1. Take the gradient of the ansatz U=A eik0SU=A\,\mathrm e^{ik_0S}: ∇U=(∇A+ik0A ∇S) eik0S\nabla U=(\nabla A+ik_0A\,\nabla S)\,\mathrm e^{ik_0S}. Why the two pieces: the amplitude gradient is O(k00)O(k_0^0), but differentiating the phase pulls down a factor ik0ik_0, so the second piece is O(k01)O(k_0^1) — the phase dominates the derivative.

Step 2. Take the divergence for the Laplacian, keeping every term: ∇2U=[∇2A+2ik0 ∇A ⁣⋅ ⁣∇S+ik0A ∇2S−k02A ∣∇S∣2]eik0S\nabla^2 U=\big[\nabla^2 A+2ik_0\,\nabla A\!\cdot\!\nabla S+ik_0A\,\nabla^2 S-k_0^2A\,|\nabla S|^2\big]\mathrm e^{ik_0S}. Why four terms: each differentiation either hits AA (no factor) or the phase (a factor ik0ik_0), giving orders k00k_0^0, k01k_0^1, k01k_0^1, and k02k_0^2 respectively.

Step 3. Substitute into the Helmholtz equation ∇2U+k02n2U=0\nabla^2U+k_0^2n^2U=0 and cancel the common eik0S\mathrm e^{ik_0S}: ∇2A−k02A∣∇S∣2+ik0(2∇A ⁣⋅ ⁣∇S+A∇2S)+k02n2A=0\nabla^2 A-k_0^2A|\nabla S|^2+ik_0(2\nabla A\!\cdot\!\nabla S+A\nabla^2 S)+k_0^2n^2A=0. Why split real and imaginary: AA and SS are real, so the real part (the k02k_0^2 and k00k_0^0 terms) and the imaginary part (the k01k_0^1 terms) must each vanish separately.

Step 4. Collect the leading real part, O(k02)O(k_0^2): −A∣∇S∣2+n2A=0-A|\nabla S|^2+n^2A=0, and divide by AA to get ∣∇S∣2=n2|\nabla S|^2=n^2. Why this is the leading balance: the dropped ∇2A\nabla^2 A term is smaller than k02A∣∇S∣2k_0^2A|\nabla S|^2 by (λ/L)2(\lambda/L)^2, so in the limit λ0→0\lambda_0\to0 the eikonal equation is exact; the O(k01)O(k_0^1) imaginary part gives the transport equation, and ∇2A\nabla^2A is the diffraction correction. *Verified in verify_eikonal-equation.py: sympy inserts U=A eik0SU=A\,\mathrm e^{ik_0S} symbolically, confirms the O(k02)O(k_0^2) real coefficient is n2−∣∇S∣2n^2-|\nabla S|^2 and the O(k01)O(k_0^1) imaginary coefficient is the transport combination 2∇A ⁣⋅ ⁣∇S+A∇2S2\nabla A\!\cdot\!\nabla S+A\nabla^2S; a 1-D check gives ∣S′∣2=n2|S'|^2=n^2.*

Go deeper · Derivation B · 1 minThe ray equation from the eikonal equation
Derivation BThe ray equation from the eikonal equation

Having the phase law ∣∇S∣2=n2|\nabla S|^2=n^2, we now derive how the ray itself curves. The strategy is to differentiate the ray-direction relation n dr/ds=∇Sn\,\mathrm d\mathbf r/\mathrm ds=\nabla S with respect to arc length, use the fact that a gradient field is curl-free, and apply the eikonal equation once more to turn the right-hand side into ∇n\nabla n. The outcome is a Newton-like equation with the index gradient as the force — the equation every ray-tracer integrates.

Step 1. Start from the ray-direction relation n drds=ns^=∇Sn\,\dfrac{\mathrm d\mathbf r}{\mathrm ds}=n\hat{\mathbf s}=\nabla S, true because s^=∇S/n\hat{\mathbf s}=\nabla S/n. Why this is the launch point: it expresses the ray's tangent purely in terms of the eikonal, so its arc-length derivative will involve only SS and nn.

Step 2. Differentiate along the ray using dds=s^ ⁣⋅ ⁣∇\dfrac{\mathrm d}{\mathrm ds}=\hat{\mathbf s}\!\cdot\!\nabla: dds ⁣(ndrds)=(s^ ⁣⋅ ⁣∇)∇S=1n(∇S ⁣⋅ ⁣∇)∇S\dfrac{\mathrm d}{\mathrm ds}\!\left(n\dfrac{\mathrm d\mathbf r}{\mathrm ds}\right)=(\hat{\mathbf s}\!\cdot\!\nabla)\nabla S=\dfrac1n(\nabla S\!\cdot\!\nabla)\nabla S. Why the chain rule takes this form: moving along the ray by ds\mathrm ds advances position by s^ ds\hat{\mathbf s}\,\mathrm ds, so the directional derivative is s^ ⁣⋅ ⁣∇\hat{\mathbf s}\!\cdot\!\nabla, and s^=∇S/n\hat{\mathbf s}=\nabla S/n.

Step 3. Use the vector identity (a ⁣⋅ ⁣∇)a=12∇∣a∣2(\mathbf a\!\cdot\!\nabla)\mathbf a=\tfrac12\nabla|\mathbf a|^2 valid for a curl-free field a=∇S\mathbf a=\nabla S (since ∇×∇S=0\nabla\times\nabla S=0): the right-hand side becomes 12n∇∣∇S∣2\dfrac1{2n}\nabla|\nabla S|^2. Why curl-free matters: the identity needs ∇×a=0\nabla\times\mathbf a=0; a=∇S\mathbf a=\nabla S is a gradient, so its curl vanishes automatically, and the awkward advective term collapses to a plain gradient.

Step 4. Apply the eikonal equation ∣∇S∣2=n2|\nabla S|^2=n^2: 12n∇(n2)=12n 2n ∇n=∇n\dfrac1{2n}\nabla(n^2)=\dfrac1{2n}\,2n\,\nabla n=\nabla n. Hence dds ⁣(ndrds)=∇n\dfrac{\mathrm d}{\mathrm ds}\!\left(n\dfrac{\mathrm d\mathbf r}{\mathrm ds}\right)=\nabla n. Why it reads as a force law: with nn as an optical potential, ∇n\nabla n pushes the ray toward higher index — the mechanism of mirages, GRIN lenses, and atmospheric bending. *Verified in verify_eikonal-equation.py: sympy checks (∇S ⁣⋅ ⁣∇)∇S=12∇∣∇S∣2(\nabla S\!\cdot\!\nabla)\nabla S=\tfrac12\nabla|\nabla S|^2 for a sample curl-free field, and reduces the ray equation to r′′=−α2rr''=-\alpha^2 r for the parabolic GRIN profile, giving a sinusoid of pitch 2π/α2\pi/\alpha.*

Go deeper · Derivation C · 1 minSnell's law from continuity of the tangential eikonal
Derivation CSnell's law from continuity of the tangential eikonal

Geometry at a sharp interface should also fall out of the eikonal picture, and it does — from a single continuity requirement. The strategy: at a plane boundary between two media the phase, and hence the tangential component of ∇S\nabla S, cannot jump (a discontinuity would mean the field is many-valued along the surface). Since ∣∇S∣=n|\nabla S|=n, the tangential component is nsin⁡θn\sin\theta, and equating it on the two sides is Snell's law. Reflection is the same statement on the incident-medium branch.

Step 1. Impose continuity of the tangential part of ∇S\nabla S across the surface: (∇S)∥(\nabla S)_\parallel is the same on both sides. Why it must be continuous: SS is single-valued and continuous along the interface, so its surface-tangential derivative — the tangential ∇S\nabla S — is fixed by that shared boundary value; only the normal part may jump.

Step 2. Resolve ∇Si\nabla S_i into normal and tangential parts. With ∣∇Si∣=ni|\nabla S_i|=n_i from the eikonal equation and θi\theta_i the angle between the ray and the surface normal, the tangential magnitude is (∇Si)∥=nisin⁡θi(\nabla S_i)_\parallel=n_i\sin\theta_i. Why the sine appears: the tangential projection of a vector of length nin_i making angle θi\theta_i with the normal is nisin⁡θin_i\sin\theta_i.

Step 3. Equate the two sides: n1sin⁡θ1=n2sin⁡θ2n_1\sin\theta_1=n_2\sin\theta_2 — Snell's law. Taking both rays in the incident medium (n2→n1n_2\to n_1) with the normal component reversed gives θ1′=θ1\theta_1'=\theta_1, the law of reflection. Why the normal jump is allowed: it carries the change of ray direction; only the tangential part is pinned, and that pinning is exactly the refraction law. *Verified in verify_eikonal-equation.py: for n1=1.00n_1=1.00, n2=1.50n_2=1.50, θ1=40°\theta_1=40° the matched tangential eikonal gives θ2=25.37°\theta_2=25.37° with n1sin⁡θ1=n2sin⁡θ2=0.643n_1\sin\theta_1=n_2\sin\theta_2=0.643; the reflection branch returns θ1′=θ1\theta_1'=\theta_1.*

Limiting cases

CaseResultMeaning
homogeneous medium, ∇n=0\nabla n=0d2r/ds2=0\mathrm d^2\mathbf r/\mathrm ds^2=0rays are straight lines; wavefronts are planes or spheres — rectilinear propagation
weak linear gradientr¨≈∇n/n\ddot{\mathbf r}\approx\nabla n/n, radius Rc=n/∣∇n∣⊥R_c=n/|\nabla n|_\perprays curve toward higher nn with radius RcR_c — mirages, GRIN fibres, atmospheric refraction
parabolic GRIN, n=n0(1−12α2r2)n=n_0(1-\tfrac12\alpha^2r^2)r′′=−α2rr''=-\alpha^2r, pitch Λ=2π/α\Lambda=2\pi/\alphasinusoidal rays; a flat-faced rod focuses at the quarter pitch Λ/4\Lambda/4
sharp interface, nn discontinuousn1sin⁡θ1=n2sin⁡θ2n_1\sin\theta_1=n_2\sin\theta_2matching tangential ∇S\nabla S gives Snell's law and θi=θr\theta_i=\theta_r
λ/L≪̸1\lambda/L\not\ll1 (focus, edge, caustic)dropped ∇2A\nabla^2A term not smalldiffraction must be restored; predicted infinite intensity at a focus is the failure flag

Worked examples

1 · A graded-index rod as a flat lens (confidence builder)

A GRIN rod has index profile n(r)=n0(1−12α2r2)n(r)=n_0\big(1-\tfrac12\alpha^2 r^2\big) with n0=1.50n_0=1.50 and gradient constant α=0.5 mm−1\alpha=0.5\ \mathrm{mm^{-1}}. Find the ray pitch, the length that focuses collimated light, and the axial crossing of a ray launched parallel to the axis at height r0=0.10 mmr_0=0.10\ \mathrm{mm}.

Step 1. In the paraxial regime the ray equation (5)(5) with this profile becomes d2r/dz2=−α2r\mathrm d^2r/\mathrm dz^2=-\alpha^2 r (the transverse index gradient is ∂n/∂r=−n0α2r\partial n/\partial r=-n_0\alpha^2 r, and n≈n0n\approx n_0 along the axis). This is simple harmonic motion in zz, so every ray is a sinusoid.

Step 2. The spatial period — the full pitch — is Λ=2π/α=2π/(0.5 mm−1)=12.57 mm\Lambda=2\pi/\alpha=2\pi/(0.5\ \mathrm{mm^{-1}})=\boxed{12.57\ \mathrm{mm}}. A ray completes one oscillation in one pitch, independent of its launch height (to this order).

Step 3. A ray entering parallel to the axis at r0=0.10 mmr_0=0.10\ \mathrm{mm} follows r(z)=r0cos⁡(αz)r(z)=r_0\cos(\alpha z). It first crosses the axis when αz=π/2\alpha z=\pi/2, i.e. at the quarter pitch z=Λ/4=π/(2α)=3.14 mmz=\Lambda/4=\pi/(2\alpha)=\boxed{3.14\ \mathrm{mm}}: a rod cut to this length turns a bundle of parallel rays into a point, focusing with two flat faces.

Step 4. The launch height sets only the amplitude, not the focus: all parallel rays cross at Λ/4\Lambda/4, which is what makes the GRIN rod a genuine lens. A 3.14 mm rod of this glass is an ff-flat imaging element, the workhorse of endoscope relays and fibre collimators.

2 · Why the horizon Sun sits higher than it should (exam level)

Near the ground the air's index falls with height at roughly dn/dh≈−3.9×10−8 m−1\mathrm dn/\mathrm dh\approx-3.9\times10^{-8}\ \mathrm{m^{-1}}. Estimate the radius of curvature of a horizontal ray and compare it with the Earth's radius; comment on the horizon refraction of ≈34′\approx34'.

Step 1. For a nearly horizontal ray the index gradient is essentially vertical, perpendicular to the ray, so the ray equation gives a radius of curvature Rc=n/∣dn/dh∣R_c=n/|\mathrm dn/\mathrm dh|. With n≈1n\approx1, Rc=1/(3.9×10−8 m−1)=2.6×107 mR_c=1/(3.9\times10^{-8}\ \mathrm{m^{-1}})=\boxed{2.6\times10^{7}\ \mathrm{m}}.

Step 2. Compare with the Earth's radius R⊕=6.37×106 mR_\oplus=6.37\times10^{6}\ \mathrm{m}: the ray's curvature radius is Rc/R⊕≈4.0R_c/R_\oplus\approx\boxed{4.0} — the ray bends with about four times the Earth's radius, curving gently around the planet. This is the surveyor's and radio engineer's "four-thirds Earth," since the effective Earth radius is R⊕/(1−R⊕/Rc)≈43R⊕R_\oplus/(1-R_\oplus/R_c)\approx\tfrac43R_\oplus.

Step 3. Because the ray curves the same way as the surface, light from just below the geometric horizon is bent back to the eye: objects appear lifted. Integrated over the whole atmosphere this raises the apparent position of a body at the horizon by the standard astronomical refraction of about 34′34' — a bit more than the Sun's own 32′32' diameter.

Step 4. The everyday consequence: when you watch the Sun's lower limb touch the horizon, the true Sun is already entirely below it. The same ray-equation bending flattens the setting Sun's disk and lengthens the day by a couple of minutes at each end.

Physics of the portrait

The eikonal equation is the centrepiece of a program one man built almost single-handed: the reduction of both optics and mechanics to a single geometry of "characteristic functions." That man measured optical systems by a single function whose gradients are the rays, and then found the very same mathematics waiting in dynamics.

Origins · 1 minWilliam Rowan Hamilton and how this was discovered
WR
William Rowan Hamilton
1805–1865 · Dublin

Hamilton was a prodigy — reading Greek at five, appointed Royal Astronomer of Ireland and Andrews Professor at Trinity College Dublin while still an undergraduate. His Theory of Systems of Rays (1828, with supplements to 1837) recast geometrical optics around a single characteristic (eikonal) function whose partial derivatives yield every ray of a system; from it he predicted conical refraction in biaxial crystals in 1832, a startling effect confirmed by Humphrey Lloyd within months — one of the first triumphs of a purely theoretical prediction in optics. Hamilton then carried the identical mathematics into dynamics, producing the Hamilton–Jacobi equation and the formulation of mechanics that bears his name, and stating explicitly that optics and mechanics are one variational subject. It was this optical–mechanical analogy that Schrödinger, a century later, ran in reverse — guessing wave mechanics from ray mechanics — so the eikonal equation is a direct ancestor of the Schrödinger equation. Hamilton's later years were consumed by the quaternions; the ray function that opened his career remains the cleaner monument.

History
1637
— Descartes and Fermat debate the cause of refraction; the ray picture is empirical, without a wave foundation
1690
— Huygens' Traité de la Lumière builds wavefronts from secondary wavelets, the geometric germ of the eikonal
1828
— Hamilton's Theory of Systems of Rays introduces the characteristic function whose gradient is the ray
1832
— Hamilton predicts conical refraction from his theory; Lloyd confirms it experimentally in 1833
1895
— Bruns names the "eikonal" and systematizes it for optical instrument design
1911
— Sommerfeld and Runge derive the eikonal equation as the short-wavelength limit of the wave equation
1926
— Schrödinger inverts the optical–mechanical analogy to reach wave mechanics from the eikonal/Hamilton–Jacobi link

Going further

Texts. Born & Wolf, Principles of Optics, 7th ed., §3.1–3.2 (the eikonal and geometrical optics) · Hecht, Optics, 5th ed., §4.2 and §3.5.2 · Saleh & Teich, Fundamentals of Photonics, 3rd ed., §1.2 (eikonal and ray equations) · Goodman, Introduction to Fourier Optics, 3rd ed. (WKB limit of scalar diffraction) · Landau & Lifshitz, Classical Theory of Fields, §53 (geometrical optics and the eikonal).

Provenance. The eikonal equation ∣∇S∣2=n2|\nabla S|^2=n^2, the ray equation d(nr˙)/ds=∇n\mathrm d(n\dot{\mathbf r})/\mathrm ds=\nabla n, and the transport equation ∇ ⁣⋅(A2∇S)=0\nabla\!\cdot(A^2\nabla S)=0 are standard (Born & Wolf §3.1–3.2; Saleh & Teich §1.2). verify_eikonal-equation.py reproduces: the symbolic O(k02)O(k_0^2) balance n2=∣∇S∣2n^2=|\nabla S|^2 and the O(k01)O(k_0^1) transport combination from inserting U=A eik0SU=A\,\mathrm e^{ik_0S}; the curl-free identity (∇S ⁣⋅ ⁣∇)∇S=12∇∣∇S∣2(\nabla S\!\cdot\!\nabla)\nabla S=\tfrac12\nabla|\nabla S|^2; the GRIN reduction r′′=−α2rr''=-\alpha^2r with pitch Λ=2π/α=12.57 mm\Lambda=2\pi/\alpha=12.57\ \mathrm{mm} and quarter-pitch focus 3.14 mm3.14\ \mathrm{mm} for α=0.5 mm−1\alpha=0.5\ \mathrm{mm^{-1}}; the tangential-eikonal Snell match (n1=1.00,n2=1.50,θ1=40°⇒θ2=25.37°n_1=1.00,n_2=1.50,\theta_1=40°\Rightarrow\theta_2=25.37°); and the atmospheric ray-curvature radius Rc=2.6×107 m≈4R⊕R_c=2.6\times10^{7}\ \mathrm m\approx4R_\oplus. The optical–mechanical analogy, Hamilton–Jacobi identification, and WKB/ℏ→0\hbar\to0 limit are recalled by name from aq-mech-optical-mechanical-analogy, aq-mech-hamilton-jacobi-equation, and aq-mech-wkb-eikonal-connection (grep-verified), not re-derived here. Atmospheric refraction ≈34′\approx34' and the "four-thirds Earth" are standard.

Builds on: Refractive Index and Optical Path Length · Ray Model of Light · Fermat's Principle of Least Time. Leads to: Snell's Law of Refraction · Law of Reflection · Refraction at a Spherical Surface · Dispersion and Prisms.

Is the eikonal S the same thing as the optical path length, or just proportional to it?

It is exactly the optical path length. Integrating the eikonal equation along a ray gives S(P2)−S(P1)=∫P1P2n ds=OPLS(P_2)-S(P_1)=\int_{P_1}^{P_2}n\,\mathrm ds=\mathrm{OPL}, so the accumulated eikonal between two points on a ray is the index-weighted distance — the same OPL that appears in Fermat's principle. That is why surfaces of constant SS are wavefronts (surfaces reached at the same phase) and why ∣∇S∣=n|\nabla S|=n: moving one metre along the ray advances SS by nn metres of optical path. The phase of the wave is just k0S=(2π/λ0) OPLk_0S=(2\pi/\lambda_0)\,\mathrm{OPL}.

How is the ray equation like Newton's second law?

Rewrite dds(n dr/ds)=∇n\frac{\mathrm d}{\mathrm ds}(n\,\mathrm d\mathbf r/\mathrm ds)=\nabla n and read nn as an optical "potential": the left side is the rate of change of the ray's momentum-like quantity ns^n\hat{\mathbf s}, and the right side ∇n\nabla n is a force pushing toward higher index. In a uniform medium the force vanishes and rays go straight, like a free particle; in a gradient they accelerate transversely, curving toward high nn. This is not a loose analogy — under the optical–mechanical analogy the ray equation is literally the trajectory equation of a particle with nn in the role of momentum, which is why the same solver traces light rays and classical orbits.

Why do we drop the ∇²A term, and what is it physically?

Because it is smaller than the term we keep by the factor (λ/L)2(\lambda/L)^2, where LL is the scale over which the amplitude varies. In the eikonal ansatz the phase carries a factor k0=2π/λ0k_0=2\pi/\lambda_0 every time it is differentiated, so the phase-derivative terms dominate the amplitude-derivative terms whenever λ≪L\lambda\ll L. The dropped ∇2A\nabla^2A term is the seed of diffraction: it is precisely what spreads a beam, fills in a shadow edge, and keeps the intensity finite at a focus. Restoring it is the business of physical optics; keeping only the leading term is geometrical optics.

Does the eikonal equation handle graded-index media, or only homogeneous ones and sharp interfaces?

Graded media are exactly where it shines. The ray equation d(n dr/ds)/ds=∇n\mathrm d(n\,\mathrm d\mathbf r/\mathrm ds)/\mathrm ds=\nabla n holds for any smooth n(r)n(\mathbf r), and integrating it produces curved rays: parabolic index profiles give sinusoidal rays (GRIN fibres and rods), a vertical atmospheric gradient gives the mirage and horizon refraction, and a spherically symmetric n(r)n(r) gives the trajectories of light around gradient lenses. Sharp interfaces are the singular case, handled by matching the tangential eikonal (Snell's law); smooth gradients are the generic, and easier, case.

Where exactly does the wavelength re-enter if the eikonal equation has none?

Through the next terms in the k0k_0 expansion. The eikonal equation is scale-free, but the transport equation ∇ ⁣⋅(A2∇S)=0\nabla\!\cdot(A^2\nabla S)=0 and, beyond it, the diffraction correction restore the wavelength: the size of a focal spot, the width of a diffraction fringe, and the angular spread of a beam all scale with λ\lambda. So a ray trace tells you where light goes to leading order, but the resolution limit, the Airy disk, and the depth of focus require the wave corrections. Practical design pairs ray tracing (geometry, aberrations) with wave optics (the diffraction limit near the focus).

Why is this called an "analogy" with mechanics if it is supposed to be exact?

"Analogy" is historical understatement. The eikonal equation ∣∇S∣2=n2|\nabla S|^2=n^2 has the identical mathematical form as the time-independent Hamilton–Jacobi equation ∣∇W∣2=2m(E−V)|\nabla W|^2=2m(E-V), with the eikonal SS matching Hamilton's principal function WW, the index nn matching the momentum 2m(E−V)\sqrt{2m(E-V)}, and optical rays matching mechanical trajectories. The correspondence is a genuine isomorphism in the short-wave / classical limit, which is why the WKB method of quantum mechanics and the eikonal method of optics are the same technique. We recall the mechanics side by name (aq-mech-optical-mechanical-analogy, -hamilton-jacobi-equation, -wkb-eikonal-connection) rather than re-derive it, but the identity — not mere resemblance — is the point.

Before this

Where this leads