This is a simplified version of [url=]Kepler motion[/url] written with EJS.
The question is why I can draw the trajectory when you change the initial condition with you mouse.
(You can drag the red arrow  to change the initial position and magnitude of velocity(vy).
How to determine the trajectory?  Do you know?

VIEW or DOWNLOAD ejs xml source
then click to translate strings for selected locale.

Press the Alt key and the left mouse button to drag the applet off the browser and onto the desktop.