# rotnum.ode # code to compute rotation number # This is set up for XPP # you can run it with a GUI or just to do the computation # xpp rotnum.ode -silent # plot the resulting output.dat file to see the devils staircase! # with the GUI, # click on InitConds Range Okay # prc(x)=-.75*sin(x) f(x,tau)=x+prc(x)+tau x'=f(x,tau) tau'=tau @ bound=10000000 aux rho=x/(2*pi*max(t,1)) @ meth=discrete,total=2000,trans=1999 @ rangeover=tau @ rangereset=no @ rangestep=200 @ rangehigh=10,rangelow=0 @ xp=tau,yp=rho @ xlo=0,xhi=10 @ ylo=0,yhi=1.75 @ range=1 only tau,rho done