# glider v'=-sin(th)-d*v^2 th'=(v^2-cos(th))/v x'=v*cos(th)*scale y'=v*sin(th)*scale par d=.25,scale=.1,lg=.04 # these initial data correspond to a nice loop init th=0.25,v=3 init x=.1,y=.2 # some stuff for the animation # glider is just a thick line # 2*lg=length glider xl=mod(x,1)-lg*cos(th) yl=mod(y,1)-lg*sin(th) xr=mod(x,1)+lg*cos(th) yr=mod(y,1)+lg*sin(th) # some controls @ total=30,dt=.025,bound=1000000 done