Euler.lagrange 1
Euler.lagrange 1
So far we have kept L(q, q̇) unspecified. How should we choose the Lagrangian in order
to reproduce the classical equations of motion? Ultimately, this needs to be decided by
experiment, but in problems in classical mechanics there is a very simple prescription, that
I will now state. Consider a system with kinetic energy T (q, q̇) and potential energy V (q).
Then the Lagrangian that leads to the right equations of motion is
L=T −V
Let us see that this gives the right equations of motion in the simple case of a particle
moving in three dimensions. The configuration space is R3 , and if we choose Cartesian
coordinates xi (that is, we choose qi = xi ) we have
1
T = m(ẋ21 + ẋ22 + ẋ23 )
2
and V = V (x1 , x2 , x3 ). Note, in particular, that T depends only on ẋi , and V depends
on xi only. We have three degrees of freedom, so we have three Euler-Lagrange equations,
given by
∂L d ∂L
0= −
∂xi dt ∂ ẋi
∂V d
=− − m (ẋi )
∂xi dt
∂V
=− − mẍi
∂xi
where we have used that ∂∂Vẋi = 0 and ∂x
∂T
i
= 0, since xi and ẋi are independent variables in
the Lagrangian formalism, as we explained above. We can rewrite the equations above in
vector notation as
d2 ⃗
m 2 (⃗x) = −∇V
dt
which is precisely Newton’s second law for a conservative force F⃗ = −∇V ⃗ .
Example 2.3.1. The simplest example of the discussion so far is the free particle of mass
m moving in d dimensions. Its configuration space is Rd , which we can parametrize using
Cartesian coordinates xi . In these coordinates the kinetic energy is given by
d
1 X 2
T = m ẋ
2 i=1 i
and the potential energy V vanishes. This gives a Lagrangian
d
1 X 2
L=T −V = m ẋ
2 i=1 i
2.3 LAGRANGIANS FOR CLASSICAL MECHANICS 17
mẍi = 0 ∀i ∈ {1, . . . , d} .
These equations are solved by the particle moving at constant speed, xi = vi t + bi , with vi , bi
constants.
Example 2.3.2. Our second example will be a pendulum moving under the influence of
gravity. Our conventions will be as in figure 1: we have a mass m attached by a rigid
massless rod of length ℓ to a fixed point at the origin. The pendulum can swing on the (x, y)
plane. The configuration space of the system is S 1 . We choose as a coordinate the angle θ
of the rod with the downward vertical axis from the origin, measured counterclockwise. The
whole system is affected by gravity, which acts downwards.
We now need to compute the kinetic and potential energy in terms of θ. The expression
of the kinetic energy in the (x, y) coordinates is 12 m(ẋ2 + ẏ 2 ). In terms of θ we have
or equivalently
g
θ̈ + sin(θ) = 0 .
ℓ
The exact solution of this system requires using something known as elliptic integrals, but
as a simple check of our solution, note that for small angles sin(θ) ≈ θ, and the Euler-
Lagrange equation reduces to
g
θ̈ + θ = 0
ℓ
p
with solution θ(t) = a sin(ωt) + b cos(ωt), where ω = g/ℓ, and a, b are arbitrary constants
that encode initial conditions. These are the simple oscillatory solutions that one expects
close to θ = 0.
Example 2.3.3. Consider instead a spring with a mass attached to it. The spring is
attached on one end to the origin, but it is otherwise free to rotate on the (x, y) plane,
without friction. In this case we ignore the effect of gravity, and we assume that the spring
has vanishing natural length, and constant κ. The configuration is shown in figure 2.
1 1
V = κℓ2 = κ(x2 + y 2 ) .
2 2
Putting everything together, we find that
1 1
L = T − V = m(ẋ2 + ẏ 2 ) − κ(x2 + y 2 ) .
2 2
2.3 LAGRANGIANS FOR CLASSICAL MECHANICS 19
The Euler-Lagrange equations split into independent equations for x and y, given by
κ
ẍ + x = 0,
m
κ
ÿ + y = 0 .
m
The general solution is then simply
x = r cos(θ) ,
y = r sin(θ) .
Taking time derivatives, and using the Chain Rule for time derivatives, we find
ẋ = ṙ cos(θ) − r sin(θ)θ̇ ,
ẏ = ṙ sin(θ) + r cos(θ)θ̇ .
This equation is quite remarkable: it tells us that there is a conserved quantity in this
system, given by mr2 θ̇. This was not obvious at all in the Cartesian formulation of the
problem,9 but it follows immediately in polar coordinates, since the Lagrangian does not
depend on θ, only on θ̇, and accordingly ∂L/∂θ = 0. We can use this knowledge to simplify
the problem. Define
J := mr2 θ̇ .
This is a constant of motion, so on any given classical trajectory it is simply a real num-
ber fixed by initial conditions. We can use this knowledge to simplify the Euler-Lagrange
equation for r, which after replacing θ̇ = J/mr2 becomes an equation purely in terms of r:
2
J2
J
mr̈ − mr + κr = mr̈ − + κr = 0 .
mr2 mr3
9
Once we know that the conserved charged is there, it is not difficult to find its expression in Cartesian
coordinates: we have mr2 θ̇ = m(xẏ − y ẋ).