Hamiltonian optics and Lagrangian optics are two formulations of geometrical optics which share much of the mathematical formalism with Hamiltonian mechanics and Lagrangian mechanics.
Hamilton's principle
In physics, Hamilton's principle states that the evolution of a system (q1(σ),…,qN(σ)) described by N generalized coordinates between two specified states at two specified parameters σA and σB is a stationary point (a point where the variation is zero) of the action functional, or δS=δ∫σAσBL(q1,⋯,qN,q˙1,⋯,q˙N,σ)dσ=0 where q˙k=dqk/dσ and L is the Lagrangian. Condition δS=0 is valid if and only if the Euler–Lagrange equations are satisfied, i.e., ∂L∂qk−ddσ∂L∂q˙k=0 with k=1,…,N. The momentum is defined as pk=∂L∂q˙k and the Euler–Lagrange equations can then be rewritten as p˙k=∂L∂qk where p˙k=dpk/dσ. A different approach to solving this problem consists in defining a Hamiltonian (taking a Legendre transform of the Lagrangian) as H=∑kq˙kpk−L for which a new set of differential equations can be derived by looking at how the total differential of the Lagrangian depends on parameter σ, positions qi and their derivatives q˙i relative to σ. This derivation is the same as in Hamiltonian mechanics, only with time t now replaced by a general parameter σ. Those differential equations are the Hamilton's equations ∂H∂qk=−p˙k,∂H∂pk=q˙k,dHdσ=−∂L∂σ. with k=1,…,N. Hamilton's equations are first-order differential equations, while the Euler–Lagrange equations are second-order.
Lagrangian optics The general results presented above for Hamilton's principle can be applied to optics. In 3D euclidean space the generalized coordinates are now the coordinates of euclidean space.
Fermat's principle
Fermat's principle states that the optical length of the path followed by light between two fixed points, A and B, is a stationary point. It may be a maximum, a minimum, constant or an inflection point. In general, as light travels, it moves in a medium of variable refractive index which is a scalar field of position in space, that is, n=n(x1,x2,x3) in 3D euclidean space. Assuming now that light travels along the x3 axis, the path of a light ray may be parametrized as s=(x1(x3),x2(x3),x3) starting at a point 𝐀=(x1(x3A),x2(x3A),x3A) and ending at a point 𝐁=(x1(x3B),x2(x3B),x3B). In this case, when compared to Hamilton's principle above, coordinates x1 and x2 take the role of the generalized coordinates qk while x3 takes the role of parameter σ, that is, parameter σ =x3 and N=2. In the context of calculus of variations this can be written as δS=δ∫𝐀𝐁nds=δ∫x3Ax3Bndsdx3dx3=δ∫x3Ax3BL(x1,x2,x˙1,x˙2,x3)dx3=0 where ds is an infinitesimal displacement along the ray given by ds=dx12+dx22+dx32 and L=ndsdx3=n(x1,x2,x3)1+x˙12+x˙22 is the optical Lagrangian and x˙k=dxk/dx3. The optical path length (OPL) is defined as S=∫𝐀𝐁nds=∫𝐀𝐁Ldx3 where n is the local refractive index as a function of position along the path between points A and B.
The Euler–Lagrange equations The general results presented above for Hamilton's principle can be applied to optics using the Lagrangian defined in Fermat's principle. The Euler–Lagrange equations with parameter σ =x3 and N=2 applied to Fermat's principle result in ∂L∂xk−ddx3∂L∂x˙k=0 with k = 1, 2 and where L is the optical Lagrangian and x˙k=dxk/dx3.
Optical momentum The optical momentum is defined as pk=∂L∂x˙k and from the definition of the optical Lagrangian L=n1+x˙12+x˙22 this expression can be rewritten as pk=nx˙kx˙12+x˙22+x˙32=ndxkdx12+dx22+dx32=ndxkds
or in vector form 𝐩=n𝐝𝐬ds=(p1,p2,p3)=(ncosα1,ncosα2,ncosα3)=n𝐞̂ where 𝐞̂ is a unit vector and angles α1, α2 and α3 are the angles p makes to axis x1, x2 and x3 respectively, as shown in figure "optical momentum". Therefore, the optical momentum is a vector of norm ‖𝐩‖=p12+p22+p32=n where n is the refractive index at which p is calculated. Vector p points in the direction of propagation of light. If light is propagating in a gradient index optic the path of the light ray is curved and vector p is tangent to the light ray. The expression for the optical path length can also be written as a function of the optical momentum. Having in consideration that x˙3=dx3/dx3=1 the expression for the optical Lagrangian can be rewritten as L=nx˙12+x˙22+x˙32=x˙1nx˙1x˙12+x˙22+x˙32+x˙2nx˙2x˙12+x˙22+x˙32+nx˙3x˙12+x˙22+x˙32=x˙1p1+x˙2p2+x˙3p3=x˙1p1+x˙2p2+p3 and the expression for the optical path length is S=∫Ldx3=∫𝐩⋅d𝐬
Hamilton's equations Similarly to what happens in Hamiltonian mechanics, also in optics the Hamiltonian is defined by the expression given above for N = 2 corresponding to functions x1(x3) and x2(x3) to be determined H=x˙1p1+x˙2p2−L Comparing this expression with L=x˙1p1+x˙2p2+p3 for the Lagrangian results in H=−p3=−n2−p12−p22 And the corresponding Hamilton's equations with parameter σ =x3 and k=1,2 applied to optics are ∂H∂xk=−p˙k,∂H∂pk=x˙k with x˙k=dxk/dx3 and p˙k=dpk/dx3.
Applications It is assumed that light travels along the x3 axis, in Hamilton's principle above, coordinates x1 and x2 take the role of the generalized coordinates qk while x3 takes the role of parameter σ, that is, parameter σ =x3 and N=2.
Refraction and reflection
If plane x1x2 separates two media of refractive index nA below and nB above it, the refractive index is given by a step function n(x3)={nAif x3<0nBif x3>0 and from Hamilton's equations ∂H∂xk=−∂∂xkn(x3)2−p12−p22=0 and therefore p˙k=0 or pk=Constant for k = 1, 2. An incoming light ray has momentum pA before refraction (below plane x1x2) and momentum pB after refraction (above plane x1x2). The light ray makes an angle θA with axis x3 (the normal to the refractive surface) before refraction and an angle θB with axis x3 after refraction. Since the p1 and p2 components of the momentum are constant, only p3 changes from p3A to p3B.
… excerpt ends here. Continue reading the full article.





