In [1]:
include("birkhoff.jl")


Syntax: krawczyk2d(function, [Interval(lo, hi), Interval(lo, hi)], precision [default is 64])
WARNING: New definition 
    +(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39
is ambiguous with: 
    +(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:989.
To fix, define 
    +(AutoDiff.Ad, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    +(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40
is ambiguous with: 
    +(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:988.
To fix, define 
    +(IntervalArithmetic.IntUnion, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    -(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39
is ambiguous with: 
    -(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:992.
To fix, define 
    -(AutoDiff.Ad, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    -(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40
is ambiguous with: 
    -(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:991.
To fix, define 
    -(IntervalArithmetic.IntUnion, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    *(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39
is ambiguous with: 
    *(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:994.
To fix, define 
    *(AutoDiff.Ad, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    *(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40
is ambiguous with: 
    *(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:993.
To fix, define 
    *(IntervalArithmetic.IntUnion, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    /(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39
is ambiguous with: 
    /(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:996.
To fix, define 
    /(AutoDiff.Ad, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    /(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40
is ambiguous with: 
    /(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:995.
To fix, define 
    /(IntervalArithmetic.IntUnion, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    +(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    +(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:989.
To fix, define 
    +(PurityIntervals.PurityInterval, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    +(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    +(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40.
To fix, define 
    +(PurityIntervals.PurityInterval, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    +(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    +(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:988.
To fix, define 
    +(IntervalArithmetic.IntUnion, PurityIntervals.PurityInterval)
before the new definition.
WARNING: New definition 
    +(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    +(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39.
To fix, define 
    +(AutoDiff.Ad, PurityIntervals.PurityInterval)
before the new definition.
WARNING: New definition 
    -(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    -(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:992.
To fix, define 
    -(PurityIntervals.PurityInterval, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    -(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    -(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40.
To fix, define 
    -(PurityIntervals.PurityInterval, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    -(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    -(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:991.
To fix, define 
    -(IntervalArithmetic.IntUnion, PurityIntervals.PurityInterval)
before the new definition.
WARNING: New definition 
    -(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    -(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39.
To fix, define 
    -(AutoDiff.Ad, PurityIntervals.PurityInterval)
before the new definition.
WARNING: New definition 
    *(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    *(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:994.
To fix, define 
    *(PurityIntervals.PurityInterval, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    *(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    *(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40.
To fix, define 
    *(PurityIntervals.PurityInterval, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    *(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    *(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:993.
To fix, define 
    *(IntervalArithmetic.IntUnion, PurityIntervals.PurityInterval)
before the new definition.
WARNING: New definition 
    *(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    *(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39.
To fix, define 
    *(AutoDiff.Ad, PurityIntervals.PurityInterval)
before the new definition.
WARNING: New definition 
    /(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    /(Any, IntervalArithmetic.IntUnion) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:996.
To fix, define 
    /(PurityIntervals.PurityInterval, IntervalArithmetic.IntUnion)
before the new definition.
WARNING: New definition 
    /(PurityIntervals.PurityInterval, Any) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:30
is ambiguous with: 
    /(Any, AutoDiff.Ad) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:40.
To fix, define 
    /(PurityIntervals.PurityInterval, AutoDiff.Ad)
before the new definition.
WARNING: New definition 
    /(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    /(IntervalArithmetic.IntUnion, Any) at /home/kriukov/temp/interval-methods/modules/IntervalArithmetic.jl:995.
To fix, define 
    /(IntervalArithmetic.IntUnion, PurityIntervals.PurityInterval)
before the new definition.
WARNING: New definition 
    /(Any, PurityIntervals.PurityInterval) at /home/kriukov/temp/interval-methods/modules/PurityIntervals.jl:31
is ambiguous with: 
    /(AutoDiff.Ad, Any) at /home/kriukov/temp/interval-methods/modules/AutoDiff.jl:39.
To fix, define 
    /(AutoDiff.Ad, PurityIntervals.PurityInterval)
before the new definition.
Out[1]:
L (generic function with 1 method)

In [2]:
draw_phase_space_general(c, 1, rect, 1e-2)


Out[2]:
4-element Array{Float64,1}:
  0.0   
  1.0472
 -1.0   
  1.0   

In [5]:
# Looking for a periodic orbit in a small vicinity as an example to reduce execution time
find_periodic_orbits(c, [1, 2, 3, 1], [Interval(-0.5-0.001, -0.5+0.002), Interval(pi/6-0.001, pi/6+0.0014)], 64, 1e-4)


Unique zero in [IntervalArithmetic.Interval(-5.00000000009821129695e-01,-5.00000000006079532277e-01),IntervalArithmetic.Interval(5.23598775591066101557e-01,5.23598775607871918874e-01)]
Unique zero in [IntervalArithmetic.Interval(-5.00000000006079532331e-01,-4.9999999999155026942e-01),IntervalArithmetic.Interval(5.23598775590062783794e-01,5.23598775606868738208e-01)]
Out[5]:
([[[IntervalArithmetic.Interval(-5.00000000009821129695e-01,-5.00000000006079532277e-01),IntervalArithmetic.Interval(5.23598775591066101557e-01,5.23598775607871918874e-01)],[IntervalArithmetic.Interval(-5.00000000006079532331e-01,-4.9999999999155026942e-01),IntervalArithmetic.Interval(5.23598775590062783794e-01,5.23598775606868738208e-01)]]],120)

In [ ]: