close all
clear all

va0 = 100;
fi0=pi()/6;
h=300;
g=9.81;

vy=va0*sin(fi0);

tmax = (-vy-sqrt(vy*vy+2*g*h))/(-g)

t = 0:0.01:tmax;

xa = va0*cos(fi0)*t;
ya = (-1/2)*g*(t.^2) + va0*sin(fi0)*t + h;

plot(xa,ya)