Reference no: EM132382150
Matlab Dynamic Systems Assignment -
The equation of motion for the standard mass-spring-damper system is
Mx·· + Bx· + Kx = f (t).
1. Given the parameters M = 2kg and K = 400N /m, create a single figure showing plots of the free response of the system to an initial conditions {xo = 1m, vo = 0 m/s} for the damping ratios ζ = {0.01, 0.1, 0.2, 0.5, 0.707, 1, 1.1, 1.2}. To that end, you should:
a. Determine a matrix of coefficients B = {B1, B2, · · · B8}.
b. "For" (hint, hint!) each of those coefficients, simulate the response of the system using the Matlab function ode45. Plot the displacement of the mass as a function of time for the first 0.5s. Use a time-resolution of 0.001s (have ode45 return values of x(t) at 1 ms intervals). All axes should be properly labeled and you should have a legend. Use different line-styles in order to be clear about which trace corresponds to which damping ratio. Your name, class section, and date should be the title of the figure.
c. Determine the exact analytic ("hand") solution to the problem for the two cases ζ1 = 0.01 and ζ8 = 1.2. Use Matlab to calculate the values of those solution at 0.05s time-steps. Create a second figure that includes plots of the two numerical solutions and the two analytical solutions. Use different line-types for the two numerical solutions and no lines for the analytical solutions. Instead, use blue diamonds for the response corresponding to ζ1 = 0.01 and red squares for ζ8 = 1.2. Figure labeling should be as for the first figure above.
II. Repeat Part I, but use initial conditions {xo = 0m, vo = 10 m/s}. You should two more figures: one with eight plots on it and a second with four plots (two line plots, two symbol plots).
III. Repeat Part I, but use initial conditions {xo = -1m, vo = 10 m/s}. You should have two more figures.
IV. Using the same system as for Parts I-III above, determine the step-responses of the systems to a step function of 100N applied at time t = 0. Again, you should have two more figures.