Studying the behaviour of a pendulum beyond the small angle approximation by using numerical methods
This lecture will first revisit a classic from your Waves course: the pendulum. However, we will see how numerical methods can be used to study the pendulum beyond the small angle approximations.
Write the pseudocode to solve the equation of motion of the pendulum using Verlet's method.
Due at the beginning of the lab.
To give you an idea, the generic pseudocode of Euler's method we saw in class is shown below. We want something equivalent that will show how to apply Verlet's method to the pendulum.
Set initial conditions x, t
Set end time tFinal
Set step size dt
x[i+1] = x[i] + f(x[i],t[i]) * dt
t[i+1] = t[i] + dt
Continue while t[i+1] < tFinal