Since you were given these formulas by the teacher, let's agree on what each symbol means.
-
t = time elapsed since launching the projectile, in seconds.
-
g = gravity, in meters per second squared ( 9.81 m/s² )
-
alpha (α) = the angle above horizontal of the launch, like a cannon. In AI2 that would be degrees, usually positive (unless you are digging a tunnel.)
-
v0 is the initial velocity
-
x is the horizontal displacement of the projectile in meters, at time t
-
y is the vertical displacement of the projectile, at time t
Please note that Canvas y values are reversed from math graph y values. Canvas graph ys start at the top and extend downwards.
The first equation (r,x,y,i) is unfamiliar and unnecessary.
Before I dive into your app, note that AI2 has a very nice graph component that would make this easy.