Selasa, 08 Februari 2011

The Lagrange

Lagrangian Equation

Lagrangian mechanics is a re-formulation of classical mechanics that combines conservation of momentum with conservation of energy. It was introduced by the French mathematician Joseph-Louis Lagrange in 1788.

In Lagrangian mechanics, the trajectory of a system of particles is derived by solving the Lagrange equations in one of two forms, either the Lagrange equations of the first kind,[1] which treat constraints explicitly as extra equations, often using Lagrange multipliers;[2][3] or the Lagrange equations of the second kind, which incorporate the constraints directly by judicious choice of generalized coordinates.[1][4] The fundamental lemma of the calculus of variations shows that solving the Lagrange equations is equivalent to finding the path for which the action functional is stationary, a quantity that is the integral of the Lagrangian over time.

The use of generalized coordinates may considerably simplify a system's analysis. For example, consider a small frictionless bead traveling in a groove. If one is tracking the bead as a particle, calculation of the motion of the bead using Newtonian mechanics would require solving for the time-varying constraint force required to keep the bead in the groove. For the same problem using Lagrangian mechanics, one looks at the path of the groove and chooses a set of independent generalized coordinates that completely characterize the possible motion of the bead. This choice eliminates the need for the constraint force to enter into the resultant system of equations. There are fewer equations since one is not directly calculating the influence of the groove on the bead at a given moment.

The equations of motion in Lagrangian mechanics are the Lagrange equations, also known as the Euler–Lagrange equations. Below, we sketch out the derivation of the Lagrange equations of the second kind. Please note that in this context, V is used rather than U for potential energy and T replaces K for kinetic energy. See the references for more detailed and more general derivations.

Start with D'Alembert's principle for the virtual work of applied forces, \mathbf{F}_i, and inertial forces on a three dimensional accelerating system of n particles, i, whose motion is consistent with its constraints,[5]:269

\delta W = \sum_{i=1}^n ( \mathbf {F}_{i} - m_i \mathbf{a}_i )\cdot \delta \mathbf r_i = 0.

where

δW is the virtual work;

\delta \mathbf r_iis the virtual displacement of the system, consistent with the constraints;

mi are the masses of the particles in the system;

\mathbf a_iare the accelerations of the particles in the system;

m_i \mathbf a_itogether as products represent the time derivatives of the system momenta, aka. inertial forces;

i is an integer used to indicate (via subscript) a variable corresponding to a particular particle; and

n is the number of particles under consideration.

Break out the two terms:

\delta W = \sum_{i=1}^n \mathbf {F}_{i} \cdot \delta \mathbf r_i - \sum_{i=1}^n m_i \mathbf{a}_i \cdot \delta \mathbf r_i = 0.

Assume that the following transformation equations from m independent generalized coordinates, qj, hold:[5]:260

\begin{array}{r c l} \mathbf{r}_1 &=& \mathbf{r}_1(q_1, q_2, \dots, q_m, t) \\ \mathbf{r}_2 &=& \mathbf{r}_2(q_1, q_2, \dots, q_m, t) \\     & \vdots &  \\ \mathbf{r}_n &=& \mathbf{r}_n(q_1, q_2, \dots, q_m, t) \end{array}

where m (without a subscript) indicates the total number of generalized coordinates. An expression for the virtual displacement (differential), \delta \mathbf{r}_iof the system for time-independent constraints is[5]:264

\delta \mathbf{r}_i = \sum_{j=1}^m \frac {\partial \mathbf {r}_i} {\partial q_j} \delta q_j,

where j is an integer used to indicate (via subscript) a variable corresponding to a generalized coordinate.

The applied forces may be expressed in the generalized coordinates as generalized forces, Qj:[5]:265

Q_j = \sum_{i=1}^n \mathbf {F}_{i} \cdot \frac {\partial \mathbf {r}_i} {\partial q_j}.

Combining the equations for δW, \delta \mathbf{r}_i, and Qj yields the following result after pulling the sum out of the dot product in the second term:[5]:269

\delta W = \sum_{j=1}^m Q_j \delta q_j - \sum_{j=1}^m \sum_{i=1}^n m_i \mathbf{a}_i \cdot \frac {\partial \mathbf {r}_i} {\partial q_j} \delta q_j = 0.

Substituting in the result from the kinetic energy relations to change the inertial forces into a function of the kinetic energy leaves[5]:270

\delta W = \sum_{j=1}^m Q_j \delta q_j - \sum_{j=1}^m \left ( \frac {d}{d t} \left ( \frac {\partial T}{\partial \dot{q}_j} \right ) - \frac {\partial T}{\partial q_j} \right ) \delta q_j = 0.

In the above equation, δqj is arbitrary, though it is by definition consistent with the constraints. So the relation must hold term-wise:[5]:270

Q_j = \frac {d}{d t} \left ( \frac {\partial T}{\partial \dot{q}_j} \right ) - \frac {\partial T}{\partial q_j}.

If the \mathbf F_iare conservative, they may be represented by a scalar potential field, V:[5]:266 & 270

\mathbf F_i = - \nabla V \Rightarrow Q_j = - \sum_{i=1}^n \nabla V  \cdot \frac {\partial \mathbf {r}_i} {\partial q_j} = - \frac {\partial V}{\partial q_j}.

The previous result may be easier to see by recognizing that V is a function of the \mathbf {r}_i, which are in turn functions of qj, and then applying the chain rule to the derivative of V with respect to qj.

Recall the definition of the Lagrangian is [5]:270

\mathcal{L} = T - V.\,

Since the potential field is only a function of position, not velocity, Lagrange's equations are as follows:

\frac {d}{d t} \left ( \frac {\partial \mathcal L}{\partial \dot{q}_j} \right ) - \frac {\partial \mathcal L}{\partial q_j} = \frac{d}{d t}\left ( \frac {\partial T}{\partial \dot{q}_j} \right ) - \frac {\partial T}{\partial q_j} + \frac {\partial V}{\partial q_j} = 0 .

This is consistent with the results derived above and may be seen by differentiating the right side of the Lagrangian with respect to \dot{q}_jand time, and solely with respect to qj, adding the results and associating terms with the equations for \mathbf{F}_iand Qj.

In a more general formulation, the forces could be both potential and viscous. If an appropriate transformation can be found from the \mathbf F_i, Rayleigh suggests using a dissipation function, D, of the following form:[5]:271

D = \frac {1}{2} \sum_{j=1}^m \sum_{k=1}^m C_{j k} \dot{q}_j \dot{q}_k.

where Cjk are constants that are related to the damping coefficients in the physical system, though not necessarily equal to them

If D is defined this way, then[5]:271

Q_j = - \frac {\partial V}{\partial q_j} - \frac {\partial D}{\partial \dot{q}_j}

and

0 = \frac {d}{d t} \left ( \frac {\partial \mathcal L}{\partial \dot{q}_j} \right ) - \frac {\partial \mathcal L}{\partial q_j} + \frac {\partial D}{\partial \dot{q}_j}.

The equations of motion in Lagrangian mechanics are the Lagrange equations, also known as the Euler–Lagrange equations. Below, we sketch out the derivation of the Lagrange equations of the second kind. Please note that in this context, V is used rather than U for potential energy and T replaces K for kinetic energy. See the references for more detailed and more general derivations.

Start with D'Alembert's principle for the virtual work of applied forces, \mathbf{F}_i, and inertial forces on a three dimensional accelerating system of n particles, i, whose motion is consistent with its constraints,[5]:269

\delta W = \sum_{i=1}^n ( \mathbf {F}_{i} - m_i \mathbf{a}_i )\cdot \delta \mathbf r_i = 0.

where

δW is the virtual work;

\delta \mathbf r_iis the virtual displacement of the system, consistent with the constraints;

mi are the masses of the particles in the system;

\mathbf a_iare the accelerations of the particles in the system;

m_i \mathbf a_itogether as products represent the time derivatives of the system momenta, aka. inertial forces;

i is an integer used to indicate (via subscript) a variable corresponding to a particular particle; and

n is the number of particles under consideration.

Break out the two terms:

\delta W = \sum_{i=1}^n \mathbf {F}_{i} \cdot \delta \mathbf r_i - \sum_{i=1}^n m_i \mathbf{a}_i \cdot \delta \mathbf r_i = 0.

Assume that the following transformation equations from m independent generalized coordinates, qj, hold:[5]:260

\begin{array}{r c l} \mathbf{r}_1 &=& \mathbf{r}_1(q_1, q_2, \dots, q_m, t) \\ \mathbf{r}_2 &=& \mathbf{r}_2(q_1, q_2, \dots, q_m, t) \\     & \vdots &  \\ \mathbf{r}_n &=& \mathbf{r}_n(q_1, q_2, \dots, q_m, t) \end{array}

where m (without a subscript) indicates the total number of generalized coordinates. An expression for the virtual displacement (differential), \delta \mathbf{r}_iof the system for time-independent constraints is[5]:264

\delta \mathbf{r}_i = \sum_{j=1}^m \frac {\partial \mathbf {r}_i} {\partial q_j} \delta q_j,

where j is an integer used to indicate (via subscript) a variable corresponding to a generalized coordinate.

The applied forces may be expressed in the generalized coordinates as generalized forces, Qj:[5]:265

Q_j = \sum_{i=1}^n \mathbf {F}_{i} \cdot \frac {\partial \mathbf {r}_i} {\partial q_j}.

Combining the equations for δW, \delta \mathbf{r}_i, and Qj yields the following result after pulling the sum out of the dot product in the second term:[5]:269

\delta W = \sum_{j=1}^m Q_j \delta q_j - \sum_{j=1}^m \sum_{i=1}^n m_i \mathbf{a}_i \cdot \frac {\partial \mathbf {r}_i} {\partial q_j} \delta q_j = 0.

Substituting in the result from the kinetic energy relations to change the inertial forces into a function of the kinetic energy leaves[5]:270

\delta W = \sum_{j=1}^m Q_j \delta q_j - \sum_{j=1}^m \left ( \frac {d}{d t} \left ( \frac {\partial T}{\partial \dot{q}_j} \right ) - \frac {\partial T}{\partial q_j} \right ) \delta q_j = 0.

In the above equation, δqj is arbitrary, though it is by definition consistent with the constraints. So the relation must hold term-wise:[5]:270

Q_j = \frac {d}{d t} \left ( \frac {\partial T}{\partial \dot{q}_j} \right ) - \frac {\partial T}{\partial q_j}.

If the \mathbf F_iare conservative, they may be represented by a scalar potential field, V:[5]:266 & 270

\mathbf F_i = - \nabla V \Rightarrow Q_j = - \sum_{i=1}^n \nabla V  \cdot \frac {\partial \mathbf {r}_i} {\partial q_j} = - \frac {\partial V}{\partial q_j}.

The previous result may be easier to see by recognizing that V is a function of the \mathbf {r}_i, which are in turn functions of qj, and then applying the chain rule to the derivative of V with respect to qj.

Recall the definition of the Lagrangian is [5]:270

\mathcal{L} = T - V.\,

Since the potential field is only a function of position, not velocity, Lagrange's equations are as follows:

\frac {d}{d t} \left ( \frac {\partial \mathcal L}{\partial \dot{q}_j} \right ) - \frac {\partial \mathcal L}{\partial q_j} = \frac{d}{d t}\left ( \frac {\partial T}{\partial \dot{q}_j} \right ) - \frac {\partial T}{\partial q_j} + \frac {\partial V}{\partial q_j} = 0 .

This is consistent with the results derived above and may be seen by differentiating the right side of the Lagrangian with respect to \dot{q}_jand time, and solely with respect to qj, adding the results and associating terms with the equations for \mathbf{F}_iand Qj.

In a more general formulation, the forces could be both potential and viscous. If an appropriate transformation can be found from the \mathbf F_i, Rayleigh suggests using a dissipation function, D, of the following form:[5]:271

D = \frac {1}{2} \sum_{j=1}^m \sum_{k=1}^m C_{j k} \dot{q}_j \dot{q}_k.

where Cjk are constants that are related to the damping coefficients in the physical system, though not necessarily equal to them

If D is defined this way, then[5]:271

Q_j = - \frac {\partial V}{\partial q_j} - \frac {\partial D}{\partial \dot{q}_j}

and

0 = \frac {d}{d t} \left ( \frac {\partial \mathcal L}{\partial \dot{q}_j} \right ) - \frac {\partial \mathcal L}{\partial q_j} + \frac {\partial D}{\partial \dot{q}_j}.

Kinetic energy relations

The kinetic energy, T, for the system of particles is defined by[5]:269

T = \frac {1}{2} \sum_{i=1}^n m_i \mathbf {v}_i \cdot \mathbf {v}_i.

The partial derivative of T with respect to the time derivatives of the generalized coordinates, \dot{q}_j, is[5]:269

\frac {\partial T}{\partial \dot{q}_j} = \sum_{i=1}^n m_i \mathbf {v}_i \cdot \frac {\partial \mathbf {v}_i} {\partial \dot{q}_j}.

The previous result may be difficult to visualize. As a result of the product rule, the derivative of a general dot product is

\frac{d}{dx} ( \mathbf{f}(x) \cdot \mathbf{g}(x) ) = \mathbf{f}(x) \cdot \frac{d}{dx} \mathbf{g}(x) + \mathbf{g}(x) \cdot \frac{d}{dx} \mathbf{f}(x).

This general result may be seen by briefly stepping into a Cartesian coordinate system, recognizing that the dot product is (there) a term-by-term product sum, and also recognizing that the derivative of a sum is the sum of its derivatives. In our case, \mathbf{f}and \mathbf{g}are equal to \mathbf{v}, which is why the factor of one half disappears.

According to the chain rule and the coordinate transformation equations given above for \mathbf{r}, its time derivative, \mathbf{v}, is[5]:264

\mathbf{v}_i = \sum_{k=1}^m \frac {\partial \mathbf{r}_i}{\partial q_k} \dot{q}_k + \frac {\partial \mathbf{r}_i}{\partial t}.

Together, the definition of \mathbf v_iand the total differential, d \mathbf {r}_i, suggest that[5]:269

\frac {\partial \mathbf {v}_i}{\partial \dot{q}_j} = \frac {\partial \mathbf {r}_i}{\partial q_j}

since

 \frac {\partial } {\partial {\dot{q}_k}} {A}{\dot{q}_k} = A

and that in the sum, there is only one \dot{q}_j.

Substituting this relation back into the expression for the partial derivative of T gives[5]:269

\frac {\partial T}{\partial \dot{q}_j} = \sum_{i=1}^n m_i \mathbf v_i \cdot \frac {\partial \mathbf {r}_i}{\partial q_j}.

Taking the time derivative gives[5]:270

\frac {d}{d t} \left ( \frac {\partial T}{\partial \dot{q}_j} \right ) = \sum_{i=1}^n \left [ m_i \mathbf a_i \cdot \frac {\partial \mathbf {r}_i}{\partial q_j} + m_i \mathbf {v}_i \cdot \frac {d}{d t} \left ( \frac {\partial \mathbf {r}_i}{\partial q_j} \right ) \right ].

Using the chain rule on the last term gives[5]:270

\frac {d}{d t} \left ( \frac {\partial \mathbf {r}_i}{\partial q_j} \right ) = \sum_{k=1}^m \frac {\partial^2 \mathbf r_i}{\partial q_j \partial q_k} \dot{q_k} + \frac {\partial^2 \mathbf r_i}{\partial q_j \partial t}.

From the expression for \mathbf v_i, one sees that[5]:270

\frac {d}{d t} \left ( \frac {\partial \mathbf {r}_i}{\partial q_j} \right ) = \frac {\partial \mathbf {v}_i}{\partial q_j}.

This allows simplification of the last term,[5]:270

\frac {d}{d t} \left ( \frac {\partial T}{\partial \dot{q}_j} \right ) = \sum_{i=1}^n \left [ m_i \mathbf a_i \cdot \frac {\partial \mathbf {r}_i}{\partial q_j} + m_i \mathbf {v}_i \cdot \frac {\partial \mathbf {v}_i}{\partial q_j} \right ].

The partial derivative of T with respect to the generalized coordinates, qj, is[5]:270

\frac {\partial T}{\partial q_j} = \sum_{i=1}^{n} \frac { \partial [ \frac{1}{2} m_i {v_i}^{2} ] }{\partial q_j} = \sum_{i=1}^{n} \frac { \partial [ \frac{1}{2} m_i \ ( \mathbf {v}_i \cdot \mathbf {v}_i ) ] }{\partial q_j} = \! \frac{1}{2} \sum_{i=1}^{n} \left[ m_i \mathbf {v}_i \cdot \frac {\partial \mathbf {v}_i}{\partial q_j} + m_i \mathbf {v}_i \cdot \frac {\partial \mathbf {v}_i} {\partial q_j} \right] = \sum_{i=1}^{n}m_i \mathbf {v}_i \cdot \frac {\partial \mathbf {v}_i}{\partial q_j}.

This last result may be obtained by doing a partial differentiation directly on the kinetic energy definition represented by the first equation. The last two equations may be combined to give an expression for the inertial forces in terms of the kinetic energy:[5]:270

\frac {d}{d t} \left ( \frac {\partial T}{\partial \dot{q}_j} \right ) - \frac {\partial T}{\partial q_j} = \sum_{i=1}^n m_i \mathbf a_i \cdot \frac {\partial \mathbf {r}_i}{\partial q_j}.

Examples

in this section two examples are provided in which the above concepts are applied. The first example establishes that in a simple case, the Newtonian approach and the Lagrangian formalism agree. The second case illustrates the power of the above formalism, in a case which is hard to solve with Newton's laws.

Falling mass

Consider a point mass m falling freely from rest. By gravity a force F = mg is exerted on the mass (assuming g constant during the motion). Filling in the force in Newton's law, we find \ddot x = gfrom which the solution

x(t) = \frac{1}{2} g t^2

follows (choosing the origin at the starting point). This result can also be derived through the Lagrange formalism. Take x to be the coordinate, which is 0 at the starting point. The kinetic energy is T = 12mv2 and the potential energy is V = −mgx; hence,

\mathcal{L} = T - V = \frac{1}{2} m \dot{x}^2 + m g x..

Then

0 = \frac{\partial \mathcal{L}}{\partial x} - \frac{\mathrm{d}}{\mathrm{d}t} \frac{\partial \mathcal{L}}{\partial \dot x} = m g - m \frac{\mathrm{d} \dot x}{\mathrm{d} t}

which can be rewritten as \ddot x = g, yielding the same result as earlier.