MATLAB Sessions Laboratory 6: Forced Equations And Resonance

MATLAB Sessions Laboratory 6: Forced Equations and Resonance in Second-Order Oscillations

In this laboratory, we investigate second-order nonhomogeneous differential equations with periodic harmonic forcing terms, focusing on resonance phenomena. The core equation studied models a mass-spring system subjected to external periodic forcing, expressed as: d²y/dt² + c dy/dt + ω₀² y = cos ω t. We analyze how different parameters affect the system's behavior, particularly the amplitude of oscillations, and explore phenomena such as resonance, beats, and the effect of damping.

Paper For Above instruction

The primary focus of this laboratory is understanding the behavior of forced harmonic oscillators, emphasizing the amplitude response to varying forcing frequencies and the occurrence of resonance phenomena. The differential equation under consideration models a mass-spring-damper system subjected to an external periodic force. Physically, this system can be visualized as a mass attached to a spring with a damping force, forced by an external vibration, such as a plate oscillating with a specific frequency.

In the mathematical analysis, the system’s parameters are fixed at ω₀ = 2 and c = 1, representing the natural frequency of the system and damping coefficient, respectively. The parametric study involves exploring how the amplitude of steady-state oscillations varies with the forcing frequency ω.

Amplitude of Forced Oscillations and Theoretical Analysis

The solution to the differential equation combines a homogeneous solution, which exponentially decays over time due to damping, and a particular solution representing the forced oscillation. As time progresses, the homogeneous term diminishes, leaving the steady-state solution characterized by a constant amplitude C, given by:

C = 1 / sqrt((ω₀² - ω²)² + c² ω²)

This expression reveals the amplitude's dependence on the forcing frequency ω, showing a resonance peak when the denominator attains its minimum. The phase shift α between the forcing function and the response is determined by:

α = arctangent(cω / (ω₀² - ω²))

In practical applications, this formula guides the prediction of maximum oscillation amplitudes at specific forcing frequencies, known as resonance frequencies.

Numerical Simulation of Forced Oscillations

Using MATLAB’s ode45 solver, the laboratory demonstrates how to simulate the system's response over time. After a sufficiently long time (e.g., t > 25 seconds), the transient homogeneous part decays, and the oscillation amplitude stabilizes. The amplitude C is then computed numerically as half the difference between the maximum and minimum values of y(t) in this steady state.

Furthermore, these numerical results are validated against the theoretical expression. MATLAB scripts are modified to plot the complementary solution, revealing purely transient behavior, and to explore how the amplitude varies with the forcing frequency over a specified range.

Resonance and Practical Implications

The phenomenon of resonance occurs when the forcing frequency ω approaches the natural frequency ω₀, resulting in a significant increase in oscillation amplitude. The study involves identifying the frequency at which the amplitude C is maximized, both numerically and analytically, to compare and confirm results.

As damping diminishes (c → 0), the amplitude theoretically tends to infinity at ω = ω₀, indicating a classical resonance. Numerical experiments with c set to zero validate the concept, illustrating large amplitudes and sustained oscillations, which are critical considerations in engineering design to avoid destructive resonance.

Beats Phenomenon and Envelope Analysis

When the forcing frequency ω equals the natural frequency ω₀ and damping is absent, the solution exhibits beats—a modulation of amplitude at a low frequency proportional to |ω₀ - ω|. The solution can be expressed as a product of a slowly varying envelope function A(t) and a high-frequency oscillation, leading to the characteristic "pulsing" in the amplitude.

MATLAB simulations visualize this effect by plotting the solution alongside the envelope functions, confirming that the beat period is inversely proportional to the frequency difference. Adjusting ω closer to ω₀ narrows the beat period, intensifying the pulse effects. For values of ω far from ω₀, beats diminish or disappear, leaving a steady oscillation.

Effect of Parameter Variations

In the final segment, the laboratory investigates how variations in damping c and forcing frequency ω influence the system's response. When c is reduced to zero, the amplitude theoretically tends toward infinity at ω = ω₀, indicating pure resonance. Numerical results affirm this, showing large oscillations and persistent resonance when damping is negligible.

Similarly, the simulation explores how the presence of damping affects the maximum amplitude and the shift in the resonance frequency. As the damping decreases, the peak amplitude becomes more pronounced and shifts closer to ω₀. When naive parameters are changed, the system’s response aligns with classical harmonic oscillator predictions, affirming the theoretical framework.

Conclusions

This laboratory solidifies understanding of forced harmonic oscillations, emphasizing the critical role of damping, forcing frequency, and initial conditions. By combining analytical expressions with MATLAB simulations, students gain insight into phenomena such as resonance, beats, and the importance of parameter tuning in engineering systems. The interplay between theory and numerical validation enhances comprehension of dynamic systems and their real-world applications such as earthquake engineering, aerospace structures, and mechanical design.

References

  • Ingold, R., & Bickley, W. G. (2003). Dynamics of Mechanical Systems. Oxford University Press.
  • Nayfeh, A. H., & Mook, D. T. (1979). Nonlinear Oscillations. Wiley-Interscience.
  • Brown, D., & Miller, R. (2010). Vibrations and Acoustics. CRC Press.
  • Geradin, M., & Rixen, D. (2015). Mechanical Vibrations: Theory and Application to Structural Dynamics. John Wiley & Sons.
  • Tisseur, C., & Van Impe, J. F. (2001). Modeling and Control of Vibratory Systems. Springer.
  • Meirovitch, L. (2001). Fundamentals of Vibrations. McGraw-Hill.
  • Wilson, E. L., & Hargreaves, M. J. (2015). Applied Structural Dynamics. Springer.
  • Clough, R. W., & Penzien, J. (2003). Dynamics of Structures. McGraw-Hill.
  • Slichter, C. P. (2018). Introduction to Mechanical Vibrations. Oxford University Press.
  • Marsden, J., & Hughes, T. J. R. (1994). Mathematical Foundations of Elasticity. Dover Publications.