Using Simulink to analyze 2 degrees of freedom system

Similar documents
Identification Methods for Structural Systems. Prof. Dr. Eleni Chatzi Lecture March, 2016

Vibrations Qualifying Exam Study Material

Solving the Van Der Pol nonlinear differential equation using first order approximation perturbation method

MATH 23 Exam 2 Review Solutions

Solving beam deflection problems using the moment-deflection approach and using the Euler-Bernoulli approach

Dynamics of Structures

Math Assignment 5

Solutions for homework 5

Math 1302, Week 8: Oscillations

Introduction to Modern Control MT 2016

ENGIN 211, Engineering Math. Laplace Transforms

In the presence of viscous damping, a more generalized form of the Lagrange s equation of motion can be written as

CDS 101/110a: Lecture 2.1 Dynamic Behavior

Vibrations: Second Order Systems with One Degree of Freedom, Free Response

AA242B: MECHANICAL VIBRATIONS

Seminar 6: COUPLED HARMONIC OSCILLATORS

ME8230 Nonlinear Dynamics

CDS 101/110a: Lecture 2.1 Dynamic Behavior

Hamilton-Jacobi theory

y 2y = 4 x, Name Form Solution method

The Phasor Analysis Method For Harmonically Forced Linear Systems

Lab 1: Dynamic Simulation Using Simulink and Matlab

SHAKING TABLE DEMONSTRATION OF DYNAMIC RESPONSE OF BASE-ISOLATED BUILDINGS ***** Instructor Manual *****

Keble College - Hilary 2014 CP3&4: Mathematical methods I&II Tutorial 5 - Waves and normal modes II

F = ma, F R + F S = mx.

HW 9, Math 319, Fall 2016

Physics 5153 Classical Mechanics. Canonical Transformations-1

Lab #2 - Two Degrees-of-Freedom Oscillator

ECE 301 Division 1 Exam 1 Solutions, 10/6/2011, 8-9:45pm in ME 1061.

221B Lecture Notes on Resonances in Classical Mechanics

MAE143A Signals & Systems - Homework 5, Winter 2013 due by the end of class Tuesday February 12, 2013.

The Plan. Initial value problems (ivps) for ordinary differential equations (odes) Review of basic methods You are here: Hamiltonian systems

Figure 1 A linear, time-invariant circuit. It s important to us that the circuit is both linear and time-invariant. To see why, let s us the notation

BMEN 398: MATLAB Module: Higher Order Differential Equations; SIMULINK Fall 2005 Updated 8/21/2005 Hart

5.1 Classical Harmonic Oscillator

1-DOF Forced Harmonic Vibration. MCE371: Vibrations. Prof. Richter. Department of Mechanical Engineering. Handout 8 Fall 2011

Dynamic Loads CE 543. Examples. Harmonic Loads

Variation Principle in Mechanics

18. Impulse and step responses

ME 375 EXAM #1 Friday, March 13, 2015 SOLUTION

Math 3313: Differential Equations Second-order ordinary differential equations

MATH 2250 Final Exam Solutions

Physics 8, Fall 2011, equation sheet work in progress

Matrix power converters: spectra and stability

kx m x B N 1 C L, M Mg θ

4. Sinusoidal solutions

Laboratory handouts, ME 340

: TEACHING DIFFERENTIAL EQUATIONS WITH AN ENGINEERING FOCUS

Math 333 Qualitative Results: Forced Harmonic Oscillators

Physics 8, Fall 2013, equation sheet work in progress

Damped harmonic motion

MATHEMATICAL MODELLING, MECHANICS AND MOD- ELLING MTHA4004Y

Chapter 3 : Linear Differential Eqn. Chapter 3 : Linear Differential Eqn.

Dr.Vinod Hosur, Professor, Civil Engg.Dept., Gogte Institute of Technology, Belgaum

1 Review of simple harmonic oscillator

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 4.0 License.

Problem 4.4 Derive the ramp response by nding the particular and homogeneous solutions of the ordinary di. equation.

Classical Mechanics Comprehensive Exam Solution

Chapter 5 Design. D. J. Inman 1/51 Mechanical Engineering at Virginia Tech

CHAPTER 6 STATE SPACE: FREQUENCY RESPONSE, TIME DOMAIN

EQUIVALENT SINGLE-DEGREE-OF-FREEDOM SYSTEM AND FREE VIBRATION

CHAPTER 12 TIME DOMAIN: MODAL STATE SPACE FORM

L = 1 2 a(q) q2 V (q).

Imaginary. Axis. Real. Axis

OSE801 Engineering System Identification. Lecture 09: Computing Impulse and Frequency Response Functions

ECE 602 Solution to Homework Assignment 1

4. Complex Oscillations

System Parameter Identification for Uncertain Two Degree of Freedom Vibration System

ES205 Analysis and Design of Engineering Systems: Lab 1: An Introductory Tutorial: Getting Started with SIMULINK

MAE 305 Engineering Mathematics I

ODE Homework 1. Due Wed. 19 August 2009; At the beginning of the class

Final Exam April 30, 2013

Multi Degrees of Freedom Systems

28. Pendulum phase portrait Draw the phase portrait for the pendulum (supported by an inextensible rod)

1 Pushing your Friend on a Swing

10.34: Numerical Methods Applied to Chemical Engineering. Lecture 19: Differential Algebraic Equations

Linear Filters. L[e iωt ] = 2π ĥ(ω)eiωt. Proof: Let L[e iωt ] = ẽ ω (t). Because L is time-invariant, we have that. L[e iω(t a) ] = ẽ ω (t a).

(f g)(t) = Example 4.5.1: Find f g the convolution of the functions f(t) = e t and g(t) = sin(t). Solution: The definition of convolution is,

Date: 1 April (1) The only reference material you may use is one 8½x11 crib sheet and a calculator.

Structural Dynamics Lecture 4. Outline of Lecture 4. Multi-Degree-of-Freedom Systems. Formulation of Equations of Motions. Undamped Eigenvibrations.

Imaginary. Axis. Real. Axis

Transient Response Analysis of Structural Systems

ODE classification. February 7, Nasser M. Abbasi. compiled on Wednesday February 07, 2018 at 11:18 PM

Date: 31 March (1) The only reference material you may use is one 8½x11 crib sheet and a calculator.

Solution of Vibration and Transient Problems

SRV02-Series Rotary Experiment # 7. Rotary Inverted Pendulum. Student Handout

Vibrational Motion. Chapter 5. P. J. Grandinetti. Sep. 13, Chem P. J. Grandinetti (Chem. 4300) Vibrational Motion Sep.

Analytical Mechanics ( AM )

Math 266 Midterm Exam 2

CHAPTER 12 OSCILLATORY MOTION

LINEAR RESPONSE THEORY

ECE 301 Fall 2011 Division 1 Homework 5 Solutions

PH.D. PRELIMINARY EXAMINATION MATHEMATICS

Lagrangian Dynamics: Derivations of Lagrange s Equations

GATE EE Topic wise Questions SIGNALS & SYSTEMS

Some Aspects of Structural Dynamics

Laboratory handout 5 Mode shapes and resonance

MODELLING OF VIBRATION WITH ABSORBER

INC 341 Feedback Control Systems: Lecture 2 Transfer Function of Dynamic Systems I Asst. Prof. Dr.-Ing. Sudchai Boonto

Rotary Inverted Pendulum

Transcription:

Using Simulink to analyze 2 degrees of freedom system Nasser M. Abbasi Spring 29 page compiled on June 29, 25 at 4:2pm Abstract A two degrees of freedom system consisting of two masses connected by springs and subject to 3 different type of input forces is analyzed and simulated using Simulink Contents Introduction and Theory 2 2 Analytical solution 2 2. Finding the homogenous solution.................................... 3 2.2 Finding particular solutions....................................... 5 2.2. Finding the particular solution for unit impulse input.................... 6 2.2.2 Finding the particular solution for unit step input...................... 6 2.2.3 Finding the particular solution for sin ωt............................ 6 3 Simulink simulation and block diagrams 7 3. Unit step simulink diagram and output................................ 8 3.. Verification of result from Simulink by Numerically solving the differential equations... 9 4 Unit impulse simulink diagram and output 4.. Verification of result from Simulink by Numerically solving the differential equations... 4. sin ωt input simulink diagram and output.............................. 2 5 Discussion 4

Introduction and Theory The system that is being analyzed is show in the following diagram Ft m x k m 2 k 2 In the above, F t is to be taken as each of the following. Unit impulse force. 2. Unit step force. 3. sin ωt It is required to find x t and t analytically and then to use Matlab s Simulink software for the analysis. The mathematical model of the system is first developed and the equation of motions obtained using Lagrangian formulation then the analytical solution is found by solving the resulting coupled second order differential equations for m and m 2. Next, a simulink model is developed to implement the differential equations and the output x t and t from Simulink is shown and compared to the output from the analytical solution. 2 Analytical solution The following is the free body diagram of the above system 2

Ft m x K -x K -x m 2 K 2 Assuming positive is downwards and that > x, force-balance equations for m results in And force-balance equations for m 2 results in m ẍ F t k x m 2 ẍ 2 k x k 2 Hence the EQM for the system become m ẍ k k x F t m 2 ẍ 2 k k 2 k x Or in matrix form m m 2 ẍ ẍ 2 k k k k k 2 x F t The above can be written in matrix form as Mẍ Kx F Where ẍ, x, F are 2 by vectors and M and K are the mass and stiffness matrices. The solution to the above is x x h x p 2. Finding the homogenous solution We start by finding x h from the following m m 2 ẍ ẍ 2 k k k k k 2 x 3

Now assume x t A cos ωt φ and t A 2 cos ωt φ, hence ẋ t ωa sin ωt φ and ẋ 2 t ωa 2 sin ωt φ and ẍ t ω 2 A cos ωt φ and ẋ 2 t ω 2 A 2 cos ωt φ. Substituting the above values in the above system results in m ω 2 A cos ωt φ k k A cos ωt φ m 2 ω 2 A 2 cos ωt φ k k k 2 A 2 cos ωt φ Divide by cos ωt φ since not zero else no solution exist we obtain m ω 2 A k k A m 2 ω 2 A 2 k k k 2 A 2 Rewrite the above as ω 2 m A k A k A 2 ω 2 m 2 A 2 k A k k 2 A 2 ω 2 m A k A k A 2 ω 2 m 2 A 2 k A k k 2 A 2 ω 2 m k A k A 2 ω 2 m 2 A 2 k k 2 A 2 k A ω 2 m k k A k ω 2 m 2 k k 2 A 2 2 From the last equation above, we see that to obtain a solution we must have ω 2 m k k k ω 2 m 2 k k 2 since if we had results in A A 2 then no solution will exist. Therefore, taking the determinant and setting it to zero Let ω 4 λ 2, hence the above becomes Solving for λ gives ω 2 m k ω 2 m 2 k k 2 k 2 k 2 k k 2 ω 2 k m ω 2 k m 2 ω 2 k 2 m ω 4 m m 2 k 2 ω 4 m m 2 ω 2 k m k 2 m k m 2 k 2 k k 2 k 2 λ 2 m m 2 λ k m k 2 m k m 2 k 2 k k 2 k 2 λ 2m m 2 k m k m 2 k 2 m k 2m2 k2 m2 2 k2 2 m2 2k k 2 m 2 2k2 m m 2 2k k 2 m m 2 λ 2 2m m 2 k m k m 2 k 2 m k 2m2 k2 m2 2 k2 2 m2 2k k 2 m 2 2k2 m 3 m 2 2k k 2 m m 2 For each of the above solutions, we obtain a different A 4 A 2 from equation 2 as follows

For λ, 2 becomes λ m k k A k λ m 2 k k 2 A 2 λ m k A k A 2 k A λ m 2 A 2 k k 2 A 2 From the first equation above, we have λ m k A k A 2 λ m k k A2 A Similarly for λ 2, Let λ 2 m k k 2 A2 A Hence now x h can be written as x h r λ m k k r 2 λ 2m k k A2 A 2 A2 A A cos ω t φ A 2 cos ω 2 t φ 2 A 2 cos ω t φ A 2 2 cos ω 2 t φ 2 4 But A 2 r A and A 2 2 r 2 A 2 x h, hence the above becomes A cos ω t φ A 2 cos ω 2 t φ 2 r A cos ω t φ r 2 A 2 cos ω 2 t φ 2 5 Now, given numerical values for k, k 2, m, m 2 we can find ω, ω 2 from 3 above, and next find r, r 2 from 4. Hence 5 contains 4 unknowns, A, A2, φ, φ 2 which now can be found from initial conditions after we find the particular solution which we will now proceed to do. 2.2 Finding particular solutions There are 3 different F t which we are asked to consider. Unit impulse force. 2. Unit step force. 3. sin ωt For each of the above, we find x p and then add it to x h found above in 5 to obtain. 5

2.2. Finding the particular solution for unit impulse input Using the standard response for a unit impulse which for a single degree of freedom system is x t mω n sin ω n t, then we write x p as x mω x p sin ω t mω 2 sin ω 2 t Hence, the general solution becomes x A cos ω t φ A 2 cos ω 2 t φ 2 r A cos ω t φ r 2 A 2 cos ω 2 t φ 2 2.2.2 Finding the particular solution for unit step input Since unit step is for t >, then, using convolution we write p p x p t t t t mω n f τ h t τ dτ h t τ dτ sin ω n t τ dτ mω n [ cos ωn t τ ω n mωn 2 [cos ω n t τ] t mωn 2 [ cos ω n t] mω sin ω t Then, since now we have 2 natural frequencies, we can write x p as x x p [ cos ω mω 2 t] [ cos ω mω2 2 2 t] Hence, the general solution becomes x A cos ω t φ A 2 cos ω 2 t φ 2 r A cos ω t φ r 2 A 2 cos ω 2 t φ 2 2.2.3 Finding the particular solution for sin ωt mω 2 ] t [ cos ω t] mω2 2 mω 2 sin ω 2 t [ cos ω 2 t] In this case, we guess that x p c cos ωt c 2 sin ωt, and since there is no forcing function being applied directly on m 2 then p hence x t c cos ωt c 2 sin ωt x p t p Then ẋ p t ωc sin ωt ωc 2 cos ωt and ẍ p t ω 2 c cos ωt ω 2 c 2 sin ωt and now we substitute these into the original ODE for x which is m ẍ k k x F t m ẍ p k p k x p sin ωt 6 6

We obtain the following m ω 2 c cos ωt ω 2 c 2 sin ωt k k c cos ωt c 2 sin ωt sin ωt Hence by comparing coefficients, we obtain or cos ωt ω 2 c m k c sin ωt m ω 2 c 2 k c 2 sin ωt ω 2 c m k c m ω 2 c 2 k c 2 c ω 2 m k c 2 m ω 2 k c must be zero since k ω 2 m only when ω ω n and we assume that this is not the case here. Hence c c 2 m ω 2 k Therefore x p becomes And the general solution becomes x x p x t t p m ω 2 k sin ωt A cos ω t φ A 2 cos ω 2 t φ 2 r A cos ω t φ r 2 A 2 cos ω 2 t φ 2 m ω 2 k sin ωt 8 3 Simulink simulation and block diagrams In simulink, we will directly solve the system from the original formulation or Hence m ẍ k k x F t m 2 ẍ 2 k k 2 k x ẍ k k x F t m m m ẍ 2 k k 2 k x m 2 m 2 ẍ F t m k m k m x ẍ 2 k k 2 m 2 k m 2 x 7

3. Unit step simulink diagram and output The simulink block diagram will be as follows for the unit step input For an initial run with parameters m m 2 k k 2 I get this warning below EDU>> simulink Warning: Using a default value of.2 for maximum step size. The simulation step size will be equal to or less than this value. You can disable this diagnostic by setting 'Automatic solver parameter selection' diagnostic to 'none' in the Diagnostics page of the configuration parameters dialog. And this is the output for x t and t for the unit step response 8

3.. Verification of result from Simulink by Numerically solving the differential equations To verify the above output from Simulink, I solved the same coupled differential equations for zero initial conditions numerically using a numerical differential equation solver and plotted the solution for x t and t and the result matches that shown above by simulink. Here is the code the plot as a result of this verification k ; k 2 ; m ; m 2 ; eq m x ''[t] - k [t] k x [t] f[t] eq2 m 2 ''[t] k k 2 [t] - k x [t] sol NDSolve[{eq, eq2, x [], x '[], [], '[] }, {x [t], [t]}, {t,, 35}]; 9

4 Solutions x t and t 3 x t t xt 2 unit step input 5 5 2 25 3 35 t 4 Unit impulse simulink diagram and output

And the output for x t and t is as follows run with parameters m m 2 k k 2 Mass m Mass m 2 INPUT Mass m 2 Solution to the following coupled second order differential equations when Ft is a unit impulse m x k k x F t m 2 x 2 k k 2 k x 4.. Verification of result from Simulink by Numerically solving the differential equations To verify the above output from Simulink, The same coupled differential equations were solved numerically for zero initial conditions numerically and the solution plotted for x t and t and the result was found to match that shown above by simulink. Here is the code used to do the verification verification

f[x_] : Piecewise[{{, x < }, {, x >.}, {, True}}] k ; k 2 ; m ; m 2 ; eq m x ''[t] - k [t] k x [t] f[t] eq2 m 2 ''[t] k k 2 [t] - k x [t] sol NDSolve[{eq, eq2, x [], x '[], [], '[] }, {x [t], [t]}, {t,, 35}]; sol Chop[sol] sol x [t] /. sol sol2 [t] /. sol Plot[Evaluate[{f[t], sol, sol2}], {t,, 35}, Frame True, FrameLabel {{"xt", None}, {"t", "Solutions x t and t"}}] Solutions x t and t.2.5 x t. xt.5. -.5 t -. 5 5 2 25 3 35 t 4. sin ωt input simulink diagram and output The simulink block diagram will be as follows for the sin ωt input 2

For an initial run with parameters m m 2 k k 2 this is the output for x t and t and showing the input signal at the same time 3

5 Discussion A coupled system of two masses and springs was analyzed using Simulink. The simulation was done for one set of parameters masses and stiffness. Simulink made the simulation of this system under different loading conditions easy to do. The 2 masses response were recorded using simulink scope and the signals captured on the same plot to make it easy to compare the response of the first mass to the second mass. The analytical analysis was more time consuming than actually making the simulation in simulink. The ability to easily change different sources to the system was useful as well as the ability to change the frequency of the input and immediately see the effect on the response. This was my first project using Simulink, and I can see that this tool will be useful to learn more as it allows one to easily analyze engineering problems. 4