Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Create a MATLAB program to simulate motion of a pendulum in 2-D. The pendulum is a uniform slender rod with its upper end inertially fixed
Create a MATLAB program to simulate motion of a pendulum in 2-D. The pendulum is a uniform slender rod with its upper end inertially fixed with a frictionless pin joint. Use Euler integration to solve the equation of motion. The pendulum should have a length of 1 meter and a mass of 5 kg.
- Plot and animate the motion of the pendulum for 5 seconds using an initial angle of 40 degrees and initial angular velocity of 0 deg/sec. You will need to determine dt such that the pendulum motion is as expected.
- Vary the time step until the pendulum becomes unstable. Plot and animate the motion. How does this compare to the motion simulated in #1 above? Why does this happen?
Include a separate MATLAB code for each part. Each code should have an animation and a plot of angle as a function of time. Include and descriptive answer at the bottom of the related code (don't forget to comment out).
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started