Derivation of Equations of Motion for Inverted Pendulum Problem
Total Page:16
File Type:pdf, Size:1020Kb
Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Derivation of Equations of Motion for Inverted Pendulum Problem Filip Jeremic McMaster University November 28, 2012 It is defined as the work needed to accelerate a body of a given mass from rest to its stated velocity In classical mechanics, the kinetic energy Ek of a point object is defined by its mass m and velocity v: 1 E = mv 2 k 2 Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Kinetic Energy Definition The energy which an object possesses due to its motion In classical mechanics, the kinetic energy Ek of a point object is defined by its mass m and velocity v: 1 E = mv 2 k 2 Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Kinetic Energy Definition The energy which an object possesses due to its motion It is defined as the work needed to accelerate a body of a given mass from rest to its stated velocity Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Kinetic Energy Definition The energy which an object possesses due to its motion It is defined as the work needed to accelerate a body of a given mass from rest to its stated velocity In classical mechanics, the kinetic energy Ek of a point object is defined by its mass m and velocity v: 1 E = mv 2 k 2 The amount of gravitational potential energy possessed by an elevated object is equal to the work done against gravity in lifting it Thus, for an object at height h, the gravitational potential energy Ep is defined by its mass m, and the gravitational constant g: Ep = mgh Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Potential Energy Definition The energy of an object or a system due to the position of the body or the arrangement of the particles of the system Thus, for an object at height h, the gravitational potential energy Ep is defined by its mass m, and the gravitational constant g: Ep = mgh Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Potential Energy Definition The energy of an object or a system due to the position of the body or the arrangement of the particles of the system The amount of gravitational potential energy possessed by an elevated object is equal to the work done against gravity in lifting it Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Potential Energy Definition The energy of an object or a system due to the position of the body or the arrangement of the particles of the system The amount of gravitational potential energy possessed by an elevated object is equal to the work done against gravity in lifting it Thus, for an object at height h, the gravitational potential energy Ep is defined by its mass m, and the gravitational constant g: Ep = mgh Lagrange's equations employ a single scalar function, rather than vector components To derive the equations modeling an inverted pendulum all we need to know is how to take partial derivatives Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Lagrangian Mechanics An analytical approach to the derivation of E.O.M. of a mechanical system To derive the equations modeling an inverted pendulum all we need to know is how to take partial derivatives Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Lagrangian Mechanics An analytical approach to the derivation of E.O.M. of a mechanical system Lagrange's equations employ a single scalar function, rather than vector components Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Lagrangian Mechanics An analytical approach to the derivation of E.O.M. of a mechanical system Lagrange's equations employ a single scalar function, rather than vector components To derive the equations modeling an inverted pendulum all we need to know is how to take partial derivatives E.O.M. can be directly derived by substitution using EulerLagrange equation: d @L @L = dt @θ_ @θ Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Lagrangian Definition In classical mechanics, the natural form of the Lagrangian is defined as L = Ek − Ep Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Lagrangian Definition In classical mechanics, the natural form of the Lagrangian is defined as L = Ek − Ep E.O.M. can be directly derived by substitution using EulerLagrange equation: d @L @L = dt @θ_ @θ Problem Our problem is to derive the E.O.M. which relates time with the acceleration of the angle from the vertical position Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Inverted Pendulum Problem The pendulum is a stiff bar of length L which is supported at one end by a frictionless pin The pin is given an oscillating vertical motion s defined by: s(t) = A sin !t Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Inverted Pendulum Problem The pendulum is a stiff bar of length L which is supported at one end by a frictionless pin The pin is given an oscillating vertical motion s defined by: s(t) = A sin !t Problem Our problem is to derive the E.O.M. which relates time with the acceleration of the angle from the vertical position Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Visualization Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Visualization Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Visualization Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Visualization Recall the definition of the Lagrangian L = Ek − Ep 1 L = mv 2 − mgy 2 Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Setup From the figure on previous page we know x = L sin θ x_ = L cos (θ)θ_ y = L cos θ y_ = −L sin (θ)θ_ Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Setup From the figure on previous page we know x = L sin θ x_ = L cos (θ)θ_ y = L cos θ y_ = −L sin (θ)θ_ Recall the definition of the Lagrangian L = Ek − Ep 1 L = mv 2 − mgy 2 Substituting into the equation for the Lagrangian we get 1 L = mv 2 − mgy 2 1 L = mL2θ_2 − mgL cos θ 2 Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Setup Continued... Velocity is a vector representing the change in position, hence v 2 =x _ 2 +y _ 2 = L2θ_2 cos2 θ + L2θ_2 sin2 θ = L2θ_2(cos2 θ + sin2 θ) = L2θ_2 1 L = mv 2 − mgy 2 1 L = mL2θ_2 − mgL cos θ 2 Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Setup Continued... Velocity is a vector representing the change in position, hence v 2 =x _ 2 +y _ 2 = L2θ_2 cos2 θ + L2θ_2 sin2 θ = L2θ_2(cos2 θ + sin2 θ) = L2θ_2 Substituting into the equation for the Lagrangian we get Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Setup Continued... Velocity is a vector representing the change in position, hence v 2 =x _ 2 +y _ 2 = L2θ_2 cos2 θ + L2θ_2 sin2 θ = L2θ_2(cos2 θ + sin2 θ) = L2θ_2 Substituting into the equation for the Lagrangian we get 1 L = mv 2 − mgy 2 1 L = mL2θ_2 − mgL cos θ 2 Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Setup Continued... Recall the Euler-Lagrange equation d @L @L = dt @θ_ @θ We shall now compute both sides of the equation and solve for θ¨ @L = 0 + mgL sin θ @θ = mgL sin θ Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator @L Computing @θ 1 L = mL2θ_2 − mgL cos θ 2 Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator @L Computing @θ 1 L = mL2θ_2 − mgL cos θ 2 @L = 0 + mgL sin θ @θ = mgL sin θ @L = mL2θ_ − 0 @θ_ = mL2θ_ d @L = mL2θ¨ dt @θ_ Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Computing d @L dt @θ_ 1 L = mL2θ_2 − mgL cos θ 2 We compute in two steps: d @L = mL2θ¨ dt @θ_ Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Computing d @L dt @θ_ 1 L = mL2θ_2 − mgL cos θ 2 We compute in two steps: @L = mL2θ_ − 0 @θ_ = mL2θ_ Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Computing d @L dt @θ_ 1 L = mL2θ_2 − mgL cos θ 2 We compute in two steps: @L = mL2θ_ − 0 @θ_ = mL2θ_ d @L = mL2θ¨ dt @θ_ d @L @L = dt @θ_ @θ mL2θ¨ = mgL sin θ g θ¨ = sin θ L Which is the equation presented in the assignment. Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Applying Euler-Lagrange Equation Now that we have both sides of the Euler-Lagrange Equation we can solve for θ¨ Background Inverted Pendulum Visualization Derivation Without Oscillator Derivation With Oscillator Applying Euler-Lagrange Equation Now that we have both sides of the Euler-Lagrange Equation we can solve for θ¨ d @L @L = dt @θ_ @θ mL2θ¨ = mgL sin θ g θ¨ = sin θ L Which is the equation presented in the assignment. Again, we use the definition