@article{Browne_2002, title={Rep-tiles with Woven Horns}, volume={5}, url={https://journal.media-culture.org.au/index.php/mcjournal/article/view/1977}, DOI={10.5204/mcj.1977}, abstractNote={<div id="articleContent"> <div id="maintext"> <div class="essay"> <p>The loop is examined as a conceptual programming tool in the context of computer artwork and fractal curve generation. In particular, a simple geometric construction for the visualization of Alexanderâ€™s horned sphere as a self-similar fractal curve in the plane is presented, based on a recursive rep-2 rectangle progression to a specified depth. Parameterized curve generation and rendering details are briefly discussed. </p> <h2>1. Loops and Computers</h2> <p>Loops form the fundamental core of almost all computer programs. The most common type is the iterative loop, typically signified by the keywords for, while, do, repeat etc, in which a given set of instructions is repeated a specified number of times. </p> <p>The recursive loop is a more powerful construct that performs a given set of instructions, typically including recursive calls with modified parameters back to the instruction set itself, until a terminating condition is met. Recursive algorithms solve problems by reducing them to smaller and smaller subproblems until a solution is found, reusing the same set of instructions as often as required. </p> <p>This elegant approach to problem solving satisfies the programmerâ€™s endless desire for efficiency and simplicity in program design. Recursive loops can always be rewritten as iterative ones, but if an algorithm can be defined with a recursive approach it is generally best implemented as such. </p> <h2> 2. Fractal Geometry</h2> <p>Fractal geometry involves the description of mathematical objects that display self-similarity on all scales [6]. Recursion is a natural way to describe such objects programatically. For instance, the fractal curve shown in Fig. 1 can be somewhat confusing to the eye until the viewer realises that itâ€™s composed of a common structure repeated at successively smaller scales. </p> <p><a href="gfx/browne-fig-1.gif"><img src="gfx/browne-fig-1thumb.gif" width="100" height="72" border="0"></a><br> Fig 1. A set of woven horns. </p> <p> The woven horn is based on a famous mathematical construct called Alexanderâ€™s horned sphere, which is traditionally visualized as a recursive set of interlocking pairs of orthogonal rings of decreasing radius [1,5]. </p> <p> The horned sphere has been embedded in the plane by reducing the interlock angle between ring pairs from 90o to 0o, then an over-under weaving pattern has been defined to reestablish ring interlock without intersection to give the woven horn set. Fig. 1 was inspired by the etching Yggdrasil by Bill Meyers [4], probably the most famous realization of Alexanderâ€™s horned sphere in the plane. </p> <p> It should be noted that the woven horn construction is a self-similar fractal but not technically an area-filling curve, as any open subset of the plane will contain points that are a non-zero distance from the curve. </p> <h2>3. Rep-tiles</h2> <p>Rep-tiles, polygons which can be divided into smaller copies of themselves, provide a method of tiling an area to a given depth of recursion [3,6]. The rep-2 rectangle with sides in the ratio 1:sqrt(2) is of particular interest. For instance, metric paper sizes A2, A3, A4 etc are rep-2 rectangles, making them convenient for stacking and printing purposes as each page can be folded in half to give two pages of the next smaller size [2]. </p> <p>Fig. 2 shows a rep-2 rectangle progression to three levels of subdivision. Note that the side length ratio 1:sqrt(2) is maintained for each generation. This fractal structure forms a rectangular lattice upon which the planar woven horn set can be generated. </p> <p><img src="gfx/browne-fig-2.gif" width="581" height="96"><br> Fig 2. Rep-2 rectangle progression. </p> <p>So how far should we recurse, given that this process is potentially infinite? Fortunately the display or printing device used to visualise the object provides a convenient terminating condition: there is little point in recursing beyond the visible resolution of the device, typically one pixel or picture element. </p> <p>One advantage of fractally defined curves is that they can be examined in infinite detail. This can be done efficiently by zooming in on an area of interest and scaling up the coordinate system accordingly, and choosing upper and lower recursion limits such that parts of the curve that lie outside the display area or are too small to see are clipped, and only the visible subset drawn. </p> <h2>3. Curve geometry</h2> <p>The construction of one generation of horn growth from a pair of left and right parent branches Pl and Pr is shown in Fig. 3. The generated curves are bounded by the rep-2 rectangle with width w and height h where: </p> <p> w = |Pl â€“ Pr|, the gap distance between the terminal points of Pl and Pr<br> h = w / ff2 </p> <p><a href="gfx/browne-fig-3.gif"><img src="gfx/browne-fig-3thumb.gif" width="100" height="74" border="0"></a><br> Fig. 3. Geometric construction of horn branches. </p> <p>Spacing parameter s forms an internal margin that creates an interior rep-2 rectangle progression offset from the bounding rep-2 rectangle (sâ€™ = ff2 s). Thus each generation attracts curves towards a central vanishing point, facilitating the woven horn design. </p> <p>Horn branches for each generation are described by two long curves Cl and Clâ€™ and two short curves Cs and Csâ€™. The actual geometry of these cubic spline curves is not important here; suffice it to say that they can be adjusted according to taste provided that the following constraints are met: </p> <p> lines CD and DE must be collinear to guarantee long curve continuity; <br> the entrance angle a formed at point A must agree with the exit angles a at G and H, and hence agree with the entrance and exit angles of future generations.</p> <p>The following guidelines were found to produce good results but are not essential: <br></p> <p> point D should be coincident with the top left corner of the interior rectangle; <br> curves should be bounded by the outer rep-2 rectangle; <br> an entrance/exit angle of 45o is convenient and aesthetically pleasing.</p> <p> This process is repeated from the terminal points G and I for the next generation. Curves Cl and Cs then become parent generators Pl and Pr, and curves Clâ€™ and Csâ€™ become intersecting parent generators Prâ€™ and Plâ€™, with the gap width w reduced and the frame of reference rotated accordingly. Fig. 4 shows the process of recursive growth to depths of 1, 2, 3 and 9. </p> <p><a href="gfx/browne-fig-4.gif"><img src="gfx/browne-fig-4thumb.gif" width="100" height="76" border="0"></a><br> Fig. 4. Increasing generation depth: (a) d = 1; (b) d = 2; (c) d = 3; (d) d = 9. </p> <h2>4. Results</h2> <p>The gap width wd of the branching pair at any particular depth d can be calculated from the spacing parameter s and the total structure width W as follows: </p> <p>wd = wd-1 /ff2 - 2sd-1 (where w0 = W and sd is the actual spacing for iteration d) <br></p> <p>The structureâ€™s appearance is now defined by just two variables: the inter-generational spacing value s and the depth of recursion d. The effect of varying control parameter d was shown in Fig. 4. The effect of varying the other control parameter s is shown below in Fig. 5. </p> <p><a href="gfx/browne-fig-5.gif"><img src="gfx/browne-fig-5thumb.gif" width="100" height="85" border="0"></a><br> Fig. 5. Spacing as a percentage of width: (a) s = 10%; (b) s = 20%; (c) s = 30%. </p> <p>Smaller spacing values yield boxier shapes with denser weave around the perimeter of each rep-tile, as seen in Fig. 5a. The shape converges to a single underlying rep-2 lattice as s approaches 0. Larger spacing values, such as those in Figs. 5b and 5c, provide rounder, looser weaves with tighter clusters in the center. The optimal spacing for aesthetic purposes was found to be around s = 13%. </p> <p>The program developed for this paper exports woven horn designs as a series of generational branch growths in the following formats: </p> <p>PostScript file of offset curves of decreasing thickness; <br> VRML file of polylines or extrusions of decreasing radius.<br></p> <p>Fig. 1 shows a depth 10 structure stored in PostScript format and rendered in PhotoShop with glass and noise filters applied. </p> <h2>Conclusion</h2> <p>Fractal geometry highlights the power, beauty and elegance of the recursive loop: simple instructions are used to visualize complex shapes that vanish inwards with infinite clarity. </p> <h2>Acknowledgments</h2> <p>Thanks to Alan Tonisson for providing useful comments. </p> <div class="metadata"> <h2> References</h2> <ul>
<li>Albers, Donald J. "The Game of â€˜Lifeâ€™." Math Horizons 1 (1994): 9.</li> <li>Gardner, Martin. The Unexpected Hanging and other Mathematical Diversions. New York: Simon and Schuster, 1969. </li> <li>Golomb, Solomon W. "Replicating Figures in the Plane." Mathematical Gazette 48 (1964): 336;403-12.</li> <li>Rolfsen Dale. Knots and Links. Wilmington: Publish or Perish, 1976.</li> <li>Weisstein, Eric W. "Alexanderâ€™s Horned Sphere." Online. Internet. 1999. Available: <http://mathworld.wolfram.com/AlexandersHornedSphere.php>.</li> <li>Weisstein, Eric W. Concise Encyclopedia of Mathematics. Boca Raton: CRC, 1999.</li> </ul>
<h2>Links</h2> <ul>
<li>http://mathworld.wolfram.com/AlexandersHornedSphere.html<br>
</li> </ul>
<h2>Citation reference for this article </h2> <h3> MLA Style </h3> <ul>
<li>Browne, Cameron. "Rep-tiles with Woven Horns" M/C: A Journal of Media and Culture 5.4 (2002). [your date of access] < http://www.media-culture.org.au/mc/0208/reptiles.php>. </li> </ul>
<h3>Chicago Style </h3> <ul>
<li>Browne, Cameron, "Rep-tiles with Woven Horns" M/C: A Journal of Media and Culture 5, no. 4 (2002), < http://www.media-culture.org.au/mc/0208/reptiles.php> ([your date of access]). </li> </ul>
<h3> APA Style </h3> <ul>
<li>Browne, Cameron. (2002) Rep-tiles with Woven Horns. M/C: A Journal of Media and Culture 5(4). < http://www.media-culture.org.au/mc/0208/reptiles.php> ([your date of access]). </li> </ul>
</div> </div> </div> </div>}, number={4}, journal={M/C Journal}, author={Browne, Cameron}, year={2002}, month={Aug.} }