function  ball
%An ODE example, Minimal version, NOT ACCEPTABLE FOR HW
[t,z] = ode45(@f,[0 10],[0 10]);
plot(t,z(:,1));

% ---------------------------------------------------
function zdot = f(t,z)
g=10; c=5; m = 20;   % parameters
zdot = [ z(2); -g-c*z(2)^2/m  ]; % note the transpose
% -------------------------------------------------

