You are on page 1of 44

The Lagrangian State Function

Introduction
• A state function is any scalar function of the state variables of a system (and possibly time), whose value at any instant of time is completely determined by the values of the state variables at that instant, and time itself
The complete dependence of the state function upon the variables is of prime importance A state function, like the state itself, is independent of the path taken to reach a particular state If the state variables are chosen as physical system variables, a state function defined in terms of these variables may then be closely associated with the physical realities of the system o This close association between the state function and the physical system is particularly true for the state function known as the Lagrangian

The State Function of Lagrange & ) of a system is defined as the difference between the • The Lagrangian L(q, q & ) and the potential energy V(q) kinetic energy T(q, q & ) ≡ T(q, q & ) - V(q ) where q and q & are the generalized coordinates and velocities L(q, q of the system in which the energy terms are expressed > The use of the term generalized coordinates is common in classical mechanics, as is & the notation q and q o These generalized coordinates are closely related to the state variables, as we shall see & i , are associated with the i th energy storage o A generalized coordinate q i and a velocity q element of the system & ) and V(q) • Comment on functional dependency of T(q, q > Since kinetic energy (by its nature) is related to energy storage due to motion, it is not surprising & ) depends on q & that T(q, q > Similarly, since potential energy is associated with energy storage due to position, the dependence of V(q ) on q is not surprising > The need to express the dependency of T on q may not be that obvious o In many problems, kinetic energy is not only a function of velocity, but of position as well ∗ Consider the system to the right where T is determined not & , but also by position r & and θ only by the velocities r

• To give the simplest interpretation to the concept of generalized coordinates & ), consider the special and energy state functions such as the Lagrangian L(q, q case where T and V each contain only a single term, as in the simple spring − mass combination & 2 and V = 1 kx 2 > Here T = 1 mx 2 2 > In this example, q is indeed a position coordinate (x) & is an actual velocity (x &) and q o For simplicity, x is measured from the equilibrium position • In this mass - spring problem, kinetic energy is determined from &) the integral of the momentum (mx & ) = ∫ mσ & dσ & = 1 mx &2 T(q, q 2
0 & x

> Similarly, the potential energy of the spring is given by : V(q ) = ∫ kσdσ = 1 kx 2 2
0 x

Here, kx is the potential force (i.e., the force necessary to maintain the spring at position x)

• These two integrals are a statement that the energy stored is equal to the energy input > Since neither the spring (assumed ideal) nor the mass is able to dissipate energy. this is a simple statement of fact o The kinetic energy stored in the motion of the mass is equal to the work that must have been done on the mass for it to have the & velocity x o The potential energy stored in the spring on the other hand. is equal to the work done on the spring to stretch it by an amount x .

Mechanical rotational & + Kθ = torque J& θ C. Mechanical translational B. as well as combinations of the two (i. Electrical series i = q D.e. consider the following four second .order differential equations which describe the mechanical and electrical systems depicted on the right A. Electrical parallel V = d λ /dt . Electrical series & + 1 q = voltage L& q C D.Electrical and Mechanical Systems • We are naturally interested in electrical and mechanical systems.. electromechanical systems) > By way of analogy. Mechanical rotational & C. Electrical parallel & + 1 λ = current C& λ L where q = charge λ = flux linkage • Simple electrical and mechanical circuits : A. Mechanical translational & + kx = force m& x B.

the 2 λ potential energy is 1 . in the parallel electrical circuit with flux λ as a general coordinate. Mechanical rotational & + Kθ = torque J& θ C. Electrical series & + 1 q = voltage L& q C D.. Electrical parallel & + 1 λ = current C& λ L where q = charge λ = flux linkage & 2. o For example. θ. Mechanical translational & + kx = force m& x B. and it is 1 kx 2 in the mechanical translational system 2 L 2 o These four analogies are summarized in the table seen in the next slide .• In these circuits the generalized coordinates are : x. q and λ > Note that each generalized coordinate occupies the same location in its particular equation .it is in fact the dependent variable of the particular equation > By relating the different coefficients and variables by their positions in these four equations . it is possible to write kinetic and potential energy terms associated with each of the four physical systems A. if the kinetic energy in the mechanical translational system is 1 mx 2 &2 then in the series electrical circuit the kinetic energy would be 1 Lq 2 o Similarly.

the integrand is the momentum of the mass (mx in the case of the integral equation used in computing kinetic energy. & and V = λ • It is interesting to note that the common electrical variables i = q rather than generalized coordinates > If i and V are used as basic coordinates to describe the electrical circuits above.Type of system Mechanical Translation Mechanical rotational Generalized coordinate q Generalized velocity & q & x & . the resulting equations are no longer differential equations. but integrodifferential equations • The energy expressions may also be dertermined by analogy through the use of integral definitions &) > In the translational case (the basis for the analogy). and the potential force (kx) in the case of potential energy . q) T(q Kinetic Energy Potential Energy Generalized Momentum V(q) p Potential Force Generalized Force f Force F Force Torque Position Velocity Angular velocity x Angular Position 1 mx & 2 1 kx 2 2 2 & 2 1 Kθ 2 1 Jθ 2 2 1 Lq &2 2 &2 1 Cλ 2 Momentum & mx Momentum kx Torque θ Electrical series Electrical parallel Charge & θ Current & Jθ Flux linkage Kθ Voltage q & q Flux linkage Voltage λ & λ 1 2 q 2C 1 2 λ 2L & Lq Charge q λ Voltage Current C Current & Cλ L & are generalized velocities.

Generalized Formulation .

of the equation is to be evaluated as a line integral.h. a generalized momentum vector p(q as well as a generalized force potential vector f (q) & q & . from the origin to an arbitrary & in the generalized velocity space point q . but rather that the r. q ) is defined. q ) = ∫ ∑ p i (q & .s. • In this formulation. q ) ≡ ∫ p T (σ & . q ) in a o It is advantageous to consider the general vector formulation for T(q simplified (expanded) form as : & q & . q )d σ & T(q 0 q V(q ) ≡ ∫ f (σ )dσ T 0 > Here we assume that the total energies may consist of several terms. q)dσ &i T(q 0 i =1 n where n is the number of generalized coordinates o We note that the upper limit of integration is a vector quantity ∗ This does not imply that T is a vector quantity. each of which may be a function of more than one variable & .& .

L. q) = ∫ p1 (σ & 1.0L 0.2.0L 0. in evaluating the line integral . σ & 1 . q & 2. q)dσ &2 T(q 0 &n q 0 &1 q &2 q & 1. partial derivatives w.0.State Function • A state function is any scalar function of the state variables and possibly time. and so forth integrate along σ > The completly expanded form of the kinetic energy function is : & . q) ∂p j (q & . whose value at any instant of time is determined by the values of the state variables at that instant and time itself & . j = 1. the value of the line integral must be independent > Since T(q of the path of integration (a basic property of a state function) & would be to > Thus. q) is a state function. q) ∂p i (q sufficient that : = for i.r. n & & ∂q j ∂q i & . it is necessary and & . q ) dσ &n + L + ∫ p n (q 0 > For a line integral of this form to be independent of path. since the integration is taking place in the q . > Although p may be a function of q as well as q & space q i need not be considered.t. the simplest path from 0 to q & 1with the remaining σ & i ' s set equal to zero.q & 3 Lσ & n . q)dσ & 1 + ∫ p 2 (q & 2 .

q ) would not be independent of path. which it must otherwise T(q be if it is to serve as as a state function o On the other hand. q ) to be a state function for T(q . the generalized momentum vector on the validity of p(q & . q ). q ) is correct. if the curl equations are satisfied. since > If these curl equations are not satisfied p(q & . but only that it has the correct form certain that p(q & . q) must be invalid. one cannot be & .• The curl equations presented on the previous slide can be used to check & .

Determine the kinetic energy for this system • The generalized coordinates chosen for this system are : x = position of the mass = q1 (measured from the equilibrium position) q a = charge flowing in the left circuit = q 2 q b = charge flowing in the right circuit = q 3 .Example : Given the electromechanical system shown below.

& .q & 3 )  L b (q1 )q    p 3 (q1 . q ) may be written in similar fashion : > Coordinate 3 : The momentum p 3 (q & . q) = L a (q1 )q & 2 + M ab (q1 )q &3 p 2 (q & . q) is concerned with coordinate q 2 and > Coordinate 2 : Momentum p 2 (q is the " electrical momentum" or flux linkage in the left circuit o Total flux linkage associated with q 2 is the sum of the self . q & 2.q & 3 ) p (q     & 3 + M ab (q1 )q &2 & 2. q ) = mq &1 p1 (q & . q) • Components of the generalized momentum vector p(q & .inductance & 2 and the mutual inductance flux linkage M ab q &3 linkage L a q o Both L a and M ab are functions of the position of the iron slug (q1 ) ∗ Thus. q) is concerned with coordinate q1 and > Coordinate 1 : Momentum p1 (q &1) & 1 = mq therefore the momentum of the iron slug (mx & . the momentum vector is : &1 &1)  mq    p1 (q & . q) =  L a (q1 )q & 2 + M ab (q1 )q & 3  = p 2 (q1 . q) = L b (q1 )q & 3 + M ab (q1 )q &2 p 3 (q • Thus. q  . & .

j = 1.2.q & 3 )  L b (q1 )q    p 3 (q1 . T( q & . q ) = ∫ mσ & 2 )d σ & 1 dσ & 1 + ∫ L a (q1 )σ & 2dσ & 2 + ∫ (L b (q1 )σ & 3 + M ab (q1 )q &3 T( q 0 0 0 &1 q &2 q &3 q & . q  ∂p1 ∂p 3 = → 0=0 & 3 ∂q &1 ∂q & .3 &1 &1)  mq    p1 (q & .∂p i ∂p j • Checking the curl equations : = & j ∂q &i ∂q ∂p1 ∂p 2 = & 2 ∂q &1 ∂q ∂p 2 ∂p 3 = & 3 ∂q &2 ∂q → 0=0 → M ab (q1 ) = M ab (q1 ) i. q ) = L a (q1 )q & 2 + M ab (q1 )q & 3  = p 2 (q1 . q ) may be evaluated by line integration : • Thus. q & 2. q ) = 1 mq & 12 + 1 L a (q1 )q & 2 2 + 1 L b (q1 )q & 3 2 + M ab (q1 )q & 2q &3 T( q 2 2 2 .q & 3 ) p (q     & 3 + M ab (q1 )q &2 & 2.

the line integral is independent of path and V(q) may be written as : V(q) = ∫ f1 (σ1 .0. σ n ) d σ n 0 0 0 q1 q2 qn . q) • This example illustrates not only the determination of the kinetic energy function T(q & .0.L.0. σ 2 .L. q n −1 . but a number of other points as well from the generalized momentum vector p(q > The resulting kinetic energy expression has three terms which are functions of more than one variable o Such terms are common if there is coupling between electrical and mechanical coordinates o In order to better specify the coupling. q).0)d σ 2 + L + ∫ f n (q1 .0)d σ1 + ∫ f 2 (q1 . one would need to mathematically describe the dependence of the self and mutual inductances on q1 q • Potential energy state function : V(q) ≡ ∫ f (σ)dσ where f is the potential force T 0 and dσ is a vector of differentials in the generalized coordinates q q > In expanded form : V(q) = ∫ ∑ f i (σ)dσ i 0 i =1 n Since V(q) is a state function. q 3 . q 2 .L.& .

q) = L(q 1 1 1 1 2 1 2 2 2 &1 &2 & & & + L a (q1 )q + + − q2 mq L (q ) q M (q ) q q kq1 − 2 b 1 3 ab 1 2 3 2 2 2 2 2C . the spring constant k and the capacitor C > The generalized force terms are : q f1 = kq1 . q ) − V(q ) • The Lagrangian state function is defined as : L(q V(q ) = & .Potential Energy Function for problem at hand • There are two potential energy storage devices in this system. f 3 = 0 C kq1  q  f = 2  C  0  > The generalized force terms are functions of only one variable. f 2 = 2 . so the curl ∂f1 ∂f1 ∂f 2 ∂f 2 = = = =0 equations are automatically satisfied ∂q 2 ∂q 3 ∂q1 ∂q 3 > The line integral of f is therefore : V(q ) = ∫ f1 (σ1 )d σ1 + ∫ f 2 (σ 2 )d σ 2 0 0 q1 q2 1 2 1 2 kq1 + q2 2 2C & . q ) ≡ T( q & .

q )d σ & T( q 0 & . q) = p (q =  ∂q & 2 & ∂q   M   & T( q . q ) ≡ ∫ p T (σ & . and consider how p(q & . q) ∂T( q & . q ) and V(q ) are known. respectively with T( q & . q ) and f (q ) • There is an alternative way of viewing the relationship between p(q & . we find that p(q & . q ) and V(q ). q ) ∂    &n   ∂q  whereas f (q ) is :  ∂V(q )    q ∂ 1   V( q ) ∂  ∂V(q )  f (q ) = =  ∂q  2 ∂q   M   V( q ) ∂     ∂q n   & q & . q) = p (q & ∂q q V(q ) ≡ ∫ f (σ )dσ T 0 ∂V(q ) ∂q = f (q ) . q)   ∂T( q   & q ∂ 1   & & . q ) is simply : might be found. q ) and f (q ) > If we assume that T( q & .& . q )  ∂T( q  & . q )  ∂T( q.

Example Write by inspection the kinetic and potential energy functions for the systems below 2 &1 &2 T = 1 m1x + 1 m2x 2 2 2 2 V = 1 k 1 x1 + 1 k 2x 2 + 1 k 3 (x1 − x 2 ) 2 2 2 2 2 2 2 2 &1 & T = 1 L1q + 1 L 2(q L q − q ) + & & 2 3 12 3 4 2 2 1 1 1 2 V= (q1 − q 2 ) 2 + (q 3 − q 4 ) 2 + q4 2C1 2C 2 2C3 m1 2 m 2 2 L(x 2 ) 2 & &1 + &2 + T= x x q 2 2 2 k k 1 2 q V = 1 (x1 − x 2 ) 2 + 2 x 2 + 2 2 2 2C(x1 ) .

which is free to swing in the plane of the paper > The forces acting on the mass m are the gravitatio nal force (mg) and the ten sion (T) in the light rod > The accelerati ons of the bob rotating about the fixed axis are : &) which acts tangentia l to the arc o The tangentia l accelerati on (L& θ & 2 which acts along the rod o The normally directed centrifuga l accelerati on Lθ in the direction of the support center A > In this fixed rod case. we are not interested in tension in the rod o We also assume that all friction and dissipatio n can be neglected • Applying Newton' s second law of motion in a direction perpendicu lar to the pendulum : & F = ma . a = accelerati on = L& θ o The component of gravitatio nal force along the arc is − mgsin θ Substituti ng : & θ − mgsin θ = mL& & & + g sin θ = 0 θ L (equation of motion of a simple pendulum) &2 Lθ & L& θ .The Simple Pendulum • The pendulum is comprised of a light rigid rod. that is pivoted at a support point A and carries a " bob" of mass m.

y = −Lcosθ ∗ The square of the velocity of the bob is : & cosθ) 2 + (Lθ & sin θ) 2 = L2θ &2 &2 + y & 2 = (Lθ v2 = x 1 & &2 o The kinetic energy is : T(θ) = mL2θ 2 o The Lagrangian state function is : & . that is : V(θ) = −mgLcosθ ∗ The coordinates of the displacement of the mass are : x = Lsinθ .• The gravitational potential energy (V(θ)) is simply the gravitational potential of the bob (mass of rod neglected) times the height to which the bob has been moved relative to the equilibrium position. θ) = T(θ & ) − V(θ) = 1 m(L2θ & 2 + 2gLcosθ) L(θ 2 .

Assume that the pendulum swings in one plane.Example Given the double pendulum. Determine the Lagrangian state function for the system Solution q1 = θ1 q2 = θ2 • The (x. y) coordinates of the mass m1 displacement are : x1 = L1sin q1 . y 2 = −L1cos q1 − L 2 cos q 2 • The potential energy state function is : V(q) = m1gL1 (1 − cosq1 ) + m 2 g[L1 (1 − cosq1 ) + L 2 (1 − cosq 2 )] L1 m1 L2 m2 We start by defining the generalized coordinates : . y) coordinates of the mass m 2 displacement are : x 2 = L1sin q1 + L 2sin q 2 . y1 = −L1cos q1 • The (x.

q ) have the general form : > Let T(q 1 2 & . q) = [a11q &1 & 1q & 2 + a11q &2 T(q + 2a12 q 2] 2 where a11 ≡ (m1 + m 2 )L2 1 a12 ≡ m 2 L1L 2 cos (q1 − q 2 ) a 22 ≡ m 2 L22 . q) = [(m1 + m 2 )L2 & & & & T(q q + 2m L L q q cos (q − q ) + m L 1 1 2 1 2 1 2 1 2 2 2q 2 ] 2 & . q) = [m1L2 & & & & & T(q q + m (L q + L 1 1 2 1 1 2 q 2 + 2L1L 2 q1q 2 cos (q1 − q 2 ))] 2 1 2 2 2 & .• The square of the velocity of the i th mass m i (i = 1.2) is : 2 2 2 2 & 1cos q1 ) 2 + (L1q & 1sin q1 ) 2 ] = L2 & &1 &1 v1 =x +y = [(L1q q 1 1 2 2 2 2 & & & & & & v2 = x + y = [(L q cos q + L q cos q ) + (L q sin q + L q sin q ) ] 2 2 2 1 1 1 2 2 2 1 1 1 2 2 2 2 2 2 & & & & = L2 q + L 1 1 2 q 2 + 2L1L 2 q1q 2 cos (q1 − q 2 ) > Therefore. the kinetic energy is given by : 1 2 2 2 2 2 & .

q) = 2 2 2m 2 L2 1L 2 [m1 + m 2 − m 2 cos (q1 − q 2 )] V(q ) = (m1 + m 2 )gL1 (1 − cos q1 ) + m 2 gL 2 (1 − cos q 2 ) . q ) = T( p. q) = 2 2 2m 2 L2 1L 2 [ m1 + m 2 − m 2 cos (q1 − q 2 )] • The Lagrangian state function is : L(p. we may solve these equations simultaneously for q in terms of p1 and p 2 .V(q ) 2 2 m 2 L22 p1 − 2m 2 L1L 2 cos (q1 − q 2 ) p1p 2 + (m1 + m 2 )L2 1p 2 where T( p. q ) . q 2 ) 2 2 m 2 L22 p1 − 2m 2 L1L 2 cos (q1 − q 2 ) p1p 2 + (m1 + m 2 )L2 1p 2 T( p. q ) : T( p. and subsequently substitute these expressions into the equation for T( p.• The generalized momenta are : p1 = p2 = ∂T & 1 + a12 q &2 = a 11q & ∂q1 ∂T & 1 + a 22 q &2 = a12 q &2 ∂q & 1 and q &2 > Thus. q) = 1 2(a11a 22 − a ) 2 12 2 [a 22 p1 − 2a 12 p1p 2 + a 11p 2 2] where a 12 = a 12 (q1 .

Lagrange’s Equation and Newton’s Law • Lagrange’s equation provides a means of deriving the equations that govern the motion of a system Partial and total differentiation operations on a Lagrangian state function yield & a set of n second-order differential equations in the coordinates q and q o These second-order differential equations may be reduced to the desired state variable form of first-order differential equations • Our objective here is to indicate (in a heuristic way) the origins and validity of Lagrange’s equation This derivation also serves to illustrate an important feature of Lagrange’s equation. namely that it is valid in any consistent set of generalized coordinates The more elegant proof of Lagrange’s equation is based on Hamilton’s principle and employs calculus of variations .

L..2. and Fi is the sum of where p i ( x forces acting on the i th particle • Suppose now that we wish to consider this same system in another coordinate system..2. n which is described in cartesian coordinates x • For simplicity. and we indicate this fact by adopting the general notation : x = x (q) . n (state variable representation) [p i ( x dt & ) is the i th particle momentum.. the q coordinates > The transformation from x to q need not be linear.dimensional space and therefore each particle has only one coordinate associated with its movement > Newton' s Second Law : d & )] = Fi for i = 1.Derivation Consider a mechanical system made up of n particles of constant mass & m i i = 1.. we assume that the particles move in a one .

q) & (q q & but also q o Thus. q )] ∂T T ∂ x & & ∂x d ∂x T T &) &) { } o Thus. it & on both q o Due to the functional dependence of x & and q follows that T will also be a function of q o Thus. =( ) = p (x = p (x & ∂q i ∂q i ∂x ∂q i dt ∂q i where the last expression is obtained by interchanging the order of differentiation . the old velocities are functions not only of q > The kinetic energy of the system may be written in terms of the 1 n & ) = ∑ mi x & i2 cartesian coordinates x as : T( x 2 i =1 & and q.> The time derivative of the old coordinates is then determined by &= the chain rule of differentiation to be : x ∑ i =1 n ∂ x (q ) ∂q i &i = x & . q )] ∂T T ∂ x & (q ∂T[ x  M  &   ∂T   =( ) &n mn x  & ∂q i   ∂q i ∂x & ∂ x   n  & & ∂T[ x (q. partial derivatives of T with respect to q i may be formed as :  ∂T  & . q )] ∂T ∂x & (q ∂T[ x  ∂x & 1 ∂T ∂x &2 &n ∂T ∂x & 1   m1x &1  = + +L+   ∂T   m x & 1 ∂q i ∂x & 2 ∂q i & n ∂q i ∂q i ∂x ∂x &  ∂T  2 2  &) = p( x where =  ∂x &2  =   & M ∂ x & .

q )] & (q ∂T[ x ∂x ∂q i o Taking the time derivative of the equation just above : But from preceeding slide : & & ∂ T[ x ( q . the partial derivative of T( x & i (i = 1. q )] & . q )] & (q & (q ∂T[ x d ∂T[ x d T ∂x & )] { } = [ p( x + &i ∂q ∂q i dt dt ∂q i . q )] ∂x d d d ∂x T & )]T &) { } + p (x { } = [ p( x & . where p ( x &i &i & ∂q ∂q ∂x o To put this result into a more convenient form. we observe that : & =∑ x = x (q ) → x j=1 n ∂x &j q ∂q j &j ∂q where = 0 unless i = j &i ∂q T &) = p (x & ∂x ∂ n ∂x ∂x & j} = = {∑ q & i ∂q & i j=1 ∂q j ∂q ∂q i Thus. q )] & (q ∂T[ x d ∂x T & ∂q i ∂q i dt dt dt ∂q i &) { }= p (x dt ∂q i ∂q i Substituting : & .& ) with respect to the i th velocity • In the same fashion. q )] & (q ∂T[ x & ∂x ∂T T T &) & ) = ( )T = p (x . n) yields : coordinate q & .2. substituting : &i ∂q & .L .

of the equation (above arrow) : & .2. q)] ∂T[x & (q & (q d ∂T[x { }= ∑ Fj &i dt ∂q ∂q i ∂q i j=1 > Letting Qi ≡ ∑ Fj j=1 n ∂x j ∂q i (force associated with q i coordinate) (generalform of Lagrangeequation) & . q)] n ∂x j & .L. no physicallaw has been called into play o From the state variableform of Newton's Second Law : d & )] = Fj for j = 1.s that describe the motion of the n particles . q)] d & (q & (q ∂x d ∂T[x & )]T = [ p(x }{ &i ∂q i ∂q ∂q i dt dt > The manipulations are nearly complete. q)] ∂T[x & .> Rearranging terms : & .s. q)] ∂T[x & .and it is important to stress that all we have done is to manipulate the kinetic energy state function o As yet. n [p j (x dt o Substituting this expressioninto the r.D.E. q)] & (q & (q d ∂T[x { }= Qi &i dt ∂q ∂q i o The Lagrangeequation corresponds to a set of n second − order O.h.

q )] & (q & (q d ∂T[ x { }= Qi & dt ∂q i ∂q i one usually separates the Q i ' s into three components in the following manner : Q i ≡ − f i − D i + Fi where f i = potential force D i = damping force Fi = applied force > Potential force : In terms of the potential energy function.• In the practical usage of the Lagrange equation. & . q )] ∂T[ x & . since Q i is considered the force acting on the i th mass ∗ Earlier. f i was defined as the force acting on the potential energy storage device . f i is given by fi = ∂V( q ) ∂q i o A negative sign preceeds f i in the expression for Q i above.

for which D i is given by : & i where β i is the viscous damping coefficient Di = β i q ∗ The viscous damping force is usually written in terms of another &) state function called the Rayleigh Dissipation Function D(q 1 n &) ≡ ∑β jq &2 where : D(q j 2 j=1 ∗ The relationship between the viscous damping force Di and the Rayleigh Dissipation Function is : &) ∂D(q &i Di = = βi q &i ∂q > The fact that the damping force opposes the motion of the system is indicated by the negative sign preceeding Di in the equation for Qi .> Damping force Di includes the force from all dissipative elements associated with the q i coordinate ∗ The only type of damping we will consider for the moment is viscous damping.

o The applied force Fi includes all external forces that are associated with the q i coordinate ∂V(q ) ∂q i &) ∂D(q &i ∂q > Thus. q)] &) & (q & (q ∂V(q ) ∂D(q d ∂T[ x =− − + Fi }{ &i &i ∂q ∂q i ∂q i ∂q dt & . q)] ∂T[ x & . Qi ≡ −f i − Di + Fi = − − + Fi Substituting into the Lagrange equation : & . q)] ∂V(q) ∂D(q &) & (q & (q d ∂T[ x { }+ + = Fi &i &i ∂q ∂q i ∂q i ∂q dt o This last equation is called the operational form of the Lagrange equation . q)] ∂T[ x & .

q) ∂D(q &) d ∂L(q + = Fi or { }& & ∂q i ∂q i ∂q i dt o This result takes a very simple form for the unforced conservative system without dissipation (Fi = Di = 0) & . q) ∂V(q) ∂D(q &) d ∂T(q o Hence : { } -{ − }+ = Fi &i &i &i ∂q ∂q ∂q i ∂q i ∂q dt & . q) = T(q & . q) d ∂L(q =0 { }&i ∂q ∂q i dt • This equation can be represented in an alternate manner by means of Hamiltion's equations o In Hamilton's formulation one uses the momentum p and coordinate q & and q . q) − V(q) L(q 0 & .• The operational form of the Lagrange equation can be rewritten in a more compact form using the Lagrangian state function & . q) ∂V(q) ∂T(q & . q) ∂L(q & . q) ∂L(q & . as used in the Lagrangian as the basic variables rather than q formulation .

L.• The state function of Hamilton.s it may appear at first glance that they are a more natural means of generating the state equations o This however is incorrect o Application of Hamilton' s equation to electrical networks for example. q ) &i = − p for i = 1. q ) ∂p i > Since Hamilton' s equations directly yield first . q ) ≡ p q > The equations of motion are given by Hamilton' s equations : ∂H(p.E. q) H(p. but not results that are identical to those produced from Kirchhof' s Laws ∗ This is due to the use of the unfamiliar momentum variable p .2. n ∂q i &i = q ∂H(p.order O. is defined as : T & − L(q & . q ). yields results that are valid.D. the Hamiltonian H(p.

q)] ∂T[ x & . q)] ∂V(q) ∂D(q &) & (q & (q d ∂T[ x { }+ + = Fi &i &i dt ∂q ∂q ∂q i ∂q i .Examples Using the Operational Form of the Lagrange Equation & .

• The system consists of two flywheels with inertas J1 and J 2 . • In addition. both flywheels are acted upon by viscous damping forces with coefficients β1 and β 2 .Example Consider the rotational mechanical system below. which are coupled together via a shaft with a torsional spring constant k 2 . as well as by applied torquesT1 (t) and T2 (t) o Note however. o The flywheels are also connected to the rigid walls by means of shafts with tortional spring constants k1 and k 3 . that the inertia J 2 is subject to viscous damping forces that are due only to the difference in velocity between J1 and J 2 Rotational System .

= β1θ 1 2 1 2 & ∂θ1 ∂θ 1 & +β θ & + β (θ & −θ & ) + k θ + k (θ − θ ) = T (t) J& θ 1 1 1 1 2 1 2 1 1 2 1 2 1 . ∂T = 0 { } = J1& θ 1 & dt ∂θ ∂θ1 1 ∂V ∂D & + β (θ & −θ & ) = k1θ1 + k 2 (θ1 − θ 2 ) . q ) ∂V(q ) ∂D(q &) d ∂T(q { }+ + = Fi &i &i dt ∂q ∂q i ∂q i ∂q For i = 1 : ∂T & → = J1θ 1 & ∂θ 1 d ∂T & . F2 = T2 (t) T= • Evaluating the Lagrange equation : & .Solution It is assumed that the system parameters are constant and that the range of the variables is unrestricted • The generalized coordinates are chosen to be the angles θ1 and θ 2 . the & and θ & generalized angular velocities are θ 1 2 > Kinetic energy : > Potential energy : > Dissipation energy : > Applied forces : 1 &2 1 & 2 J1θ1 + J 2θ 2 2 2 1 1 1 2 2 V = k1θ1 + k 2 (θ1 − θ 2 ) 2 + k 3θ 2 2 2 2 1 &2 1 & −θ & )2 D = β1θ β 2 (θ 1 + 1 2 2 2 F1 = T1 (t) . q ) ∂T(q & .

x  θ 2  T2 (t) &  θ 2  . q ) ∂T(q & .• Evaluating the Lagrange equation : & . =0 & dt ∂θ 2 ∂θ 2 ∂V ∂D & −θ & ) = k 3θ 2 + k 2 (θ 2 − θ1 ) . = β 2 (θ 2 1 & ∂θ 2 ∂θ 2 & + β (θ & −θ & ) + k θ + k (θ − θ ) = T (t) J 2& θ 2 2 2 1 3 2 2 2 1 2 • The Lagrange equations may be placed in state variable form in terms of a state vector x and an input vector u (t) :  θ1  θ &   T1 (t)  1  & = A x + Bu (t) x= . u (t) =  . q) ∂V(q) ∂D(q &) d ∂T(q { }+ + = Fi &i &i dt ∂q ∂q i ∂q i ∂q ∂T & for i = 2 : = J 2θ 2 & ∂θ 2 → d ∂T ∂T & & { } = J 2θ 2 .

order systems. they resemble phase variables) > For second .0 1 0 0   0 0 (β1 + β 2 ) k2 β2   (k1 + k 2 )  1 − −   J J1 J1 J1 J1  1 A=  .. B=  0 0 0 0 0 1     (k + k 3 ) k2 β2 β  0 1  − 2 − 2   J2  J2  J2 J2 J2     • It is interesting to note that if the generalized coordinates are considered in sets of two. the phase variables and the generalized coordinates of Lagrange are often identical . they are related by derivatives (i.e.

q 2 .L. x n ) = 0. x 2 .L. x1 . which takes the form of either an algebraic equation f(x1 . however. q 3 ) &1 = q & 3 or q1 = q 3 > There is an obvious constraint in this problem. x & 2 .Example : Determine the Lagrange equations of motion for the electrical system in the figure below : + L 1 (q 1 ) q1 q3 R2 q2 R1 e in (t) ~ C e o (t) L2 Solution : Since the applied force is in the form of a voltage e IN (t). namely q o Consequently. x 2 . x & n . x 2 . x n ) = 0 differential equation of the form g(x ∗ Constraints that cannot be expressed as either algebraic or integrable differential equations are known as nonholonomic constraints ∗ A common example is the inequality constraint f(x1 . x n ) ≤ 0 . there are only two generalized coordinates o This is an example of a holonomic constraint. L . or an integrable & 1. L. we select the coordinates as charge q (refer to table of generalized coordinates for different systems) • The circuit contains three energy storage elements and therefore we might expect three generalized coordinates (q1 .

q) to determine T(q & . we choose our generalized coordinates as q1 and q 2 & 1 ) requires specification > Note that the nonlinear element L1 (q o We do this in terms of a flux linkage vs. the inductance L1 is constant and ∗ For q =0 &1 ∂q & 1 ) it is best to • Due to the presence of the nonlinear element L1 (q integrate the momentum vector & .• Due to the holonomic constraint (q1 = q 3 ). flux linkages increase linearly up to a &1 = α point where q &1) ∂L(q & 1 < α. q) p (q − Momentum vector : & 1 )q & 1 + L 2q &1 L1 (q & . q) =  p (q  0   α &1 q λ λα . current curve shown below o As a practical matter.

the kinetic energy function is : & . F2 = 0 &1 q . q) = ∫ (L1 (σ1 )σ1 dσ1 + L 2 q 2 0 • The other state functions may be written as : 1 2 V(q) = q2 2C 1 1 2 & & & &2 D(q) = R 1 (q1 − q 2 ) + R 2 q 2 2 2  F1  • The generalized force is : F =   F2  F1 = e IN (t) .• Thus. q) = ∫ (L1 (σ & 1 )σ & 1 + L 2σ & 1 ) dσ &1 T(q 0 &1 q 1 2 & &1 & & & T(q.

2 &i &i dt ∂q ∂q i ∂q i ∂q 1 2 & . = =0 & & ∂q1 ∂q 2 ∂q1 ∂q 2 & ) d ∂T ∂L (q & 1 )& &1 + q &1 1 1 & &1 + L 2& &1 { } = L1 (q q q q o &1 &1 dt ∂q ∂q o & ) d ∂T ∂L (q &1 & 1 )+ q & 1 1 1 + L 2 ]& { } = [L1 (q q & & dt ∂q1 ∂q1 o ∂V ∂V q 2 =0 . q ) = ∫ (L1 (σ &1 & 1 )σ & 1 dσ & 1 + L 2q > Evaluating parts of the whole : T( q 2 0 ∂T ∂T ∂T ∂T & 1 )q & 1 + L 2q &1 .• Applying Lagrange's equations of motion : d ∂T ∂T ∂V ∂D { }− + + = Fi for i = 1. & 1 + (R 1 + R 2 )q &2 = R 1 (q = − R 1q &1 &2 ∂q ∂q • Lagrange's equations are therefore : & ) ∂L (q & 1 )+ q & 1 1 1 + L 2 ]& &1 + R 1 (q &1 − q & 2 ) = e IN (t) [L1 (q q &1 ∂q & 1 + (R 1 + R 2 )q &2 + − R 1q q2 =0 C V(q ) = 1 2 q2 2C 1 1 & ) = R 1 (q &1 − q & 2 ) 2 + R 2q &2 D(q 2 2 2 &1 q . = L1 (q =0 . = ∂q1 ∂q 2 C ∂D ∂D &1 − q &2) .

then L1 (q & 1 ) = L1 a constant the nonholonomic constraint q & 1curve equal to the slope of the λ vs q & ) ∂L (q ∴ 1 1 =0 &1 ∂q o The Lagrange equations may be simplified as : &1 + R 1 (q &1 − q & 2 ) = e IN (t) (L1 + L 2 ) & q q2 =0 C o We note also that the output voltage of the circuit is given by : q 2 (t) e 0 (t) = C o Defining the terms : L ≡ L1 + L 2 .& 1 ) characteristic by applying • If we consider linearizing the L1 (q & 1 ≤ α . R ≡ R 1 + R 2 &1 + R 1 (q &1 − q & 2 ) = e IN (t) L& q & 1 + (R 1 + R 2 )q &2 + − R 1q & 1 + Rq &2 + − R 1q q2 =0 C q 2 (t) e 0 (t) = C .