Sierpiński curves are a recursively defined sequence of continuous closed plane fractal curves discovered by Wacław Sierpiński, which in the limit n → ∞ completely fill the unit square: thus their limit curve, also called the Sierpiński curve, is an example of a space-filling curve. Because the Sierpiński curve is space-filling, its Hausdorff dimension (in the limit n → ∞) is 2. The Euclidean length ln of the nth iteration curve Sn is
l n = 2 3 ( 1 + 2 ) 2 n − 1 3 ( 2 − 2 ) 1 2 n = 2 7 4 3 sinh ( n log ( 2 ) + arsinh ( 3 2 5 4 ) ) {\displaystyle {\begin{aligned}l_{n}&={\frac {2}{3}}\left(1+{\sqrt {2}}\right)2^{n}-{\frac {1}{3}}\left(2-{\sqrt {2}}\right){\frac {1}{2^{n}}}\\[4px]&={\frac {2^{\frac {7}{4}}}{3}}\sinh \left(n\log(2)+\operatorname {arsinh} \left({\frac {3}{2^{\frac {5}{4}}}}\right)\right)\end{aligned}}}
That is, it grows exponentially with n beyond any limit, whereas the limit for n → ∞ of the area enclosed by Sn is 5/12 that of the square (in Euclidean metric).
Uses of the curve The Sierpiński curve is useful in several practical applications because it is more symmetrical than other commonly studied space-filling curves. For example, it has been used as a basis for the rapid construction of an approximate solution to the Travelling Salesman Problem (which asks for the shortest sequence of a given set of points): The heuristic is simply to visit the points in the same sequence as they appear on the Sierpiński curve. To do this requires two steps: First compute an inverse image of each point to be visited; then sort the values. This idea has been used to build routing systems for commercial vehicles based only on Rolodex card files. A space-filling curve is a continuous map of the unit interval onto a unit square and so a (pseudo) inverse maps the unit square to the unit interval. One way of constructing a pseudo-inverse is as follows. Let the lower-left corner (0, 0) of the unit square correspond to 0.0 (and 1.0). Then the upper-left corner (0, 1) must correspond to 0.25, the upper-right corner (1, 1) to 0.50, and the lower-right corner (1, 0) to 0.75. The inverse map of interior points are computed by taking advantage of the recursive structure of the curve. Here is a function coded in Java that will compute the relative position of any point on the Sierpiński curve (that is, a pseudo-inverse value). It takes as input the coordinates of the point (x, y) to be inverted, and the corners of an enclosing right isosceles triangle (ax, ay), (bx, by), and (cx, cy). (The unit square is the union of two such triangles.) The remaining parameters specify the level of accuracy to which the inverse should be computed.
Representation as Lindenmayer system The Sierpiński curve can be expressed by a rewrite system (L-system).
Alphabet: F, G, X Constants: F, G, +, − Axiom: F−−XF−−F−−XF Production rules: X → XF+G+XF−−F−−XF+G+X Angle: 45 Here, both F and G mean "draw forward", + means "turn left 45°", and − means "turn right 45°" (see turtle graphics). The curve is usually drawn with different lengths for F and G. The Sierpiński square curve can be similarly expressed:
Alphabet: F, X Constants: F, +, − Axiom: F+XF+F+XF Production rules: X → XF−F+F−XF+F+XF−F+F−X Angle: 90
Arrowhead curve The Sierpiński arrowhead curve is a fractal curve similar in appearance and identical in limit to the Sierpiński triangle.
… excerpt ends here. Continue reading the full article.

![Sierpiński curve: Sierpiński curve ("Sierpiński's square snowflake"[1]) of first order](https://upload.wikimedia.org/wikipedia/commons/thumb/2/26/Sierpinski-Curve-1.png/500px-Sierpinski-Curve-1.png?utm_source=en.wikipedia.org&utm_campaign=parser&utm_content=thumbnail)


![Sierpiński curve: Sierpiński "square curve"[2] of orders 2–4](https://upload.wikimedia.org/wikipedia/commons/thumb/1/1f/Sierpinski_curve_orders_2-4.png/1280px-Sierpinski_curve_orders_2-4.png?utm_source=en.wikipedia.org&utm_campaign=parser&utm_content=thumbnail)

