MechanicsLagrangian Mechanics3 of 6
Lagrangian Mechanics · 3

Action and the Euler-Lagrange Equations

Newton's F⃗=ma⃗\Force{\vec{F}} = m\Acc{\vec{a}} tracks motion step by step, forcing us to keep up with every constraint force and curved coordinate direction, so we want a way to find a system's path by looking at its entire journey at once using energy.

The Action and the Tug-of-War Between T and V
y\htmlClass{lc-blue}{y}
v\htmlClass{lc-pink}{v}
mg\Force{m g}
F=ma\Force{F} = m\Acc{a}

Instead of stepping forward instant by instant with forces, we score every possible path y(t)\Coord{y(t)} between the fixed start and end points by integrating the difference between kinetic energy T\Kin{T} and potential energy V\Pot{V}:

S=∫tstarttendL dt⏟Action,L=T−V⏟Lagrangian\displaystyle \underbrace{\Action{S} = \Action{\int_{t_{\text{start}}}^{t_{\text{end}}}} L\,\Action{dt}}_{\Action{\text{Action}}}, \qquad \underbrace{L = \Kin{T} - \Pot{V}}_{\text{Lagrangian}}

Nature picks the path where the action S\Action{S} is stationary, meaning a tiny wiggle of the path leaves S\Action{S} unchanged to first order.

Let's test this score on a 1 kg1\text{ kg} ball thrown straight up in uniform gravity g=10 m/s2g = 10\text{ m/s}^2 from y(0)=0\Coord{y}(0) = 0 to y(2)=0\Coord{y}(2) = 0, and see how S\Action{S} singles out the true parabolic trajectory from a family of trial paths.

Testing Trial Paths for a Thrown Ball
11
22
55
t (s)t\ (\text{s})
y (m)\Coord{y}\ (\text{m})
flat\text{flat}
triangle\text{triangle}
ytrue\Coord{y_{\text{true}}}
S=∫02(12y˙2−10y)dtSflat=?Striangle=?\begin{aligned}\Action{S} &= \Action{\int_0^2}\left(\tfrac12\Vel{\dot y^2} - 10\Coord{y}\right)\Action{dt}\\[4pt] \Action{S_{\text{flat}}} &= {?}\qquad \Action{S_{\text{triangle}}} = {?}\end{aligned}
Text solution
Write the action integral for the ballWith m=1 kgm = 1\text{ kg} and g=10 m/s2g = 10\text{ m/s}^2, substitute T=12y˙2\Kin{T} = \frac{1}{2}\Vel{\dot{y}^2} and V=10y\Pot{V} = 10\Coord{y} into S\Action{S} == ∫(T−V) dt\Action{\int} (\Kin{T} - \Pot{V})\,\Action{dt}.
S\displaystyle \Action{S} =∫02(12y˙2−10y)dt\displaystyle = \Action{\int_0^2} \left(\frac{1}{2}\Vel{\dot{y}^2} - 10\Coord{y}\right) \Action{dt}
Differentiate the trial archFor the adjustable family of parabolas y(t)=At(2−t)=2At−At2\Coord{y(t)} = At(2 - t) = 2At - At^2 pinned at y(0)=0\Coord{y}(0) = 0 and y(2)=0\Coord{y}(2) = 0, take the time derivative to get the velocity.
y˙(t)\displaystyle \Vel{\dot{y}(t)} =2A(1−t)\displaystyle = 2A(1 - t)
Integrate kinetic and potential energyIntegrate 12y˙2\frac{1}{2}\Vel{\dot{y}^2} and 10y10\Coord{y} from t=0t = 0 to t=2t = 2, then subtract to get the action S(A)\Action{S(A)} as a function of the parameter AA.
∫0212y˙2 dt=∫022A2(1−t)2 dt=2A2[−(1−t)33]02=43A2∫0210y dt=10A∫02(2t−t2) dt=10A[t2−t33]02=403AS(A)=43A2−403A=43(A2−10A)\displaystyle \begin{aligned} \int_0^2 \frac{1}{2}\Vel{\dot{y}^2}\,dt &= \int_0^2 2A^2(1 - t)^2\,dt \\ &= 2A^2\left[-\frac{(1 - t)^3}{3}\right]_0^2 \\ &= \Kin{\frac{4}{3}A^2} \\[6pt] \int_0^2 10\Coord{y}\,dt &= 10A\int_0^2 (2t - t^2)\,dt \\ &= 10A\left[t^2 - \frac{t^3}{3}\right]_0^2 \\ &= \Pot{\frac{40}{3}A} \\[6pt] \Action{S(A)} &= \Kin{\frac{4}{3}A^2} \Pot{- \frac{40}{3}A} \\ &= \frac{4}{3}(A^2 - 10A) \end{aligned}
Find the stationary pathSet the derivative of S(A)\Action{S(A)} with respect to AA to zero.
dSdA\displaystyle \frac{d\Action{S}}{dA} =43(2A−10)\displaystyle = \frac{4}{3}(2A - 10) =0  ⟹  A\displaystyle = 0 \implies A =5\displaystyle = 5

So A=5A = 5 gives the exact physical trajectory ytrue(t)=10t−5t2 m\Coord{y_{\text{true}}(t)} = 10t - 5t^2\text{ m} with S(5)=−1003≈−33.333 J⋅s\Action{S(5)} = -\frac{100}{3} \approx -33.333\text{ J}\cdot\text{s}. Nudging AA to 5+ε5 + \varepsilon gives S(5+ε)=43(−25+ε2)\Action{S(5 + \varepsilon)} = \frac{4}{3}(-25 + \varepsilon^2), which has no linear ε\varepsilon term because the action curve S(A)\Action{S(A)} is flat right at A=5A = 5.

Drag the arch's peak up and down to see how kinetic and potential energy trade off, making the total action level out right at the true path.
1

The Euler-Lagrange Equation and Generalized Coordinates

Testing a one-parameter family only checks one shape at a time; we want a differential equation that makes the action stationary against any tiny local nudge along the path, in whatever coordinates fit the system best.

The Euler-Lagrange Equation and Generalized Coordinates
y(t)\Coord{y}(t)
h\htmlClass{lc-blue}{h}
Δt\Delta t
L=T−V∂L∂y⏟?=ddt(∂L∂y˙⏟?)\begin{aligned} L &= \Kin{T} - \Pot{V}\\ \underbrace{\dfrac{\partial L}{\partial \Coord{y}}}_{\textstyle ?} &= \dfrac{d}{dt}\bigg(\underbrace{\dfrac{\partial L}{\partial \Vel{\dot y}}}_{\textstyle ?}\bigg)\end{aligned}

For the action S\Action{S} == ∫L(qi,q˙i,t) dt\Action{\int} L(\Coord{q_i}, \Vel{\dot{q}_i}, t)\,\Action{dt} to be stationary (δS=0\Action{\delta S} = 0) under any small nudge of the path, every generalized coordinate qi\Coord{q_i} must obey the Euler-Lagrange equation at every instant:

∂L∂qi⏟how L changeswith position(generalizedforce)\displaystyle \underbrace{\Force{\frac{\partial L}{\partial q_i}}}_{\substack{\text{how } L \text{ changes} \\ \text{with position} \\ \Force{\text{(generalized}} \\ \Force{\text{force)}}}} =ddt(∂L∂q˙i)⏟how L changeswith velocity(generalizedmomentum)\displaystyle = \frac{d}{dt}\underbrace{\left(\Mom{\frac{\partial L}{\partial \dot{q}_i}}\right)}_{\substack{\text{how } L \text{ changes} \\ \text{with velocity} \\ \Mom{\text{(generalized}} \\ \Mom{\text{momentum)}}}}

For the thrown ball with L=12my˙2−mgyL = \frac{1}{2}m\Vel{\dot{y}^2} - mg\Coord{y}, the generalized force is ∂L∂y=−mg\Force{\frac{\partial L}{\partial y}} = \Force{-mg} and the momentum is ∂L∂y˙=my˙\Mom{\frac{\partial L}{\partial \dot{y}}} = m\Vel{\dot{y}}, so the Euler-Lagrange equation immediately gives −mg=ddt(my˙)=my¨\Force{-mg} = \frac{d}{dt}(m\Vel{\dot{y}}) = m\Acc{\ddot{y}}.

Anywhere along the true parabolic path, a local poke changes potential energy from its height and kinetic energy from its tilted sides by equal amounts to first order, leaving the Action unchanged to first order.
2

Single Degree of Freedom: The Simple Pendulum

Now let's find the equation of motion for a simple pendulum of mass mm on a rigid, massless rod of length ℓ\ell, using only its angle θ\Coord{\theta} from the downward vertical.

θ\htmlClass{lc-blue}{\theta}
ℓ\ell
mm
y=0\htmlClass{lc-blue}{y} = 0
y=−ℓcos⁡θ\htmlClass{lc-blue}{y} = -\ell\cos\htmlClass{lc-blue}{\theta}
v=ℓθ˙\htmlClass{lc-pink}{v} = \ell\htmlClass{lc-pink}{\dot{\theta}}
The Simple Pendulum in Generalized Coordinates
θ\htmlClass{lc-blue}{\theta}
ℓ\ell
mm
g\Acc{g}
L=T−V=?L = \Kin{T} - \Pot{V} = {?}
Text solution
Write T\Kin{T} and V\Pot{V} in terms of θ\Coord{\theta}Moving along an arc of radius ℓ\ell with the pivot at y=0\Coord{y} = 0, the bob has speed v=ℓθ˙\Vel{v} = \ell\Vel{\dot{\theta}} and height y=−ℓcos⁡θ\Coord{y} = -\ell\cos\Coord{\theta}.
T\displaystyle \Kin{T} =12mv2\displaystyle = \frac{1}{2}m\Vel{v^2} =12mℓ2θ˙2,V\displaystyle = \frac{1}{2}m\ell^2\Vel{\dot{\theta}^2}, \qquad \Pot{V} =mgy\displaystyle = mg\Coord{y} =−mgℓcos⁡θ\displaystyle = -mg\ell\cos\Coord{\theta}
Form the LagrangianSubtract V\Pot{V} from T\Kin{T}, watching the double negative on the potential energy term.
L\displaystyle L =T−V\displaystyle = \Kin{T} - \Pot{V} =12mℓ2θ˙2+mgℓcos⁡θ\displaystyle = \frac{1}{2}m\ell^2\Vel{\dot{\theta}^2} + mg\ell\cos\Coord{\theta}
Take the partial derivativesDifferentiate LL with respect to θ\Coord{\theta} (holding θ˙\Vel{\dot{\theta}} fixed) to get the gravitational torque, and with respect to θ˙\Vel{\dot{\theta}} (holding θ\Coord{\theta} fixed) to get the angular momentum.
∂L∂θ\displaystyle \Force{\frac{\partial L}{\partial \theta}} =−mgℓsin⁡θ,∂L∂θ˙\displaystyle = -mg\ell\sin\Coord{\theta}, \qquad \Mom{\frac{\partial L}{\partial \dot{\theta}}} =mℓ2θ˙\displaystyle = m\ell^2\Vel{\dot{\theta}}
Set ∂L∂θ=ddt(∂L∂θ˙)\Force{\frac{\partial L}{\partial \theta}} = \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right) and simplifyDifferentiate the angular momentum with respect to time and divide both sides by mℓ2m\ell^2.
−mgℓsin⁡θ=ddt(mℓ2θ˙)=mℓ2θ¨θ¨+gℓsin⁡θ=0\displaystyle \begin{aligned} -mg\ell\sin\Coord{\theta} &= \frac{d}{dt}\left(m\ell^2\Vel{\dot{\theta}}\right) = m\ell^2\Acc{\ddot{\theta}} \\[4pt] \Acc{\ddot{\theta}} + \frac{g}{\ell}\sin\Coord{\theta} &= 0 \end{aligned}

So the pendulum's angular equation of motion comes straight from scalar energies in θ\Coord{\theta}, without resolving force vectors or solving for the tension in the rod.

3

Coupled Motion and Cyclic Coordinates: Cart and Pendulum

Now let the pendulum's pivot ride on a cart of mass MM that slides along a frictionless horizontal track: we want the coupled equations of motion for the cart's horizontal position x\Coord{x} and the pendulum's angle θ\Coord{\theta}.

MM
x\htmlClass{lc-blue}{x}
θ\htmlClass{lc-blue}{\theta}
ℓ\ell
mm
00
xbob=x+ℓsin⁡θ\htmlClass{lc-blue}{x_{\text{bob}}} = \htmlClass{lc-blue}{x} + \ell\sin\htmlClass{lc-blue}{\theta}
ybob=−ℓcos⁡θ\htmlClass{lc-blue}{y_{\text{bob}}} = -\ell\cos\htmlClass{lc-blue}{\theta}
Coupled Motion and Conserved Momentum: Cart and Pendulum
MM
x\htmlClass{lc-blue}{x}
x˙\htmlClass{lc-pink}{\dot{x}}
θ\htmlClass{lc-blue}{\theta}
ℓ\ell
mm
00
x¨=?θ¨=?\Acc{\ddot x} = {?}\qquad \Acc{\ddot\theta} = {?}
Text solution
Find the bob's speed from Cartesian coordinatesWrite (xbob,ybob)(\Coord{x_{\text{bob}}}, \Coord{y_{\text{bob}}}) in terms of x\Coord{x} and θ\Coord{\theta}, differentiate with respect to time, and square and add the velocity components.
xbob=x+ℓsin⁡θ  ⟹  x˙bob=x˙+ℓθ˙cos⁡θybob=−ℓcos⁡θ  ⟹  y˙bob=ℓθ˙sin⁡θ\displaystyle \begin{aligned} \Coord{x_{\text{bob}}} &= \Coord{x} + \ell\sin\Coord{\theta} \\ \implies \Vel{\dot{x}_{\text{bob}}} &= \Vel{\dot{x}} + \ell\Vel{\dot{\theta}}\cos\Coord{\theta} \\[6pt] \Coord{y_{\text{bob}}} &= -\ell\cos\Coord{\theta} \\ \implies \Vel{\dot{y}_{\text{bob}}} &= \ell\Vel{\dot{\theta}}\sin\Coord{\theta} \end{aligned}
vbob2=x˙bob2+y˙bob2=(x˙+ℓθ˙cos⁡θ)2+(ℓθ˙sin⁡θ)2=x˙2+2ℓx˙θ˙cos⁡θ+ℓ2θ˙2(cos⁡2θ+sin⁡2θ)=x˙2+2ℓx˙θ˙cos⁡θ+ℓ2θ˙2\displaystyle \begin{aligned} \Vel{v_{\text{bob}}^2} &= \Vel{\dot{x}_{\text{bob}}^2} + \Vel{\dot{y}_{\text{bob}}^2} \\ &= (\Vel{\dot{x}} + \ell\Vel{\dot{\theta}}\cos\Coord{\theta})^2 + (\ell\Vel{\dot{\theta}}\sin\Coord{\theta})^2 \\ &= \Vel{\dot{x}^2} + 2\ell\Vel{\dot{x}}\Vel{\dot{\theta}}\cos\Coord{\theta} \\ &\quad + \ell^2\Vel{\dot{\theta}^2}(\cos^2\Coord{\theta} + \sin^2\Coord{\theta}) \\ &= \Vel{\dot{x}^2} + 2\ell\Vel{\dot{x}}\Vel{\dot{\theta}}\cos\Coord{\theta} + \ell^2\Vel{\dot{\theta}^2} \end{aligned}
Build the LagrangianAdd the cart's kinetic energy 12Mx˙2\frac{1}{2}M\Vel{\dot{x}^2} and the bob's kinetic energy 12mvbob2\frac{1}{2}m\Vel{v_{\text{bob}}^2}, then subtract the potential energy V=−mgℓcos⁡θ\Pot{V} = -mg\ell\cos\Coord{\theta}.
L=T−V=12(M+m)x˙2+mℓx˙θ˙cos⁡θ+12mℓ2θ˙2+mgℓcos⁡θ\displaystyle \begin{aligned} L &= \Kin{T} - \Pot{V} \\ &= \frac{1}{2}(M + m)\Vel{\dot{x}^2} + m\ell\Vel{\dot{x}}\Vel{\dot{\theta}}\cos\Coord{\theta} \\ &\quad + \frac{1}{2}m\ell^2\Vel{\dot{\theta}^2} + mg\ell\cos\Coord{\theta} \end{aligned}
Write the θ\Coord{\theta} Euler-Lagrange equationTake the partials with respect to θ\Coord{\theta} and θ˙\Vel{\dot{\theta}}, then apply the product and chain rules when taking ddt(∂L∂θ˙)\frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right) along the path.
∂L∂θ=−mℓx˙θ˙sin⁡θ−mgℓsin⁡θ∂L∂θ˙=mℓx˙cos⁡θ+mℓ2θ˙ddt(∂L∂θ˙)=mℓx¨cos⁡θ−mℓx˙θ˙sin⁡θ+mℓ2θ¨\displaystyle \begin{aligned} \Force{\frac{\partial L}{\partial \theta}} &= -m\ell\Vel{\dot{x}}\Vel{\dot{\theta}}\sin\Coord{\theta} \\ &\quad - mg\ell\sin\Coord{\theta} \\[4pt] \Mom{\frac{\partial L}{\partial \dot{\theta}}} &= m\ell\Vel{\dot{x}}\cos\Coord{\theta} + m\ell^2\Vel{\dot{\theta}} \\[4pt] \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right) &= m\ell\Acc{\ddot{x}}\cos\Coord{\theta} \\ &\quad - m\ell\Vel{\dot{x}}\Vel{\dot{\theta}}\sin\Coord{\theta} + m\ell^2\Acc{\ddot{\theta}} \end{aligned}
Equating ∂L∂θ\Force{\frac{\partial L}{\partial \theta}} and ddt(∂L∂θ˙)\frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right), canceling −mℓx˙θ˙sin⁡θ-m\ell\Vel{\dot{x}}\Vel{\dot{\theta}}\sin\Coord{\theta} on both sides, and dividing by mℓm\ell gives the first coupled equation:
ℓθ¨+x¨cos⁡θ+gsin⁡θ\displaystyle \ell\Acc{\ddot{\theta}} + \Acc{\ddot{x}}\cos\Coord{\theta} + g\sin\Coord{\theta} =0\displaystyle = 0
Write the x\Coord{x} Euler-Lagrange equationBecause x\Coord{x} does not appear in LL, ∂L∂x=0\Force{\frac{\partial L}{\partial x}} = 0, so the horizontal momentum ∂L∂x˙\Mom{\frac{\partial L}{\partial \dot{x}}} is conserved and its time derivative is zero.
∂L∂x=0∂L∂x˙=(M+m)x˙+mℓθ˙cos⁡θ=constantddt(∂L∂x˙)=(M+m)x¨+mℓθ¨cos⁡θ−mℓθ˙2sin⁡θ=0\displaystyle \begin{aligned} \Force{\frac{\partial L}{\partial x}} &= 0 \\[4pt] \Mom{\frac{\partial L}{\partial \dot{x}}} &= (M + m)\Vel{\dot{x}} \\ &\quad + m\ell\Vel{\dot{\theta}}\cos\Coord{\theta} \\ &= \Mom{\text{constant}} \\[4pt] \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{x}}}\right) &= (M + m)\Acc{\ddot{x}} \\ &\quad + m\ell\Acc{\ddot{\theta}}\cos\Coord{\theta} \\ &\quad - m\ell\Vel{\dot{\theta}^2}\sin\Coord{\theta} \\ &= 0 \end{aligned}

Two habits keep coupled problems clean. First, whenever motions combine, don't guess the speed in your head: write the Cartesian coordinates (x,y)(\Coord{x}, \Coord{y}) in terms of your generalized coordinates and differentiate them. Second, don't mix up the partial derivative ∂∂q˙i\frac{\partial}{\partial \Vel{\dot{q}_i}} and the total time derivative ddt\frac{d}{dt}. When you take ∂L∂θ˙\Mom{\frac{\partial L}{\partial \dot{\theta}}}, hold all other variables fixed so x˙\Vel{\dot{x}} and θ\Coord{\theta} act like constants. Then, when you apply ddt\frac{d}{dt} to that result, remember that every coordinate qj(t)\Coord{q_j(t)} and velocity q˙j(t)\Vel{\dot{q}_j(t)} changes with time and needs the product and chain rules.

Key concepts

To find a system's equations of motion with the Lagrangian method, start by counting its degrees of freedom and choosing independent generalized coordinates q1\Coord{q_1}, q2\Coord{q_2}, …\dots that automatically respect the constraints (such as θ\Coord{\theta} for a pendulum on a rigid rod, or x\Coord{x} and θ\Coord{\theta} for a cart and pendulum). Write the total kinetic energy T\Kin{T} and potential energy V\Pot{V} in terms of those coordinates and their time derivatives, using Cartesian positions x(qi)\Coord{x(q_i)}, y(qi)\Coord{y(q_i)} first whenever motions combine (like xbob=x+ℓsin⁡θ\Coord{x_{\text{bob}}} = \Coord{x} + \ell\sin\Coord{\theta}), and form the Lagrangian:

L\displaystyle L =T−V,S\displaystyle = \Kin{T} - \Pot{V}, \qquad \Action{S} =∫tstarttend(T−V) dt\displaystyle = \Action{\int_{t_{\text{start}}}^{t_{\text{end}}}} (\Kin{T} - \Pot{V})\,\Action{dt}

The true path makes the action S\Action{S} stationary (δS=0\Action{\delta S} = 0), which means each coordinate obeys its own Euler-Lagrange equation:

∂L∂qi\displaystyle \Force{\frac{\partial L}{\partial q_i}} =ddt(∂L∂q˙i)\displaystyle = \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{q}_i}}\right)

Before taking time derivatives, check LL for any cyclic coordinate qi\Coord{q_i} that is missing from LL, like x\Coord{x} in the cart-and-pendulum Lagrangian. Because ∂L∂qi=0\Force{\frac{\partial L}{\partial q_i}} = 0, its momentum ∂L∂q˙i\Mom{\frac{\partial L}{\partial \dot{q}_i}} is automatically constant. In the same way, if LL does not depend explicitly on time tt, energy is conserved. Finally, only put conservative forces into V(q)\Pot{V(q)}. Gravity, springs (V=12kx2\Pot{V} = \frac{1}{2}k\Coord{x}^2), and electrostatic forces come from a position-dependent potential (F=−∂V∂q\Force{F} = -\frac{\partial \Pot{V}}{\partial \Coord{q}}) and fit right into L=T−VL = \Kin{T} - \Pot{V}. Friction and air drag oppose velocity q˙\Vel{\dot{q}} and drain energy over a round trip, so they cannot be written as V(q)\Pot{V(q)} and must be added as a non-conservative generalized force Qi\Force{Q_i} beside ∂L∂qi\Force{\frac{\partial L}{\partial q_i}}: ∂L∂qi+Qi\Force{\frac{\partial L}{\partial q_i}} + \Force{Q_i} == ddt(∂L∂q˙i)\frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{q}_i}}\right).

4

Practice

1

A ball of mass m=2 kgm = 2\text{ kg} moves vertically in uniform gravity g=10 m/s2g = 10\text{ m/s}^2, starting at y(0)=0\Coord{y}(0) = 0 and landing back at y(1)=0\Coord{y}(1) = 0 at t=1 st = 1\text{ s}. Consider the family of parabolic trial paths y(t)=At(1−t)\Coord{y(t)} = At(1 - t), where AA is an adjustable parameter. (a) Calculate the integrated kinetic energy ∫01T dt\int_0^1 \Kin{T}\,dt, the integrated potential energy ∫01V dt\int_0^1 \Pot{V}\,dt, and the action S(A)\Action{S(A)} == ∫01(T−V) dt\Action{\int_0^1} (\Kin{T} - \Pot{V})\,\Action{dt} in terms of AA. (b) Find the value of AA where S(A)\Action{S(A)} is stationary, and show that writing A=Atrue+εA = A_{\text{true}} + \varepsilon leaves no linear term in ε\varepsilon in S(A)\Action{S(A)}.

Differentiate y(t)=A(t−t2)\Coord{y(t)} = A(t - t^2) with respect to tt first so you can form T=12my˙2\Kin{T} = \frac{1}{2}m\Vel{\dot{y}^2} before integrating from 00 to 11.

(a) Differentiating y(t)=A(t−t2)\Coord{y(t)} = A(t - t^2) with respect to time gives the velocity:
y˙(t)\displaystyle \Vel{\dot{y}(t)} =A(1−2t)\displaystyle = A(1 - 2t)
With m=2 kgm = 2\text{ kg}, the kinetic energy is T\Kin{T} == 12(2)y˙2\frac{1}{2}(2)\Vel{\dot{y}^2} == A2(1−2t)2A^2(1 - 2t)^2 (watch out for forgetting the 12\frac{1}{2} in 12my˙2\frac{1}{2}m\Vel{\dot{y}^2}, which would double the kinetic integral to 23A2\frac{2}{3}A^2 and halve AtrueA_{\text{true}} to 2.5 m/s22.5\text{ m/s}^2). Integrating from t=0t = 0 to t=1t = 1 gives:
∫01T dt\displaystyle \int_0^1 \Kin{T}\,dt =A2∫01(1−4t+4t2) dt\displaystyle = A^2 \int_0^1 (1 - 4t + 4t^2)\,dt =A2[t−2t2+43t3]01\displaystyle = A^2\left[t - 2t^2 + \frac{4}{3}t^3\right]_0^1 =13A2\displaystyle = \Kin{\frac{1}{3}A^2}
With g=10 m/s2g = 10\text{ m/s}^2, the potential energy is V=mgy=20A(t−t2)\Pot{V} = mg\Coord{y} = 20A(t - t^2), so:
∫01V dt\displaystyle \int_0^1 \Pot{V}\,dt =20A∫01(t−t2) dt\displaystyle = 20A \int_0^1 (t - t^2)\,dt =20A[t22−t33]01\displaystyle = 20A\left[\frac{t^2}{2} - \frac{t^3}{3}\right]_0^1 =103A\displaystyle = \Pot{\frac{10}{3}A}
Subtracting ∫01V dt\int_0^1 \Pot{V}\,dt from ∫01T dt\int_0^1 \Kin{T}\,dt (adding T+V\Kin{T} + \Pot{V} instead of subtracting T−V\Kin{T} - \Pot{V} is a common slip that flips the sign to A=−5 m/s2A = -5\text{ m/s}^2) gives the action:
S(A)\displaystyle \Action{S(A)} =A2−10A3 J⋅s\displaystyle = \frac{A^2 - 10A}{3}\text{ J}\cdot\text{s}
(b) Setting the derivative with respect to AA equal to zero gives the stationary path:
dSdA\displaystyle \frac{d\Action{S}}{dA} =2A−103\displaystyle = \frac{2A - 10}{3} =0  ⟹  Atrue\displaystyle = 0 \implies A_{\text{true}} =5 m/s2\displaystyle = 5\text{ m/s}^2
which matches the true physical trajectory y(t)=5t−5t2 m\Coord{y(t)} = 5t - 5t^2\text{ m}. Substituting A=5+εA = 5 + \varepsilon into S(A)\Action{S(A)} gives:
S(5+ε)\displaystyle \Action{S(5 + \varepsilon)} =(5+ε)2−10(5+ε)3\displaystyle = \frac{(5 + \varepsilon)^2 - 10(5 + \varepsilon)}{3} =(25+10ε+ε2)−(50+10ε)3\displaystyle = \frac{(25 + 10\varepsilon + \varepsilon^2) - (50 + 10\varepsilon)}{3} =−25+ε23 J⋅s\displaystyle = \frac{-25 + \varepsilon^2}{3}\text{ J}\cdot\text{s}
The +10ε+10\varepsilon and −10ε-10\varepsilon terms cancel completely, confirming that the action is stationary to first order at the true path.
2

A bead slides along a rigid wire bent into a curved vertical loop. (a) When the wire is frictionless and the bead's position is described by its arc length s\Coord{s} along the wire, explain why the normal force of the wire never appears in the Euler-Lagrange equation for s\Coord{s}. (b) If the wire is rough and exerts kinetic friction on the bead, explain why you cannot account for friction by adding a friction potential energy term Vfriction(s)\Pot{V_{\text{friction}}}(\Coord{s}) to L=T−VL = \Kin{T} - \Pot{V}.

Think about the direction of a small allowed nudge δs\Coord{\delta s} compared to the normal force in part (a), and what happens to the work done over a round trip from AA to BB and back to AA in part (b).

(a) Because the generalized coordinate s\Coord{s} measures distance along the wire, every trial path s(t)\Coord{s(t)} automatically satisfies the constraint of staying on the wire, and any small allowed nudge δs\Coord{\delta s} points tangent to the wire. The normal force from the wire acts perpendicular to the wire at every point, so it does zero work during any allowed displacement δs\Coord{\delta s} and therefore never changes the energy along the path or enters L=T−VL = \Kin{T} - \Pot{V}.
(b) A potential energy V(s)\Pot{V}(\Coord{s}) depends only on position s\Coord{s}, which means a force derived from it (F=−∂V∂s\Force{F} = -\frac{\partial \Pot{V}}{\partial \Coord{s}}) has a single fixed direction at each point s\Coord{s} and does zero net work over any round trip from AA to BB and back to AA. (A common slip is to try writing Vfriction(s)\Pot{V_{\text{friction}}}(\Coord{s}) == fks\Force{f_k} \Coord{s}, which would give a constant force −∂V∂s=−fk-\frac{\partial \Pot{V}}{\partial \Coord{s}} = \Force{-f_k} that pushes toward decreasing s\Coord{s} even when the bead is moving in the −s\Coord{-s} direction!) Kinetic friction always opposes the velocity s˙\Vel{\dot{s}}, reversing direction whenever the bead turns around and draining mechanical energy on both legs of a round trip. Because the work done depends on the path taken rather than position alone, friction cannot be written as V(s)\Pot{V}(\Coord{s}) and must enter as a non-conservative generalized force Qs\Force{Q_s} added to ∂L∂s\Force{\frac{\partial L}{\partial s}} in the Euler-Lagrange equation: ∂L∂s+Qs\Force{\frac{\partial L}{\partial s}} + \Force{Q_s} == ddt(∂L∂s˙)\frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{s}}}\right).
3

A block of mass mm attached to a horizontal spring of spring constant kk (with potential energy V(x)=12kx2\Pot{V}(\Coord{x}) = \frac{1}{2}k\Coord{x}^2) slides on a frictionless surface, where x\Coord{x} is the displacement from equilibrium. Write the Lagrangian L(x,x˙)L(\Coord{x}, \Vel{\dot{x}}), evaluate ∂L∂x\frac{\partial L}{\partial x} and ∂L∂x˙\frac{\partial L}{\partial \dot{x}}, state the physical meaning of each partial derivative, and use the Euler-Lagrange equation to obtain the equation of motion.

Write T\Kin{T} and V\Pot{V} first, and watch the minus sign between them in L=T−VL = \Kin{T} - \Pot{V} before taking ∂L∂x\frac{\partial L}{\partial x}.

With kinetic energy T=12mx˙2\Kin{T} = \frac{1}{2}m\Vel{\dot{x}^2} and spring potential energy V=12kx2\Pot{V} = \frac{1}{2}k\Coord{x}^2, the Lagrangian is:
L(x,x˙)\displaystyle L(\Coord{x}, \Vel{\dot{x}}) =T−V\displaystyle = \Kin{T} - \Pot{V} =12mx˙2−12kx2\displaystyle = \frac{1}{2}m\Vel{\dot{x}^2} - \frac{1}{2}k\Coord{x}^2
(Be careful not to write L=T+VL = \Kin{T} + \Pot{V}, which is total energy; using a plus sign gives ∂L∂x=+kx\Force{\frac{\partial L}{\partial x}} = +k\Coord{x} and leads to the runaway equation mx¨−kx=0m\Acc{\ddot{x}} - k\Coord{x} = 0.)
Holding x˙\Vel{\dot{x}} fixed gives the partial derivative with respect to position:
∂L∂x\displaystyle \Force{\frac{\partial L}{\partial x}} =−kx\displaystyle = -k\Coord{x}
which is the restoring spring force on the block.
Holding x\Coord{x} fixed gives the partial derivative with respect to velocity:
∂L∂x˙\displaystyle \Mom{\frac{\partial L}{\partial \dot{x}}} =mx˙\displaystyle = m\Vel{\dot{x}}
which is the block's linear momentum.
Setting ∂L∂x=ddt(∂L∂x˙)\Force{\frac{\partial L}{\partial x}} = \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{x}}}\right) gives the equation of motion:
−kx\displaystyle -k\Coord{x} =ddt(mx˙)\displaystyle = \frac{d}{dt}(m\Vel{\dot{x}}) =mx¨  ⟹  mx¨+kx\displaystyle = m\Acc{\ddot{x}} \implies m\Acc{\ddot{x}} + k\Coord{x} =0\displaystyle = 0
4

A puck of mass mm slides on a frictionless horizontal table while attached to a central spring anchored at the origin with potential energy V(r)=12kr2\Pot{V}(\Coord{r}) = \frac{1}{2}k\Coord{r}^2. In plane polar coordinates (r,θ)(\Coord{r}, \Coord{\theta}), the puck's Cartesian coordinates are x=rcos⁡θ\Coord{x} = \Coord{r}\cos\Coord{\theta} and y=rsin⁡θ\Coord{y} = \Coord{r}\sin\Coord{\theta}. (a) Differentiate x(t)\Coord{x(t)} and y(t)\Coord{y(t)} with respect to time to find v2=x˙2+y˙2\Vel{v^2} = \Vel{\dot{x}^2} + \Vel{\dot{y}^2} and write the Lagrangian L(r,θ,r˙,θ˙)L(\Coord{r}, \Coord{\theta}, \Vel{\dot{r}}, \Vel{\dot{\theta}}). (b) Identify the cyclic coordinate in LL, use its Euler-Lagrange equation to find the conserved quantity, and explain what physical quantity and symmetry it represents.

Both r(t)\Coord{r(t)} and θ(t)\Coord{\theta(t)} vary with time, so use the product rule when differentiating x=rcos⁡θ\Coord{x} = \Coord{r}\cos\Coord{\theta} and y=rsin⁡θ\Coord{y} = \Coord{r}\sin\Coord{\theta}.

(a) Applying the product and chain rules to x(t)\Coord{x(t)} == r(t)cos⁡θ(t)\Coord{r(t)}\cos\Coord{\theta(t)} and y(t)\Coord{y(t)} == r(t)sin⁡θ(t)\Coord{r(t)}\sin\Coord{\theta(t)} gives:
x˙=r˙cos⁡θ−rθ˙sin⁡θy˙=r˙sin⁡θ+rθ˙cos⁡θ\displaystyle \begin{aligned} \Vel{\dot{x}} &= \Vel{\dot{r}}\cos\Coord{\theta} - \Coord{r}\Vel{\dot{\theta}}\sin\Coord{\theta} \\ \Vel{\dot{y}} &= \Vel{\dot{r}}\sin\Coord{\theta} + \Coord{r}\Vel{\dot{\theta}}\cos\Coord{\theta} \end{aligned}
Squaring and adding the components, the cross terms ∓2rr˙θ˙sin⁡θcos⁡θ\mp 2\Coord{r}\Vel{\dot{r}}\Vel{\dot{\theta}}\sin\Coord{\theta}\cos\Coord{\theta} cancel out:
v2=x˙2+y˙2=(r˙cos⁡θ−rθ˙sin⁡θ)2+(r˙sin⁡θ+rθ˙cos⁡θ)2=r˙2(cos⁡2θ+sin⁡2θ)+r2θ˙2(sin⁡2θ+cos⁡2θ)=r˙2+r2θ˙2\displaystyle \begin{aligned} \Vel{v^2} = \Vel{\dot{x}^2} + \Vel{\dot{y}^2} &= (\Vel{\dot{r}}\cos\Coord{\theta} - \Coord{r}\Vel{\dot{\theta}}\sin\Coord{\theta})^2 + (\Vel{\dot{r}}\sin\Coord{\theta} + \Coord{r}\Vel{\dot{\theta}}\cos\Coord{\theta})^2 \\ &= \Vel{\dot{r}^2}(\cos^2\Coord{\theta} + \sin^2\Coord{\theta}) + \Coord{r}^2\Vel{\dot{\theta}^2}(\sin^2\Coord{\theta} + \cos^2\Coord{\theta}) \\ &= \Vel{\dot{r}^2} + \Coord{r}^2\Vel{\dot{\theta}^2} \end{aligned}
(A common slip is writing v2=r˙2+θ˙2\Vel{v^2} = \Vel{\dot{r}^2} + \Vel{\dot{\theta}^2} without the r2\Coord{r}^2 factor on θ˙2\Vel{\dot{\theta}^2}, which has the wrong dimensions and misses the r\Coord{r} dependence of the angular kinetic energy.) With T\Kin{T} == 12m(r˙2+r2θ˙2)\frac{1}{2}m(\Vel{\dot{r}^2} + \Coord{r}^2\Vel{\dot{\theta}^2}) and V=12kr2\Pot{V} = \frac{1}{2}k\Coord{r}^2, the Lagrangian is:
L\displaystyle L =T−V\displaystyle = \Kin{T} - \Pot{V} =12mr˙2+12mr2θ˙2−12kr2\displaystyle = \frac{1}{2}m\Vel{\dot{r}^2} + \frac{1}{2}m\Coord{r}^2\Vel{\dot{\theta}^2} - \frac{1}{2}k\Coord{r}^2
(b) The angle θ\Coord{\theta} does not appear explicitly in LL, so θ\Coord{\theta} is a cyclic coordinate with ∂L∂θ=0\Force{\frac{\partial L}{\partial \theta}} = 0. Its Euler-Lagrange equation gives:
ddt(∂L∂θ˙)\displaystyle \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right) =∂L∂θ\displaystyle = \Force{\frac{\partial L}{\partial \theta}} =0  ⟹  ∂L∂θ˙\displaystyle = 0 \implies \Mom{\frac{\partial L}{\partial \dot{\theta}}} =mr2θ˙\displaystyle = m\Coord{r}^2\Vel{\dot{\theta}} =constant\displaystyle = \Mom{\text{constant}}
Physically, mr2θ˙m\Coord{r}^2\Vel{\dot{\theta}} is the puck's angular momentum about the origin, which is conserved because the central spring potential V(r)=12kr2\Pot{V}(\Coord{r}) = \frac{1}{2}k\Coord{r}^2 is rotationally symmetric: rotating the entire system through any angle about the origin leaves the Lagrangian unchanged.
5

A cart of mass MM slides along a frictionless vertical track (upward vertical coordinate y\Coord{y}) while attached to a vertical spring of potential energy 12ky2\frac{1}{2}k\Coord{y}^2. A pendulum of mass mm and length ℓ\ell (angle θ\Coord{\theta} from the downward vertical) hangs from a pivot on the cart, so the bob has coordinates xbob=ℓsin⁡θ\Coord{x_{\text{bob}}} = \ell\sin\Coord{\theta} and ybob=y−ℓcos⁡θ\Coord{y_{\text{bob}}} = \Coord{y} - \ell\cos\Coord{\theta}. In uniform gravity gg, the Lagrangian of the system is

L=12(M+m)y˙2+mℓy˙θ˙sin⁡θ+12mℓ2θ˙2−12ky2−(M+m)gy+mgℓcos⁡θ\displaystyle \begin{aligned} &L = \frac{1}{2}(M + m)\Vel{\dot{y}^2} \\ &\quad + m\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\sin\Coord{\theta} \\ &\quad + \frac{1}{2}m\ell^2\Vel{\dot{\theta}^2} \\ &\quad - \frac{1}{2}k\Coord{y}^2 - (M + m)g\Coord{y} \\ &\quad + mg\ell\cos\Coord{\theta} \end{aligned}

Derive the coupled Euler-Lagrange equations of motion for θ(t)\Coord{\theta(t)} and y(t)\Coord{y(t)}, showing each partial derivative and total time derivative clearly.

In the cross term mℓy˙θ˙sin⁡θm\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\sin\Coord{\theta}, remember that both y˙(t)\Vel{\dot{y}(t)} and θ(t)\Coord{\theta(t)} change with time when you apply ddt\frac{d}{dt} to ∂L∂θ˙\Mom{\frac{\partial L}{\partial \dot{\theta}}} and ∂L∂y˙\Mom{\frac{\partial L}{\partial \dot{y}}}.

Equation for θ(t)\Coord{\theta(t)}: Holding y\Coord{y}, y˙\Vel{\dot{y}}, θ˙\Vel{\dot{\theta}} fixed, differentiate LL with respect to θ\Coord{\theta}:
∂L∂θ\displaystyle \Force{\frac{\partial L}{\partial \theta}} =mℓy˙θ˙cos⁡θ−mgℓsin⁡θ\displaystyle = m\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\cos\Coord{\theta} - mg\ell\sin\Coord{\theta}
Holding y\Coord{y}, θ\Coord{\theta}, y˙\Vel{\dot{y}} fixed, differentiate LL with respect to θ˙\Vel{\dot{\theta}}:
∂L∂θ˙\displaystyle \Mom{\frac{\partial L}{\partial \dot{\theta}}} =mℓy˙sin⁡θ+mℓ2θ˙\displaystyle = m\ell\Vel{\dot{y}}\sin\Coord{\theta} + m\ell^2\Vel{\dot{\theta}}
Now take the total time derivative ddt(∂L∂θ˙)\frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right) along the trajectory using the product and chain rules on mℓy˙(t)sin⁡θ(t)m\ell\Vel{\dot{y}(t)}\sin\Coord{\theta(t)} (forgetting to differentiate sin⁡θ(t)\sin\Coord{\theta(t)} here is a common slip: it drops the +mℓy˙θ˙cos⁡θ+m\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\cos\Coord{\theta} term so it fails to cancel with ∂L∂θ\Force{\frac{\partial L}{\partial \theta}}):
ddt(∂L∂θ˙)\displaystyle \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right) =mℓy¨sin⁡θ+mℓy˙θ˙cos⁡θ+mℓ2θ¨\displaystyle = m\ell\Acc{\ddot{y}}\sin\Coord{\theta} + m\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\cos\Coord{\theta} + m\ell^2\Acc{\ddot{\theta}}
Setting ∂L∂θ=ddt(∂L∂θ˙)\Force{\frac{\partial L}{\partial \theta}} = \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{\theta}}}\right), canceling mℓy˙θ˙cos⁡θm\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\cos\Coord{\theta} from both sides, and dividing by mℓm\ell gives:
mℓy˙θ˙cos⁡θ−mgℓsin⁡θ=mℓy¨sin⁡θ+mℓy˙θ˙cos⁡θ+mℓ2θ¨ℓθ¨+(g+y¨)sin⁡θ=0\displaystyle \begin{aligned} m\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\cos\Coord{\theta} - mg\ell\sin\Coord{\theta} &= m\ell\Acc{\ddot{y}}\sin\Coord{\theta} + m\ell\Vel{\dot{y}}\Vel{\dot{\theta}}\cos\Coord{\theta} + m\ell^2\Acc{\ddot{\theta}} \\[4pt] \ell\Acc{\ddot{\theta}} + \Acc{(g + \ddot{y})}\sin\Coord{\theta} &= 0 \end{aligned}
Equation for y(t)\Coord{y(t)}Holding θ,y˙,θ˙\Coord{\theta}, \Vel{\dot{y}}, \Vel{\dot{\theta}} fixed, differentiate LL with respect to y\Coord{y}:
∂L∂y\displaystyle \Force{\frac{\partial L}{\partial y}} =−ky−(M+m)g\displaystyle = -k\Coord{y} - (M + m)g
Holding y\Coord{y}, θ\Coord{\theta}, θ˙\Vel{\dot{\theta}} fixed, differentiate LL with respect to y˙\Vel{\dot{y}}:
∂L∂y˙\displaystyle \Mom{\frac{\partial L}{\partial \dot{y}}} =(M+m)y˙+mℓθ˙sin⁡θ\displaystyle = (M + m)\Vel{\dot{y}} + m\ell\Vel{\dot{\theta}}\sin\Coord{\theta}
Take the total time derivative ddt(∂L∂y˙)\frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{y}}}\right) using the product and chain rules on mℓθ˙(t)sin⁡θ(t)m\ell\Vel{\dot{\theta}(t)}\sin\Coord{\theta(t)} (watch out for treating sin⁡θ\sin\Coord{\theta} as constant here, which would miss the centripetal term +mℓθ˙2cos⁡θ+m\ell\Vel{\dot{\theta}^2}\cos\Coord{\theta}):
ddt(∂L∂y˙)\displaystyle \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{y}}}\right) =(M+m)y¨+mℓθ¨sin⁡θ+mℓθ˙2cos⁡θ\displaystyle = (M + m)\Acc{\ddot{y}} + m\ell\Acc{\ddot{\theta}}\sin\Coord{\theta} + m\ell\Vel{\dot{\theta}^2}\cos\Coord{\theta}
Setting ∂L∂y=ddt(∂L∂y˙)\Force{\frac{\partial L}{\partial y}} = \frac{d}{dt}\left(\Mom{\frac{\partial L}{\partial \dot{y}}}\right) and moving all terms to one side gives the second coupled equation:
(M+m)y¨+mℓθ¨sin⁡θ+mℓθ˙2cos⁡θ+ky+(M+m)g=0\displaystyle \begin{aligned} &(M + m)\Acc{\ddot{y}} + m\ell\Acc{\ddot{\theta}}\sin\Coord{\theta} + m\ell\Vel{\dot{\theta}^2}\cos\Coord{\theta} \\ &\quad + k\Coord{y} + (M + m)g = 0 \end{aligned}