An Algorithm to Automatically Detect the Smale Horseshoes

Smale horseshoes, curvilinear rectangles and their U-shaped images patterned on Smale’s famous example, provide a rigorous way to study chaos in dynamical systems. The paper is devoted to constructing them in two-dimensional diffeomorphisms with the existence of transversal homoclinic saddles. We first propose an algorithm to automatically construct “horizontal” and “vertical” sides of the curvilinear rectangle near to segments of the stable and of the unstable manifolds, respectively, and then apply it to four classical chaotic maps the Duffing map, the Hénon map, the Ikeda map, and the Lozi map to verify its effectiveness.


Introduction
Among a variety of mathematical characteristics of chaos, the existence of a horseshoe by S. Smale has been recognized as the most important signature of chaos from geometrical point of view.The horseshoe theory is based on the geometry of continuous maps on some subsets of interest in state space.Here the images of the subsets can be computed reliably, so rigorous investigation of chaos becomes possible even for systems without explicit solutions.
Although the theory provides a powerful tool for many rigorous studies of chaos, such as estimating topological entropy, verifying existence of chaos, and revealing invariant sets of chaotic attractors, it has not been used extensively like many other numerical methods, such as computing Lyapunov exponents or bifurcation diagrams.Beside of reliable computation based on interval arithmetic, another main reason is probably because it is not as convenient to find horseshoes in practical systems as other nonrigorous methods.In recent years, much work has been done in providing more applicable criteria to guarantee the existence of horseshoes 1-4 .The criteria have been applied to many dynamical systems 3, 5-7 .Recently, a progress was made in 8 which proposed a method for finding horseshoes in twodimensional 2D chaotic maps or Poincaré maps .The method was implemented with A MATLAB GUI program http://www.mathworks.com/matlabcentral/fileexchange/14075 to help readers to improve efficiency and has been successfully applied to some novel cases, for example, a hyperchaotic spacecraft circuit 9 , the fractional-order unified system 10 , and so forth.However, researches still need to find horseshoes manually with their own experiences.So this paper proposes a simple algorithm to automatically detect the Smale horseshoes in 2D chaotic maps.
The paper is organized as follows.Section 2 revisits the Smale horseshoe and tries finding some key points; Section 3 introduces our algorithm as well as some classical examples; Section 4 draws conclusions.

The Smale Horseshoe
First let us recall the notion of the Smale horseshoe.Consider a square S ⊂ R 2 with four vertices A, B, C, and D. The diffeomorphism is defined as follows: First the map contracts the square S horizontally with a factor less than 1/2, stretches it vertically with a factor greater than 2, then folds it like a horseshoe, and puts it back on the square S, as shown in Figure 1, where h sends A to A', B to B , C to C', and D to D'.As shown in Figure 1, p is a period-1 saddle point, W s and W u are the corresponding stable manifold {z : h n z → p as n → ∞} and unstable manifold {z : h n z → p ass n → −∞} of p. Another intersection q is what Poincaré called a homoclinic point.The homoclinic point here is transverse in the sense that the stable and unstable manifolds are not tangent at q.
The main point in the Smale horseshoe is not the shape of the square S and its image of under h, but the "crossing" relation that h S goes through S twice between AD and CB while any point of A B and C D does not locate inside of S, which guarantees the existence of the two disjoint blocks S 0 and S 1 .So the Smale horseshoes can be used extensively in many practical systems, where S will no longer be a square.

The Algorithm for Finding the Smale Horseshoes in 2D Maps
For convenience, we use a subscript to denote the iteration times, for example, q 1 h q , q 0 q, q −1 h −1 q , and use a combination of two points with a different cap to denote a piece of a different manifold between them; for example, pq denotes the piece of W u from p to q, and qp denotes the piece of W s from q to p.
The key to detecting a Smale horseshoe is the boundary of S. For the standard case demonstrated in Figure 1, the process is very easy.When we iterate each point of qq 1 reversely from q to q 1 , q −1 q h −1 qq 1 must intersect pq three times at least.The first and last intersection points are q −1 and q, respectively.We denote the second one with r −1 .Let S W be a block with four sides: pq −1 , q −1 r −1 , r −1 q, and qp .The map h sends the sides to pq, qr, rq 1 , and q 1 p, respectively.Here, q −1 r −1 and rq 1 intersect twice at s and s, respectively.It is obvious that h S W and S W also satisfy the relation of the Smale horseshoe.However, for a practical chaotic map f : R 2 → R 2 , we will face the following five difficulties.1 There are many saddle points with all periods; we have to pick a proper one to ensure the rest computation, but p in Figure 1 is only period-1.2 Both W s and W u have two branches, but Figure 1 only illustrates one of them.3 The two eigenvalues of f at p can be positive or negative, but Figure 1 only illustrates the positive one.4 h has a horseshoe, but f may not.5 S W cannot be applied in rigorous studies of chaos because there exist unavoidable numerical errors in practical computations.An algorithm which can automatically detect a Smale horseshoe must handle the above difficulties.
So in our algorithm, we first find a transverse homoclinic point, then we locate S W using the stable and unstable manifolds, and last we extend the boundary of S W outside to get S.The algorithm is as follows with its detailed flowchart illustrated in Figure 2.
1 Find a periodic point p at first.Supposing that p has period N, we compute the eigenvalues of the Jacobian matrix of f N at p.If one eigenvalue locates in the inside of the unit circle and the other one locates outside the unit circle, then p is a saddle point of f N ; otherwise, we need to find another p and try again.If any of the eigenvalues is negative, then we take I 2; otherwise, I 1.Let g f IN ; then, we find a transverse homoclinic point q by computing the corresponding stable and unstable manifolds of p.
2 Detect S W by finding a proper iteration time M and a proper intersection point r with the following procedure.Let M 1 and r p, that is, r 1−M p. Iterate the map g reversely for each point of q 1−M r 1−M from q 1−M to r 1−M until q −M r −M intersects pq again not q −M .If the new intersection point is not in r 1−M q, then set r −M to be r 1−M , M M 1 and try it again; otherwise, set r −M to be the point and compute Move v forward on W s with arc length stepsize δt Let q be the intersection point Compute W u with its arc length l u and stepsize δl u the image of r −M q under the map g M .If rq M does not intersect the new q −M r −M twice, we increase M with step 1 and try it again; otherwise, we take the manifold pieces pq −M , q −M r −M , r −M q, and qp as the boundary of S W .
3 Extend the boundary of S W outward with an equally small distance of δ to get a new boundary S. Then we compute the image of S under g M , and check whether the condition of the Smale horseshoe is satisfied.Generally, the smaller the δ is, the easier the condition can be satisfied; therefore we should decrease δ when the condition fails.
Remark 3.1.The algorithm is based on a saddle with transversal homoclinic.Whether it is fully automatic depends on the procedure to detect this saddle via the periodic orbit and the manifolds computation in the first step.Fortunately, they are both fundamental problems in numerical study of dynamical systems, and there are many good algorithms and software packages in the literature to do this, for example, 11, 12 .So it can be handled by the detailed control flow shown in Figure 2.
Remark 3.2.The intersection of the stable manifold and the unstable manifold must be transversal not tangential , which guarantees that the algorithm will terminate in a finite number of steps according to the general geometry described by Wiggins  where the two parameters usually set to a 2.75 and b 0.2 to produce chaotic behavior.
Numerical computation shows that the map has three fixed saddle points.Among them, the Jacobian matrix at the origin has two positive eigenvalues, λ 1 ≈ 0.07476 and λ 2 ≈ 2.67524.Clearly, I N 1, then we find a homoclinic point q 1.6057128, 0.1206999 .After a process illustrated in Figure 3, where the solid lines blue indicate the stable manifold and the dot lines red indicate the unstable manifold, we detect S w at M 3, and finally find a horseshoe, as illustrated in Figure 4.
Example 2 the Hénon map .The Hénon map, as a discrete model of the Lorenz system, is one of the most studied dynamical systems that exhibit chaotic behavior.It maps a point x n , y n in the plane to a new point given by where the two parameters canonically take a 1.4 and b 0.3 14 .Our computation shows that the map has two fixed saddle points.We randomly choose one, that is, p 0.6313545, 0.1894063 .The corresponding Jacobian matrix has one positive eigenvalue of λ 1 ≈ 0.155946 and one negative eigenvalue of λ 2 ≈ −1.92374.So N 1 and I 2. Then we find a homoclinic point q 0.584132, 0.101649 .When M 1, we find a horseshoe illustrated in Figure 5.
Example 3 the Ikeda map .The Ikeda map is a discrete-time dynamical system simplified from a plane-wave model.The map is given by where t n 0.4 − 6/ 1 x 2 n y 2 n and u is a parameter 15 .The map has a strange attractor for u 0.9.Our computation only finds one fixed saddle point, that is, p 0.5327546, 0.2468968 .The corresponding Jacobian matrix has two negative eigenvalues,   where the two parameters also take a 1.4 and b 0.3.Our computation shows that the map has two fixed saddle points.However, the stable and unstable manifolds of each point do not intersect.In order to find a homoclinic point, we try period two.Consequently, we only find one period-2 obit, that is, p 0.8571429, −0.0857143 , and the corresponding Jacobian matrix has two negative eigenvalues with λ 1 ≈ −0.06975 and λ 2 ≈ −1.2902.Obviously, N 2 and I 2; then, we find a homoclinic point q 0.849499, −0.0943964 .When M 1, we find a horseshoe, illustrated in Figure 7, finally.
Remark 3.3.The "crossing" relation between h S and S is the key to the existence of horseshoe.The relation remains unchanged if we map h S and S to their images by a homeomorphism.Therefore, if we find a horseshoe with a certain homoclinic point q, then we have infinitly many horseshoes just by iterating S with the system map f.On the other hand, if we find a different homoclinic point, then we may get a different horseshoe, which may be transformed from the original S under some iterations of the system map.For example, we can get a new horseshoe of the Duffing map only by changing q to 0.1207000, 0.00902376 .A horseshoe similar to this one, for example, that in Figure 8, can be gotten by Figure 2 under two time iterations of the Duffing map.

Conclusions
We have proposed an algorithm for finding the Smale horseshoes in 2D chaotic maps.Numerical studies for four classical maps suggest that this algorithm can effectively find their horseshoes.Comparing with 8 , this method is dedicated to the Smale horseshoes in 2D maps.The advantage of the algorithm is that horseshoes can be found automatically by only a few given parameters, which is less dependent on researchers' experience.In 8 , one has to find a horseshoe manually by a lot of trials, which may take hours sometime.The time consumed for the above examples is shown in Table 1, which takes a few seconds at most.So the algorithm is more efficient.In the algorithm, each side of the boundaries is a curve taken parallel along a stable or unstable manifold.This way, the existence of a Smale horseshoe is guaranteed.From this point of view, the algorithm is more applicable than methods using rectangles or polygons to compose boundaries, for example, 8 .

Figure 2 :
Figure 2: The flowchart of the algorithm.

13 .
Now we demonstrate the ability and efficiency of this algorithm by finding horseshoes of several classical chaotic maps in the following four examples.Example 1 the Duffing map .The Duffing map is a discrete version of the Duffing equation 13 .It takes a point x n , y n in the plane and maps it to a new point given by x n 1 y n , y n 1 −bx n ay n − y 3 n ,

Figure 3 :Figure 4 :
Figure 3: The process of detecting S w .

Figure 5 :
Figure 5: A Smale horseshoe found in the Hénon map.

Figure 6 :
Figure 6: A Smale horseshoe found in the Ikeda map.

Figure 7 :
Figure 7: A Smale horseshoe found in the Lozi map.

Figure 8 :
Figure 8: Another Smale horseshoe found in the Duffing map.