Professional Documents
Culture Documents
6 Lag Rang I An Dynamics
6 Lag Rang I An Dynamics
Lagrangian Dynamics
Having completed our mathematical foundation, we are ready to greatly
extend your abilities in classical mechanics. Newtons equation F = p may
oer the correct description of an object (or a system of objects), however,
in some cases it provides a rather complicated formalism. The formalism
is particularly complicated when there are restrictions or constraints to the
motion of objects. For example when a particle moves in a groove, that may
be of irregular shape, Newtons formalism would require writing expressions
for the forces that conne the particle to the groove. It can be challenging
to nd expressions for such forces (which will vary in time, with the position
of the particle).
In Lagrangian mechanics, we will work with an alternative formalism
based on independent generalized coordinates that completely characterize
the possible motion of the particle. These can greatly simplify problems as
one no longer needs a detailed knowledge of all constraint forces acting in
a system before calculating the dynamics. Lagrangian mechanics is based
on Hamiltons principle, which formulates classical mechanics in a way that
we can apply the calculus of variations in the form of the Euler-Lagrange
equations. Having introduced this formalism, we will consider several problems that would be very dicult with Newtons approach, such as double
pendulums and systems of coupled objects.
6.1
Generalized coordinates
choose x and y as coordinates. Or, we could choose the polar and azimuthal
angles and as generalized coordinates to completely describe the particle
position. Note that generalized coordinates are not unique; we have some
choice with some choices being more convenient than others.
For now we will consider only cases where ng = nf nk . Later we will
consider how to work with any remaining constraints among the chosen q1 ,
. . ., qn .
Generalized coordinates may have units of length, or angle or something
completely dierent! For example, we will see that in the theory of small
oscillations, the generalized coordinates are conventionally chosen to have
units of mass length. Importantly, once a choice of generalized coordinates has been made, with a set of units, the units of the generalized
momentum and force are related as:
{pj } =
mass length2 1
time
{qj }
(6.1)
{Fj } =
mass length2 1
{qj }
time2
(6.2)
6.2
Hamiltons Principle
much wider range of physical phenomena, for example in quantum mechanics, electromagnetism and relativity. Hamiltons principle gives a formalism
equivalent to Newtons equations of motion for classical mechanics problems.
Setting S = 0 allows us to apply the Euler-Lagrange equations:
(
)
L
d L
=
(6.5)
dt qj
qj
Note that the quantity L/ qj = pj can be identied as the generalized
momentum and L/qj = Fj , on the right, is the generalized force. The
above equation is equivalent to Newtons second law, p j = Fj . However,
let us recall that qj is a generalized coordinate, so pj does not necessarily
have units of momentum and neither should Fj necessarily have units of
force. For example, if the generalized coordinate is an angle, , then the
corresponding generalized momentum is the angular momentum about the
axis of and the generalized force is the torque.
6.2.1
(6.6)
where G (q, t) is any function of the generalized coordinates and time. The
dierence in the action for this Lagrangian and the original Lagrangian,
L (q, q,
t), is:
t2
d
S [q(t)] S [q(t)] =
G(q, t)dt = G(q(t2 ), t2 ) G(q(t1 ), t1 )
(6.7)
dt
t1
That is, the dierence only depends on the end-point values of the path
q(t). When minimizing S over the paths q(t) there can be no variation in
the paths at the end-points (q(t1 ) = 0 and q(t2 ) = 0), so S and S are
minimized by the same path. Thus the equations of motion are invariant
under a shift that can be written as dG(q, t)/dt.
(q, q,
This can also be seen by substituting L
t) into the Euler-Lagrange
equation:
(
)
(
)
d L
d
dG
L
dG
+
=
+
(6.8)
dt qj
dt qj dt
qj
qj dt
(
)
d L
d dqj dG
L
dG
+
=
+
(6.9)
dt qj
dt dqj qj dt
qj
qj dt
where the terms involving dG/dt cancel.
54
6.2.2
mV t mV.x = L +
(6.11)
L = m (v V) = mv +
2
2
dt 2
dt
For a system of N interacting particles,
1
L=
mn v n2 U ({xn }, {xn })
2
N
(6.12)
n=1
U=
U1 (xn ) +
U2 (xn xn )
(6.13)
n
n<n
However, it should be noted that velocity-dependent potentials can appear in the case of charged particles interacting with electromagnetic elds.
6.3
Conserved quantities
6.3.1
Momentum Conservation
If the Lagrangian does not depend on one or more of the generalized coordinates, we have:
L
Fj =
=0
(6.15)
qj
The Euler-Lagrange equations then give pj = Fj , that is, the generalized
momentum pj is conserved.
As an example, we can consider the motion of a particle in a uniform
gravitational eld, such as near the surface of the Earth. Let (x, y) be
coordinates parallel to the surface and let z be the height. The kinetic and
potential energy are:
)
1 (
T = m x 2 + y 2 + z 2
2
U = mgz
(6.16)
L
=0
x
Fy =
(6.17)
L
=0
y
(6.18)
L
= my
y
(6.19)
L
= mx
x
py =
Integrating, we obtain:
x(t) = x(0) +
px
t
m
y(t) = y(0) +
py
t
m
(6.20)
Now, let us consider the motion in the z direction. In this case the Lagrangian does depend on z so the momentum pz is not conserved, but instead
given by:
( )
d L
L
d
(pz ) =
=
(6.21)
dt
dt z
z
pz = m
z = mg = Fz
(6.22)
Integrating:
z(t)
= z(0)
gt
(6.23)
1
z(t) = z(0) + z(0)t
gt2
2
(6.24)
56
6.3.2
Energy Conservation
Next, let us consider the case when the Lagrangian does not depend on time.
Consider the function:
t) =
H(q, q,
t)
pj qj L(q, q,
(6.27)
j=1
dH
L
L
L
=
pj qj + pj qj
qj
qj
dt
qj
qj
t
(6.28)
j=1
Note that pj = L/ qj and along the path of motion of the system the
Euler-Lagrange equations give pj = L/qj . Hence the term in brackets
vanishes and we are left with:
dH
L
=
dt
t
(6.29)
1
j=1
mj r 2j U (r1 , . . . , rn )
(6.30)
1
j=1
mj r j + U (r1 , . . . , rn ) = T + U
(6.31)
That is, H is the total energy of the system. Note, however, that it is not
always the case that H = T + U .
57
6.4
Coordinate Systems
(6.32)
(
)
If the motion is conned to a plane, one can use T = 12 m x 2 + y 2 .
Cylindrical coordinates
In cylindrical coordinates (, , z), is the radial coordinate in the (x, y)
plane, z is the height above the (x, y) plane, and is the azimuthal angle:
x = cos
y = sin
x = cos sin
y = sin + cos
(6.33)
(6.34)
(6.35)
(
)
Again, if the motion is conned to a plane, one can use T = 12 m 2 + 2 2 .
Spherical coordinates
In spherical coordinates (r, , ), r is the radius, is the polar angle, and
is the azimuthal angle. On the globe, one conventionally chooses = 0 to
correspond to the North pole, and = /2 to correspond to points on the
equator. In spherical polar coordinates:
y = r sin sin
z = r cos
z = r cos r sin
x = r sin cos
58
(6.36)
6.5
(6.37)
Examples
Now let us consider some example problems, to demonstrate how the Lagrangian formulation of classical mechanics can be used. Let us rst recall
the recipe for solving mechanics problems with this method:
1. Choose a convenient set of generalized coordinates, {q1 , . . . , qn }.
2. Find the kinetic energy T (q, q,
t), the potential energy U (q, q,
t) and
the Lagrangian L(q, q,
t) = T U .
3. Find the generalized momenta pj = L/ qj and the generalized forces
Fj = L/qj .
4. Use the Euler-Lagrange equations to write the equations of motion.
5. Identify any conserved quantities.
6.5.1
One-dimensional motion
L
= mx
x
(6.39)
m
x = U (x)
(6.40)
(6.41)
which is nothing other than the statement F = ma, where a is the acceleration.
The Lagrangian does not explicitly depend on t, so the quantity H should
be conserved:
1
H = px L = mx 2 + U (x)
(6.42)
2
59
(
)
0 = x m
x + U (x)
(6.43)
(
)
dx
dx
dt dU (x)
=
m
+
(6.44)
dt
dt
dx dt
(
)
d 1
2
mx + U (x)
(6.45)
=
dt 2
6.5.2
Let us now consider a particle moving in two dimensions subject toa potential U (), which depends only on the distance from the origin = x2 + y 2
In cylindrical coordinates, the Lagrangian is:
)
1 (
L = m 2 + 2 2 U ()
(6.46)
2
The Euler-Lagrange equations give the equations of motion:
( )
d L
L
=
m
= m 2 U ()
(6.47)
dt p
( )
L
d ( 2 )
d L
=
m = 0
(6.48)
dt
dt
Note that the angular momentum is conserved:
p = m2
(6.49)
This relation allows the elimination of from the rst Euler-Lagrange equation, leaving:
p2
m
=
U ()
(6.50)
m3
We can expect the quantity H to be conserved, due to time independence
of the Lagrangian:
H = p + p L(, )
(6.51)
L
L
+
L(, )
)
1 (
= m 2 + m2 2 m 2 + 2 2 + U ()
2
=T +U
=
(6.52)
(6.53)
(6.54)
That is, the total energy H is conserved. Note that the total energy can
also be written:
)
1 (
H = m 2 + 2 2 + U ()
(6.55)
2
p2
1
= m 2 +
+ U ()
(6.56)
2
2m2
60
= m
+ U () = 0
dt
m3
6.5.3
(6.57)
m
M
0
0
X
x
(6.60)
)
1
1 (
(M + m) X 2 + mX x + m 1 + tan2 x 2 mgx tan
2
2
(6.61)
61
(M + m) X
x=0
(6.62)
dt X
X
( )
(
)
d L
L
+ m 1 + tan2 x
=
MX
= mg tan (6.63)
dt x
x
The rst equation gives:
m
x
M +m
Substituting into the second equation gives:
=
X
(6.64)
(M + m) g sin cos
M + m sin2
(6.65)
x
=
and
= mg sin cos
X
(6.66)
M + m sin2
That is, both objects travel with constant acceleration, which can be expected since the gravitational force that drives the system is constant.
6.5.4
(6.67)
x2 = l1 sin 1 + l2 sin 2
(6.68)
y2 = l1 cos 1 l2 cos 2
(6.69)
x 2 = l1 1 cos 1 + l2 2 cos 2
y 2 = l1 1 sin 1 + l2 2 sin 2
62
(6.70)
(6.71)
L1
1
m1
L2
m2
Figure 6.2: The double pendulum.
We can now re-write the kinetic and potential energies in the chosen generalized coordinates:
(
)
1
1
T = m1 l12 12 + m2 l12 12 + 2l1 l2 (cos 1 cos 2 + sin 1 sin 2 ) 1 2 + l22 22
2
2
U = m1 gl1 cos 1 m2 gl1 cos 1 m2 gl2 cos 2
(6.72)
Noting the trigonometric identity cos 1 cos 2 + sin 1 sin 2 = cos (1 2 ),
the Lagrangian can be written:
L=T U =
1
1
(m1 + m2 ) l12 12 + m2 l1 l2 cos (1 2 ) 1 2 + m2 l22 22
2
2
+ (m1 + m2 ) gl1 cos 1 + m2 gl2 cos 2
(6.73)
1
L
p2 =
= m2 l1 l2 cos (1 2 ) 1 + m2 l22 2
2
p1 =
63
(6.74)
(6.75)
L
= m2 l1 l2 sin (1 2 ) 1 2 (m1 + m2 ) gl1 sin 1
1
(6.76)
)
(
p2 = m2 l1 l2 cos (1 2 ) 1 m2 l1 l2 sin (1 2 ) 1 2 1 + m2 l22 2
L
= m2 l1 l2 sin (1 2 ) 1 2 m2 gl2 sin 2
2
(6.77)
Re-writing:
l1 1 +
m2 l 2
m2 l 2
cos (1 2 ) 2 +
sin (1 2 ) 22 + g sin 1 = 0
(m1 + m2 )
(m1 + m2 )
(6.78)
l1 cos (1 2 ) 1 l1 sin (1 2 ) 2 + l2 2 + g sin 2 = 0
1
(6.79)
An analytical solution to the equations can be obtained in the limit of small
oscillations, where: cos 1,2 1, sin 1,2 1,2 and we neglect terms of
higher than rst order in 1 and 2
1 + 2 + 02 1 = 0
1 + 2 + 02 2 = 0
(6.80)
(6.81)
m2
m1 + m2
l2
l1
02 =
g
l1
(6.82)
(6.83)
where a and b are constant amplitudes. The equations of motion can then
be written in matrix form:
)( )
(
a
2 + 02
2
=0
(6.84)
b
2
2 + 02
For oscillations of non-zero amplitude, the determinant of the above matrix
vanishes. This gives a quadratic equation in 2 :
( 2
)(
)
02 2 02 4 = 0
(6.85)
64
02 (1 + ) 02
(1 )2 + 4
2 (1 )
(6.86)
That is, there are two normal mode solutions, corresponding to two possible
oscillation frequencies. Let us consider the case of equal pendulums with
l1 = l2 and m1 = m2 . In this case = 1/2 and = 1. The mode energies
are given by:
(
)
2 = 02 2 2
(6.87)
Substitution back into the matrix equation gives:
)
) )( )
(
( (
a
2( 2 +
1 ( 12 2
)2
2
)
0
=0
b
2 2
2 2 +1
(6.88)
1 2
a
=
b
2 2
(6.89)
with the + sign corresponding to the higher frequency mode. Thus the
two modes correspond to cases where the pendulums oscillate in and out of
phase. The in-phase case corresponds to the lowest frequency.
6.6
Constraints
(6.90)
In this( particular
example we could solve the above equation and substitute
)
R
2 = 1 + a 1 . However, in other cases it may not be straightforward to
solve the equation representing the constraint. In the rest of this section,
well consider how constraints can be handled in the Lagrangian formalism.
65
a( 2 - 1)
2
R 1
Figure 6.3: One cylinder rolling o another. When there is no slipping, the
angles 1 and 2 are constrained by Eq. 6.90.
6.6.1
Holonomic Constraints
(6.92)
We treat like new coordinates and consequently we can apply the EulerLagrange equations:
(
)
d L
L
=0
(6.93)
dt
(6.94)
That is, the use of Lagrange multipliers acting as eective coordinates encodes the constraints into the problem. Meanwhile, the Euler-Lagrange
equations for q are:
(
)
d L
L
=0
(6.95)
dt q
q
( )
L
f
d L
=
(6.96)
dt q
q
q
The left-hand side is the equation of motion for the unconstrained problem.
The right-hand side contains the eect of the constraint forces in the system.
66
6.6.2
Let us return to the example of one cylinder rolling of another. There are two
constraints in the system. First, we have the constraint that the cylinders
are in contact:
f1 = r R a = 0
(6.97)
Second, there is the no slipping constraint:
f2 = R1 a (2 1 ) = 0
The Lagrangian can be written:
) 1
1 (
L = T U = M r 2 + r2 12 + I 22 M gr cos 1
2
2
(6.98)
(6.99)
where M is the mass of the rolling cylinder. The kinetic energy contains
a contribution from both the center-of-mass movement of the cylinder and
the rotation about the center-of-mass. I is a constant representing the rotational inertia.
To account for the constraints, let us introduce Lagrange multiplies 1
and 2 . The shifted Lagrangian is:
L = L + 1 f1 + 2 f2
(6.100)
= M r M r12 + M g cos 1 1 = 0
dt r
r
(
)
d L
L
= M r2 1 + 2M rr 1 M gr sin 1 2 (R + a) = 0
dt 1
1
(
)
d L
L
= I 2 + 2 a = 0
(6.101)
dt 2
2
Let us now implement the constraints, which give r = (R + a) a constant,
(6.102)
(6.103)
(6.104)
(6.105)
(6.106)
(6.108)
where we have dened = I/(M a2 ). Note that is a dimensionless parameter and 0 1. Now, substitution into Eq. 6.102 yields:
)
Mg (
(0)
(3 + ) cos 1 2 cos 1
= 1
1+
(6.109)
(f )
1
1 = cos1
(6.110)
3+
(f )
68