% right-hand side of pendulum ODE

function yDot = pendulum_rhs(t,y)

global m g 

yDot = zeros(size(y),1);
yDot(1) = y(2);
yDot(2) = -g/m*sin(y(1));