Challenge

Week 3 - Solving second order ODEs

Aim:

Main aim of the program here is to represent tje motion of pendulum using the ode.

Simple pendulum:

A simple pendulum consists of a mass m hanging from a string of length L and fixed at a pivot point P. When displaced to an initial angle and released, the pendulum will swing back and forth with periodic motion

Above mentioned is the ODE that we will be using for Sloving the motion of simple pendulumn

and we simulate the motion between 0-20 sec, for angular displacement=0,angular velocity=3 rad/sec2 at time t=0.

Here we solve the ordinary differential equation ,using matlab inbuilt function ode45 .

here we give all the required details of the pendulumn the details mentioned are:

1.length

2.damping co-efficient

3.mass of pendulumn

4.acceleration due to gravity

here the damping occurs due to air friction and gravity pulling the bob to mean position.

The required code for both the ODE function and sloving simple pendulumn code are attached below .

here is curve of angular velocity and angular displacement

Green line defined angular displacement

red line defines angular velocity

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.