Lagrange and Hamilton Formulation of Mechanics, Physics tutorial

D'Alembert's Principle:

D'Alembert's Principle: The definition of virtual work was δW = ΣijFij.δri where sum comprises all (constraint and non-constraint) forces. Assuming the position coordinates are in the inertial frame (but not essentially our generalized coordinates), Newton's second law states ΣijFij = Pi sum of all forces applying on the particle provide rate of change of momentum. We may then rewrite δW:

δW = ΣiΣjFij.δri = ΣidP i.δr i

Thus, relation can be written as

ΣijFij(nc)-dP.δr i = 0,...................................Eq.1

Above equation is referred to as D'Alembert's principle. Expression illustrates that rate of change of momentum is determined only by non-constraint forces. In this form, it is not much use, but conclusion that rate of change of momentum is determined only by non-constraint forces is the significant physical statement.

Generalized Equations of Motion:

From Newtonian mechanics that work is associated to kinetic energy, so it is natural to expect

T ≡ Σi1/2midri . dr i = T({qk}, {dqk}, t)

T must be obtained by first writing T in terms of position velocities {ri} and then using definition of position coordinates in terms of generalized coordinates to re-write T as the function of generalized coordinates and velocities.

Recalling D'Alembert's principle, equation can be written as:

ΣiFi→(nc).∂r i /∂qk = fk = d/dt(∂T/∂dqk)-(∂T/∂qk)

This is generalized equation of motion.

The Lagrangian and the Lagrange's Equations:

For conservative non-constraint forces, we can obtain a slightly more compact form of the generalized equation of motion, known as the Euler-Lagrange equations.

Generalized Conservative Forces:

Now let us specialize to non-constraint forces which are conservative; i.e. Fi(nc) = -∇iU({r j }). Where ∇I indicates gradient with respect to r i. Whether constraint forces are conservative is unrelated; we will only explicitly require potential for non-constraint forces. U is supposed to be the function of coordinate positions only; there is no explicit dependence on time or on velocities, ∂U/∂t = 0 and ∂U/∂ri. Let us employ this expression in writing generalized force:

fk = ΣiFi→(nc).∂r i /∂qk = -ΣiiU({r j }).∂r i /∂qk = ∂/∂qkU({q1},t).

We made use of holonomic constraints to re-write U as the function of {ql} and possibly t, and realize that previous line is just partial derivative of U with respect to qk. Therefore, rather than finding the equation of motion by computing generalized force from non-constraint forces and coordinate transformation relations, we can re-write potential energy as the function of generalized coordinates and compute generalized force by gradients thereof.

The Euler-Lagrange Equations:

An even simpler method exists; we may re-write the generalized equation of motion using the above relationship between generalized force and gradient of the potential energy as

∂U/∂qk = d/dt(∂T/∂dqk) - ∂T/∂qk

State the Lagrangian as

L ≡ T - U

As we have assumed holonomic constraints, we have ∂U/∂qk = 0. This permits replacement of d/dt(∂T/∂dqk) with d/dt(∂L/∂dqk) providing

d/dt(∂L/∂dqk) - (∂L/∂qk) = 0

This is Euler-Lagrange equation; there is one for each generalized coordinate qk.

Lagrange's Mechanics:

Newton's Second Law:

We consider N particles moving in three-dimensional space, and we explain location of each particle using Cartesian coordinates. We let mi be mass of particle i, and we let xi, yi, and zi be respectively x, y and z-coordinates of particle i. For time derivatives of coordinates (and all other physical observables), we use dot notation first introduced by Isaac Newton

x.i = dxi/dt and x..i = d2xi/dt2

We let Fxi be x-component of force on particle i. Then, Newton's Second Law takes form Fxi = mxi.

For instance, if we study motion of single particle of mass m moving in one dimension in the harmonic potential with related force Fx = -kx. Newton's second law takes form- kx = mx.

Conservative Systems:

In the qualitative sense conservative systems are those for which total energy E is sum of kinetic and potential energies. For any isolated system E is conserved (i.e. dE/dt = 0), and for conservative systems, sum of potential energy and kinetic energy is conserved. Explicitly, we have following definition:

The classical mechanical system is conservative if there exists the function U(x1, y1, z1, x2,...zn) known as potential energy such that for any coordinate xi(or yi or zi), we can write

Fxi = ∂U/∂xi(or Fyi = ∂U/∂yi or Fzi = ∂U/∂zi)

Where Fxi(or Fyi or Fzi) is x (or y or z) component of force on particle i. As the example, we can consider one dimensional particle moving in harmonic well with force F = -kx. For such a system, potential energy exists and is provided by U(x) = 1/2 kx2 By differentiating potential energy with respect to x, force is attained. We can then be sure that for harmonic oscillator total energy is conserved

E = 1/2 mdx2 + 1/2 kx2

Lagrange's Equations:

Now derive Lagrange's equations for special case of the conservative system in Cartesian coordinates. Start with equation for kinetic energy. We first distinguish expression with respect to one of velocities

∂T/∂xj = mjdxj

Definition: Classical Lagrangian is provided by

L = T - U

Classical Lagrangian is a difference between kinetic and potential energies of system. Using the definition we get

d/dt(∂L/∂xj) - ∂L/∂xj = 0

The equation given above is Lagrange's equations in Cartesian coordinates. We use plural (equations), as Lagrange's equations are the set of equations. We have separate equation for each coordinate xj. A entirely analogous set of equations is attained for other Cartesian directions y and z.

Generalized Coordinates:

Much of Lagrange's work was concerned with methods useful for systems subject to external constraints.

Lagrange's Equations in Generalized Coordinates:

Lagrange has shown that the form of Lagrange's equations is invariant to the particular set of generalized coordinates chosen. For any set of generalized coordinates, Lagrange's equations take the form

(d/dt)(∂L/∂qi) = 0

exactly the same form that we derived in Cartesian coordinates. We now illustrate how to use Lagrange's equations in generalized coordinates by applying the approach to the free motion of a particle confined to move on the perimeter of a ring as discussed previously. The meaning of the expression of "free particle" is the absence of any external forces. We can arbitrarily set the potential energy U to zero. Then, in Cartesian coordinates, the Lagrangian for any free particle in the xy-plane can be expressed as

L = 1/2m(dx2 +d y2)

Because of the constraint, Lagrangian is the function of single coordinate f. We finally give Lagrange's equations

∂L/∂Φ = mR2Φ, and d/dt(∂L/∂Φ) = mR2d2Φ and (∂L/∂Φ)= 0

So therefore

d/dt(∂L/∂Φ) = d/dtmR2dΦ/dt = 0

Equation given above means acceleration of coordinates Φ is zero so that particle moves with the constant generalized velocity Φ.

Generalized Momenta:

Equation can be interpreted to mean that quantity ∂L/∂Φ = mR2Φ is conserved. To fully explore meaning of conservation of a quantity like ∂L/∂Φ, consider the Lagrangian in Cartesian coordinates for the particle of mass in one dimension.

L = 1/2mdx2 - U(x)

By differentiating L with respect to velocity dx, we get linear momentum.

∂L/∂x = mdx

Which is conserved in case of no external forces; that is linear momentum is conserved if U(x) is the constant. Using this simple equation, we are lead to given definition:

Generalized momentum pi conjugate to coordinate qi is stated by

pi = ∂L/∂qi

Lagrangian for Some Physical Systems:

i) 1-D motion-the pendulum:

One of the simplest nonlinear systems is one-dimensional physical pendulum (so called to differentiate it from linearized harmonic oscillator approximation). The pendulum comprises of the light rigid rod of length l, making the angle Θ with vertical, swinging from the fixed pivot at one end and with the bob of mass m attached at the other end. This system is also known as simple pendulum to distinguish it from spherical pendulum and compound pendula that have more than one degree of freedom.

Potential energy with respect to equilibrium position Θ = 0 is U(Θ) = mgl(1- cosΘ ), where g is acceleration due to gravity, and velocity of bob is vΘ = lΘ, So that kinetic energy T= 1/2mvΘ2 = 1/2ml2Θ2

The Lagrangian, L= T - U, is thus

L (Θ, dΘ) = 1/2ml22 - mgl(1 - cosΘ)

This is also effectively the Lagrangian for particle moving in the sinusoidal spatial potential, so physical pendulum gives a paradigm for problems like motion of the electron in the crystal lattice or of the ion or electron in a plasma wave.

Lagrangian equation of motion is

d/dt(∂L/∂Θ) where ∂L/∂Θ = ml2Θ and ∂L/∂Θ = -mglsinΘ

Hence Lagrangian equation of motion is ml2d2Θ/d Θ = -mglsinΘ.

ii) 2-D motion with time-varying constraint:

Consider the weight rotating about origin on the frictionless horizontal surface and constrained by the thread, initially of length a, that is being pulled steadily downward at speed u through the hole at origin so that radius r = a - ut.

The Lagrangian is L = T= 1/2m [u2 + (a -ut)2Θ2]

So we again have conservation of angular momentum m(a -ut)2dΘ = l = constant

This can be integrated to provide Θ as the function of t,

Θ = Θ0 + (l/mu)[1/(a - ut) - 1/a] = Θ0 +lt/[ma(a - ut)]

iii) Atwood Machine:

Consider two weights of mass m1 and m2 suspended from a frictionless, inertia less pulley of radius a by a rope of fixed length. The height of weight 1 is x with respect to the chosen origin and the holonomic constraint given by rope lets us to express height of weight 2 as -x, so that there is only one degree of freedom for this system. Kinetic and potential energy are

T = 1/2(m1 + m2)dx2/dx and U = m1gx - m2gx

Lagrange's equation of motion now becomes

(m1 + m2)d2x/dx = -(m1 - m2)g

d2x/dx = [(m1 - m2)/(m1 + m2)]g

iv) Particle in E.M. field:

The fact that Lagrange's equations are the Euler-Lagrange equations for the extraordinarily simple and general Hamilton's principle suggests that Lagrange's equations of motion may have a wider range of validity than simply problems where the force is derivable from a scalar potential.

The equation of motion of a charged particle in an electromagnetic field, under the influence of the Lorentz force,

md2r/dr = eE(r, t) + edr X B(r,t)

Where e is the charge on the particle of mass m. We assume the electric and magnetic fields E and B, respectively, to be given in terms of the scalar potential Φ and vector potential A by the standard relations

E = -∇Φ - ∂tA, and B = ∇ x A

Lagrange's equation of motion then becomes

md2q/dq = e[(-∂Φ/∂qi) - (∂Ai/∂t)] + eΣj=1edqj[(∂Aj/∂qi)(∂Ai/∂qj)]

Transformations of the Lagrangian:

Point transformations:

Given the arbitrary Lagrangian L(q, dq, t) in one generalized coordinate system, q ≡ {qi|i = 1,n} (e.g. a Cartesian frame), we often want to know the Lagrangian L'(Q, dQ, t ) in another coordinate system, Q ≡ {Qi|i =1,n}, (e.g. polar coordinates). Thus, suppose there exists a set g ≡ {gi|i = 1,n} of twice differentiable functions gi such that qi gi (Q,t ), i = 1,...,n.

We need inverse function of g also to be twice differentiable, in which case g: Q → q is said to be C2 diffeomorphism. Transformation g maps a path in Q-space to the path in q-space. Though, it is physically same path; all we have changed is representation. What we need to discuss how Lagrangian transforms is the coordinate-free formulation of Lagrangian dynamics. Therefore, if we can state

L' so that L'(Q(t), dQ(t), t) = L(q(t), aq(t), t) for any path, then S is automatically invariant under coordinate change and will be stationary for same physical paths, irrespective of what coordinates they are represented in. One can prove that equation provides correct dynamics by computing transformation of Euler-Lagrange equations explicitly and showing that equation signifies

(d/dt)(∂L'/∂Qi) - (∂L'/∂Qi) = 0

Gauge transformations:

The Lagrangian gives the function for which Lagrange's equations represent correct dynamical equations of motion. We generally normalize L in the natural way, example by requiring that part linear in mass be equivalent to the kinetic energy, hence this freedom is not encountered much in practice. Though, there is a more significant source of non-uniqueness, called as a gauge transformation of Lagrangian in which L is replaced by L', stated by

L'(q, dq, t) = L(q, dq, t) + ∂M/∂t + dq.∂M/∂q

Now add the gauge term, taking M = 1/2ω02x. Then, from equation, new Lagrangian is

L' = 1/2(dx2+2ωxdx - ω02x2)

Hamiltonian mechanics:

Legendre Transform

The Legendre transform is a method of changing the dependence of a function of one set of variables to another set of variables. In mathematics, it is often desirable to express a functional relationship f(x) as a different function, whose argument is the derivative of f, rather than x. If we let p = df/dx be argument of this new function, then new function is written f *(p) and is known as Legendre transform of original function, named after Adrien-Marie Legendre. Legendre transform f *of the function f is stated as follows:  f *( p) = maxx ( px - f (x)).  Legendre transform is its own inverse. Like the familiar Fourier transform, Legendre transform takes the function f(x) and produces the function of different variable p. Though, while Fourier transform comprises of the integration with the kernel, Legendre transform uses maximization as transformation procedure. Legendre transformation can be generalized to Legendre-Fenchel transformation. It is usually utilized in thermodynamics and in Hamiltonian formulation of classical mechanics.

Total differential of Helmholtz free energy is provided by

dA = -dT - PdV.

Where S is entropy, T is temperature, V is volume and p is pressure. From the total differential, it is clear that Helmholtz free energy is stated as the function of temperature and volume; i.e. A = A(T, V ).

The Classical Hamiltonian and Hamilton's Equations:

Now apply the notion of the Legendre transform to the classical Lagrangian. A function of all the generalized coordinates and their respective time derivatives; i.e. L = ({qi}, {dqi}t). For generality, also include possibility that Lagrangian has explicit time dependence. Such explicit time dependence can happen when external forces applying on the system are time-dependent.

Resulting time-dependent potentials can be significant in systems, as for instance, study of interaction of radiation with matter. Light is made up of electric and magnetic fields which oscillate in time, and when light interacts with matter, electrons are subjected to time dependent potentials. For system of particles each having masses mi described by the set of generalized coordinates qi, the classical Hamiltonian is stated by

H = ΣiPidqi - L({qi}, {dqi}, t).

Hamiltonian is then seen to be the expression for total energy of the conservative system in terms of the generalized coordinates and momenta. With the Hamiltonian expressed in terms of the proper variables, Hamilton's equations of the system as

∂H/∂Px = Px/m = dx and ∂H/∂x = ∂U/∂x = -Px

Construction of the Hamiltonian in Spherical Polar Coordinates - Central Force Motion:

For systems with spherical symmetry (e.g. the rigid rotator), spherical polar coordinates are the most convenient set of generalized coordinates. As depicted above, the spherical polar coordinates are r, Θ and Φ. The coordinate r is the distance from the origin of coordinates to the particle, Θ is the angle the line connecting the origin of the coordinates to the particle position makes with the z-axis and Φ is the angle the projection of the line defining Θ onto the xy-plane makes with the x-axis. The connections between Cartesian coordinates and spherical polar coordinates can be derived readily using trigonometry. The result is

x = rsinΘcosΦ    y= rsinΘcosΦ    z = rcosΘ

Another significant relation is direct result of Pythagoras theorem

r = √x2 + y2 + z2

Using definition of classical Hamiltonian

= 1/2m [dr2 + r22 + r2sin2ΘΦ2]+ U(r)

Finally equation should be transformed to replace velocities with generalized momenta. Lastly get

H = [P2r/2m + P2Θ/2mr2 + P2Φ/2mr2sin2Θ] +U(r)

If needed equations of motion can be attained by applying Hamilton's equations to constructed Hamiltonian.

Tutorsglobe: A way to secure high grade in your curriculum (Online Tutoring)

Expand your confidence, grow study skills and improve your grades.

Since 2009, Tutorsglobe has proactively helped millions of students to get better grades in school, college or university and score well in competitive tests with live, one-on-one online tutoring.

Using an advanced developed tutoring system providing little or no wait time, the students are connected on-demand with a tutor at www.tutorsglobe.com. Students work one-on-one, in real-time with a tutor, communicating and studying using a virtual whiteboard technology.  Scientific and mathematical notation, symbols, geometric figures, graphing and freehand drawing can be rendered quickly and easily in the advanced whiteboard.

Free to know our price and packages for online physics tutoring. Chat with us or submit request at [email protected]

©TutorsGlobe All rights reserved 2022-2023.