In [1]:
;pwd
In [2]:
;cd ..
In [3]:
include("kicked-rotor.jl")
Out[3]:
In [4]:
using PyPlot
In [5]:
function plot_points(N, k)
data = zeros(N, 2)
x0 = [2pi*rand(), 2pi*rand()]
for i in 1:N
output = T0(x0, k, i)
data[i, 1:2] = output
end
data
end
Out[5]:
In [11]:
p2_points = [
1.32812164615400647499 2.65624329230801270538;
3.1415926535897929937 3.14159265358979299348;
4.95506366102558011696 3.62694201487157351165]
Out[11]:
In [12]:
p3_points = [
0.806560442745249376478 1.61312088549050729701;
1.76748900938308797098 1.7674890093830876094;
4.51569629779649877807 2.74820728841341117127;
5.47662486443433212634 2.33503221084453809028;
0.806560442745255646961 3.94815309633504728909;
1.76748900938308795797 3.53497801876617509433;
4.515696297796499524 4.51569629779649880409;
5.47662486443433730145 4.67006442168907884207]
Out[12]:
In [13]:
p4_points = [
0.49205012902309243144 0.984100258046184617634;
1.12061271550002283293 1.12061271550002283185;
1.94858418114797580253 1.45653405212488297558;
4.33460112603161137933 2.38601694488363606458;
5.79113517815649389738 1.45653405212488297373;
5.16257259168158489336 2.02097993808812039277;
1.1206127154980039095 4.26220536909146416197;
0.492050129023091697679 4.82665125505470410557;
1.94858418114797550947 3.89716836229595025741;
4.33460112603161313617 4.82665125505470410036;
5.16257259167956314384 5.16257259167956295736;
5.79113517815649432412 5.29908504913340143742]
Out[13]:
In [10]:
k = 1
for i in 1:500
points = plot_points(200, k);
plot(points[:,1], points[:,2], "b.", markersize=1, alpha=0.3)
end
plot(p2_points[:,1], p2_points[:,2], "r.", markersize=3)
plot(p3_points[:,1], p3_points[:,2], "r.", markersize=5)
plot(p4_points[:,1], p4_points[:,2], "m.", markersize=5)
#plt.xlim(1,2)
#plt.ylim(0.9, 1.5)
#plt.xlabel(L"$\theta$")
#plt.ylabel(L"$\phi$")
xlabel("x")
ylabel("p")
plt.savefig("standard_k$k.pdf")
In [ ]: