Top Banner
417

C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Aug 07, 2015

Download

Documents

C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998
Page 2: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Preface

Some people can read a musical score and in their minds hear the music ... Others can see, in their mind's eye, great beauty and structure in certain mathematical functions ... Lesser folk, like me, need to hear music played and see numbers rendered to appreciate their structures.

Peter B. Schroeder

The line between science and art is a fuzzy one; the two are fraternal philosophies formalized by ancient Greeks like Eratosthenes, the astronomer and poet, and Ictinus, the architect of the Parthenon. Computer graphics helps reunite these philosophies by providing scientific ways to represent natural, mathematical, and artistic objects.

I hope that this book will appeal to a broad audience due to the amazing array of topics -from cancer growth simulations to seaweed and leave vein development, from logic to genetics, art, artificial intelligence, and fun games played in higher dimensions. The numerous color figures and computer codes should encourage reader involvement and experimentation. Each of this book's six major sections has an introduction mentioning the latest research, references, and updates in the field. Additionally, the book presents information on the latest practical applications of fractals and on the use of fractals in commercial products such as antennas and reaction vessels. In short, fractals are increasingly finding application in practical products where computer graphics and simulations are integral to the design process.

In this book, the computer is often used to explore scientific realms like a microscope revealing hidden worlds full of intricate beauty. Today, mathematicians, chemists, and physicists have begun to enjoy and present bizarre mathematical patterns in new ways - ways sometimes dictated as much by a sense of aesthetics as by the needs of logic. Moreover, computer graphics allows non-mathematicians to experience some of the pleasure mathematicians take in their work and to better appreciate the complicated and interesting graphical behavior of simple formulas.

Computers, chaos, and freedom - three words which may never before have appeared together in a single sentence. However, computers and computation are now providing humankind with an unlimited landscape for exploration, and unparalleled aid for the imagination. This book is meant to be a stimulus for the imagination - an energizing elixir for scientific creativity. This book is also about some of the many things which researchers do with a computer: simulating, uisualizing, speculating, inventing, and exploring. Some of the topics in the book may appear to be curiosities, with little practical application or purpose. However, I have found all of these experiments to be useful and educational, as have the many students, educators, and scientists who have written to me during the last few years. Keep in mind that throughout history, experiments, ideas and conclusions originating in the play of the mind have found striking and unexpected practical applications. I urge you to explore all of the topics in this book with this principle in mind.

I would like to thank Professor Jose Encarna9ao, Editor-in-Chief of Compw/er5 and Graphics, and Annette Leeuwendal and Cristina Cushing from Elsevier for making this book possible.

I created the fractal on the book cover using the methods described on pages 415-423.

Clifford A. Pickover Yorktown Heights, New York

Page 3: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Introduction

I wonder whether fractal images are not touching the very structure of our brains. Is there a clue in the infinitely regressing character of such images that illuminates our perception of art? Could it be that a fractal image is of such extraordinary richness, that it is bound to resonate with our neuronal circuits and stimulate the pleasure I infer we all feel. P.W. Atkins

1. Chaos and Graphics Section of Computers and Graphics

In 1989, Professor Jose Encamagao, Editor-in-Chief of the international journal Computers and Graphics, invited me to edit and found the journal's "Chaos and Graphics" section. The goal of my on-going section is to provide visual demonstrations of complicated and beautiful structures that can arise in systems based on simple rules. The section also presents papers on the seemingly paradoxical combinations of randomness and structure in systems of mathematical, physical, biological, electrical, chemical, and artistic interest. Topics include: iteration, cellular automata, bifurcation maps, fractals, dynamical systems, patterns of nature created from simple rules, and aesthetic graphics drawn from the universe of mathematics and art.

This book is a smorgasbord of papers from the "Chaos and Graphics" section of Computers and Graphics. Regretfully, I could not include all papers published over the years due to space limitations. Although I have attempted to place the papers in six major categories (Geometry and Nature; Attractors; Cellular Automata, Gaskets, and Koch Curves; Mandelbrot, Julia and Other Complex Maps; Iterated Function Systems; and Computer Art), naturally many of the topics overlap.

2. The Fractal Goose

Little did I know that I would have my first encounter with fractals when I was a boy, before the word "fractal" was coined, and before computers were used to explore the intricacy of fractal shapes. It all started when I found a tattered book titled The Story of an African Farm at a garage sale. It was written by Olive Schreiner and published in 1883. In the book was an early, poignant description of the fractal geometry of nature and, in particular, a fascinating description of blood vessel branching:

A gander drowns itself in our dam. We take it out, and open it on the bank, and kneel looking at it. Above are the organs divided by delicate tissues; below are the intestines artistically curved in a spiral form, and each tier covered by a delicate network of blood vessels standing out red against the faint blue background. Each branch of the blood-vessels is comprised of a trunk, bifurcation and rebifurcating into the most delicate, hair-like threads, symmetrically arranged. We are struck with its singular beauty. And, moreover - and here we drop from our kneeling into a sitting position -this also we remark: of that same exact shape and outline is our thorn-tree seen against the sky in mid-winter; of that shape also is delicate metallic tracery between our rocks; in that exact path does our water flow when without a furrow we lead it from the dam; so shaped are the antlers of the homed beetle. How are these things related that such union should exist between them all? Is

Page 4: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

it chance? Or, are they not all the fine branches of one trunk, whose sap flows through us all? That would explain it. We nod over the gander's insides.

Today, scientists have come a long way in characterizing and modeling the century-old goose's guts. These days computer-generated fractal patterns are everywhere. From squiggly designs on computer art posters to illustrations in the most serious of physics journals, interest continues to grow among scientists and, rather surprisingly, artists and designers. The word "fractal" was coined in 1975 by mathematician Benoit Mandelbrot to describe an intricate-looking set of curves, many of which were never seen before the advent of computers with their ability to quickly perform massive calculations. Fractals often exhibit self-similarity which means that various copies of an object can be found in the original object at smaller size scales. The detail continues for many magnifications - like an endless nesting of Russian dolls within dolls. Some of these shapes exist only in abstract geometric space, but others can be used as models for complex natural objects such as coastlines and blood vessel branching. Interestingly, fractals provide a useful framework for understanding chaotic processes and for performing image compression. The dazzling computer-generated images can be intoxicating, motivating students' interest in math more than any other mathematical discovery in the last century.

Benoit Mandelbrot, the father of fractals, informally defines fractals as "shapes that are equally complex in their details as in their overall form. That is, if a piece of a fractal is suitably magnified to become of the same size as the whole, it should look like the whole, either exactly, or perhaps only after slight limited deformation." Like the ever-decreasing cats in Dr. Seuss's The Cat in the Hat Comes Back, certain aspects of fractal patterns can be made more apparent when one knows where to magnify the objects. In this book, the various contributors use the computer as a microscope to search for beautifiil forms in geometrical space.

Physicists are interested in fractals because the practical side of fractals is that they can sometimes describe the chaotic behavior of real-world things such as planetary motion, fluid flow, the diffusion of drugs, the behavior of inter-industry relationships, and the vibration of airplane wings. (Many times chaotic behavior produced fractal patterns.) Traditionally when physicists or mathematicians saw complicated results, they often looked for complicated causes. In contrast, many of the shapes in this book describe the fantastically complicated behavior of the simplest formulas. The results should be of interest to artists and non-mathematicians, and anyone with imagination and a little computer programming skill. Some readers may wonder why scientists and mathematicians use computer graphics to display mathematical results. Science writer James Gleick said it best:

Graphic images are the key. It's masochism for a mathematician to do without pictures ... [Otherwise] how can they see the relationship between that motion and this. How can they develop intuition?

So while we may enjoy fractals for their sheer beauty, the computer graphics methods may be used to visualize interesting manifestations of chaotic, or irregular, behavior arising from simple formulas. Get set for the erratic side of nature and mathematics - the discontinuous, infinitely-detailed monstrosities.

3. Chaos

To ancient humans. Chaos represented the unknown, the spirit world - menacing, nightmarish visions that reflected man's fear of the irrational and the need to give shape and form to his apprehensions. Today, chaos theory is an exciting, growing field that usually involves the study of wide-ranging phenomena exhibiting a sensitive dependence on initial conditions. Although chaos often seems totally "random" and unpredictable, it often obeys strict mathematical rules derived from equations that can be formulated and studied. One important research tool to aid

Page 5: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

in the study of chaos is computer graphics. From chaotic toys with randomly blinking lights to wisps and eddies of cigarette smoke, chaotic behavior is generally irregular and disorderly; other examples include weather patterns, some neurological and cardiac activity, the stock market, and certain electrical networks of computers. Chaos theory has also often been applied to a wide range of visual art.

In physics, there are certain famous and clear examples of chaotic physical systems. We can list a few examples here: thermal convection in fluids, supersonic panel flutter in supersonic aircraft, particles impacting on a periodically vibrating wall, various pendula and rotor motions, nonlinear electrical circuits, and buckled beams. Francis Moon in all his books (for example. Chaotic Vibrations) gives many more examples.

4. New Practical Fractals

Fractals are increasingly finding application in practical products where computer graphics and simulations are integral to the design process. As one example. Amalgamated Research Inc., of Idaho, USA, manufactures space-filling fractal conduits. These devices contain many root-like outlets and are designed to minimize turbulence. The company's engineered fractal cascade (EFC) can draw or inject fluid simultaneously throughout a mixing vessel.

Amalgamated Research's basic invention replaces random scaling and distribution of free interfluid turbulence with the geometrically-controlled scaling and distribution of fluid flow through "engineered" fractals. This means that EFCs can be used as fiinctional alternatives to turbulence, acting as engineered eddy cascades. Engineering applications include control of flows in chromatography, adsorption, absorption, distillation, aeration, scrubbing, extraction and reactor processes. (For more information, see http://www.arifractal.com/.)

Another company. Fractal Antenna Systems Inc. based in Fort Lauderdale, Florida, is developing a branching "Fractenna" for hand-held telephony. As the company's name implies. Fractal Antenna Systems develops antennas using fractal geometric patterns with designs repeated at many size scales. The company's trade secrets do not permit us to know all the details at this time, but this highly efficient sender and receiver of electrical waves is said to be no bigger than a small coin.

Fractal antennas hold great promise, because these miniature, virtually-invisible devices may be used in everything fi-om wireless LANs to cell phones and televisions. Most cellular and wireless devices use wand antennas protruding from cases. Fractennas can be incorporated in the wireless or cellular device's casing, making them virtually unbreakable.

A third practical use of fractals is the fiberoptic faceplate - an array of millions of optical-fiber tubes packed into a thin cylindrical pipe. The composite tube acts as an image-plane transfer device. This means that an image entering one surface exits the other surface as an undistorted digitized image, regardless of the shape of the optical tube. You can use these tubes like periscopes by bending them in order to see around a corner.

Several years ago, Lee Cook, a fiberoptic researcher the Galileo Electro-Optics Corporation in Sturbridge, Massachusetts, was interested in preparing arrays of optical waveguides that were perfect as possible. Analysis of certain recursive tilings led Cook and his colleagues to conclude that the edges of optically useftil tilings were fractal in nature. This led to the development of assembly techniques and fractal array structures that allowed the Galileo researchers to prepare highly ordered fiber arrays. One patent has already been granted on these techniques, and Incom, Inc. of Charlton, Massachusetts, has recently purchased Galileo's fractal fiberoptic technology.

Fractal fiberoptics (a trademarked term) may have been the first engineered fractal materials with optically usefiil properties. A fractal fiber-array, which consists of fibers of fibers (called multi-multifibers), results in an extremely high degree of internal order and an optically

Page 6: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

useful packing in the fiberoptic. This increased order produces a markedly improved image contrast. The perimeters of these new multi-multifibers are exactly analogous to a fi*actal Gosper snowflake. (To create a Gosper snowflake, recursively transform each face of an equilateral hexagon into three segments of equal length so as to preserve the original area of the solid.)

What does the fiiture of fractals hold? Aside from obvious applications in education and art, four fields come to mind for especially increased growth: geology, medicine, astronomy, and pure math. All of these fields benefit because fractal geometry provides a language and concep­tual framework for ill-defined geometries, and the power law inherent in fractals condenses their description. For example, fractals will be increasingly used to estimate the strength of rocks under shearing forces, in the analysis of breast mammograms, and in analyzing the randomness of transcendental numbers such as Jt and e. (For more information on practical applications, see http://www.math.vt.edu/people/hoggard/FracGeomReport/node7.html) Dr. Bruce Elmegreen of IBM is currently using fractals to explaining the relative proportion of high-to low-mass stars in the ,sky. The ultimate goal of his work is to explain how the Earth and solar system formed from tenuous, cosmic gas.

I asked fractal expert Professor Michael Frame of Union College and Yale University, "What scientific areas would benefit most by using fractals?" He replied:

Currently, the largest deficiency is in statistics. Common statistical methodologies don't usually make use of the scale invariance characterizing fi-actals, and as we accumulate more evidence that many real data sets exhibit the long-term dependence and long-tailed distributions that can arise in scaling processes, the need for appropriate statistical tests is apparent.

When proper fractal statistics are developed, I imagine the impact in all fields will be considerable. Materials science will probably be affected to a great degree. DLA (diffusion-limited aggregation) and turbulence remain two of the biggest puzzles. With enough computational power to do proper statistics on DLA clusters and turbulent flow patterns, we may begin to develop some real understanding of these processes.

On a different level, the perceived complexity of our surroundings depends in part on the language with which we describe them. Finding a better language is the main task of science, of literature, of art, of music. To the extent that many natural processes exhibit scaling, fractals provide an important component of any language. As we develop our ability to understand and analyze fractals, our language for understanding the world improves and simplifies.

I thank Professor Frame for the advice and support he has provided over the years regarding the "Chaos and Graphics" section of Computers and Graphics and for bringing several interesting references to my attention for the section introductions of this book.

For Further Reading

For up-to-date information sources on the world wide web regarding fractals, chaos, and graphics see: http://sprott.physics.wisc.edu/pickover/home.htm. The most celebrated fractal program is the freeware Fractint. Developed through collaboration between its main authors ("The Stone Soup Group") and hundreds of interested programmers and artists, Fractint features numerous fractal types and hundreds of control options. Fractint can be found at http://spanky.triumf ca. Other popular and versatile programs for Windows 95 are listed at http://www.geocities.com/SoHo/Lofts/5601/. A useful source for beginners is the FAQ (Frequently Asked Questions) at http://fractal.mta.ca/sci.fractals-faq/. This FAQ is posted monthly to sci.fractals, a Usenet newsgroup covering fractals, mathematics, and software. The FAQ document is a beginner's reference on fractals, and includes images, papers, bibliographies, answers to commonly asked questions, and archive listings of fractal software. Another related newsgroup is sci.nonlinear. Finally, the Infinite Fractal Loop is a web ring dedicated to fractal art and includes some of the foremost artists in the field (http://www.fractalus.com/ifl/).

The following lists some classic and recent reading in the field of fractals, chaos, and graphics:

Page 7: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

(1) Avnir, D., Ofer, B., Lidar, D. and Malcai, O. (1998) Is the geometry of nature fractal? Science. January 2, 279(5347): 3 9 ^ 0 .

(2) Avnir, D., Biham, O., Lidar, D., and Malcai, O. (1997) On the abundance of fractals. In Fractal Frontiers, M. Novak and T. Dewey, eds. World Scientific: River Edge, New Jersey.

(3) Bamsley, M. (1988) Fractals Everywhere. Academic Press: New York. (4) Briggs, J. (1992) Fractals. Simon and Schuster: New York. (5) Chaos Demonstrations, a program which contains examples of Julia sets and over 25 other

types of chaotic systems. This peer-reviewed program won the first annual Computers in Physics contest for innovative educational physics software. Contact the Academic Software Library, Box 8202, North Carolina State University, Raleigh, NC 27695-8202, Tel. (800) 955-TASL or (919) 515-7447. Chaos Demonstrations is by J. C. Sprott and G. Rowlands, and it requires an IBM PC or compatible.

(6) Gleick, J. (1987) Chaos. Viking: New York. (7) Hellemans, A. (1997) Chaos keeps data under wraps. Science. May 2; 276 (5313): 679.

(Article on optical communications.) (8) Malcai, O., Lidar, D., Biham, O., and Avnir, D. (1997) Scaling range and cutoffs in

empirical fractals. Physical Review. E56: 2817-2820. (9) Mandelbrot, B. (1984) The Fractal Geometry of Nature. Freeman: New York.

(10) Mandelbrot, B. (1998) Is nature fractal? Science. 279(5352): 783-786. (11) Moon, E (1987) Chaotic Vibrations. John Wiley and Sons, New York. (Moon gives many

practical examples of chaos in real physical systems.) (12) Moon, F. (1998) Applied Dynamics: Modern Methods and Applications. Wiley: New

York. (13) Peitgen, H., and Richter, P. (1986) The Beauty of Fractals. Springer: Berlin. (14) Perry, J. (1997) Estimating chaos in an insect population. Science. June 20; 276

(5320):1881. (15) Pickover, C. (1990) Computers, Pattern, Chaos and Beauty. St. Martin's Press: New

York. (16) Pickover, C. (1991) Computers and the Imagination St. Martin's Press: New York. (17) Pickover, C. (1995) Keys to Infinity, Wiley: New York. (18) Pickover, C. (1995) The Pattern Book: Fractals, Art and Nature. World Scientific: River

Edge, New Jersey. (19) Pickover, C. (1996) Fractal Horizons: The Future of Fractals. St. Martin's Press: New

York. (20) Schroeder, M. (1991) Fractals, Chaos, Power Laws. Freeman: New York. (21) Spedding, V (1997) Fractals give clues to nature's chaos. Scientific Computing World.

December, 34: 24-25. (22) Sprott, C. (1993) Strange Attractors. M&T Books: New York. (23) Stevens, C. (1989) Fractal Programming in C. M&T Books: New York. (24) Stewart, I. (1989) Does God Play Dice? (The Mathematics of Chaos). Basil Blackwell:

New York. (25) Strasmich, M. (1998) Great Media Company (Catalog of Science, Fractal, and Computer

Art Books), PO Box 598, Nicasio, CA 94946. This fine company distributes books, videos, prints, and calendars.

(26) Vreeswijk, C. and Sompolinsky, H. (1996) Chaos in neuronal networks with balanced excitatory and inhibitory activity. Science. December 6; 274 (5293): 1724.

(27) Wegner, T., and Peterson. M. (1991) Fractal Creations. Waite Group Press: California. (28) Williams, N. (1997) Fractal geometry gets the measure of life's scales. Science. April 4;

276 (5309): 34. (29) YLEM - Artists using science and technology. This newsletter is published by an

Page 8: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

organization of artists who work with video, ionized gases, computers, lasers, holograms, robotics, and other nontraditional media. It also includes artists who use traditional media but who are inspired by images of electromagnetic phenomena, biological self-replication, and fractals. Contact: YLEM, Box 749, Orinda, CA 94563.

Page 9: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V All rights reserved

Part I. Geometry and Nature

"Whatever can be done once can alvv ays be repeated," begins Louise B. Young in The Mystery of Matter w hen describing the shapes and structures of nature. From the branching of rivers and blood vessels, to the highly convoluted surface of brains and bark, the physical w^orld contains intricate patterns formed from simple shapes through the repeated application of dynamic procedures.

Questions about the fundamental rules underlying the variety of nature and mathematical shapes have led to the search to identify, measure, and define these patterns in precise scientific terms. Our seemingly chaotic w^orld is actually highly structured. From an evolutionary standpoint, biological themes, structures, and "solutions" are repeated w hen possible, and inanimate forms such as mountains and snovv flakes are constrained by physical law s to a finite class of patterns. The apparently intricate fabric of nature and the universe is produced from a limited variety of threads w^hich are, in turn, organized into a multitude of combinations.

The idea that nature and mathematics are inextricably linked is not nev^ - and neither is the application of that idea in computer graphics. Computer graphics, in general, provides a w ay to represent all kinds of biological objects (for an excellent book on techniques for simulating nature, see Rivlin (1986)). The Fibonacci sequences, as w ell as a number of published papers, address the generation of mathematically derived morphological models for plants (Jena, 1984). Researchers have explored the use of rules based on the law s of nature, such as logarithmic spirals for sea shells (Kawaguchi, 1982) or tree branching patterns determined from the study of living specimens (Aono, 1984). Other papers describe the generation of plant leaf vein patterns (Kolata, 1987) and woodgrains (Yessios, 1979). Bloomenthal (1985) describes methods for simulating tree bark, leaves, and limbs. These and other successes provide continuing incentive for more research on the mathematical basis of natural forums.

More recent discussions by David Avnir and colleagues at the Hebrew^ University of Jerusalem raise interesting questions on the degree to which fractals actually describe the irregular face of nature (Avnir, et al. 1998). This article points readers to other recent papers investigating fractal geometry's role in describing intricate natural structures and phenomena.

For Further Reading

(1) Aono, M., Kunii, L. (1984) Botanical tree image generation. IEEE Computer Graphics and Applications, 4: 10-34.

(2) Aqvist, J. and Tapia, 0. (1987) Surface fractality as a guide for studying protein-protein interactions. Journal of Molecular Graphics. 5(1) 30-34.

(3) Avnir, D., Ofer, B., Lidar, D. and Malcai, O. (1998) Is the geometry of nature fractal? Science. January 2, 279(5347): 39-40.

(4) Batty, M. and Longley, P. (1994) Fractals Cities: A Geometry of Form and Function. California: Academic Press. (This book describes the development and use of fractal geometry for understanding and planning the physical form of cities; shows how fractals enable cities to be simulated through computer graphics.)

(5) Bloomenthal, J. (1985) Modeling the mighty maple. Computer Graphics (ACM SIG-GRAPH). San Francisco. 19(3) 305-311.

Page 10: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

(6) Briggs, J. (1992) Fractals. New York: Simon and Schuster. (7) Costantino, R., Desharnais, R., Gushing, J. and Dennis, B. (1997) Chaotic dynamics in

an insect population. Science. January 17; 275 (5298):389. (8) Family, F. (1988) Introduction to droplet growth processes: simulation theory and

experiments. In Random Fluctuations and Pattern Growth: Experiments and Models. Stanley, H., Ostrowsky, N. (eds.) Kluwer: Boston.

(9) Feder, J. (1988) Fractals. Plenum: New York. (10) Glass, L. and Mackey, M. (1988) From Clocks to Chaos: The Rhythms of Life Princeton

University Press: New Jersey. (11) Hassell, M. (1974) Insect Populations. Journal of Animal Ecology. 44: 283-296. (12) lUert, C , and Pickover, C (1992) Generating irregularly oscillating fossil seashells. IEEE

Computer Graphics and Applications, May, 12(3): 18-23. (13) Kadanoff, L. (1986) Fractals: where's the physics? Physics Today. February, 6-7. (14) Kawaguchi, Y (1982) A morphological study of the form of nature. SIGGRAPH July '82

Proceedings: Boston. 16(3): 223. (15) Kolata, G. (1984) Esoteric math has practical result. Science. 225: 494-495. (16) Landini, G. (1991) A fractal model for periodontal breakdown in periodontal disease.

Journal of Periodontal Research 26: 176-179. (17) Marder, M. (1997) Roughing it. Science. August 1; 277 (5326):647. (Fractals and

computational material science.) (18) Musgrave, K. (1989) The synthesis and rendering of eroded fractal terrains. Computer

Graphics (ACM-SIGGRAPH) July 23(3): 41-50. (19) Nottale, L. (1991) The fractal structure of the quantum space-time. In A. Heck and J.

Perdang, Applying Fractals in Astronomy New York: Springer. (20) Pickover, C. (1996) Fractal Horizons: The Future of Fractals. St. Martin's Press: New

York. (21) Rivlin, R. (1986) The Algorithmic Image. Microsoft Press: Redmond, WA. (22) Robinson, A. (1985) Fractal fingers in viscous fluids. Science 228: 1077-1080. (23) Taylor, C. (1990) Condoms and cosmology: the "fractal" person and sexual risk in

Rwanda. Social Science and Medicine. 31(6): 1023-1028. (24) West, B. and Goldberger, A. (1987) Physiology in fractal dimensions. American Scientist

75: 354-365. (This article describes the fractal characterization of the lungs' bronchial tree, the Weierstrass fiinction, the fractal geometry of the heart, and "fractal time".)

(25) West, B. (1990) Fractal Physiology and Chaos in Medicine. World Scientific: River Edge, New Jersey.

(26) Williams, N. (1997) Fractal geometry gets the measure of life's scales. Science. April 4; 276 (5309):34.

(27) Yessios, C. (1979) Computer drafting of stones, wood, plant and ground materials. Computer Graphics (ACM-SIGGRAPH) August '79 Proc, Chicago 13(2): 190.

Page 11: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved

Chaos and Graphics

CHAOS GAME VISUALIZATION OF SEQUENCES

H. JOEL JEFFREY Computer Science Dept., Northern Illinois University, DeKalb, IL 60115

Abstract—Iterated function systems can be used to produce a representation of complex images. It was recently shown that one can produce visual representation of the structure of long (2-100 K) sequences by reversing the IPS technique, using a fixed set of affine maps and having map selection controlled by the sequence. The resulting Chaos Game Representation (CGR) is a 1-1 map between plotted points and sub­sequences. Nonuniformity of distribution of subsequences produces nonuniformity in the CGR. The CGR is a picture of the sequence, often with visually striking features corresponding to sets of subsequences, thus a new set of questions and areas of investigation. This paper presents the technique, several examples using DNA sequences as examples of nonrandom sequences whose structure is of great independent interest, algorithms for approximating arbitrarily closely subsequences corresponding to observable features of the CGR, and a description of a program based on these algorithms that has useful for exploring features of CGRs. Finally, several extensions to the basic CGR algorithm are proposed.

INTRODUCTION

It seems to be very difficult for human beings to develop intuition for long sequences of letters or numbers. We seem to be very good at recognizing and using patterns and structures, and comparatively poor with long se­quential presentations. (A unique discussion of this fact, with some very far-reaching implications may be found in [ 5 ].) Converting a sequence, which is basically a uni-dimensional set of inputs, into a graphical form that presents the data in a way that allows visual grasp of the overall pattern, as well as detailed analysis, ex­pands our capabilities as investigators in two ways. It makes standard investigations easier or more efficient, and allows entirely new questions and areas of inves­tigation to develop. An excellent example of this phe­nomenon is the Mandelbrot set. The graphical presen­tation of the set is both highly motivating and provoc­ative of many questions that quite literally could not occur without it (e.g., what is the angle of any of the smaller copies of the large cardiod?).

Chaos game representation [4] is a technique for converting the one-dimensional sequence into a two-dimensional form that preserves subsequence structure while providing a provocative visual representation. Further, CGR can be used to approximate any set of subsequences in terms of other sequences with a known structure.

1. THE CHAOS GAME

The chaos game is an algorithm which allows one to produce pictures of fractal structures using paper and pencil or, obviously, a computer. In simplest form, it proceeds as follows:

1. Locate three dots on a piece of paper as the vertices of a triangle, and label them with the numerals 1 through 6 (1 and 2 for the first vertex, 3 and 4 for the second, 5 and 6 for the third).

2. Pick a point anywhere on the paper and mark it. This is the initial point.

3. Roll a 6-sided die. Since the vertices are labelled, the number that comes up on the die is a label on a vertex. Place a mark halfway between the previous point and the indicated vertex. For example, if 3 is rolled, place a mark on the paper halfway between the previous point and the vertex labelled "3 . "

4. Continue to roll the die, on each roll marking the paper at the point half way between the previous point and the indicated vertex.

This procedure is the Chaos Game [ 1 ]. In general, the mathematical subset of the plane defined in the limit, is known as the attractor. Figure 1 is a picture of this attractor after 50,000 repetitions; it is the Sier-pinski Triangle.

The result of the Chaos Game on other than three points is not, as one might think, a four-, five-, etc., pointed Sierpinski-like figure. For five points, six, or seven initial points the chaos game produces a figure with visible patterns (pentagons within pentagons, a striated hexagon, or heptagons within heptagons), but for eight or more point the game yields essentially a filled-in polygon, except that the center is empty.

With four initial points, however, the result is dif­ferent: It is a square uniformly and randomly filled with dots.

1.1. Iterated function systems Mathematically, the chaos game is described by an

iterated function system (IFS)[1]. An IFS is a set of pairs of Hnear mappings, each pair of the form x = ax -\- by -\- e,y = ex + dy -\- /. Each pair of maps gives the function for computing the new value of the x and y coordinates. If vertices are at (0, 0), (0, 1), and (1, 0), and 3 is rolled, vertex 2 is indicated, and the co­ordinates of the new point are given by x = 0.5 • (x + 0) = 0.5x, and 3; = 0.5 • (y + 1.0) = 0.5> + 0.5.

With three vertices, and one map per coordinate, we need six maps. We can write the maps in a compact

Reprinted from Comput. & Graphics Vol 16, No. I, pp. 25-33, 1992

Page 12: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

H. JOEL JEFFREY

Table 2. IFS code for the fiUed-in square.

Fig. 1. The resuU of the chaos game on three points.

tabular form as follows. We let w{x, y) = (ax -\- by + e, ex -\- dy + / ) , and then the map is given by the six coefficients a through/f For the Sierpinski triangle, the maps are:

w, 0.5 0 0 0.5 0 0

W2 0.5 0 0 0.5 0 0.5.

W3 0.5 0 0 0.5 0.5 0.5

Since the choice of map is determined by a die (or random number generator), each map has an asso­ciated probability, all equal in the case of the unloaded die. If the probabilities are not equal, the shape of the attractor is unchanged, but the shading may be [1].

In tabular form, including the probabilities, we can use the compact notation, which is known as the IFS eode (Table 1). Table 2 presents the IFS code for the filled-in square.

2. NONRANDOM SEQUENCES

Quite by chance, the author and a colleague (G. M. Henry) discovered that in these cases the random number generator can make a very significant differ­ence. As noted above, with a good random number generator, the Chaos Game on 8 points produces an almost-filled octagonal. However, when the game is played using Turbo Pascal 3.0, which has a flawed ran­dom number generator[6], elaborate patterns are vis­ible, resembling a circle within a circle, the circles con­nected by 8 (or, respectively, 16) spidery lines.

Further, not all flawed random number generators produce a visible pattern from Chaos Game; using DOS Basic (Version 2.1) RND, which is a quite poor ran­dom number generator, the Chaos Game on eight points produces no visible patterns.

w

1 2 3

Table 1

a

0.5 0.5 0.5

. IFS code for the Sierpinski Triangle.

b

0 0 0

c

0 0 0

d

0.5 0.5 0.5

e

0 0 0.5

f

0 0.5 0.5

P

0.33 0.33 0.33

w

1 2 3 4

a

0.5 0.5 0.5 0.5

b

0 0 0 0

c

0 0 0 0

d

0.5 0.5 0.5 0.5

e

0 0 0.5 0.5

f

0 0.5 0 0.5

P

0.25 0.25 0.25 0.25

3. CHAOS GAME REPRESENTATION OF DNA SEQUENCES

Intuitively, nonrandomness means that a sequence has "structure." More mathematically, it means a nonuniformity of subsequences[6]. If a sequence of numbers is used to produce an attractor for an IFS code, as described above, and that attractor has visually observable structure then we have revealed some un­derlying structure in the sequence of numbers, or some nonuniformity of subsequences. Thus, if the IFS for 16, 8, or 4 points is controlled by a poor (/>., not very random) random number generator, the attractor dis­plays nonuniformity (i.e., visually observable subsets or features).

Since a DNA sequence can be treated formally as a string composed from the four letters "a," "c," "g," and "t" (or "u"), it is an obvious candidate for testing the CGR to see whether in fact visually interesting fea­tures were present.

Specifically, we experimented with several DNA se­quences, as follows: Instead of "rolling a 4-sided die," use the next base (a, c, g, t/u) to pick the next point. Each of the four corners of the square is labelled "a," "c," "g," or "u;" if a "c," for example, is the next base, then a point is plotted half way between the previous point and the "c" corner.

Example: The first 6 bases of the GenBank sequence HUMHBB (human beta globin region, chromosome 11) are "gaattc":

1. The first "g" is plotted halfway between the center of the square and the "g" corner.

2. The next base, "a," is plotted halfway between the point just plotted and the "a" corner.

3. The base "a" is plotted half way between the pre­vious point and "a" corner.

4. Next, "t" is plotted half way between the previous point and the "t" corner, etc.

Plotting these six bases, we obtain Fig. 2. As with the initial points of the Sierpinski triangle,

little significance is visible. However, if we continue for the entire 73,357 bases of HUMHBB, we obtain Fig. 3.

The CGR of HUMHBB is a good example of the point of this visualization technique, for it illustrates a number of the characteristics of CGRs in general, and of a certain class of vertebrate DNA sequences in particular:

1. Perhaps the most obvious characteristic of this CGR is the almost empty area in the upper right quadrant (the g-quadrant). A smaller copy of this "scoop"

Page 13: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos game visualization

_ . . . . , - , . . . , - . . . , - ^ . . . - . . r - •. . - rj.Mf: ^*^- • •.-.;• " "T- •.t'?'^'''^rS -'•'•^'.••':: - . • ' . : ^ ' ' 2 ^

' .'. •'•''•V* - - ' -T- ;* >n'^""

Fig. 2. CGR of the first six bases of HUMHBB.

appears in the upper left, or c-quadrant, presenting a double-scoop appearance. As discussed in the next section, each point in the CGR corresponds to ex­actly one subsequence (starting from the first base), up to resolution of the screen. Therefore, this graphic pattern indicates repeated patterns in the gene sequence. The same is true of any other visible pattern.

The "double-scoop" corresponds to a compara­tive sparseness of CG pairs in the sequence; a ran­dom sequence with all CG pairs has a CGR with a completely empty double-scoop area. (This is dis­cussed in more detail in Section 4.)

2. Note that any base v U always be plotted somewhere in the quadrant with its label since a base is always plotted half way toward its comer.

3. The CGR has self-similarity: There is a copy of the double scoop at the top of the a- and t-quadrants. Further, this continues: If we examine the picture in horizontal "strips" (in halves, quarters, etc.), we see that at the top of each quarter-strip there are four copies; at the top of each eighth-strip there are eight, and so forth.

4. A rather noticeable feature of this CGR is the set of curves on the top of the upper left quadrant of the plot, curving from the solid block up and to the right.

Fig. 4. The shaded filled-in square (see Table 3).

5. The self-similarity and division into quadrants, subquadrants, etc., is a consequence of the non­uniform probabilities of subsequences in general, rather than a particular property of DNA sequences, as may be seen by examining Fig. 4, the attractor for the IFS in Table 3 [1].

The usefulness of the CGR for investigating DNA sequence structure is currently under investigation.

4. PROPERTIES OF THE CGR OF A SEQUENCE

In this section we discuss the relation between the CGR and the sequence itself. We shall assume that the sequence is a string over an alphabet of four letters {a, b,c, d], which label a square beginning at the lower left corner in clockwise order.

THEOREM 1. There is a one-to-one map between the sequence and the interior of the square, in which the k-th point plotted on the CGR of a sequence corresponds to the first k-long initial subsequence of the sequence, and no other subsequence (up to the resolution of the screen). Thus, there is a one-to-one correspondence be­tween the subsequences (anchored at the start) of a sequence and points of the CGR.

Proof (By induction on k.) Assign coordinates of (0,), (0, 1), (1, 1), and (1,0) to the a-, b-, c-, and d-vertices of the square, respectively. For A: = 1, the only point present is located at ( i , i ) , ( | , i ) , ( i , i ) , o r ( | , \). Conversely, if a point is at (5, | ) , it can only have come from the letter "a" (and similarly for "b," "c," or"d") .

Now suppose we have a point at location {x,y) and assume (without loss of generality) that next letter is

Table 3. IFS code for the shaded fill-in square.

Fig. 3. CGR of human beta globin region on chromosome 11 (HUMHBB) (73,357 bases).

w

1 2 3 4

a

0.5 0.5 0.5 0.5

b

0 0 0 0

c

0 0 0 0

d

0.5 0.5 0.5 0.5

e

0 0 0.5 0.5

f

0 0.5 0 0.5

P

0.1 0.2 0.3 0.4

Page 14: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

8 H. JOEL JEFFREY

a. Then the next point is at (x/2, y/2). Conversely, if a point corresponding to (x, y) is present in the CGR, there is another point (w, u) such that (x, y) = W/(w, r) , / = 1,2, 3, or 4. By the induction hypothesis (w, u) corresponds to the initial /c-long sequence s. Therefore, {x,y) corresponds to the (A: + 1 )-long se­quence sa,sb,sc, or sd, (depending on whether / = 1, 2, 3, or 4, and we have the result.

The definition of the chaos game is that a point is plotted half-way between the previous point and the vertex with its label; mathematically, the new x-co-ordinate is \ • Xow (for letters "a" and "b") or ^ • (Xow + 1) (for "c" and "d"). Therefore, any sequence is always plotted somewhere in the quadrant of square with that label: for any string 5, sa is plotted somewhere in the <2-quadrant, sb in the /j-quadrant, etc. Conversely, any two points in the same quadrant must have the same last letter. Further, the notion of quadrant is re­cursive; each quadrant can be divided into quadrants, etc. Thus, in Fig. 2, "g" is plotted in the g-quadrant, and then "a" is plotted in the upper right subquadrant of the g-quadrant (the one with its upper right vertex at the center of the entire figure), or what might be called the "ga" subquadrant. Any point in the square would be mapped to this subquadrant. Thus, "a" pro­duces a copy of the g-quadrant that is one-half the size (side length) of the g-quadrant, or one-fourth of the size of the entire picture. The next "a" then produces a one-half size copy of the "ga" subquadrant, the "gaa" sub-subquadrant, and then "t" produces a "gaat" sub-sub-subquadrant.

Further, due again to fact that a base is plotted in its quadrant, the converse holds as well: If two points are within the same quadrant, they correspond to se­quences with the same last base; if they are in the same subquadrant, the sequences have the same last two bases; if they are in the same sub-subquadrant they have the same last three bases, etc.

Thus, we have the following:

THEOREM 2. In a CGR whose side is of length 1, two sequences with suffix of length k are contained within the square with side of length 2~^. Further, the center of the square is given by the following recursive defi­nition:

1. The center of the suffix ofO length is(^, ^) 2. If the center of the square containing sequences with

suffix w is at (x, y), then (a) the center of the square containing sequences

with suffix wa is {x/2,y/2)\ (b) the center of the square containing sequences

with suffix wb is (x/2, {y + 1 )/2); (c) the center of the square containing sequences

with suffix wc is at {{x 4- 1 )/2, (y + 1 )/2); (d) the center of the square containing sequences

with suffix wd is at ((x + 1 )/2, y/2).

(In the subsection below, "Arbitrary Subsequences," we shall see that the converse holds as well: Each subquadrant of size \ ^ with center is given by the above definition corresponds exactly to those sequences that

terminate in the /c-long sequence given in the defini­tion.)

The resolution of most monitors or printers is such that the points for sequences with identical suffixes of length over 10 (maximum) are superimposed. How­ever, any portion of the CGR may be magnified to any degree, revealing finer structure of the CGR and therefore of the sequence. Thus, there is no limit on the length of subsequences that may be displayed.

5. SIERPINSKI CARPETS

5.1. AC- and BD-deficient sequences Figure 5 shows the CGR of a 50,000-letter sequence

with all "ac" subsequences removed. It is similar to a Sierpinski carpet[3]. We shall use this figure as ex­amples and motivation for the discussion (in the fol­lowing section) of finding the sets of subsequences cor-resusing visual features of a CGR.

The large empty square, of side length | , with its lower left corner at the center of the CGR, is the area in which all sequences terminating in "ac" would be plotted. (It is empty because, of course, there are no such subsequences in this sequence.) The square of side length g, with its lower left comer at the upper right comer of the largest empty square, is represents all "acc-"terminated sequences. Similarly, the square of side ^ , next on the diagonal toward the c-corner, represents all sequences "accc"-terminated subse­quences, and so on. Figure 6 shows this set of subquad-rants.

It is very instmctive to examine another set of subquadrants, the set in the upper right subquadrant of the lower right quadrant (or, the c-subquadrant of the d-quadrant) (see Fig. 7). In this subquadrant we see a ^ -size copy of the "ac-," "ace-," "accc-," etc. subquadrants marked in Fig. 6. The largest of this set corresponds to all subsequences terminating in "acd;" the next to all terminating in "accd," the next to "acccd," and so on. A similar set, each a 5 -size copy of the set in the c-quadrant, is found in the c-subquad­rant of the b-quadrant and the c-quadrant of the a-quadrant.

Fig. 5. Random sequence without "ac" subsequences.

Page 15: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos game visualization

/ ac b

Fig. 6. Empty squares and their corresponding subsequences. Fig. 8. Random sequence without "be" subsequences.

In general, close examination of Fig. 5 reveals that

in every subquadrant, of side length r^, /c = 1 ,2 , . . . ,

there is a complete copy of the entire CGR. The CGR of a random sequence with no "bd" sub­

sequences shows the same form, but the sequences of empty area, in decreasing size order, go up and to the left.

5.2. BC- and AD-deficient sequences The CGR of a sequence with no "be" or "ad" sub­

sequences (/.^., letters from the same side of the square) has a similar set of empty areas as discussed in the above subsection. However, when the letters of the missing subsequence share a side of the square, the boundaries of the missing areas are colinear (as op­posed to above case, when the boundaries share only the single corner point). As a result, although the same size areas are missing, the boundaries of the areas are fractal, and the attractor appears quite different from Fig. 5. Figure 8 shows the CGR for a 50,000 letter sequence with no "be" subsequences. Figure 9 is the same CGR, but with areas corresponding to various missing subsequences noted.

square of size —^^ (where | s \ denotes the length of 5)

5.3. Arbitrary subsequences Suppose we have a subsequence s of interest. Let us

call this the primary subsequence. (We might, for in­stance, be interested in whether s is more or less fre­quent in the sequence than average.) Define the "pri­mary image" (denoted by the symbol D) to be the

•21-given by the recursive definition of Theorem 2. If there are no subsequences s in the sequence, the primary image is empty; if there are additional instances of 5, the primary image will be denser than average.

If the center of the primary image is (x, y), and it

has side length -^, we can define the a-image of the

primary image to be the subquadrant whose center is

(x/2, y/2), and whose side length is —j^. The b-, c-,

and d-images have the same side length and are cen­tered at (x/2, {y + l ) /2) , ({x + l) /2, (y + l ) /2) , and ((x + \)/2, y/2), respectively.

Thus, there is a point in the a-image of the primary square if and only if there is a point in the primary image that is mapped into the a-image by the a-map.

. acd '{• accd

Fig. 7. Half-size copy of the squares marked in Fig. 6. Fig. 9. Subsequences corresponding to empty areas of Fig. 8.

Page 16: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

10 H. JOEL JEFFREY

This in turn can only occur if the subsequence sa occurs in the sequence. Thus, the points in the a-image of the primary image are the a-maps of all points in the pri­mary image, and similariy for the b-, c-, and d-images of the primary square.

Now let us consider a 2-letter extension of s, say sab. The subsequences of this form in the sequence produce a set of points in the b-map of the a-map of the primary image, or 5(a (D)). Thus, ab produces an image of the primary image of size J of the primary image size, whose center is defined by Theorem 2.

In general, every sequence t defines an image of the

primary image, of size -JTJ . If there are no instances

of the primary sequence present in the sequence, then the primary image and all /-images of the primary im­age will be empty, for all sequences /.

For any sequence s of length greater than 1 we can therefore define a CGR in Cantor set-like fashion as follows:

1. Remove the 5-image of the unit square. This is the primary image.

2. For each A: > 0, For each string t of length /c, Remove the ^image of the primary image.

It should be noted that if t is of the form xa, then the /-image of the primary image is the a-image of the x-image of the primary image, and therefore the above algorithm may be formulated recursively.

6. SUBSEQUENCES CORRESPONDING VISUAL FEATURES

It is common, when using the CGR to investigate a set of sequences (e.g., a set of DNA sequences for the same protein in several species) to find a feature of the CGR and want to identify the sets of subsequences that correspond to the feature. Figure 10, for example, shows the CGR of 15 concatenated coding sequences in the human globin region on chromosome 11. (Not all the DNA sequence actually codes for proteins.) An easily identifiable feature is the roughly oval area marked on the figure in which the density of the points is several times that of the CGR as a whole. This in­dicates a set of subsequences several times more fre-

.^^

/

ggaggagggqajag l9

Id

^ /y

r' / 1 X

c db cca cdca ddca bca aca dca a b d

Fig. 11. Subquadrant-subsequence correspondence.

quent than average; we would like to be able to easily identify the subsequences corresponding to this feature.

6.1. Approximation of features Recall from the above section that the a-image of

the primary square is the {pvbarp - Wa(^), for some q in the CGR, that the a-image is contained in the a-quadrant, and similarly for the b-, c-, and d-images. The points in the a-quadrant correspond to any sub­sequence ending in "a," and conversely any subse­quence ending in "a" produces a point in the a-quad­rant. The a-quadrant is thus the a-image of the entire CGR, and similarly for the b-, c-, and d-quadrants. Figure 11 illustrates the fundamental correspondence of string to subquadrant.

Let us denote by J the map corresponding to a, and similarly for 5, c, and d. Then any sequence s ~ SiS2' • * s„ defines a map s„s„-i • • • Ji, such that if the sequence / corresponds to point p of the CGR, the sequence ts corresponds to sip) = s„s„-i • • - Si(p).

From the definition of the IFS maps, if the CGR is based on the unit square, the square of side length 1, with lower left corner = (0,0) (as in Theorem 2), then the center is at (^, ^), and centers of the a-, b-, c-, and d-quadrants are at ( i , | ) , ( i , | ) , ( | , | ) , a n d ( | , 1), respectively. The center of the aa-subquadrant is then at ( | , g), the ca-subquadrant (the upper-right, or c-, subquadrant of the a-quadrant) is at ( | , g), etc. Using binary representation, we have Table 4.

The center of each subquadrant is represented by two bit strings, the x- and ^-coordinates in binary with the binary point dropped.

Since the corners of the CGR are at (0, 0), (I , 0), (1, I) , and (1, 0), only two operations are involved

Table 4. Centers of quadrants, binary representation.

Quadrant Center

Fig. 10. Fifteen concatenated coding sequences of HUMHBB.

a b c d aa ca

(.01, (.01, (.11, (.11,

(.001, (.011,

.01)

.11)

.11)

.01) ,001) .011)

Page 17: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos game visualization 11

in finding a new point in the CGR, whether the center or comer of a subquadrant or any other point: mul­tiplying by 5 and multiplying by 5 and then adding | . The5mapof(x, );)is(x/2, );/2 + \);cis{x/2 + , y/2 + ^); dis (x/l + , y/2). Multiplying by ^ is represented in binary by prefixing a 0, and if the left­most bit of a number is 0, then adding 5 is represented by simply changing that 0 to 1. Therefore, the com­bination of multiplying by and adding 5 is represented by prefixing a 1. Therefore, if a location is given by bit strings x and y, we can describe the a, b, c, and J maps as shown in Table 4.

Now let us consider the converse: Suppose we have a point p whose coordinates are given by bit-strings x and y (e.g., 101, 011). The left-most bits of jc and y are 1 and 0, respectively. Examining Table 5, we see that the only map that can produce this pair of leftmost bits is J, and thus p = J(01, 11). Continuing, if q is the preimage of/?, then the leftmost bits of are 0 and 1, so ^ = b{ {,_ 1). Similarly, (1, 1) = c(0, 0). Thus, (101,011) = d{b{c((0,0)))), which means that (101, 011) is the point corresponding to subsequence "cbd." (Note the reversal as we go to the string from the com­position of maps.) The correspondence of bit-pairs to maps is summarized in Table 6.

6.2. Algorithms Based on the above analysis, we can define algo­

rithms for locating, resizing, and moving a box cor­responding to any subquadrant of a CGR, as follows:

1. Define the initial subsequence to be "a." 2. To draw a box corresponding to a subsequence, find

the corners of the box by finding the image of each of the comers of the CGR under the map corre­sponding to the sequence: If 5 = 51 2 • • • 5„, then 5((0, 0)) = s„s„-i • • • 5i((0, 0)), and similarly for (0, 1),(1, 1), and (1,0).

3. To move a box, (a) Convert the subsequence corresponding to the

current box to the corresponding x and y bit-strings.

(b) Add/subtract 1 to/from the x and/or y bit-strings: Up: Add 1 to the y bit-string Down: Subtract 1 from the y bit-string Left: Subtract 1 from the x bit-string Right: Add to the x bit-string.

(c) Convert the new x and y bit strings to a se­quence of letters.

(d) Redraw the box. 4. To enlarge a box, delete the rightmost letter of the

subsequence, and draw the box corresponding to the sequence.

Table 5. CGR maps in binary.

a{x, y) = (Qjc, 0>') b{x, y) = (01, \y) c{x,y) = i\x, \y) d{xy) = {lx,Oy)

Table 6. Map to bit-pair correspondence.

Map Bit pair

c h c d

0,0 0, 1 1,1 1,0

5. To shrink a box, append "a" to the subsequence and redraw the box corresponding to the sequence. (Any letter could have been used; "a" is an arbitrary choice.)

These algorithms only allow boxes to be defined and moved in units of quadrants, subquadrants, sub-subquadrants, etc. In other words, one cannot use them to define a box of side length 5 centered at the point (5, 5). Such a box would not correspond to a single subsequence; the sequences that correspond to this box are the four subquadrants corresponding to subse­quences "ag," "ct," "ga," and "tc" (Fig. 12).

The above algorithms allow the definition of a set of subquadrants of any size, each corresponding to a set of subsequences with a fixed suffix, that approximate any area (or combination of areas) of a CGR as closely as desired. In essence, the feature of interest is covered with a set of squares of varying sizes, approximating the feature as desired.

6.3. Description of program The above algorithms have been implemented in a

working program for analyzing CGRs. The program is approximately 1,600 lines of Turbo Pascal 5.0, run­ning on an IBM AT or PS/2 with EGA or VGA mon­itor. The program produces a CGR from a user-spec­ified sequence file and then allows the user to define and move a box on the CGR. The eight outer keys of the keypad permit movement of the box in any direc­tion (including diagonals). A user may at any point elect to retain a box; it is redrawn in another color and the subsequence defining the box is added to an on-

Fig. 12. Square not corresponding to a single subsequence.

Page 18: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

12 H. JOEL JEFFREY

screen list. This on-screen list may be edited, and de­leted sequences (and their corresponding boxes) are removed.

Figure 13 demonstrates the use of the CGR analysis program to find the subsequences that define features of a CGR. In lower-left quadrant of the CGR of the human alpha-1 antitrypsin gene (HUMAIATP) is an irregularly shaped figure that is visibly sparser. The figure shows that the area is approximated by the subquadrants for six different sequences, from four to six bases in length. (Most of the figures in this paper were produced with this program.) It would be very difficult to recognize such a set of sequences via ordi­nary statistical analysis methods, for the area does not correspond to a single comparatively rare subsequence (such as a single tetranucleotide, for example). Rather, it corresponds to a set of comparatively rare sequences, of different lengths. Finding such sets might be possible in principle, by examining or otherwise processing sets of frequency counts, but some of the sets are large enough to effectively preclude effective human pattern recognition. (The whole point of the CGR, and other visualization techniques, is to avoid long sequences of data.) For example, there are 4^ = 1,024 sequences of length 5, and 4^ = 4,096 of length 6. Further, the "tgatca"-square is part of the sparse area. It is difficult to see how such a set of sequence characteristics might be discovered by examining these large sets of fre­quency counts other than via CGR analysis.

Figure 14 is a good example of using the CGR, to­gether the CGR approximation algorithm, to recognize and analyze features of a sequence that in all likelihood would not occur without it. Figure 14 is the CGR of the amino acids of the bacteriophage PT7. Note the somewhat star-shaped region approximately one quar­ter of a side length from the right edge. This region results from the absence of a somewhat complex set of subsequences of amino acids missing from the DNA sequence. Traditional statistical analysis would be un­likely to reveal such a feature, as it produces statistics on the relative frequency of subsequences (usually of a single length), and the star shape results from the absence of several subsequences of several lengths.

cgaa aatca tatca attca cggaa tgatca

k' \iC

\

I

' • , \ l

"

:;^,

.. 'L .., /.

.*/

*-

,;-,

^'' '-,/:

• y-r''^'

.v"/ " .;; ,

• ' ./ '* ' "''

' ~ 1 ' '

ag>

, ^ - ? " *

l a X^: '<:

\ * -'',\ * 1

Fig. 13. Approximating an irregular feature of HUMAIATP.

Fig. 14. CGR of bacteriophage PT7 (using amino acids).

7. RELATED WORK

Symbolic dynamics[2], a topic in dynamical sys­tems theory, associates strings of symbols with orbits of a dynamical system. It is a powerful tool for ana­lyzing the orbits. It would be interesting to find out whether this approach can be reversed, finding dy­namical systems whose behavior is represented by a given sequence.

To date we have relied solely on visual character­ization of the patterns found in CGRs, both as to rec­ognizing features and judging similarity of features. An objective, mathematical measure is needed. The pattern recognition literature reveals little in the way of a formal definition or characterization of "pattern" that is directly applicable. However, digital image en­hancement techniques are clearly applicable. The Hausdorff distance[l] has been used to formalize sim­ilarity of patterns, and may prove useful in defining similarity of CGRs.

To our knowledge CGR is the first attempt to use particular sequences of numbers (or symbols) to con­trol the chaos game, and thereby analyze/characterize the sequences themselves. Since the approach is new, so far as we know, we conclude with some open ques­tions and extensions of the technique, most of which have been barely, if at all, explored. (We invite the reader to take this list as provocative, in the spirit of initiating a brain-storming session, rather than in any way complete or exhaustive.)

8. EXTENSIONS AND OPEN QUESTIONS

8.1. Pattern recognition and similarity To date, all work with CGRs has relied on using

them as an aid to human intuition, presenting a great deal of information visually. We do not view this as a fault, as visualization of scientific information is, in our view, a valuable and growing field. However, there is no reason to limit CGRs to this use. Specifically, the great body of image enhancement and pattern recog­nition work can be applied to CGRs. These approaches may well improve the usefulness of the CGR as a vi­sualization method, and provide the obvious possibil­ities of standard feature extraction.

The above-mentioned Hausdorff distance as a mea­sure of similarity of CGRs is a formalization related to these developments that seems quite useful. For ex-

Page 19: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos game visualization 13

ample, it may be that one can find CGRs that are rep­resentative of groups of DNA sequences, and the Hausdorff distance from an unknown DNA sequence to the representative CGRs provides information as to what the unknown sequence codes for.

In some applications this may be a necessary step in applying CGRs to a large body of sequences. For example, biologists typically believe this step is nec­essary. We feel a cautionary note is in order, however: human visual processing is far superior to any currently known technology, so there well be human-recogniz­able characteristics of CGRs that are resistant to current technology.

8.2. Sequences over larger alphabets The CGR technique presented in this paper works

only for sequences over an alphabet of four letters. For larger alphabets of size « > 4, one might think of de­fining the CGR on a regular «-gon. Although this can be done, it does not provide a good visualization of the sequence, because a random sequence on an n-gon does not produce a filled-in polygon.

The following approach does work: Divide the unit square (as with the standard CGR) into n equal non-overlapping portions covering the square {i.e., a tiling of the square). This tiling defines n maps of an IFS code in which map k defines the mapping of the unit square onto tile k. A random input sequence then pro­duces a filled-in unit square, as with the standard CGR, and so any nonuniformity in the input sequence pro­duces a nonuniformity in the density of areas of the CGR, and vice versa. We therefore have the same con­ditions that permit the standard CGR to represent a sequence on four letters.

We have experimented with this approach in DNA sequences. In a DNA sequence three bases (letters) define one amino acid; such ordered triples are known as codons. Each codon defines one amino acid (the building blocks of proteins), although there are only 20 amino acids; several codons code for the same amino acid. In addition, there are three "stop codons" and a particular "start" codon which control cellular machinery that produces the protein based on the DNA sequence, so a total of 24 equivalence classes of codons are present. We have produced a CGR in which the unit square is divided into 24 (4 by 6) squares, and the CGR is produced by 24 mappings onto these squares. If two codons code for the same protein, the

same map is used. The result is a CGR with identifiable areas of greater or lesser density. We have also produced a CGR using only the codons for the 20 amino acids, with a 4 X 5 tiling of the square. The usefulness of this approach to biological investigations remains un­known.

8.3. Natural language representation The input sequence for a CGR can be any sequence.

The CGR analysis program discussed above ignores any input letters not in the four-element alphabet. En­glish text files can, and in fact have been used produce CGRs with visual features. (As illustrated in [4], such CGRs are unUke those of DNA sequences.) An appli­cation in which this might prove useful is in establishing authorship of texts. One part of such work depends on syntactic and stylistic characteristics of texts, rather than semantics or historical references. It is conceivable the CGRs of works of various authors, or bodies of texts, may show distinctive characteristics.

The standard CGR is in certain respects poorly suited to this application, as it is based on only four letters, but the extension to larger alphabets discussed above addresses this difficulty.

A somewhat different extension would be to very large sets of maps, perhaps 100 (10 X 10 tiling) or 10,000 (100 X 100 tiUng). This would allow plotting of points corresponding to words, and the result would be a visualization of the sequences of words used. Since in some sense a grammar of defines the possible legit­imate sequences of words of the language, this graphical representation of text may prove useful in natural lan­guage processing in general, as well as authorship anal­ysis.

REFERENCES 1. M. F. Barnsley, Fractals Everywhere, Springer-Verlag,

New York (1988). 2. R. L. Devaney, An Introduction to Chaotic Dynamical

Systems, Addison Wesley Publishing, Redwood City, CA (1989).

3. J. Feder, Fractals, Plenum Press, New York (1988). 4. H. J. Jeffrey, Chaos game representation of genetic se­

quences. Nucleic Acids Research 18(8), 2163-2170 (1990).

5. P. G. Ossorio, "What Actually Happens"—The Repre­sentation of Real World Phenomena, University of South Carolina Press, Columbia, SC (1978).

6. S. K. Park and K. W. Miller, Random number generators: Good ones are hard to find. Com. of the ACM, 31( 10), 1192-1201(1988).

Page 20: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 15

Chaos and Graphics

TUMOR GROWTH SIMULATION

WERNER DCCHTING University of Siegen, Dept. of Electrical Engineering, Holderlinstr. 3, D-5900 Siegen, West Germany

Abstract—This paper gives a survey of the author's work on systems analysis, control theory, cellular automata, and computer science applied to complex biological systems.

Mathematicians have long been interested in cellular automata theory and the game 'iife"[l]. However, only recently have physicians been able to look, via 2D- and 3D-computer graphics, directly at normal and malignant cells in a three-dimensional tissue. This re­cent development makes it possible to simulate differ­ent kinds of tumor treatment and to look to the patho­logical state of cells in the surrounding tissue.

In medicine, one characteristic feature of malignant tumors is uncontrolled proliferation[2], Therefore, from the viewpoint of control theory, a main question is: How is the growth of normal and malignant cells regulated? This question can be studied at different levels: (i) molecular biology level (genes and onco­genes), (ii) cellular level (cell-cycle processes), and (iii) organ level. At present, the experimental data about the control mechanisms at the first level are still very diffuse. For this reason we have focused on con­structing feedback control models which describe the cell division of normal and tumor cells at the cellular level. This work led to the hypothesis postulated in 1968[3]: Cancer may be interpreted as a structurally unstable closed-loop control circuit.

At that early time, we mainly studied the dynamic behavior and the stability conditions in the time do­main by applying block-oriented simulation lan­guages [4]. With the increasing progress in computer science, we extended our first approaches and devel­oped models which additionally describe the spatial behavior of tumor growth.

Some of the oversimplifying assumptions underlying the following approaches are: constant volume of a cubic cell, constant cell phase duration, only horizontal and vertical communication between neighboring cells, a limited tissue volume, and neglect of side-effects, metastases, and immunologic reactions. The design philosophy for constructing a computer model of tu­mor growth requires modular-structured subsys-tems[5]: (i) feedback control models which describe the cell division of normal and tumor cells including experimentally gained data of cell-cycle phase dura­tions, (ii) heuristic cell-production and interaction rules describing the cell-to-cell communication, for instance distance-dependent cell division rules, and (iii) trans­port equations for simulating cell movement.

Details of the simulation strategy are as follows:

• the cell-cycle phase durations of cells are generated by a pseudorandom number generator;

• the knowledge base of cell production rules comprises the following observations: • a normal cell can only divide if there is an empty

position in its neighborhood; furthermore, its di­vision is limited to a distinct number of cell cycles;

• a tumor cell can divide even if there is no empty space available for a daughter cell; this rule is re­stricted by a distant-dependent statement as fol­lows: For in vitro tumor growth, if the distance between the dividing tumor cell and the nutrient medium is more than three cell layers, the tumor cell will transfer to the resting (dormant) state GO and later on into the phase of necrosis (cell death).

These statements have been transformed into algo­rithms, and we have written modular-structured sub­programs in FORTRAN IV. The simulation run can be considered as a row-to-row computation of the cell algorithm for each individual cell. The input data for a simulation run are:

• initial configuration of normal and malignant cells • cell-cycle phase durations of normal and malignant

cells • information of cell loss rate • information about the structure of the capillary net­

work • treatment schemes including dose rate and treatment

intervals.

As for the first example, we fed the computer model with the experimentally gained data of the cell-cycle phase durations of the adenocarcinoma of a mouse. The division of a cell is going on along this series of phases: Gl in which proteins and ribonucleic acid are synthesized, S in which DNA is duplicated, G2 in which the cell synthesizes RNA and protein molecules required for transit through this phase, M leading to cell division, GO in which the cell is resting, and N in which the cell is dying. The simulation run starts by inoculating a single tumor cell living in the state of mitosis (M) into the center of the cell space of a nu­trient medium. According to the cell-interaction and production rules, the tumor continuously grows to be­come a tumor spheroid [ 6 ]. Figs. 1 a and 1 b only show the tumor configuration in the steady state at T = 300 units of time. It is very important to know in which phase of the cell cycle a tumor cell is residing because the sensitivity of tumor cells differs from cell phase to cell phase. This is a decisive fact for tumor treatment

Reprinted from Comput. & Graphics Vol 14, Nos. 3/4, pag. 505-508, 1990

Page 21: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

16 WERNER DOCHTING

Fig. la. Tumor spheroid at T = 300 units of time. Fig. 2a. Initial configuration of a single tumor cell placed in a tissue segment (cortex) at T = 1 unit of time.

Fig. lb. Cross-section of the tumor spheroid at T = 300 units of time. (Symbols: O = N Phase, ^ = GO Phase, ^ = M Fig. 2b. Spread oftumor cells and capillaries at T= 120 units

Phase, Of = G1, S and G2 Phases.) of time.

Page 22: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Tumor growth simulation 17

Fig. 3a. Cross-section of an irradiated tumor spheroid at T = 350 units of time. (Symbols: ® = N Phase, O = GO Phase,

* = M Phase, <* = Gl, S and G2 Phases.)

because radiation therapy and chemotherapeutic drugs are killing tumor cells only during distinct cell-cycle phases. Therefore, Fig. lb indicates the actual cell-cycle phase in which each tumor cell is residing. It should be stressed that in our computer model the reference input signal in terms of control theory is the constant thickness of the outside proliferating margin of the tu­mor spheroid, which is in balance with the necrotic cells of the inner area of the spheroid (see Fig. lb).

To get results closer to the biological reality (in vivo), the nutrient medium of the in vitro model was sub­stituted by a capillary network. For this purpose we have simulated the formation of blood vessels during the evolution of a tissue segment of a normal brain of a rate[7] by additionally introducing transport equa­

tions to the model developed so far. Then, in the in vivo model of a segment of the brain of a rat (Fig. 2a) we have introduced a single tumor cell which will divide according to the cell-division rules of a tumor cell. The simulation result (Fig. 2b) impressively demonstrates the spread of tumor cells at T = 120 units of time. Furthermore, it can be clearly seen in Fig. 2b that new capillaries have been formed to supply the tumor with oxygen and glucose. This process is called neovascu­larization. Thus, further rapid tumor growth is possible.

The aim of our work is not only to predict spatial tumor growth but also to simulate and to optimize different kinds of tumor treatment (surgery, radiation and chemotherapy). Thus, algorithms describin^can-cer treatment had to be developed [ 8 ] , for example by introducing a "Linear Quadratic Model" for comput­ing the number of lethally hit tumor cells as a function of radiation dose rate. In this way it is possible to test different clinical treatment schemes (standard and nonstandard schedules) on in vitro tumor spheroids by computer experiments. Fig. 3a illustrates the slice of a tumor spheroid which has been irradiated. A com­parison between Fig. lb and Fig. 3a shows that radia­tion mainly has killed the proliferating tumor cells of the outer margin of the tumor spheroid.

Furthermore, if we apply clinical treatment sched­ules of radiation therapy to in vitro tumor spheroids, computer simulation may also give an answer to critical questions concerning optimal treatment schemes such as: Is a multifractionated irradiation (Fig. 3b) more effective than a radiation treatment with one high single dose per week? This work is being done in [ 8 ]. It leads to the surprising preliminary result that in both cases, with the same overall dose after five weeks, the number of tumor cells has decreased to about the same level.

In the long run, the objective of our approach is to optimize treatment strategies and schedules in vitro and in vivo by computer simulation prior to clinical therapy.

NUMBER OF TUMOR CELLS

10000

8000

6000 1

4000 1

2000

0 I I r n I I I I I I I I '"I "1 "'I "'I "'I I I '"I '"I '"I '"I '"I I I "'i '"I '"i '"I '"i I I '"I '"i '"I '"i '"I I ^ 0 48 96 144 192 240 288 336 384 432 480 528'576 524 672 720 768 816 864 912 960 TIME/h

Fig. 3b, Number of tumor cells of a multifractionated radiation treatment of a tumor spheroid.

Page 23: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

18 WERNER DOCHTING

REFERENCES

1. M. Gardner, On cellular automata, self-reproduction, the Garden of Eden and the game life. Scientific American 224, 112-117(1971).

2. I. F. Tannock and R. P. Hill (Eds.), The Basic Science of Oncology, Pergamon Press, New York (1987).

3. W. Diichting, Krebs, ein instabiler Regelkreis, Versuch einer Systemanalyse. Kybernetik 5, 70-77 (1968).

4. W. Diichting, Computer simulation of abnormal eryth-ropoiesis—an example of cell-revewal regulating systems. Biomed. Technik 21, 34-43 (1976).

5. W. Duchting, Computer models applied to cancer re­

search. In Modeling and Control of Systems, A. Blaquiere (Ed.), Springer-Verlag, Berlin, 397-411 (1989).

6. W. Duchting, Recent progress in modeling and simulation of three-dimensional tumor growth and treatment. J?/o-systems\%,19-9\ (1985).

7. T. Vogelsaenger, Modellbildung und Simulation von Re-gelungsmechanismen wachsender BlutgefaGstrukturen in normalen Geweben und malignen Tumoren, Dissertation Siegen(1986).

8. W. Duchting, R. Lehrig, G. Radermacher, and W. Ulmer, Computer simulation of clinical irradiation schemes ap­plied to in-vitro tumor spheroids. Strahlentherapie und Onkologie 165, 873-878 (1989).

Page 24: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 19

Chaos and Graphics

COMPUTER SIMULATION OF THE MORPHOLOGY AND DEVELOPMENT OF SEVERAL SPECIES OF SEAWEED

USING LINDENMAYER SYSTEMS

JOHN D . CORBIT and DAVID J. GARBARY Department of Biology, St. Francis Xavier University, Antigonish, Nova Scotia, Canada, B2G ICO

Abstract—Lindenmayer systems (L-systems) are used to model the structure and development of several species of seaweed. The agreement between the images produced by the models and the actual plants is very good. Two species exhibit the fractal property of self-similarity to at least four levels of recursion. The possibiHty of a relation between the L-systems coding and the biological coding mechanism is noted.

1. INTRODUCTION

L-systems, named for their originator, Astrid Linden­mayer [ 1, 2 ], are string rewriting systems with a graph­ical interpretation. Each L-system consists of an axiom and a set of production rules. On each iteration the production rules are applied to all of the characters in the starting string.

Simple bracketed OL-systems are used here. Such systems use of the following set of symbols: F, f, +, —, [, and ]. The graphical interpretation of these symbols results in movements of a LOGO-like turtle in the plane. Thus, " F " gives a forward movement of 1 unit with pen down, "f" is a forward movement of 1 unit without drawing, "+" is a turn to the left by a preset angle increment, " - " is a right turn by the angle in­crement, " [" is push the current state of the turtle to a pushdown stack, and " ] " is pop a turtle state up from the stack. A formal mathematical definition of L-systems and a classification of different types of L-systems are given in the literature[ 1, 2, 3, 4]. The L-systems algorithm is available both as detailed pseu­docode [ 5 ] and as a complete L-systems program writ­ten in the C language [ 3 ].

L-systems, i.e., an axiom and a set of production rules, provide an elegant shorthand way to capture the rules embodied in various structures. They have been used to model numerous geometric fractal types and a variety of plants [ 1, 2, 3, 4, 6 ].

In this paper we use L-systems to model the mor­phology and development of several species of seaweed in the Division Rhodophyta (red algae). We chose the red algal genus, Antithamnion, because species in this group are filamentous, i.e., they consist of strings of cells. Different species within this genus are character­ised by different branching patterns. The advantage of using filamentous plants is that the symbol " F " of the L-system is identified with a single cell of the plant. Here we analyse the branching patterns and write L-systems for three species of Antithamnion. These L-systems successfully capture not only the adult forms of these plants, but also their ontogeny.

2. METHOD

Published photographs and drawings of three species o^Antithamnion, A.pterocladellum Norris[1],A. den-sum (Suhr) Howe [8, 9 as ^. defectum; see [10] for

Reprinted from Comput. & Graphics Vol. 17, No. 1, pag. 85-88, 1993

change of name to A. densum], and A. tenuissimum (Hauck) Schiffner[l 1], were analysed to identify the distinctive features of their structures. The structures were coded as L-systems. The data, i.e., angles (5), axiom (co), and production rules {pi, Pi, - - -, Pn) for each system, were entered into an L-systems computer program. The program was run for successive iterations and the resulting images were displayed on the com­puter screen.

The computer was an Apple Macintosh II. The soft­ware was a program called L-System' written by Paul Bourke of the Architecture School, University of Auckland, Auckland, New Zealand. This program has a very convenient user interface. It implements context-free bracketed L-systems, context-sensitive L-systems, and stochastic L-systems. Simple bracketed L-systems were used here.

3. RESULTS AND DISCUSSION

The L-systems for three plants are presented in Table 1. For each plant the data in the table consist of (1) the angle increment (6 in degrees) equated with the symbols "+" and "—," (2) the axiom (co), which is the initial state of the system, and (3) the list of pro­duction rules (pi, P2, •'', Pn)- For clarity blocks of rules that are involved in the same structural or func­tional components of the plant are set off by headings inserted in the table. The structural components are the main axis, left and right branches, branchlets, and the functional components are cell elongation and de­layed cell elongation. In writing the L-systems individ­ual cells of the coded plants were separated by the symbol "f" The resulting in white "space" separations between cells made it possible to easily distinguish sin­gle cells in the graphic images. Such "spaces" corre­spond to the presence of translucent cell walls between adjacent pigmented cells.

Images resulting from these L-systems are shown in Figs. 1,2, and 3. These images are in good visual agree­ment with published photographs and drawings of the three plants that they represent, Antithamnion ptero-cladellum[l], Antithamnion densum[S, 9 both as A. defectum], and Antithamnion tenuissimum[\\].

' The program, L-System, is available from Intellimation, P.O. Box 1530, Santa Barbara, CA 93116.

Page 25: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

20 JOHN D . CORBIT and DAVID J. GARBARY

Table 1. L-Systems for three species of seaweed {Antihamnion).

A. pterocladellum

k 10"

Main axis oo: abF p , : a - • FFf Pi.b-^c py. c - • F d d d e [ + + + + + m ] [ mjddfc

Delayed cell elongation P4: d - * e Ps: e - • g P6: g - * h P?: h - • i Ps: i -*- J P9: J - ^ k p,o: k - • FF

Branch Piiim ->^ nofF Pi2. n - • fFF P\3'- o-*p

P\4- P -*• f^[ Piy q ^ fF[ p,6: r -^ fF[ Pn: s -»• fF[

A ir-l--4-4_-l--l--l-l41Po Aj[++T-T-++rijrQ

- — B ] [ + + + + + I ] F r - C ] [ + + + + J ] F s D i r + + + K l F t

PiB-1 ^ f F [ — E K + + L 1 F

Right branchlets Px9. A - • BF P20: B — Ff+C P 2 i : C - ^ F f + D /722: D ->• Ff+E P23: E - • Ff+G /724: G — Ff+

L^y? branchlets P25: H ^ IF P26:1 - ^ F f - J /727: J - • F f - K /728: K — F f - L P29: L — F f - M pyo: M - * Ff-

A. densum

k 12°

Main axis co: abF Pi: a - * Ff P2:h^c py. c - * FFFz[+++k][ 774: d ^ FFFz[+++k][ Ps: e -* FFFz[+++fj]FFfg Pel g -> FFFz[+++k][ ;77: h -^ F F F z [ + + + k ] [ — Ps: i -> FFFz[ fjJFFfc

Indeterminate branch pg. j -»• abF

Left determinate branch PxQ. k -> ImfF A . : l - > f F /7i2: m - • n Pxi. n - • fFF[—A]Fo Pu: 0 — fFF[—B]Fp Pis: p ^ fFF[—C]Fq p,6: q ^ f F F [ — D ] F

/?/^/z? determinate branch Pif. r - ^ stfF Pis. s -> fF / 7 i 9 : t - » • u

/72o: u -»• fFF[4-+A]Fv ;72i: V -*• fFF[++B]Fw ;722: w - • fFF[++C]Fx /723: X - * fFF[++D]F

Branchlets P24- A - • fFB P25: B ->• fFC /726: C — fFD /727: D - * fF

Cell elongation P2s: z -*• Fz

-rjFFfd -rJFFfe

-rjFFfh -rjFFfi

A. tenuissimum

6:20°

Main axis (o: abF A : a - » - F f P2: b - ^ c P3: c - • F F F Q [ + + + + A ] [ A : d -^ + F F F Q [ + + + + A ] [ — Ps. e-»• F F F Q [ + + + + A ] [ p^: g -> - F F F Q [ + + + + A ] [ -P7: h - • F F F Q [ + + + + A ] [ — pg: i-»• FFFQ[+++fp]FFfi p^: j - • F F F Q [ + + + + A ] [ p,o: k — + F F Q [ + + + + A ] [ — p , , : 1 -H- F F F Q [ + + + + A [ p,2: m -*- - F F F Q [ + + + + A ] [ -/7,3: n - • F F F Q [ + + + + A ] [ — P H : 0 -> FFFQ[ fpJFFfc

Indeterminate branch P15: p -»• abF

Left determinate branch /7,6: A - • BCfFFF PM'. B — fF p.g: C ^ D p,9: D - • fFFFE P20. E -^ fFF[-P]FG P21: G - * fFF[-P]FH P22. H - ^ fFF[-P]F

/?/^/z/ determinate branch P23:1 ^ JKfFFF P24: J - * fF P25: K - • L P2(,: L — fFFFM P27: M - • fFF[+P]FN P28: N — fFF[+P]FO P29: 0 - • fFF[+P]F

Branchlet p^: P — fFfF

Cell elongation P 3 . : Q - ^ F Q

—IjFFfd IJFFfe

—IlFFfg - — I ] F F f h —IjFFfi

—IjFFfk —IjFFfI - I jFFfm

IjFFfn —IjFFfo

A developmental sequence for Antithamnion den­sum is shown in Fig. 4. The sequence begins with a single cell that represents the initial apical cell of the upright axis that develops during spore germination. The axiom of the L-system (co) is identified with this single cell (initial apical cell). Figure 4 shows the se­quence of images resulting from the first 12 iterations of the L-system for ^. densum. The main axis consists of a string of cells. The cells of the main axis result from cell divisions only by the apical cell at the tip of the filament. The first apical cell division that occurs on the first iteration results in a basal cell that remains diminutive thereafter and does not branch. The second and subsequent apical cell divisions (iterations) result in axial cells of the main axis that do branch, and it is the pattern of this branching that distinguishes the three different species of Antithamnion.

Branching occurs following mitosis in intercalary cells, which generates a lateral apical cell. This new apical cell develops into a new branch. The growth of the new branch then proceeds by apical cell division in a manner similar to that of the main axis. On the first apical cell division in the branch, as in the main axis, a diminutive non-branching basal cell is produced.

Subsequent apical cell divisions in the branch also re­sult in cells that branch.

Antithamnion produces two types of branches. The first type, apparent in all three species studied here (Figs. 1, 2, and 3), is opposite determinate branching. These branches are arranged in opposite pairs along the main axis. They are determinate in the sense that they grow to a certain number of cells in length and then cease to grow thereafter. The second type of branch is called indeterminate, and these branches are indeterminate in the sense that they continue to grow more or less indefinitely.

Using these definitions of determinate and indeter­minate, then the main axes of all of the species of mod­elled here are indeterminate and continue to grow on each iteration. All of the species have opposite pairs of determinate branches. The shapes of these deter­minate branches are different for the different species (note especially A. pterocladellum in Fig. 1), but they are all similar in that they grow to a certain number of cells in length and cease to grow thereafter.

In A. densum and A. tenuissimum (Figs. 2 and 3) the pattern of pairs of opposite determinate branches is interrupted periodically by the formation of an in-

Page 26: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Lindenmayer systems and seaweed 21

X \ \ \ X "^Vy '

- A '

V N N ^

c ^ "**. \ \ V \ \ \ \

AN \ \ N > V \ \ \

>

N <kN N N N

tv ^ ^ ^ ^ C ' A \ \ \ ^ - - < « I " - - -^ J ^^ X.

N <kN N N N

"^^X \ N \

N VN \ \ N N

C ^ \ N N \

Xv ^ ^ ^

^ ^ vN N N N N

tv ^ ^ ^ < t x - >

t I 11>

! / ; > :

/ / / / <, / / / />^

X ^ ' f / / / / <, / / / />;"

^x * '

/ / / /^^

f

/ / / / <» / / / />'

» ' I 'AC

* f t f O

I I I 1^^

Jc "

/ / / / < , / / / / ^

/ / / />*" / / / > ' ' I ! > ' - - "

Fig. 1. Image generated by the L-system for^. pterocladellum (18 iterations).

determinate branch. These indeterminate branches are smaller replicas of the main axis, and they show the same pattern of opposite pairs of determinate branches with periodic indeterminate branches. The plants thus show the fractal property of self-similarity. The L-sys­tem models achieve this self-similarity by making re­cursive calls which replicate the main axis. These calls are made by p^ in the L-system for A. densum and by Pi5 in the L-system for A. tenuissimum (see Table 1). In the models the depth of self-similarity, or number of recursive calls, depends upon the number of itera­tions. This is true to life in that the actual plants con­tinue to grow in this self-similar way to at least four levels of recursion. The images shown in Figs. 2 and 3 represent relatively young plants, and higher degrees of self-similarity are possible in older plants.

4. CONCLUSIONS

The results of this investigation make it clear that L-systems can be used to successfully capture many of the structural features of real plants, several species in the genus Antithamnion. The L-systems presented here generate images that look very much like the plants they are intended to represent. A comparison of the

photograoh of a specimen of ^. tenuissimum (Fig. 5) with the computer simulation of 4. tenuissimum shows that the visual agreement is quite good. A similar degree of agreement is obtained when comparing the simu­lations to the actual structures of the other two species studied here, A. pterocladellum and A. densum.

The simulations presented here are not merely sim­ulations of the overall appearance of a given plant. Instead, as illustrated in Fig. 4, these L-systems simulate the actual developmental sequence whereby the plant, beginning from an initial apical cell, through a series of iterations with cell divisions, becomes the maturing plant.

A fractal plant model, namely, one with recursive calls to an alias of the apical cell of the main axis, gives images that agree very well with the structure of spec­imens of the real plants. Therefore, to this extent the fractal property of self-similarity has been demon­strated in two species of real plants.

Finally, it is of interest to speculate whether or not a correspondence exists between the production rules of the L-systems and actual developmental control mechanisms operating at the cellular level in these spe­cies of red algae.

\ .

\ •

""V

\

\

/

/

Fig. 2. Image generated by the L-system for A. densum (15 iterations).

Page 27: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

22 JOHN D . CORBIT and DAVID J. GARBARY

Fig. 3. Image generated by the L-system for A. tenuissimum (24 iterations).

1 •1 •

I 10

'^^f^^M

Fig. 4. Developmental sequence showing the first 12 iterations in the development of ^. densum.

Fig. 5. Photograph of an actual specimen oi A. tenuissimum (From A. Athanasiadis, A comparative study of Antithamnion tenuissimum and three varieties of 4. Crucialum, including var. scandinavicum var. nov. (Rhodophyceae). Nord. J. Bot. 6, 703-709, 1986). For comparison with the simulation shown

in Fig. 3.

Acknowledgements—We thank Paul D. Bourke, Kenelm W. Philip, and John Quinn for encouraging our studies of L-systems. In addition we thank A. Athanasiadis for providing the negative with which Figure 5 was produced. This work was supported by a grant from the Natural Sciences and En­gineering Research Council of Canada to DJG.

REFERENCES 1. A. Lindenmayer, Mathematical models for cellular in­

teractions in development: I. Filaments with one-sided inputs. / Theor. Biol. 18, 280-299 (1968).

2. A. Lindenmayer, Mathematical models for cellular in­teractions in development: II. Simple and branching fil­aments with two-sided inputs. / Theor. Biol. 18, 300-315(1968).

3. P. Prusinkiewicz and J. Hanan, Lindenmayer Systems, Fractals, and Plants, Lecture Notes in Biomathematics No. 79, Springer-Verlag, New York (1989).

4. P. Prusinkiewicz and A. Lindenmayer, The Algorithmic Beauty of Plants, Springer-Verlag, New York (1990).

5. D. Saupe, A unified approach to fractal curves and plants. In H.-O. Peitgen and D. Saupe (Eds.) The Science of Fractal Images, Springer-Verlag, New York, 272-286 (1988).

6. R. A. Morelli, R. E. Walde, E. Akstin, and C. W. Schnei­der, L-system representation of speciation in the red algal genusDipterosiphonia (Ceramiales, Rhodomelaceae). / Theor. Biol. 149, 453-465 (1991).

7. R. E. Norris, Species of Antithamnion (Rhodophycae, Ceramiaceae) occurring on the Southeast African coast (Natal). J. Phycol. 23, 18-36 (1987).

8. I. A. Abbott and G. J. Hollenberg, Marine Algae of Cal­ifornia, Stanford University Press, Stanford, CA (1976).

9. D. Garbary, D. Belliveau and R. Irwin, Apical control of band elongation in Antithamnion defectum (Ceramiaceae, Rhodophyta). Can. J. Bot. 66, 1308-1315 (1988).

10. A. Athanasiadis, Evolutionary biogeography of the North Atlantic Antithamnioid algae. In D. J. Garbary and G. R. South (Eds.) Evolutionary Biogeography of the Marine Algae of the North Atlantic, Springer-Verlag, Berlin (1990).

11. A. Athanasiadis, A comparative study of Antithamnion tenuissimum and three varieties of . cruciatum, including var. scandinavicum var. nov. (Rhodophyceae). Nord. J. 5o/. 6, 703-709(1986).

Page 28: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 23

Chaos and Graphics

GENERATING FRACTALS FROM VORONOI DIAGRAMS

KEN SHIRRIFF Computer Science Division, 571 Evans Hall, University of California, Berkeley, CA 94720

Abstract—This paper describes how to generate fractal patterns by recursively creating Voronoi diagrams on a set of points. These patterns resemble such things as leaf veins and roadmaps. By varying the degree of subdivision and the distribution of points, different output patterns can be obtained.

Voronoi diagrams can be used to generate interesting clipped to that region. We repeat this process recur-fractal patterns that resemble leaf veins, roadmaps, and sively, building a new Voronoi diagram inside each cracked pottery glaze. The patterns are generated by region of the higher level diagram. Listing 1 gives a recursively creating a Voronoi diagram inside each pseudocode description of the algorithm. Figure 1 Voronoi polygon. (A Voronoi diagram consists of demonstrates execution of the algorithm through four nearest-neighbor polygons. Given a set of points, the levels. The first point set consists of 5 points; the next Voronoi polygon around each point is the region of sets are 25, 125, and 625 points, the plane closer to the selected point than to any other The output can be varied in several ways. The most point [1].) obvious parameters are the number of points at each

To generate the fractal images, we start with a small level and the total recursion depth. Figure 2 uses 10, set of points and draw the Voronoi diagram of these 100, 1000, and 10000 points in four levels of recursion, points. Then, we use a denser set of points and compute Thus, each polygon is subdivided into an average of a new Voronoi diagram inside each region of the first 10 subpolygons. The line thickness is halved at each diagram. That is, for each region, we consider only the level to emphasize the higher levels. In Fig. 3, the points inside that region, and draw a Voronoi diagram number of points at each level is computed with fac-

"max—level" is the number of levels to do. ''num—points" is an array of the number of points at each level "pointset" is an array of sets of points. "drawing^area" is the initial screen region. "v or polygons" is a set of Voronoi polygons. "generate—points" generates a set of points. "intersect" intersects a set of points with a region, returning a set of points. "voronoi—diagram" generates the Voronoi polygons of a set of points. "draw" draws polygons clipped to a region.

function main(max_level, num_points) pointset [ max_level ] = generate—points (num_points [ max_level ]) for i = 1 to max_level-1

pointset [ i ] = first num_points [ i ] points o/pointset [ max_level ] end for draw_fractal( 1, drawing—area)

function draw—fractal (level, region) points = intersect (pointset [ level ], region) vor—polygons = voronoi—diagram( points) draw (vor—polygons, clipped to region) if (level < max—level)

for i in points draw—fractal (level +1, vor—polygons [ i ])

end for end if

Listing 1. Pseudocode for the Voronoi fractal algorithm.

Reprinted from Comput. & Graphics Vol. 17, No. 2, pag. 165-167, 1993

Page 29: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

24 K. SHIRRIFF

Fig. 1. Iterations of the algorithm over four levels, showing results after 5, 25, 125, and 625 points. Fig. 4. Nonuniform distribution on a disk. The levels have

10, 100, 1000, and 10000 points.

torials: the levels have 2!, 3!, 4!, 5!, 6!, 7!, and 8! points. This results in more subdivision in deeper levels. Fi­nally, a small degree of subdivision at each level, for instance by using 3, 9, 27, and 81 points, gives a more angular result than larger subdivisions.

The distribution of points can be changed to affect the output. Figure 4 uses a distribution of points in a circle, weighted towards the edge. The result is some­what reminiscent of Escher. Figure 5 uses a nonuniform distribution in the plane; the first level is weighted to the left, the second to the bottom, the third to the right, and the fourth to the top. As a result, polygons on different scales shrink in each of the four directions.

A final way to vary the output is, for each polygon, randomly decide if it is to be subdivided or not sub-

Fig. 2. A Voronoi fractal generated by subdivision by 10. The four levels have 10, 100, 1000, and 10000 points.

Fig. 3. A Voronoi fractal with more subdivision at lower levels. The levels have 2!, 3!, 4!, 5!, 6!, 7!, and 8! points.

Fig. 5. Nonuniform distribution on a square. Successive levels are weighted towards the left, bottom, right, and top, and

have 10, 100, 1000, and 10000 points respectively.

Page 30: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Generating fractals from Voronoi diagrams 25

divided. This creates an image with voids of various sizes, and with a smaller fractal dimension. However, the result is not particulariy pleasing, and a sample image is not included.

Acknowledgements—This research was supported by an IBM Graduate Fellowship. The initial Voronoi diagram code was

written by Steven Fortune and is described in [2]. I wish to thank Clifford Pickover for his helpful comments.

REFERENCES 1. F. P. Preparata and M. I. Shamos, Computational Ge­

ometry, Springer-Veriag, New York (1985). 2. S. Fortune, A Sweepline Algorithm for Voronoi Diagrams,

Algorithmica 2, 153-174 (1987).

Page 31: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 27

Chaos and Graphics

CIRCLES WHICH KISS: A NOTE ON OSCULATORY PACKING

CLIFFORD A. PICKOVER IBM Thomas J. Watson Research Center, Visualization Systems Group, Yorktown Heights, NY 10598

Abstract—This paper provides a light introduction to simple graphics techniques for visualizing a large class of shapes generated by osculatory packing of circles and spheres.

This note provides several simple recipes for graphically interesting structures based on the osculatory packing of finite areas using circles and spheres. The problem of covering a finite area wdth a given set of circles has received frequent attention [ 1 ]. As background, the densest packing of non-overlapping uniform circles is the hexagonal lattice packing where the ratio of covered area to the total area (packing fraction) is 0 = 7r/VT2 = 0.9069. The limiting packing fraction for nested hexagonal packing of circles, with k different circle sizes is

the plane. In this case the circle center is discarded, and a new attempt to place a circle is made.

Circle center distributions were chosen in three ways in order to generate artistic patterns. In Figs. 2-3, the circle centers were selected using a uniform white noise generator. Fig. 2b is a magnification of a tiny area of Fig. 2a. In Fig. 3, an upper bound is used for the largest allowed circle size. Figs. 4a and 4b are created from Brownian (random walk) noise. To create these figures, the center positions of the newly placed circles were computed from:

0A= 1 - ( I -0.9069)* (1)

This applies to cases where each of the uncovered areas, or interstices, is also hexagonally packed by smaller circles. For larger values of k,<t>k approaches unity (1).

Past work has usually defined a distribution of circles as osculatory if any available area is always covered by the largest possible circle [1]. If the original area to be covered is a tricuspid area (Fig. 1), then the first circle to be placed must be tangent to the three original larger circles. This kind of packing is also often referred to as Apollonian packing[2]. In contrast to past work, the criterion for osculatory packing is relaxed here: each successively placed circle on the plane need only be tangent to at least one previous circle (tangent-l packing). To generate the artistic figures in this paper, a circle center is randomly placed within the available interstice. The circle then grows until it becomes tan-ge. to its closest neighbor. The process is repeated several thousand times. One easy way to simulate this on a computer is to determine the distances dt from the newly selected circle center to all other circles / on the plane. Let

di = di - r, (2)

where r, is the radius of circle /. min{5/} is then the radius of the new circle. Note that if there exists a neg­ative 8i then the selected center is within a circle on

Xi = Xi-i + Xi + r/_iCOs(27rX2)

y, = y,., + X3 + r/-isin(2irX2) (3)

where X is a random number. Fig. 5 shows tangent-1 spheres with a Gaussian-white center distribution. The Gaussian noise was produced by

Gj = {\/n) 2 h (4)

where Xk are random numbers on (0,1), and n - 5. Note that n can have different values for the x and y directions. Fig. 5 shows a simple, easy-to-implement model of soap bubbles produced by ray-tracing a Gaussian osculatory distribution of spherical shells (Eq.

Fig. I. Tricuspid interstices in standard osculatorv* packing.

Reprinted from Comput. & Graphics Vol. 13, No. 1, pag. 63-67, 1989

Page 32: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

28

Fig. 2a. Tangent-1 osculatory packing for white distribution of circle centers.

Fig. 2b. Magnification of a small section of Fig. 2a.

Page 33: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Circles which kiss 29

Fig. 3. Osculatory packing for white distribution of circle centers with an upper bound for allowed circle radii.

2 is extended to three dimensions). Two light sources were used to produce the figure, and the picture res­olution is 1024 X 1024. Figs. 6a and 6b show covering area vs. time plots for circles placed on a 100 X 100-unit plane. "Time" indicates the number of attempts to place a circle. For a white distribution of circles (Fig. 6a), the value for the covering area rapidly achieves a plateau as available voids are filled. For the Brownian distribution, the covering area function has a very different shape. The various intermediate pla­teaus indicate packed domains in which the wandering circles temporarily get trapped (because surrounding voids are scarce). Since the circle sizes are not con­strained to some minimum radius, the wandering circle can always "squeeze" its way out of a tightly packed area.

The fractal dimensions D for these pictures can be computed from the mass-radius power law relationship m ^ r^.m(r) is the combined area of all circles con­tained within a measuring circle of radius r. By ob­serving the change in mass as a function of r, the di­mension can be empirically computed. For the white osculatory tangent-1 packing, D ^ 1. Statistical self-

similarity of the packing in Fig. 2 indicates that suc­cessive magnifications will have a similar appearance. For the brown distributions in Figs. 4a and 4b, D '^1.8. Interestingly, recent research has used similar circle placement techniques to model thin-film growth and the kinetics of droplet formation [ 3 ] . Thin films play an increasingly important role in a variety of ap­plications, from microelectronics to biochemical sen­sors.

This note provides another example of interesting graphical behavior in chaotic systems. For additional information on the distribution of circle radii in stan­dard Apollonian packing, and for packing of hyper-spheres in «-dimensional space, see [1, 4] . Over the last few years, mathematicians have begun to enjoy and present bizarre mathematical patterns in new ways—ways sometimes dictated as much by a sense of aesthetics as by the needs of logic [5, 6]. Moreover, computer graphics allows non-mathematicians to ex­perience some of the pleasure that mathematicians take in their work and to better appreciate the very com­plicated and interesting graphical behavior of certain simple formulas.

Page 34: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

30

Fig. 4a. Brownian distribution of circle centers.

Fig. 4b. Brownian distribution of circle centers. The total covering area is visually accented by filling these regions.

Page 35: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Circles which kiss 31

Fig. 5. Soap bubbles in the moonlight. This figure was produced by ray-tracing a Gaussian osculatory distribution of spherical shells.

2 4

Time

Covering Area for White Distribution Covering Area for Brownian Distribution

Fig. 6a. Covering area function for white tangent-1 packing. Fig. 6b. Covering area function for brown tangent-1 packing.

REFERENCES

1. H. Kausch-Blecken, V. Schmeling and N. Tschoegl, Os­culatory packing of finite areas with circles. Nature 225, 1119-1121 (1970).

2. D. Boyd, The residual set dimensions of the Apollonian packing. Mathematika 20, 170-174 (1973). B. Mandel­brot, The Fractal Geometry of Nature, Freeman, New York (1983).

3. F. Family and P. Meakin, Getting the drop on thin films. Science News 134, 124 (1988). (See also June 25, 1988 Phys. Rev. Lett.)

4. M. Gardner, Packing of circles and spheres. Scien. Amer. 218, 130-135(1968).

5. C. Pickover, Computers, Pattern, Chaos and Beauty, St. Martin's Press, New York (1990).

6. I. Peterson, Portraits of equations. Science News 132(12), 184-186 (1987) (and cover picture).

Page 36: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 33

Chaos and Graphics

GRAPHICAL IDENTIFICATION OF SPATIO-TEMPORAL CHAOS

ARUN V. HOLDEN Centre for Nonlinear Studies, The University of Leeds, Leeds LS2 9JT, UK

and

A. V. PANFILOV Institute of Biological Physics, USSR Academy of Sciences, Pushchino, 142292 Moscow Region, USSR

Abstract—A graphical method for identifying spatio-temporal chaos in irregular spatio-temporal patterns is illustrated using numerical solutions of partial differential equations that model cardiac tissues.

Chaos is irregular, complicated behaviour that has been produced by nonlinear systems that can be systems of equations or actual biological, chemical, engineering, or physical systems [1]. The behaviour appears as a continuous or discrete time series and the actual system can be modeled by a nonlinear recursion (a map) or nonlinear ordinary differential equations. The irregu­larity is produced by a deterministic system and shows long-term unpredictability—this is due to sensitivity of initial conditions.

Although the possibility of chaotic behaviour has been known in principle since the work of Poincaire, the current enthusiasm for chaos [ 2 ] is based on the availability of computers for numerical experiments, and computer graphics for displaying the results of these numerical and laboratory experiments. Although, formally, a mathematician would require proof of the existence of a strange attracting set and a scientist would require a positive maximal Lyapunov exponent as in­dices of chaos, in practice, chaos is identified graphically by the reconstruction of a low order, strange (appar­ently with a fractal structure) attractor from numerical solutions or experimental observations. This can be done by using the method of delays, by plotting the variable x(t) against its earlier values x(t — r ) , x{t — 2T), • • • [3]. The reconstructed attractor is then quantified, by estimation of the spectrum of Lya­punov exponents, and the various dimensions and en­tropies of the attractor that can be defined [4, 5].

These methods can be appUed to time series, but most processes of interest are not simply time series, but spatially extensive. Thus, they are spatio-temporal patterns, and can be represented in discrete space by discrete time, discrete state (cellular automata), or discrete time-continuous state (coupled map lattice) models. In continuous space, a continuous time, con­tinuous state model is a partial differential equation. These spatially extensive systems and their models can exhibit periodic, patterned or irregular behaviours. A major question is whether spatio-temporal irregularity (in a model or in experimental observations) is due to

deterministic nonlinear processes, and hence is spatio-temporal chaos.

One approach is to ignore the spatial aspects, as in Lorenz's truncation of the Navier-Stokes equations, to three nonlinear ordinary differential equations [6]. Although this has been remarkably successful, it is not satisfactory in situations where spatial effects are of interest.

In discrete space models, spatio-temporal chaos can be considered as a pattern that does not repeat itself as long as the model is iterated [7]: the determinism is guaranteed by a simple model. This is not applicable to experimental observations.

We have been interested in modelling wave phe­nomena in cardiac tissue [8], where recirculation of electrical activity is associated with arrhythmias and ventricular fibrillation. Cardiac tissue is described by a reaction-diffusion equation, where the nonlinear

Fig. 1. Difference in electrical potential between two runs with similar initial conditions; red: —ve^ blue: -\-ve, yellow: no dif­ference. To begin, the difference is apparent only at the fast front of the rotating vortex; with time, the difference increases and spreads throughout the medium. However, the vortex

structure is still apparent as new vortices arise.

Reprinted from Comput. & Graphics Vol 15, No. 2, pag. 201-302, 1991

Page 37: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

34 ARUN V. HOLDEN and A. V. PANFILOV

"reaction" components describe the electrical behav­iour of the cell membrane. These equations are com­plicated, and so are investigated by numerical methods. Numerical solutions of 2D reaction-diffusion equations can show spiral wave solutions (or vortices), which are believed to correspond to the recirculation of ex­citation seen in ventricular fibrillation [9 ] .

Our numerical computations have shown an insta­bility in these spiral waves for a particular model of cardiac tissue: the rotating spiral wave breaks down as a result of interactions between the fronts and backs of successive waves [10, 11]. This spatio-temporal ir­regularity is obtained in numerical solutions of deter­ministic partial differential equations, however, if it is spatio-temporal chaos, it is necessary to demonstrate a sensitivity to initial conditions.

To demonstrate such sensitivity to initial conditions, we take two integrations with very similar initial con­ditions and plot the difference between them; this method could be used with spatio-temporal data with similar initial conditions. The results are displayed in Fig. 1. Initially, there is hardly any difference between the two runs, and this difference is only apparent at the steeply rising wavefront of the spiral wave. As tip fragmentation occurs, a difference becomes visible at the centre of the vortex, and this difference increases and spreads outward from the centre of the vortex.

REFERENCES 1. A. V. Holden (ed.), Chaos, Manchester University Press,

Manchester, UK; Princeton University Press, Princeton NJ(1986).

2. I. Stewart, Does God Play Dice? The Mathematics of Chaos, Blackwell, Oxford (1989).

3. N. H. Packhard, J. P. Crutchfield, J. D. Farmer, and R. S. Shaw, Geometry from a time series. Phys. Rev. Lett. 45,712-716(1980).

4. A. Wolf, Quantifying chaos with Lyapunov exponents, In Chaos, A. V. Holden (ed.), Manchester University Press, Manchester, UK (1986).

5. P. Grassberger, Estimating the fractal dimensions and entropies of strange attractors. In Chaos, A. V, Holden (ed.), Manchester University Press, Manchester, UK (1986).

6. E. Lorenz, Deterministic nonperiodic flow. / Atmos. Sci. 20, 130-141 (1963).

7. S. Wolfram, Universality and complexity in cellular au­tomata, Physica lOD, 1-36 (1984).

8. A. V. Holden, M. Markus, and H. G. Othmer (eds.), Nonlinear Wave Processes in Excitable Media, Plenum, New York (1990).

9. A. T. Winfree, When Time Breaks Down. The Three-Dimensional Dynamics of Electrochemical Waves and Cardiac Arrhythmias, Princeton University Press, Princeton, NJ( 1987).

10. A. V. Panfilov and A. V. Holden, Self-generation of tur­bulent vortices in a two-dimensional model of cardiac tissue. Phys. Lett. A., 151, 23-26 (1990).

11. A. V. Panfilov and A. V. Holden, Spatio-temporal irreg­ularity in a two-dimensional model of cardiac tissue. Int. J. Bifurcation and Chaos, 1, 219-255 (1991).

Page 38: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 35

C h a o s a n d G r a p h i c s

MANIFOLDS AND CONTROL OF CHAOTIC SYSTEMS

HELEN QAMMAR^ and A. VENKATESAN

Department of Chemical Engineering, University of Akron, Akron, OH 44325, U.S.A.

Abstract—^Because of the erratic oscillations in chaotic systems, it is often desirable to control them to a steady state. When a controller is added it creates a new dynamical system whose properties are influenced by the underlying chaotic system. Increasing the amount of control has a dramatic effect on the manifolds and the basin for the desired stable steady state. Therefore, it is important to understand the effect of the unique properties of chaotic systems when developing new controller designs to yield optimum performance.

1. INTRODUCTION

The control of chaos has recently attracted much attention [1-8]. The existing control techniques can be classified as (1) feedback where the error between the actual and desired response is used to perturb the chaotic system and (2) nonfeedback where a small driving force is added to the chaotic system and thus the effectiveness of these controllers must consider the unique properties of the chaotic system. These properties include sensitivity to initial conditions, existence of a dense set of unstable orbits within the chaotic attractor, ergodicity of the chaotic motion, fractal structure of the chaotic attractor, and the existence of a homoclinic tangle within which the chaotic attractor is embedded.

It is important to remember that adding a controller creates a new dynamical system. If the desired response, also called the reference state, is away from the chaotic attractor then we are not concerned with the structure of the chaotic attractor but only with the structure of the manifolds for the reference state. This state should be stable and have a large, non-sparse basin of attraction so that the controlled system quickly converges to the reference state and is relatively insensitive to noise. The degree to which the controlled system obtains these attri­butes depends on the properties of the underlying chaotic system. To understand the influence of the underlying system we shall show how the stable manifold and the basin for the desired reference state change as the interaction between the controller and chaotic system becomes stronger.

2. UNCONTROLLED SYSTEM

Consider a practical example of a chaotic system from chemical engineering, namely the solution polymerization of vinyl acetate in a full-scale industrial reactor. Vinyl acetate monomer, dissolved in solvent and in the presence of an initiator.

undergoes an exothermic, free-radical reaction to form polyvinyl acetate. The reaction takes place in a continuously stirred reactor (CSTR). Heat from the reaction is transferred to cooUng water in the jacket surrounding the reactor. A mathematical model of a laboratory-scale reactor was developed and verified by Teymour and Ray [9-11]. They easily modified this model to include the differences found in a typical full-scale reactor.

The resulting non-dimensional model of Eqs (1)-(4) consists of four ordinary differential equations describing the dynamics of the monomer volume fraction, Vm, solvent volume fraction, Vs, dimension-less initiator concentration, Zi, and the dimensionless reactor temperature, y.

dVm . , , . PiTif ,, fqoui - 7 - = (1 - <Ps) — ^ - Vm - — d-T Pm \ ^in

-OVrnik^ + hrm)P " 9 1 ^ ^ ^ Ifk^zJr (1)

dVs Psf /

- _ - = 1 - Ok^Zi - Zi dx V ^in

(2)

(3)

dy 1 /p fCpf N Pf / \

pCpTc [MW]^ pCp^in

oc(UA) , , Ohi ,^ , , (y- yamh) - ^ j.rr. (^mVm + ^ X s )

pCpqir pC^VT,

P =

^ Author for correspondence.

Ifkdzjf:

kt

(4)

(5)

Reprinted from Comput. & Graphics Vol. 19, No. S, pag. 455-466, 1995

Page 39: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

36 H. Qammar and A. Venkatesan

J 1 Pp Pm

i P i d T j -(6)

Also included is the concentration of free-radicals, P, and the change in the volumetric flow rates between the feed, ^in, and the reactor output, ^out, because of the density changes resulting from the polymerization reaction. The temperature dependence for some of the model parameters are listed in Table 1. In the interest of brevity and because we assume most readers will be unfamiliar with even the standard chemical engineering notation we will omit a discus­sion of the specific terms in this system. Details about the model can be found in ref. [9].

Teymour and Ray uncovered a wide variety of nonlinear behavior exhibited by this model including

Table 1. Temperature dependent model parameters

Kinetic parameters kp = 4.899 X 10 e^

M r m • :1.42x 10-2e^A:p

multiplicity, period-doubling, and chaos. We are interested in one scenario where chaos and a stable steady state coexist. (This multipHcity depends on starting the reactor with polymer in it; an impractical but physically possible condition.) All of the reactor conditions are as stated in refs [9-11] unless otherwise noted. The uncontrolled system was integrated using LSODA [12] with a step-size of 0.05 time units. An example of the multiphcity is shown in Fig. 1 and the basin boundary is given in Fig. 2(a). Note that in this case the boundary appears to be smooth.

3. CONTROLLED SYSTEM

The role of the controller is simply to force the reactor to operate at the stable steady state for the uncontrolled system, i.e. y* = Fss- We have chosen this control objective because our purpose is to show the effect on the system manifolds when a small change, such as adding a controller, is made to the dynamical system. Note for all points starting in the basin of the steady state, if we do nothing (i.e. no control) the reactor will eventually go to the desired temperature, y*. We designed a simple proportional feedback controller (Eq. 7) which measures the error between the actual reactor temperature, y, and the desired temperature, y*, and manipulates the tem­perature of the feed, yr.

Physical properties p^= 0.9584-1.3276 X IQ-^T p, = 1.211-8.496 X 10-^ r

74.12 ^ "60.21+0.116(r+273) CP = 0.3453 + 9.55 x IQ-^T- 25)

yr=yr + Kc{y- • / ) • (V)

The value for the controller parameter, Ac, also called the proportional gain, can be chosen to optimize the controller performance. When Kc is non-zero we have a new dynamical system with the same state-space dimension but different non-

100

Fig. 1. Co-existing chaotic attractor and stable steady state for system of Eqs (l)-(6).

Page 40: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Manifolds and control of chaotic systems

(b) 1.05

37

0.25 0.3 MONOMER FRACTION

0.35 1.01

0.2 0.25 0.3 MONOMER FRACTION

0.35

1.05

Sl.04

< cc 1.03 UJ " ' ^ ^

a.

(c)

LU 1.02

* •• r*i:i*':li:

Iiiitii.iatlti.t* it.iiitititt 2.1. • • *a lllif **'

• i ; t i . . . . .

PMliiil!!i!l| J"::: •:!Hi«ili

1.01 0.2

u-l—•« ti ts t Hl"il

1.04 (d)

0.25 0.3 MONOMER FRACTION

0.35 0.25 0.3 MONOMER FRACTION

0.35

Fig. 2. Effect of fcp on basin of attraction for steady state. Initial conditions: zi = 1.0 and Vs = 0.6. Steady state: v„, = 0.331, y = 1.019. (a) IQ = 0.0, (b) Kc = 0.5, (c) ^ = 1.5, (d) Ac = 2.0.

Fig. 3. Convergence time to steady state in uncontrolled system.

Page 41: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

38 H. Qammar and A. Venkatesan

linearities from the system defined by Eqs (l)-(6)- In this paper we view Ac as a measure of how much we are changing the underlying dynamical system.

Figure 2 shows the basin of attraction for the stable steady state for four values of Ac. For Ac = 0.5 we have enhanced the region of successful control since some of the points originally in the chaos basin are now attracted to the desired steady state. As we increase Ac, and thus increase the amount of change to the underlying system, some points which were originally in the steady state basin are no longer stable. We believe all of these points lead to chaos based on numerous simulations. Note that the basin boundary between the stable steady state and the chaotic attractor is no longer smooth and may be exhibiting a fractal nature typical of chaotic systems. One explanation for this change in the boundary is that the homoclinic tangle associated with the chaotic attractors is now very close to the stable steady state.

For each of the initial conditions in Fig. 2(a) we calculated the amount of time needed to reach the steady state to within 0.1%. The convergence times are plotted using MATLAB version 4.2 on a SPARCstation and are shown in Fig. 3. An example of the MATLAB graphics code is given in Table 2. Points not in the steady state basin are shown as zero convergence time. The 3-D view depicts a curved, smooth manifold of the stable steady state which causes the abrupt, crevice-like shape in Fig. 3.

Figure 4 shows the convergence times to the steady state for the same initial conditions as in Fig. 3 for three values of Ac. The viewpoint differs from Fig. 3 so that we can more clearly visualize the changes to the manifold. For small values of Ac, for example Ac = 0.5, there is less modification of the underlying dynamical system and the stable manifold is quite obvious. As Ac increases, and thus the magnitude of the feedback increases, the manifold is less obvious and the convergence time is a complicated function

Table 2. M-file for displaying convergence times using MATLAB

clear nn=fopen('lorbas.dat') a=fscanf (nn, '%g %g %g%g', [4,inf ] ) ; fclose(nn); t=a(l,:); yl=a(2,:); y2=a(3,:); y3=a(4,:); x=2:0.1:12.; y=2:0.2:12.; ll=length(t); fori=l:ll in=(yl(i)-2.)/0.1+l; n=(y2(i)-2,)/0.1+l; time(m.n)=t(i); end pause s=[120 45] ; surfl(y,x,timers) shading interp ; colormap copper; axis ([2,0 12, 0. 15. 20 80]) view(15,30); xlabel 'X'; ylabel 'Y': zlabel ' CONVERGENCE TIME ' ; title 'CONVERGENCE TIME FORLORENZ SYSTEM' set(get(gca,'Title'),'FontName', 'Palatino','FontWeight','bold', 'FontSize',14) end

of the initial condition. For the case when Ac = 2.0 we can see that for only a very small region near the steady state would a linear approximation be valid. The manifolds associated with the steady state of Fig. 4(c) must be highly nonlinear and bear httle resemblance to those yielding the structure seen in Fig. 3.

4. CONCLUSIONS

In this paper we have tried to show some of the difficulties of designing effective and robust control­lers for chaotic systems. When a controller is designed

TEMPERATURE 1,04 0.2 MONOMER FRACTION

Fig. 4. (a)—legend opposite.

Page 42: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Manifolds and control of chaotic systems 39

Fig. 4. Convergence time to steady state in the controlled system, (a) Kc = 0.5, (b) Ac = 15, (c) Kc = 2.0.

Fig. 5. Schematic of some of the manifolds in the Lorenz system.

so that a chaotic signal is fed back, the result may be fractal basins and highly nonlinear manifolds for the desired stable reference state [2]. Perhaps the ideal controller would be one that modifies the chaotic system by causing a crisis. In this case a stable manifold of the reference state would intersect with the chaotic attractor causing any trajectory on the attractor to quickly converge to the desired state.

In this work a manifold associated with a stable steady state was highlighted by using a convergence time plot. We feel that such plots may be very useful in introducing the concept of manifolds to students. Consider a schematic of the manifolds (Fig. 5) associated with the three steady states of the Lorenz system when (7=10.0, 6 = 8/3 and r = 20 [13].

Page 43: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

40 H. Qammar and A. Venkatesan

Fig. 6. Convergence time showing a stable manifold for a steady state in the Lorenz system.

Figure 6 shows a convergence time plot for one of the symmetric stable steady states which more clearly shows the fast spiral nature of the manifold.

REFERENCES 1. E. Ott, C. Grebogi, and J. A. York, Controlling chaos.

Phys. Rev. Lett. 64, 1196-1199 (1990). 2. H. Qammar, F. Mossayebi, and T. Hartley, Indirect

adaptive control of a chaotic system. Chem. Engng Commun. 110, 99 (1991).

3. B. Peng, V. Petrov, and K. Showalter, Controlling chemical chaos. J. Phys. Chem. 95, 4957-4959 (1991).

4. G. Chen and X. Dong, From chaos to order— perspectives and methodologies in controlling chaotic nonlinear dynamical systems. Int. J. Bif. Chaos^ in press (1995).

5. K. Pyragas and A. Tamasevicius, Experimental control of chaos by delayed self-controlling feedback. Phys. Lett. A 180, 99-102 (1993).

6. P. Parmananda, P. Sherard, R. W. Rollins, and H. D. Dewald, Control of chaos in an electrochemical cell. Phys. Rev. EAly R3003-3006 (1993).

7. T. Kapitaniak, L. J. Kocarev, and L. O. Chua, Controlling chaos without feedback and control signals. Int. J. Big. Chaos 3, 459-468 (1993).

8. Y. Liu and J. R. Rios Leite, Control of Lorenz chaos. Phys. Lett. A 185, 35-37 (1994).

9. F. Teymour, Ph.D. Dissertation, University of Wiscon­sin (1989).

10. F. Teymour and W. H. Ray, The dynamic behavior of continuous solution polymerization reactors—IV. Chem. Engng Sci. 44, 1967-1982 (1989).

11. F. Teymour and W. H. Ray, The dynamic behavior of continuous solution polymerization reactions—^VI. Chem. Engng Sci. 41, 4133-4140 (1992).

12. L. Petzold, Automatic selection of methods for solving stiff and nonstiff systems of ordinary differential equation. SI AM J. Sci. Stat. Comput. 4,136-148 (1983).

13. E. N. Lorenz, Deterministic nonperiodic flow. J. Atmos. Sci. 20, 130-141 (1963).

Page 44: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 41

Chaos and Graphics

A VACATION ON MARS—AN ARTIST'S JOURNEY IN A COMPUTER GRAPHICS WORLD

CLIFFORD A. PICKOVER IBM Thomas J. Watson Research Center, Visualization Systems Group, Yorktown Heights, NY 10598

Abstract—This note provides several artistic examples of landscapes produced on a graphics supercomputer. The shapes were created using a single graphics primitive, and rendered using lighting and shading facilities of 3-D extensions to X-windows and the PHIGS+ proposed graphics standard. In order to encourage reader involvement, this informal article also provides several simple numerical recipes for computing the forms in the paper.

The heavens call to you, and circle about you, displaying to you their eternal splendors, and your eye gazes only to earth.

Dante

1. INTRODUCTION

The idea that nature and mathematics are inextricably linked is not new—and neither is the application of that idea in computer graphics. What is new is the use of rich software tools and powerful new hardware to visualize artistic and mathematical models of nature. The purpose of this paper is threefold: (a) to present a gallery of artistically interesting landscapes resembhng extraterrestrial terrain, (b) to emphasize the role of simple graphical primitives and the simplest of C-coded algorithms in generating complicated aesthetic struc­tures, and (c) to indicate the degree to which such studies are facilitated with the emergence of a new class of graphics supercomputers. Reader involvement is encouraged by giving numerical recipes for the various forms.

Informally speaking, the landscapes in this paper are fractals—rough-edged objects which continue to exhibit structural details upon increasing magnifica­tion. These complicated objects have been studied ex­tensively by B. Mandelbrot, who coined the word "fractal" (in 1975) to describe such irregular shapes, and who originated the idea of fractal landscapes in computer graphics[l, 2]. Various methods have been used in the past to generate terrain, and many of these methods have used Brownian (or Brownian-like) noise functions (described later) to create an irregular sur­face. In order to generate these noisy surfaces, the methods sometimes involve the addition of randomly placed and randomly oriented faults in a plane, or the use of fast Fourier transform filtering, or the displace­ment of points on a grid (for a review see [3]). The reader is directed to The Fractal Geometry ofNature[ 1 ] and reference [ 2 ] for details of this work in "Brownian and fractional Brownian surfaces," and more infor­mation on fractals. Voss[3, 4] used fractal concepts to create very convincing forgeries of natures. New ter­rain synthesis methods have since been proposed by Musgrave [ 5 ], Fouriner [ 6 ], and Lewis [ 7 ]. These and other experiments provide continuing incentive for more research on the rapid generation of natural and

artistic landscapes. For readers interested in additional background material in this area, a directed reading fist is provided in the Reference section [8-14].

The method I have used involves the circular disks which are randomly moved on a plane in order to ap­proximate a Brownian surface. I have not seen this approach published in the scientific literature, but considering the simplicity of the method, I expect oth­ers have used similar techniques. The main purpose is to show the reader how to create pretty landscapes using simple methods. Although the approach here sacrifices both the mathematical purity and graphic detail of tra­ditional fractals, the process is conceptually simple and easy to implement—and attractive pictures result.

2. NUMERICAL COMPUTATION

The algorithms and hardware described in this article permit the entire computation and full graphics ren­dering of artistically interesting terrains in approxi­mately 1 to 2 minutes using a Stellar GSIOOO computer.

The terrains shown in the figures were generated using a Brownian distribution of filled circles. To pro­duce this distribution, have your computer take a cir­cular disk of height 1 unit and randomly walk the disk over a plane. Have the moving circle leave behind an irregular trail of circles. After the walk continues for a long time, a bumpy pile of disks finally result. The mountains were generated by viewing (with the aid of a graphics supercomputer) the "bumpy pile" from an angle specified by the user. Red lights were used to illuminate the terrain. Of course, most readers will not have access to a graphics supercomputer, but even if sophisticated graphics computers are unavailable, the resulting Brownian intensity profiles look quite mar­velous if the pile height is represented as color in a 2-D representation.

A C program (Table 1) was written which computes a Brownian distribution of filled circular disks, sums the intensities, and writes an image array to a file on disk. The circle radius was 25, and the array size was 512X512. The Brownian walk step-size was 2, giving a large overlap between successive circles. Notice that since a constant radius of 25 was used for the circle size, these landscapes will not show detail at small size scales. However, the simple numerical methods used

Reprinted from Comput. & Graphics Vol. 16, No. 1, pag. 9-13, 1992

Page 45: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

42 CLIFFORD A. PICKOVER

Table 1. C code to generate raw data for landscapes.

#include <Jstdio.h) #include (fcntl.h) #define SQR(x) ((x)*(x)); #define max(a,b) ((a)>(b)?(a):(b)) #define min(a,b) ((a)<(b)?(a):(b))

char ProgramName[128]; mainO {

int screen[512][512]; char PixelData [1048576]; /* 512*512*4 */ char filename [128]; int seed = 12345; int 1, i, j , k, m, stat; long ii; int width, height; int botx, boty, topx, topy; float scale, lift, xsq, ysq, sumx, centerx, sumy, centery,

radius, radius sq; int numiter, maxpix, fd, div; float stepx, stepy; int iseed; float ran2 (); width = 512; height = 512; srand (3234569); strcpy (FrogramName, "circleg");

ysq = SQR ((float) j - centery); if ((xsq + ysq) < = radius sq)

screen [i][j] = screen [i][j] + lift; }

} \ /* k repetition loop */

-V

/* Initialize Image Array */ for(i = 0; i<512;i++){

for(j = 0;j<512;j++){ screen [i][j] = 0; }

} /*-- Input and Initialize Several Parameters --*/ lift = 1; centerx = 250; centery = 250; printf ("number of iterations (e.g. 1000)"); scanf ("%d", &numiter); printf ("radius (e.g. 20) "); scanf ("%r', &radius); radius sq = radius*radius; printf (*'%d %f\n'*, numiter, radius);

/* Main Loop */ for (k = 1; k < = numiter; k++) { /* CaU Random Number Generator */ stepx = (float) rand()/32767.; if (stepx > .5) stepx = 2;

else stepx = - 2 ; stepy = (float) rand()/32767.; if (stepy > .5) stepy = 2;

else stepy = - 2 ; /* Move the Circle */ centerx = centerx + stepx; centery = centery + stepy; /* Reset Position */ if (centerx > = 512.) centerx = 250.; if (centery > = 512.) centery = 250.; if (centerx < = 0.) centerx = 250.; if (centery < = 0.) centery = 250.;

botx = max( 1, centerx - radius); topx = min(512, centerx + radius); boty = max( 1, centery - radius); topy = min(512, centery + radius); /* Fin in Circles --*/

for (i = botx; i < = topx; i++) { for (j = boty; j < = topy; j++) {

xsq = SQR ((float) i - centerx); }

/* Find Maximum Intensity and Scale -maxpix = -10000;

for(i = 0; i<512;i++){ for(j = 0;j<512;j++){

if (screen [i][j] > maxpix) maxpix = screen [i][j];

scale = 100./(float) maxpix; printf ("%d\n", maxpix); for(i = 0; i<512;i++){

for(j = 0; j<5l2;j++){ screen [i][j] = screen [i][j]*scale; }

/* Dump an Image to Disk */ /* Each Pixel is Represented as a Character-*/ /*Here, the output file happens to repeat each /•intensity value 4 times for later graphics

routines, but the user may create any format at this point which is useful.

*/ printf ("before image conversion\n"); /•Convert from integer to char*/

k = 0; for(i = 0;i<5l2;i+-l-){

for(j =0;j<512;j++){ for (m = 0; m < = 3; m++){

PixelData[k] = (char) screen [i][j]; k = k + 1;

} }

} printf ("after image converstion\n"); /* Open Output File and Write */ strcpy (filename, "fractal"); printf ("opening file\n"); fd = open (filename, 0_WRONLY | 0__CREAT,

0666); if (fd == -1) die ("can't open output file"); printf ("%d", width); printf ("%d", height);

stat = write (fd, &width, sizeof (width)); if (stat != sizeof (width)) die ("bad write: width"); stat = write (fd, &height, sizeof (height)); if (stat != sizeof (height)) die ("bad write: height"); stat = write (fd, PixelData, width*height*sizeof

(unsigned long)); fprintf (stderr, "%s: Finished writing %s (%d x %d)/n"

ProgramName, filename, width, height); close (fd);

}/*end of main*/

die (mess) char *mess; {

fprintf (stderr, "%s error: %s\nexiting\n", ProgramName, mess);

exit(l);

Page 46: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

A vacation on Mars 43

Table 2. Computation time (seconds) for various coriiputing machines.

AIX 370 on IBM 3090 Stellar GSIOOO with vector optimization Silicon Graphics IRIS 4D/120GTX,

optimization 3 Silicon Graphics IRIS 4D/120GTX,

optimization 0 SUN4/280 SUN4/110 Diskless Stellar GSIOOO, optimization 0 AT&T 6386e with Weitak 1167

coprocessor IBM 4381 AT&T 6386e without Weitak 1167

coprocessor

CPU

(2, (5,

(8,

(13, (13, (17, (29,

(31, (62,

(122,

Elapsed

11) 7)

13)

18) 29) 28) 32)

43) 105)

131).

Table 2 lists approximate computer times (CPU time, elapsed time), in seconds. Some of the systems, such as AIX 370, had multiple users which affects the elapsed time number.

in this paper are not intended to create realistic models of earthly terrain, which have been rendered so skill­fully in the past[l], but to teach the reader about a simple means for generating artistically interesting panoramas. It would be scientifically interesting to identify the computational efficiently of this technique relative to others, but this is beyond the scope of this article.

The mountains were generated by viewing the ac­cumulated intensity profile from an angle specified by the user. This graphical process is described in the next section. For each scene, approximately 35,000 circular disks were used. (As an interesting aside, it was rela­tively easy to detect certain bad random number gen­erators by observing the mountain shapes.) Atmo-

Fig. 2. A snapshot taken somewhere between the polar regions (Fig. I) and the warmer regions (Fig. 3).

spheric effects were generated by using a Gaussian ran­dom distribution of circular disks. To create this distribution, simply sum about 10 random numbers and divide the sum by 10. Do this twice to obtain an Xand y position for a circle of height 1 unit. As with the random-walk methods for the mountains, sum the accumulated intensities of the circles, but instead of viewing the profile from the side, view it from above. By coloring the intensity distribution with interesting color lookup tables, a variety of artistic atmospheric effects can be achieved. Ogden[9] mentions the use of circle summation for simulating natural looking clouds.

Fig. 1. Like Mars, this imaginary planet is a scarred landscape, with beautiful white winter polar regions. The sky is produced

using a Gaussian distribution of circular disks.

Fig. 3. Terrain with deformed Gaussian sky. The mountains' rust color is achieved by shining two reddish lights upon the

surface.

Page 47: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

44 CLIFFORD A. PICKOVER

Fig. 4. Terrain with red, hazy atmosphere.

It is interesting to compare the performance of this numerically intensive graphics computation across various computing machines. The C program in Table 1 may be representative of many realistic texture gen­erators which are based on statistical processes (for example, see [15]). Such programs would have both numerically intensive computation and image output. Table 2 is a list of approximate computer times for various computing machines tested. One thousand circles were used for this test. Note that the C-program does no graphic rendering, but simply creates a 3-D Brownian profile, which can subsequently be rendered.

3. GRAPHICS COMPUTATION

Interestingly, only a single graphic primitive was used for the foreground terrain in each figure, namely a "polytriangle" {i.e., n shaded triangular facets at spec­ified 3-D coordinates). The polytriangle is one of sev­eral 3-D primitives in the extended X-windows and PHIGS+ standard provided by the Stellar GSIOOO graphics supercomputer, f PHIGS+, itself, is an exten­sion to the PHIGSt graphics standard (ISO 9592), and it addresses the lighting and shading of three-di­mensional data[16]. The position of each of the tri­angular facets is determined by the height of the circular

t Stellar and GSIOOO are trademarks of Stardent Computer Inc., 521 Virginia Road, Concord, MA. The Stellar machine contains four high-speed floating'-point engines configured to work separately or in tandem. The rendering processor per­forms special computations such as per-pixel arithmetic for hidden-surface elimination, depth-cueing, and shading. The floating point performance is 40 MFLOPS, single or double precision. The polygon rendering rate is 150K Gouraud shaded, Z-buffered triangles per second. Since this article was written, the terrain software also runs on an IBM RISC System/ 6000 using the GL graphics language.

X PHIGS (the Programmer's Hierarchical Interactive Graphics System) goes beyond the older CORE and GKS standards to provide 3-D primitives such as polyline and fill area, as well as hierarchical data structures.

Fig. 5. View of a nearby planet. To produce the planet, a white distribution of circular disks is mapped to the surface

of a sphere, and an orange-red color lookup table is used.

disk profile, and the facets are Gouraud shaded to pro­duce the final, smooth shaded structure.

Lighting of the shapes in the figures was applied on a primitive by primitive basis; that is, no interactions between objects such as shadows or reflections were defined. The reflectance calculation is conceptually applied at points on the facet being lit and shaded, and produces color at these points. Input to the reflectance calculation includes the position on the primitive at which the reflectance equation is being applied, the reflectance normal, diffuse color at that position, the set of light source representations, and the eye point (see, for example, [17]). For the figures, two lights were used. Light colors and directions are specified in

Fig. 6. Terrain with texture-mapped water and deformed Gaussian sky.

Page 48: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

A vacation on Mars 45

a convenient input file, and the terrain can be mag­nified, rotated, and translated in real-time. The reso­lution of the triangular mesh which makes up the ter­rain can be changed interactively. Background atmo­spheric effects were added by merging the terrain image with a background image using IBM's software package lAX (see SB 11-8415, "The IBM Image Access executive—Program Description and Operations Manual"). If desired, specular reflections can be used to produce highlights on shiny surfaces. As is tradi­tional, the intensity of specular reflections, unlike dif­fuse reflections, is highly dependant on the viewing angle of the observer. The specular exponent [17] used to control the shininess was about 10.

4. GRAPHICS GALLERY

Perhaps an angel of the Lord surveyed an endless sea of chaos, then troubled it gently with his finger. In this tiny and tem­porary swirl of equations, our cosmos took shape.

Martin Gardner

Like Mars, this imaginary planet is a scarred land­scape, with beautiful white winter polar regions (Fig. 1). The pigment that gives Mars its rust-red hue is actually rust or iron oxide. The rust color in Fig. 2 was achieved by shining two reddish lights with (red, green, blue) mixture of about (1, .1, .1) and (1, .2, .2). On a scale from 0 to 1, the ambient, diffuse, and specular lights' intensities were about 0.2, 0.7, and 0.5, respec­tively. The Gaussian skys in Figs. 1-4 are identical except for different color lookup tables and stretching deformations. In Fig. 5, a white distribution of circular discs is mapped to the surface of a sphere, and an or­ange-red color lookup table is used. Figure 6 shows the same sky as in Figs. 3 and 4 using a different color look-up-table.

5. SUMMARY

It is indeed fascinating that complicated and artistic mountainscapes can be fully computed and rendered in under 2 minutes using the new class of graphics supercomputers which have become readily available in 1989. This new breed of computer can typically plot much more than 50,000 shaded triangular facets in a second. (For a review of such kinds of computers, see [19]). This speed may make such hardware and soft­ware systems of interest to both artists and computer graphics scientists. A variety of artistic effects can be achieved by adjusting the circle radius, using a changing circle radius, and using a different number of circles. Even if sophisticated graphics computers are unavail­able, the resulting Brownian intensity profiles produced

by the C code can be used to create a variety of graph­ically interesting textures [ 18 ] . A report such as this can only be viewed as introductory; however, it is hoped that the techniques, equations, and systems will provide useful tools and stimulate future studies in the graphic characterization of morphologically rich landscapes produced by the simplest of generating formulas.

REFERENCES 1. B. B. Mandelbrot, The Fractal Geometry of Nature, Free­

man, San Francisco (1982). 2. B. Mandelbrot, Stochastic models for the earth's relief,

the shape and the fractal dimension of coastlines, and the number-area rule for islands. Proc. Natl. Acad. Sci. 72, 3825-3828(1975).

3. R. Voss, Fractals in nature: from characterization to sim­ulation. In The Science of Fractal Images, H. Peitgen, and D. Saupe (Eds.). Springer-Verlag, New York (1988).

4. R. Voss, Random fractal forgeries. In Fundamental Al­gorithms in Computer Graphics, R. Earnshaw (Ed.), Springer-Verlag, Berlin, 30-45 (1985).

5. K. Musgrave, The synthesis and rendering of eroded frac­tal terrains. Computer Graphics (ACM-SIGGRAPH) 23(3), 41-50 (July 1989).

6. A. Foamier, D. Fussel, and L. Carpenter, Computer ren­dering of stochastic models. Commun. ACM 25, 371-378(1982).

7. J. Lewis, Generalized stochastic subdivision. ACM Trans. Graph. 6(3), 167-190 (July 1987).

8. D. Saupe, Algorithms for random fractals. In The Science of Fractal Images, H. Peitgen, and D. Saupe (Eds.). Springer-Verlag, New York, 71-113 (1988).

9. J. Ogden, E. Adelson, J. Bergen, and P. Burt, Pyramid-based computer graphics. RCA Engineer 30(5), 4-15 (Sept./Oct. 1985). (Describes the synthesis of clouds, galaxies, waves, and woodgrains.)

10. C. Yessios, Computer drafting of stones, wood, plant and ground materials. SIGGRAPHAugust '79 Proc, Chicago 13(2), 190(1979).

11. G. Miller, The definition and rendering of terrain maps. Computer Graphics 20(4), 39-48 (1986).

12. S. Loveyjoy, and B. Mandelbrot, Fractal properties of rain, and a fractal model. Tellus 37A, 209-232 (1985).

13. A. Pentland, Fractal-based description of natural scenes. IEEE Trans. Pattern Anal. Machine Intelligence PAMl-6(4), 661-674 (November 1984).

14. M. Panne, 3-D Fractals, Creative Computing, 78-81 (July 1985).

15. K. Perlin, Hypertexture. Computer Graphics {ACM-SIGGRAPH) 23(3), 253-262 (July 1989).

16. A. van Dam, PHIGS+ functional description, revision 3.0. Computer Graphics {ACM SIGGRAPH), 22(3) (entire volume) (July 1988).

17. J. Foley and A. van Dam, Fundamentals of Interactive Computer Graphics, Addison-Wesley, Massachusetts (1984).

18. C. Pickover, Computers and the Imagination, St. Martin's Press, New York (1991); C. Pickover, Computers, Pattern, Chaos, and Beauty, St. Martin's Press, New York (1990).

19. See for example any recent issue of Computer Graphics World, One Technology Park Drive, POB 987, Westford MA 01886.

Page 49: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved

Part II. Attractors

In this section we have several fascinating demonstrations of chaotic attractors and intricate dynamical systems, by leading researchers in the chaos field. I'm sure that the computer graphics experiments in this section were inspired by a number of researchers' work over the past few decades. The early days of modern dynamics span half a century, starting with French mathematician Jules Henri Poincare and Russian mathematician Alexander Mikhailovich Lyapunov in the early 1900s. The geometry of chaotic dynamical systems was firmly established in 1892 by Poincare in his research in celestial mechanics. George BirkhofF's 1932 paper on remarkable curves was one of the first papers in the mathematical literature to discuss chaotic attractors. After undergoing a relatively quiet period, the study of dynamics was revived between 1961 and 1971, partly as a result of the increasing use of computer graphics strategies of doing mathematics. In fact, digital simulations of the properties of periodic motions in nonlinear oscillations have become increasingly important, especially since chaos in real physical systems were clearly demonstrated in 1963 by MIT scientist Edward Lorenz, an atmospheric scientist who proposed a simple model for atmospheric convection that displayed unpredictable behavior. Douglas Hofstadter in his book Metamagical Themas gives a detailed and quite readable description of various problems in nonlinear iteration, bifurcation theory, and strange attractors. He also mentions some of the scientists and mathematicians who have studied, discovered, and popularized many of the important features inherent in phenomena exhibiting bifiircating behavior. (These scientists include: Ulam, Eckmann, Myrberg, Stein, Collet, Koch, Feigenbaum, May, Ruelle, Duffing, Van der Pol, Levinson, Cartwright and Littlewood, Lorenz, Stein, Ulam, Smale, Rossler, Ueda, Shaw, and Farmer - just to name a few.) The discovery of the recursive regularity of bifiircation maps, first made by Mitchell Feigenbaum using a little calculator, was one of the major recent advances in the chaos field. Readers may also be interested in a lively 1989 article by M. Hirsch titled "Chaos, Rigor, and Hype" which appeared in the Mathematical Intelligencer. Hirsch notes that many important chaotic systems were first identified and explored not by computer simulation but by mathematical proof, and he cites the work of Poincare, BirkhofF, Levinson, Smale, Anosov, Kolmogorov, Arnold, and Moser as examples.

Students and other readers fairly new to the chaos field may want to review some of the fiindamental chaos concepts to better appreciate the papers in this section. For example, you should have some familiarity with dynamical systems which provide a deep reservoir for striking images. Dynamical systems are models containing the rules describing the way some quantity undergoes a change through time. For example, the motion of planets about the sun can be modelled as a dynamical system in which the planets move according to Newton's laws. Generally, portraits of dynamical systems track the behavior of mathematical expressions called differential equations. Think of a differential equation as a machine that takes in values for all the variables and then generates the new values at some later time. Just as one can track the path of a jet by the smoke path it leaves behind, computer graphics provides a way to follow paths of particles whose motion is determined by simple differential equations. The practical side of dynamical systems is that they can sometimes be used to describe the behavior of real-world things such as planetary motion, fluid flow, and engine vibration.

A chaotic attractor is represented by an unpredictable trajectory where a minute difference

49

Page 50: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

50

in starting positions of two initially adjacent points leads to totally uncorrelated positions later in time or in the mathematical iteration. Predictable attractors represent the behavior to which a system settles down or is "attracted" (for example, a point or a looping closed cycle). An example of a fixed point attractor is a mass at the end of a spring, with friction. The mass eventually arrives at an equilibrium point and stops moving. {A fixed point is a point that is invariant under the mapping (i.e., Xt =Xt+\). An invariant curve is a generalization of a fixed point and is also invariant under the map or flow.)

A limit cycle can be exemplified by a metronome. The metronome will tick-tock back and forth - its motion always periodic and regular, in contrast to a strange attractor with its irregular, unpredictable behavior. Its behavior can still be graphed, but the graph is much more complicated. With "tame" attractors, initially close points stay together as they approach the attractor. With strange attractors, initially adjacent points eventually follow widely divergent trajectories. Like leaves in a turbulent stream, it is impossible to predict where the leaves will end up given their initial positions.

To best understand the Markus and Hess paper in this section, the reader should have some familiarity with the Lyapunov exponent A that quantifies the average stability of the oscillatory modes. This exponent is a good tool for diagnosing whether or not a system is chaotic. This can be computed with the aid of a computer for data that comes from numerical simulation or from a physical experiment. As an example, this exponent is fairly easy to compute for one dimensional maps jc„+i =/(x„). (A number of natural phenomena can be described by one-dimensional maps of this kind.) One-dimensional maps are characterized by a single Lyapunov exponent which is positive for chaos, zero for a marginally stable orbit, and negative for a periodic orbit:

A < 0, the orbit is stable,

A = 0, the orbit is neutrally stable,

A > 0, the orbit is locally unstable and chaotic.

Any system containing at least one positive Lyapunov exponent is defined to be chaotic, with the magnitude of the exponent reflecting the time scale on which the system's dynamics become unpredictable. As an example, consider the equation

Y - ^ '

[\+Xtf'

where ^ is a constant, and A is the usual bifurcation parameter. This equation has been used to fit a considerable amount of data on insect populations, and high-resolution bifurcation maps of this equation are presented in my book Computers, Pattern, Chaos, and Beauty. We can compute the exponent by

dx, A = lim — y^ In

N-.00 N ^-^ n = 1

n+\

AXn X =/(A, beta).

where dx:„+i/dx:„ = A[-JC/?(1 +xy^~^ +(1 +x)~^] in this special case. You will find that for certain values of A and ji the map is chaotic with a positive exponent, while for others the map is periodic.

For Further Reading

(1) Abraham, R., Shaw, C. (1985) Dynamics - The Geometry of Behavior, Part 3: Global Behavior. Aerial Press: California. (Actually, the entire book collection of Aerial Press, including the Visual Math Series, is an educational wonderland).

Page 51: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

51

(2) Abraham, R., Shaw, C. (1983) Dynamics - The Geometry of Behavior, Part 2: Chaotic Behavior. Aerial Press: California.

(3) Aronson, D., Chory, M., Hall, G. and McGehee, R. (1980) A discrete dynamical system with subtly wild behavior. In New Approaches to Nonlinear Problems in Dynamics, RJ. Holmes, ed. Society for Industry and Applied Mathematics.

(4) Berge, R, Pomeau, Y., Vidal, C. (1984) Order Within Chaos, Wiley: New York. (5) Campbell, D., Crutchfield, J., Farmer, D., Jen, E. (1985) Experimental mathematics: the

role of computation in nonlinear science. Communications of the ACM. 28: 374—389. (6) Crutchfield, J., Farmer, J., Packard, N. (1986) Chaos. Scientific American. 255: 46-57. (7) Chossat, P. and Golubitsky, M. (1988) Symmetry-increasing bifurcations of chaotic

attractors. Physica D. 32, 423^26. (8) R. Devaney (1989) An Introduction to Chaotic Dynamical Systems. Addison-Wesley. (9) Feigenbaum, M. (1979) The universal metric properties of nonlinear transformations.

Journal of Statistical Physics. 21: 669-706. (10) Feigenbaum, M. (1981) Universal behavior in nonlinear systems. Los Alamos Science. 1:

4-27. (11) Gleick, J. (1987) Chaos: Making a New Science. Viking: New York. (12) Grebogi, C , Ott, E., and Yorke, J. (1985) Chaos, strange attractors, and fractal basin

boundaries in nonlinear dynamics. Science 238: 632-637. (A great overview, with definitions of terms used in the chaos literature.)

(13) Grebogi, C , Ott, E., and Yorke, J. (1985) Attractors on an N-Torus: quasiperiodicity versus chaos, Physica 15D: 354-373. (Contains some gorgeous diagrams of dynamical systems).

(14) Hirsch, M. (1989) Chaos, rigor, and hype, Mathematical Intelligencer 11(3): 6-9. (Pages 8 and 9 include James Gleick's response to the article.)

(15) Moon, F. (1987) Chaotic Vibrations. John Wiley and Sons, New York. (Moon gives many practical examples of chaos in real physical systems.)

(16) Pickover, C. (1990) Computers, Pattern, Chaos and Beauty. St. Martin's Press: New York.

(17) Stewart, I. (1989) Does God Play Dice? (The Mathematics of Chaos). Basil Blackwell: New York.

(18) "Symmetries and Asymmetries" (1985) Mosaic Volume 16, Number 1, January/February. (An entire issue on the subject of fractals, symmetry and chaos. Mosaic is published six times a year as a source of information for scientific and educational communities served by the National Science Foundation, Washington DC 20550).

(19) Shaw, A. (1984) The Dripping Faucet as a Model Chaotic System. Aerial Press: California.

Page 52: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 53

Chaos and Graphics

AUTOMATIC GENERATION OF STRANGE ATTRACTORS

J. C. SPROTT Department of Physics, University of Wisconsin, Madison, WI 53706

Abstract—A pair of coupled quadratic difference equations with randomly chosen coefficients is repeatedly iterated by computer to produce a two-dimensional map. The map is tested for stability and sensitivity to initial conditions. The process is repeated until a chaotic solution is found. In this way a computer can generate a large collection of strange attractors that are all different, and most of which have considerable aesthetic appeal. A simple computer program and examples of its output are provided. Many of the attractors have been systematically evaluated for visual appeal, and a correlation is found with the Lyapunov exponent and correlation dimension.

1. INTRODUCTION Art and music derive much of their aesthetic appeal from a juxtaposition of order and unpredictability. In recent years it has come to be widely understood that simple mathematical equations can have solutions that, over the long term, are for all practical purposes un­predictable. And yet the simplicity of the equations ensures that the unpredictability is accompanied by a degree of determinism and order. Such equations are said to exhibit chaos[l], and their solutions usually form a strange attractor[2]. A strange attractor is an example of a fractal [ 3 ], a geometrical object of non-integer dimension and structure on all size scales, al­though the structure in general is not self-similar. Strange attractors are thus powerful generators of new visual new art forms[4].

A single equation with different coefficients can pro­duce an almost endless variety of strange attractors, most of which have considerable beauty. Even simple personal computers can easily generate these patterns. The difficulty is that no one knows how to predict the conditions under which chaos will result, and thus the same standard examples are generally exhibited.

Whereas most previous work in the production of strange attractors starts with a system known to be chaotic, this paper proposes a way for a computer to search a large class of potentially chaotic equations for visually interesting solutions. The visual appeal of the resulting patterns is shown to correlate with mathe­matical quantities that characterize the attractors, sug­gesting that it might be possible to refine further the automatic selection of patterns with strong visual ap­peal.

2. TWO-DIMENSIONAL QUADRATIC MAPS For a system to exhibit chaos, the governing equa­

tions must be nonlinear. A quadratic equation is per­haps the simplest such example. However, a single equation in a single variable has solutions that lie along segments of a curve and thus tend to be rather unin­teresting. The graph of a quadratic equation is a pa­rabola.

With a pair of equations involving two variables x and y, the solutions are more interesting and are well suited for display on a computer monitor or sheet of

Reprinted from Comput. & Graphics Vol. 17, No. 3, pag. 325-232, 1993

paper. The simplest such example is the two-dimen­sional quadratic map given in its most general form by

Xn+\ = fli + a2Xn + a^xl + a^Xnyn + asyn + a^yl

y„+i = ay ~\- UgXn + agxl + awXnyn + «iiy« + anyl

The character of the solution is determined by the val­ues of the twelve coefficients fli through an and the initial values XQ and yo.

With some initial value of XQ and y© at « = 0, suc­cessive values of X and y are determined by repeatedly iterating the above equations. The iterates are plotted as points on a two-dimensional surface. After a number of iterations, the solution will do one of four things: (a) It will converge to a single fixed point; (b) it will take on a succession of values that eventually repeat, producing a limit cycle; (c) it will be unstable and di­verge to infinity; (d) it will exhibit chaos and gradually fill in some often complicated but bounded region of the x-y plane.

The visually interesting solutions are the chaotic ones. Most of these solutions are strange attractors in that a range of starting values of x and y, within the basin of attraction, yield the same eventual solution. The first few iterates should be discarded, since they almost certainly lie off the attractor. Occasionally so­lutions are chaotic and visually appealing but are not attractors since each pair of initial values produces a different shape. The boundary of the basin of attraction of a strange attractor may itself be a fractal.

3. SENSITIVITY TO INITIAL CONDITIONS To search automatically for chaotic solutions, it is

necessary to have a criterion for detecting chaos. One such criterion is the sensitivity to initial conditions. Imagine iterating the two-dimensional quadratic map described above with two initial conditions that differ by a small amount. If successive iterates approach a fixed point or limit cycle, the difference between the two solutions will on average grow smaller with each iteration. If the solution is unstable or chaotic, the dif­ference will tend to grow larger with each iteration. Unstable solutions can be eliminated by discarding

Page 53: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

EAMTMNQQXUYGA F = 1.27 L = 0.10 ECVQKGHQTPHTE

^ j ^

F = 1 . 7 9 L = 0 . 1 4

w^^^^cr^"5L-^i-^'' ? ]':

^ ^ 9 ^ ^ ^ ^ - -"'-•^liJ'

EFIRCDERRPVLD

r>^ 1 Irs

F = 1 . 37 L - 0.05 EGIIETPIQRRUL

(b)

(c)

EGLXOESFTTPSV F - 1.77 L - 0.12 EGXQSNSKEECTX

^^(E ""-. % {IB

- ^ i ^

F -

^.-y

1.42 L - 0.10

r fa

(f)

EILIBVPKJWGRR

(g) (h)

Fig. 1. Examples of strange attractors produced by two-dimensional iterated quadratic maps.

54

Page 54: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

ELUFBBFISGJYS

/jr*

• ^

-t// // mi

'^^^7M ^ \ i

F = 1.59 L - 0.18 EMCRBIPOPHTBN F = 1.39 L - 0

(i) (J) EMDVAIDOYHYEA

EVBWNBDELYHUL

/^^ fjh^-~~

i^^^Sk W-iP^'feppn^fe ^>l! ZJlr^

-~

'

| H ^ 7

> #

*^^ :f"QP

f

F =

P ^ ^

^ijl

1 . 4 7 L = 0 . 1 3

(o)

EODGQCNXODNYA

. / ^ V " fll?

/ J&^^^

/ - / '-^^^S^^SBHIB^^

^^m JH^;-^' mK^/"'^ jaig=^ ' **^

¥/

WAj

;S

7/7 /1 Pw|.

^KJ ' . ^ •

F -

\

1 , 3 1 L - 0 . 0 7

(I)

EUWACXDQIGKHF

(P)

F = 1.69 L = O.IS

Fig. 1. (cont'd.)

55

Page 55: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

56 J. C. SPROTT

cases in which xory grow beyond some arbitrary large value such as 10^.

The difference between the two solutions initially grows on average at an exponential rate for a chaotic system. The rate of divergence is characterized by the Lyapunov exponent [ 5 ], which can be thought of as the power of 2 by which the separation increases on average for each iteration. Thus, if the separation dou­bles with each iteration, the Lyapunov exponent is 1 bit per iteration. The Lyapunov exponent can be thought of as the rate at which information about the initial condition is lost, or, equivalently, the rate at which the accuracy of a prediction declines as one pro­jects farther into the future.

A two-dimensional map actually has two Lyapunov exponents, since a cluster of nearby initial points may expand in one direction and contract in another, stretching out like a cigar. The more positive one is the one that signifies chaos, and it is the one that dom­inates after a few iterations using the above proce­dure [6]. It has been conjectured [ 7 ] that the fractal dimension F is related to the two Lyapunov exponents through the relation

F= 1 -LJL2

where Li is the more positive of the two exponents. A further difficulty is that the two solutions even­

tually get far apart, on the order of the size of the at-tractor, and the growth saturates. This problem can be remedied if after each iteration the points are moved back to their original separation along the direction of the separation. The Lyapunov exponent is then deter­mined by the average of the distance they must be moved for each iteration in order to maintain a con­stant separation. If the two cases are separated by a distance d„ after the «th iteration and the separation after the next iteration isd„+i, the Lyapunov exponent is determined from

L= i:\og2idn^i/d„)/N

where the sum is taken over all iterations from n = 0 to n = N — 1. After each iteration, the value of one of the iterates is changed to make d„+i = d„. For the cases here, d„ is taken equal to 10"^.

Calculation of the Lyapunov exponent is only one possible way to identify chaotic attractors. One could also visually inspect all the stable solutions or look for cases with non-integer fractal dimension. Visual in­spection is inefficient since only about 7% of the stable solutions of the two-dimensional quadratic maps are chaotic. Calculation of the fractal dimension is rela­tively time-consuming, typically requiring several thousand iterations. The Lyapunov dimension calcu­lation is very fast and reliable. The exponential growth of the separation ensures that for most cases only a few iterations are required to determine the sign of the largest exponent.

4. COMPUTER SEARCH PROCEDURE

The procedure for implementing a computer search for strange attractors is straightforward. Choose the 12 coefficients ai through an randomly over some inter­val, choose initial conditions XQ and yo, iterate the equations for the map while calculating the Lyapunov exponent and checking for divergence, and keep only those solutions that are bounded and have a positive Lyapunov exponent.

A computer program"* that repetitively performs these operations is listed in the Appendix. It is written in a primitive version of BASIC so as to be widely accessible and easily understood. The program should run without modification under Microsoft BASICA, GW-BASIC, QBASIC, QuickBASIC, or Visual BASIC for DOS, Borland International Turbo BASIC, and Spectra Publishing PowerBASIC on IBM PC or com­patibles. It assumes VGA (640 X 480 pixel) graphics. If the hardware or BASIC compiler do not support this graphics mode, change the SCREEN 12 command line 130 to a lower number (i.e., SCREEN 2 for CGA mode). A compiled BASIC and a computer with a math coprocessor are strongly recommended.

The coefficients are chosen in increments of 0.1 over the range —1.2 to 1.2 (25 possible values) in line 320. Smaller coefficients result in missing many chaotic so­lutions, and larger coefficients produce mostly unstable solutions. The increment was chosen so that each at-tractor is visibly different and coefficients can be coded into letters of the alphabet A through YiA = —\.2,B = —1.1, etc.) for easy reference and replication. Thus each attractor is uniquely identified by a 12-letter name. The number of possible cases is thus 25 ^ or about 6 X 10^^. Of these, approximately 1.6% are chaotic or about 10 ' cases [ 8 ]. Viewing them all at a rate of one per second would require over 30 million years! Thus it is very unlikely that any patterns produced by the program will ever have been seen before, and like snowflakes, nearly all of them are different.

Initial conditions are set arbitrarily to x = y = 0.05 in line 310. Other small initial values produce the same result for most cases as expected for an attractor. The Lyapunov exponent is calculated using an initial con­dition in which x is increased by 10"^ (line 310). The program performs 100 iterations before considering the Lyapunov exponent (line 640). After 100 itera­tions, the program begins keeping track of the mini­mum and maximum values ofx and y (lines 520-550) so that after 1000 iterations the screen can be cleared and resized to allow a 10% border around the attractor (line 560). If 11,000 iterations are reached with a pos­itive Lyapunov exponent and a bounded solution, the result is assumed to be a strange attractor (line 620). The search immediately resumes after each attractor

* An IBM DOS disk containing the BASIC source code in the Appendix, an executable version of the code, and a more versatile menu-driven strange attractor program with 3-D glasses are available for $30 postpaid ft-om the author. Specify 3.5 or 5.25-inch disk.

Page 56: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic generation of strange attractors 57

is confirmed and continues until a key is pressed (line 650).

The search procedure is surprisingly fast. On a 33 MHz 80486 computer running QuickBASIC 4.5, the program finds about 1200 strange attractors per hour. The listing in the Appendix only displays the attractors on the screen. A more versatile program would call a subroutine from line 620 to print the attractors, perhaps after user confirmation or evaluation, or would save the coded coefficients in a disk file for later analysis.

5. SAMPLE STRANGE ATTRACTORS

Figure 1 shows samples of the shapes that arise from the iteration of such two-dimensional quadratic maps. These cases are all strange attractors and were selected for their beauty and diversity from a much larger col­lection. However, they are by no means atypical, and there are many others that would have served equally well. It is remarkable that such a diversity of shapes comes from the same simple set of equations with only different numerical values of the coefficients.

The cases shown were produced on a laser printer with 300 dots per inch resolution on an 8.5 X 11-inch page after about 500,000 iterations. Of course, the pro­gram needs modification to output the plots to a printer at high resolution. However, satisfactory results can be obtained by any of the various utilities that allow one to print a screen image.

Also shown on each figure is the code name preceded by the letter E to denote a two-dimensional quadratic map, the Lyapunov exponent L (in bits per iteration) and the fractal dimension F. F is actually the corre­lation dimension[9] and is somewhat ill-defined be­cause the dimension of a strange attractor varies some­what with scale. The dimension is taken here at a scale of about 1% of the largest diameter of the attractor.

Normally, correlation dimension calculations are very slow because they involve determining the spatial separation between every pair of points that constitute the attractor. A much faster technique that entails only a slight loss in accuracy was used here. The method requires that the coordinates of the last N iterates be retained. A value of A = 500 is generally sufficient. With each new iteration, one of the previous A/ points is chosen randomly, and its separation from the new point is calculated. A count is kept of those cases for which the separation is less than each of two values, which differ by a factor of 10, and whose geometric mean is the size scale for which the dimension is to be calculated. If the respective counts are Ni (for the smaller value) anxi N2 (for the larger value), the cor­relation dimension is given by

i = logio(iV2/iVi)

With little computational penalty, the value of F can be updated whenever N\ or A2 is incremented. The accuracy of the dimension estimate is of

6. AESTHETIC EVALUATION

A collection of about 7500 such attractors was sys­tematically examined by the author and seven vol­unteers, including two graduate art students, a former art history major, three physics graduate students, and a former mathematics major. All evaluators were born and raised in the United States. The evaluations were done by choosing attractors randomly from a collection of about 18,000 and displaying them sequentially on the computer screen without any indication of the quantities that characterize them. The volunteers were asked to evaluate each case on a scale of one to five according to its aesthetic appeal. It only took a few seconds for each evaluation.

At the end of the session a graph similar to Fig. 2 was produced in which the average rating is displayed using a gray scale on a plot in which the largest Lya­punov exponent (L) and correlation dimension (F) are the axes. The darkness of each box increases with the average rating of those attractors whose values of L and F fall within the box. Figure 2 shows a summary of all the evaluations, although the cases examined by the various individuals show a similar trend. In par­ticular, all evaluators tended to prefer attractors with a dimension between about 1.1 and 1.5 and a Lya­punov exponent between zero and about 0.3. Some of the most interesting cases have Lyapunov exponents below about 0.1.

The dimension preference is perhaps not surprising since many natural objects have dimensions in this range. The Lyapunov exponent preference is harder to understand, but it suggests that strongly chaotic sys­tems are too unstructured to be appealing. For the 443 cases that were rated five (best) by the evaluators, the average correlation dimension was F = 1.30 ± 0.20, and the average Lyapunov exponent was L = 0.21 ±0.13 bits per iteration, where the errors represent plus or minus one standard deviation. About 28% of the cases evaluated fall within the error bars.

Fig. 2. Results of evaluating 7500 strange attractors, showing that the most visually appealing cases are those with small Lyapunov exponents (L) and with correlation dimensions

(F) somewhat greater than one.

Page 57: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

58 J. C. SPROTT

I€M|R¥miS»)Qia§l»UIM«IU^»IRy(lll

luuuuzirraivvEraDLBNETxsyyxcxji P = 1.99 L = 8.28

Fig. 3. Examples of strange attractors produced by three-dimensional iterated quadratic maps in which the color is determined by one of the variables.

7. SUGGESTIONS FOR FURTHER WORK

The method described above can be easily extended in a number of ways [ 10]. There is nothing special about two-dimensional quadratic maps, other than per­haps simplicity and consequent computational speed. There's an infinity of other nonlinear maps and flows. For example, Pickover has produced nice two-dimensional sculptures using trigonometric maps [11]. It is straightforward to add cubic and higher order terms to the equations. More complicated nonlinearities do not significantly enhance the occurrence of chaotic so­lutions, but they do somewhat increase the variety of

patterns. The number of coefficients increases rapidly with the order of the polynomial, and the variety of cases becomes even larger.

Having found a visually appealing attractor, one can make small variations of the coefficients to optimize even further its appearance. The attractors can be an­imated by producing a succession of frames, each with a slightly different value of one or more of the param­eters.

Adding a third dimension (x, y, and z) increases the number of coefficients to 30 for quadratic maps. It also raises interesting possibilities for new display

Page 58: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic generation of strange attractors 59

modes. The simplest case is to plot x and y, but to ignore z, which is equivalent to viewing the projection (or shadow) of the attractor on the x-y plane. Alter­nately, the attractor can be projected onto the x-z or y-z plane or rotated through an arbitrary angle. A gray scale can be used to represent the number of iterates that fall within a given rectangle on the screen [12].

Another possibility is to code the third dimension in color. Examples of three-dimensional quadratic maps using 16 colors are shown in Fig. 3. These figures were produced directly from VGA screen images using a color ink-jet printer. Some computer languages allow one to cycle through a variety of color palettes to find the most pleasing combination of colors or to produce a kind of animated color display. Modern versions of BASIC have such a PALETTE command.

It is also possible to produce an anaglyph[13] in which each x-y value is plotted twice, once in red and once in cyan, displaced horizontally by a distance pro­portional to z so as to produce a three-dimensional monochrome image when viewed through red/blue glasses. Color three-dimensional images can be pro­duced by plotting the two colored views side-by-side and either viewing them cross-eyed or through an in­expensive prism stereoscope.^

These techniques can also be applied to two- and even one-dimensional maps by using a previous value of one of the variables as the third variable. The at­tractors can be rotated to provide a view from the most pleasing angle or animated with successively rotated images.

Chaotic maps can also be used to produce a crude kind of computer music. For a two-dimensional map, X might be used to control the pitch and y the duration of each note. The result is a not-displeasing though alien-sounding form of music that might appeal to those with exotic musical tastes.

The method described above can also be applied to systems of nonlinear ordinary differential equations whose solutions are continuous flows rather than dis­crete maps. In such a case, chaos requires at least three equations and three variables. Differential equations can be solved approximately on a digital computer by reducing them to appropriate finite difference equa-tions[14]. Long computing times are required for high accuracy, which fortunately is not essential in this ap­plication.

Plots of the basin of attraction for strange attractors are sometimes very beautiful, especially when multiple nearby attractors compete and produce a fractal boundary. The popular Mandelbrot and Julia sets are basins of attraction. It is traditional to plot in different colors the number of iterations required for each un­stable initial condition to reach some large value. Such plots require a large amount of computer time, how­ever.

^ Stereoscopes and other 3-D supplies are available from Reel 3-D, P.O. Box 2368, Culver City, CA 90231.

Much more could be done with correlating the aes­thetic appeal of the attractors with the various nu­merical quantities that characterize them. The Lya-punov exponent and correlation dimension are only two such quantities; there are infinitely many oth-ers[15]. One could determine if there are discernible differences between the preferences of scientists and artists. Preliminary indications suggest that complexity might appeal more to artists than to scientists, who tend to see beauty in simplicity. There may be dis­cernible cultural differences. One could determine whether the results are the same for more complicated systems of equations and for different methods of dis­playing the results, such as color versus monochrome.

If such correlations exist, then it should be possible to program the computer to be even more selective and to become a critic of its own art [16]. Like the infinite number of monkeys with an infinite number of typewriters who will eventually reproduce all the works of Shakespeare, so too the computer starting with random numbers might evolve into something of an artist with unparalleled stamina and productivity.

Acknowledgments—Mary Lou Herman, Mark Johnston, Kathy Ley, Earle Scime, Matt Stoneking, Christopher Watts, and Debora Wood assisted with the evaluations. Cliff Pickover made a number of useful suggestions. I am indebted to George Rowlands for introducing me to chaos and fractals and to Edward Pope for assuring me that these patterns would be interesting to those whose artistic tastes are more refined than my own.

REFERENCES 1. J. Gleick, Chaos: Making a New Science, Viking, New

York (1987). 2. A. K. Dewdney, Probing the strange attractors of chaos,

Sci.Am. 235,90-93(1976). 3. B. B. Mandelbrot, The Fractal Geometry of Nature,

W. H. Freeman, New York (1982). 4. H. O. Peitgen and P. H. Richter, The Beauty of Fractals:

Images of Complex Dynamical Systems, Springer-Verlag, New York (1986).

5. H. G. Schuster, Deterministic Chaos, Springer-Verlag, New York (1984).

6. A. Wolf, J. B. Swift, H. L. Swinney, and J. A. Vastano, Determining Lyapunov exponents from a time series, Physica 16D, 285-317 (1985).

7. J. Kaplan and J. A. Yorke, Functional differential equa­tions and the approximation of fixed points. Springer Lecture Notes in Mathematics 730, 228 (1978).

8. J. C. Sprott, How common is chaos? Phys. Lett. A 173, 21(1993).

9. P. Grassberger and I. Procaccia, Characterization of strange attractors, Phys. Rev. Lett. 50, 346-349 (1983).

10. J. C. Sprott, Strange Attractors: Creating Patterns in Chaos, M & T Books, San Mateo, CA (1993).

W. C. Pickover, Million-point sculptures, Comp. Graph. Forum 10, 333 (1991).

12. C. Pickover, A note on rendering 3-D strange-attractors, Comp. & Graph. 12, 263 (1988).

13. J. C. Sprott, Simple programs produce 3D images, Comp. Phys. 6, 132(1992).

14. H. Gould and J. Tobochnik, An Introduction to Computer Simulation Methods, Addison-Wesley, Reading, MA (1988).

15. J. D. Farmer, E. Ott, and J. A. Yorke, The dimension of chaotic attractors, Physica 7D, 153 (1983).

16. H. W. Franke, Computer Graphics, Computer Art, Springer-Veriag, New York (1985).

Page 59: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

60 J. C. SPROTT

APPENDIX

110 DEFDBL A-Z: DIM A (12) 120 RANDOMIZE TIMER 130 SCREEN 12 140 GOSUB 300 150 GOSUB 400 160 GOSUB 500 170 GOSUB 600 180 ON T% GOTO 130, 140, 150 190 END

300 REM Set parameters 310 X = .05: Y = .05: XE = X + .000001: YE = Y 320 For 1% = 1 to 12: A(I%) = .1 * (INT(25 * RND) - 12): NEXT 1% 330 T% = 3: LSUM = 0: N = 0 340 XMIN = 1000000#: XMAX = -XMIN: YMIN = XMIN: YMAX 390 RETURN

'Reseed random number generator 'Assume VGA graphics 'Set parameters 'Iterate equations 'Display results 'Test results

XMAX

400 REM Iterate equations 410 XNEW = A(l) + X * (A(2) -f A(3) * X + A (4) * Y) + Y * (A(5) + A(6) * Y) 420 YNEW = A(7) + X * (A(8) + A(9) * X + A(10) * Y) + Y * (A(l 1) + A(12) * Y) 430 N= N + 1 490 RETURN

500 REM Display results 510 IF N < 100 or N > 1000 THEN GOTO 560 520 IF X < XMIN THEN XMIN = X 530 IF X > XMAX THEN XMAX = X 540 IF Y < YMIN THEN YMIN = Y 550 IF Y > YMAX THEN YMAX = Y 560 IF N = 1000 THEN GOSUB 800 570 IF X > XL AND X < XH AND Y > YL AND Y < YH AND N > 1000 THEN PSET (X, Y) 590 RETURN

600 REM Test results 610 GOSUB 700 620 IF N > 11000 THEN T% = 2 630 IF ABS (XNEW) + ABS (YNEW) > 1000000# THEN T% 640 IF N > 100 AND L < .005 THEN T% = 2 650 IF LEN(INKEY$) THEN T% = 0 660 X = XNEW: Y = YNEW 690 RETURN

'Calculate Lyapunov exponent 'Strange attractor found 'Unstable 'Limit cycle 'User key press

700 REM Calculate Lyapunov exponent 710 XSAVE = XNEW: YSAVE = YNEW: X = XE: Y = YE: N = N - 1 720 GOSUB 400 'Reiterate equations 730 DLX = XNEW - XSAVE: DLY = YNEW - YSAVE: DL2 = DLX * DLX + DLY • DLY 740 DF = 1000000000000# * DL2: RS - 1# / SQR (DF) 750 XE = XSAVE + RS * (XNEW - XSAVE) : YE = YSAVE + RS * (YNEW - YSAVE) 760 XNEW = XSAVE: YNEW - YSAVE 770 LSUM = LSUM + LOG(DF) : L = .721347 • LSUM / N 790 RETURN

800 REM Resize the screen (and discard the first thousand iterates) 810 DX = .1 • (XMAX - XMIN) : DY = .1 * (YMAX - YMIN) 820 XL = XMIN - DX: XH = XMAX + DX: YL = YMIN - DY: YH = 830 IF XH - XL < .000001 OR YH - YL < .000001 THEN GOTO 890 840 WINDOW (XL, YL) - (XH, YH) : CLS 850 LINE (XL, YL) - (XH, YH), , B 890 RETURN

YMAX + DY

Page 60: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 61

Chaos & Graphics

ATTRACTORS WITH DUELING SYMMETRY

CLIFFORD A. REITER

Department of Mathematics, Lafayette College, Easton, PA 18042, U.S.A. e-wa//:[email protected]

Abstract—Two functions of the plane having distinct symmetries are intertwined using a sinew function to create a function of three variables having different symmetries in different regions of space. The attractor resulting from the iteration of this function can be visualized using a nonlinear semi-inverted projection to the plane. This projection makes the dueling symmetries of the attractor apparent. Schemes similar to genetic algorithms can be used to search parameter space for interesting examples of attractors with these dueling symmetries. © 1997 Elsevier Science Ltd

1. INTRODUCTION

Attractors arising frona the iteration of functions in the plane that are designed to have symmetry have been the subject of recent study [1]. These attractors can be forced to have n-fold rotational symmetry and reflections can be forced or avoided. Examples of attractors with forced symmetry in three and higher dimensions have also been constructed [2, 3]. This note describes the creation of attractors in three space that are forced to have different symmetries in different regions. These attractors are then projected to the plane using a semi-inverted central projection that results in placing the attractor inside an annulus where one edge of the attractor has one symmetry type and the other edge has a different symmetry type.

When an object is preserved under an nth of a turn rotation about its center it is said to have cyclic symmetry of order n and its group of symmetries is denoted by C„. If it also has the symmetry of a reflection across a line through the center then it has dihedral symmetry and its symmetry group is denoted D„. Numerous examples of these symmetries occur in nature: a starfish has Ds symmetry, and a snowflake has De symmetry. Discussion of the symmetry of natural objects can be found in many places; for further examples see [4-6]. Human designs with delightful symmetries abound and even pervade modern logo's and hubcaps [7]. Examples of these artifacts with the kind of duehng symmetry described here are less common but certainly appear. The New York City subway token has an inner D^ symmetry and an outer circular symmetry that is infinitely smooth. Hubcaps are also a rich source of examples of this dueling symmetry. Figure 1 shows a hubcap with Cg outer symmetry and D^ inner symmetry. A walk through a parking lot will yield vast combina­tions of inner and outer symmetries among hubcaps.

The next section deals with the functions used to create attractors with symmetry in the plane. We then turn to a discussion of our construction of attractors with dueling symmetry.

2. SYMMETRIC ATTRACTORS

A function f is said to be equivariant with respect to a group of symmetries H if for all (T£H, f(o-(x)) = (T(f(x)). For example, if H— C„, then G^H means that a is a rotation and f is d-equivariant implies that the iterates of the rotation of a point are the same as the rotation of the iterates of the point. This means that the attractor associated with f tends to have the desired symmetries though it may be that the attractor has only the symmetry given by an admissible subgroup of symmetries [8, 9] or it may have the desired symmetry only in a trivial manner. Thus, even after identifying the appropriate equiv­ariant functions one still needs to do some work to find interesting examples.

The theory of which functions are equivariant with respect to C„ and D„ is well developed. For example, from [1] we know that the polynomial functions that are equivariant with respect to D„ are of the form f(z) = Vx(u{z), v[z))z -h ViHz), v(z))z"-i where u{z) — z'z, v(z) = Re{z^), and pi(w,v) and P2(w,v) are arbitrary 2-variable real polynomials. In that con­struction f is a polynomial in the two variables jc and y which are the real and imaginary parts of the complex number z = x-^iy. The general form for the polynomial function pi is Pi(w, v) = J2ii=o...N^'j^'^ and hence the polynomial can be identified with its matrix of coefficients («y). It is also known that the polynomials equivariant with respect to C„ have the same form but the matrix coefficients are allowed to be complex. The traditional function type to use for creating examples of attractors with symmetry in the plane are f (z) = (>l -h azz -h PReiz") -f- wi)z + yT'K That is, pi (M, V) = >l + CO/ + aw + Pv and p2(w, v) = y. In matrix notation, these are identified with the

special 2 by 2 and 1 by 1 matrices and

(y). As we will see, in our work with duehng attractors we often found it more useful work with 3 by 3 and 2 by 2 matrices of coefficients.

Reprinted from Comput. & Graphics Vol 21, No. 2, pag. 263-271, 1993

Page 61: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

62 C. A. Reiter

Fig. 1. A hubcap with Cg outer symmetry and D5 inner symmetry.

Figure 2 shows an example of an attractor in the plane with Cs symmetry and Fig. 3 shows an example of an attractor with D^ symmetry. Notice the five pinwheel arms on the outer edge in Fig. 2 and the eight bean shapes on the outer edge of Fig. 3. In each image the frequency with which each pixel is visited is recorded with color. In these figures and some subsequent ones we use red to designate the low frequency regions; moving through hues corre­sponds to increasing frequency with magenta being used for the highest frequency regions. The attractors shown in these figures, like all our attractors, result from 200 million iterations of the functions. The parameters used to create these images are given in Appendix A.

3. DUELING SYMMETRY

Our construction of dueling attractors utilizes two functions with symmetry in the plane intertwined and connected via a function of a single real variable that is used connect the parts of the attractor driven by each of the two functions. This function is the sinew function WL(/) = /(I - L{\ - fi)^). The value of L so that w^(0 repeatedly maps [—1,1] onto itself is L = i^^^i^^« 4.957474795414. This sinew func­tion is designed so that when / is near — 1 or 1, iteration o^^jjj) will include long sequences near that endpoint but in the long term it moves around the interval [—1,1]. Figure 4 shows a plot of W/ (/) for L = 4.957 which is the value for L that we used for our calculations. This choice for a value of L slightly

Fig. 2. An attractor in the plane with C5 symmetry.

Page 62: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Attractors with dueling symmetry 63

Fig. 3. An attractor in the plane with D^ symmetry.

below the extreme was made so that less time is spent near the endpoints so that in the long term there is more balance between limiting and intermediate behavior. Iteration beginning with the point 0.2 is also shown in Fig. 4. After 8 iterations the point falls very near 1; after an additional 12 iterations the points of iteration are just visible emerging from near 1.

Our attractors in three space are constructed by iterating a map from R^ to R^. It is convenient to identify the three coordinates as the real and imaginary parts of a complex coordinate, z, along with a real coordinate, /. Let fi{z) and f2(z) denote functions in the complex plane which are equivariant with respect to presumably different symmetry groups. We compute new z and t values via:

V V 4.957(0 /

Notice that when t remains near 1, then fi(/) dominates the z update and when / remains near — 1, then f2(0 dominates the z update. We may imagine the attractor as fitting inside a *can' shaped region in space where the / coordinate corresponds to the direction of the central axis of the can. Thus, iteration of this function is designed to move points back and forth between the ends of the can, but the symmetry of the attractor ought to be driven by the symmetry of fi(z) at one end of the can and by the symmetry of fiCz) at the other end of the can.

This attractor is then projected using a semi-inverted central projection. This projection is one dimension lower than the projection used in [3] for projecting attractors with the symmetry of the 4-cube

to three space. In particular, suppose we denote a point in three space given by (x,y) and t. For convenience we assume that the {x,y) points of attractor have been seminormalized. That is, the coordinates have been rescaled to lie between —1 and 1. Our choice of WiXt) automatically provides this seminormaUzation for t. When ^ = 1, we want the projection to move the unit disk into the space between the nested disks with radii 2 and 3. If we let V = {x,y) and w = TT , then we move v into the desired space by using 2w + v. When t= —I, we want the projection to move the unit disk into the space between the nested disks with radii 1 and 2. In this case, we move v into the desired space by using 2M —V. Notice the minus sign causes a reversal of direction that along with the translation by 2u gives a kind of inversion. When / is in between — 1 and 1, we take the corresponding combination, that is, 2u +1 v. Of course, this projection is discontinuous at the origin but this is Uttle problem as we expect a repelling fixed point at the origin for interesting attractors. Figure 5 shows the result of projecting the attractor shown in Fig. 2 as though it corresponded to / = 1 overlaid with the result of projecting the attractor shown in Fig. 3 as though it corresponded to ^= — 1. Notice the five 'arms' from Fig. 2 are still visible as are the eight 'beans' of Fig. 3, but the attractor has been inverted so the beans appear on the inner edge. Of course, detail is lost as the images are compressed into a much smaller area.

Figure 6 shows the actual dueling attractor that connects the two attractors from Figs 2 and 3 via the sinew function. Its limiting behaviors are given by Fig. 5 but unlike Fig. 5 which is a composite of the projection of two 2-D attractors, this figure is the

Page 63: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

64 C. A. Reiter

Fig. 4. The sinew function and some of its iterates.

projection of a single 3-D attractor. Notice that this projection of the attractor has the desired C5 outer symmetry and Dg inner symmetry. The five arms and eight beans are still visible but the connective parts of the attractor fill in vast regions between (compare to Fig. 5) and slightly disturb the inner and outer symmetry. Notice that the yellow connective parts of the attractor do seem to connect the high frequency regions of the inner and outer symmetries; however, since those symmetries are not compatible, the connections are not symmetric.

Figure 7 shows a dueling attractor with Ci 1 outer symmetry and D5 inner symmetry. Notice the connections seem to have close to C5 symmetry. Figures 8 and 9 are examples where the inner and outer symmetries are partially compatible. For variety, in these figures magenta is used for the low frequency regions and as the frequency increases the hue decreases; red is used for the highest frequency regions. The attractor used to create Fig. 8 has C2 outer symmetry and Ce inner symmetry. Since 2

divides 6 an object having Ce symmetry also has C2 symmetry; hence, the result retains the C2 symmetry throughout. The attractor used to create Fig. 9 has C3 outer symmetry and D^ inner symmetry. Since an object with D3 symmetry also has C3 symmetry, the resulting dueling attractor retains the C3 symmetry throughout.

The parameters used for our illustrations were located using an ad hoc process which shares several features with genetic algorithms [10] though it is also distinctly different from classical genetic algorithms. First, random choices of coefficients of 2-D attrac-tors were made and attractors that were plausible were saved. Plausibility required iteration of the function remaining finite for tens of thousands of iterations and an image of the 2-D attractor had to avoid the origin and have a nontrivial number of pixels lit. Once an initial population of plausible attractors is estabUshed the attractors can be mated by taking the parameters for the outer symmetry from one member of the population and taking the

Page 64: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Attractors with dueling symmetry 65

' ^ - ^ ^ ^

Fig. 5. A semi-inverted projection of the two 2-D attractors from Figures 2 and 3.

parameters for the inner symmetry from another. The resulting attractor might not be plausible, but the probability that it will be is far greater than for a random choice of parameters. Mutations were implemented by randomly varying one real or complex parameter ±1 unit, then observing whether the attractor remained plausible, and halving or doubling the variation until a maximal motion that remained plausible was determined. We attempted to

automate a measure of fitness by using box counting to estimate the fractal dimension of the image; this was to some extent successful, but in practice we tended to prune our population by selecting those with visually interesting attractors because we couldn't resist intervening in the selection process. Nonetheless, the mating and mutation aspects of these computations were important. Most of the examples in this note resulted from mating two

Fig. 6. The dueling attractor using the same limiting functions as Figures 2 and 3.

Page 65: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

66 C. A. Reiter

Fig. 7. A dueling attractor with Cn outer symmetry and Ds inner symmetry.

attractors created independently and while most of the mutations were modest variants of their pre­decessors, some of the mutations were vastly super­ior.

Figures 10 and 11, like Figs 6 and 7, have no compatible symmetry. Figure 10 shows an attractor with Cs outer symmetry and C4 inner symmetry. Notice, however, that the inner symmetry is very close to dihedral and the visible red connections seem to almost retain some C4 symmetry. In these figures yellow is used for the low frequency regions and as the

frequency increases the hue decreases (wrapping around); green is used for the highest frequency regions. Figure 11 shows an attractor with outer C5 symmetry and inner D2 symmetry. Notice the total lack of symmetry in the connective part of the attractor. Also notice that the outer symmetries in these attractors is given by the same attractor. Hence this is an example of two dueling attractors that share half their parameters (genes). These resulted from a common ancestor mating with different attractors from the population of plausible attractors.

Fig. 8. A dueling attractor with C2 outer symmetry and Cf, inner symmetry.

Page 66: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Attractors with dueling symmetry 67

Fig. 9. A dueling attractor with C3 outer symmetry and D^ inner symmetry.

While it is notoriously difficult to prove results about the chaotic behavior of attractors, we can investigate this experimentally via the Ljapunov exponents [11, 12]. Table 1 shows the Ljapunov exponents for the dueUng attractors shown in our images. Each of these has positive Ljapunov exponents which are associated with chaotic behavior. Also notice that all of these attractors share a Ljapunov exponent of 0.33 since they all

share the sinew function and its behavior is unaffected by the behavior of the other coordi­nates.

4. CONCLUSIONS

Attractors in three space with different symmetries in different regions can be created using two functions of the plane and connecting them with a sinew function that is designed to spend time near

Fig. 10. A dueling attractor with C5 outer symmetry and C4 inner symmetry.

Page 67: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

68 C. A. Reiter

Fig. 11. A dueling attractor with Cs outer symmetry and D2 inner symmetry.

each region but to move back and forth between them. The attractor can be projected from three dimensions in a meaningful way using a semi-inverted central projection. Interesting examples can be constructed using simple automatic measures of whether the attractor is plausibly interesting. The population of plausible attractors can be pruned to include the most appeahng attractors. Genetic algorithm like procedures can mate and mutate these attractors and yield a more diverse population of interesting attractors for further selection and regeneration.

Acknowledgements—The work of Gabriel Brisson [13] providing a foundation for the development of code used to generate the images is appreciated. Conversations with Thomas Yuster regarding potential sinew functions were most helpful.

REFERENCES 1. Field, M. and Golubitsky, M., Symmetry in Chaos.

Oxford University Press, New York, 1992. 2. Brisson, G., Gartz, K., McCune, B., O'Brien, K.,

Reiter, C. Symmetric attractors in three-dimensional space. Chaos, Solitons and Fractals, 7, 1996, 1033-1051.

Table 1. Ljapunov exponents of the dueling attractors.

Figure

6 7 8 9

10 11

h 0.33 0.33 0.39 0.33 0.33 0.33

^2

0.28 0.19 0.33 0.19 0.17 0.30

^2

-0.48 -0.43 -0.38 -0.39 -0.32 -0.11

3. Reiter, C , Attractors with the symmetry of the «-cube, to appear in Experimental Mathematics.

4. Stewart, I. and Golubitsky, M., Fearful Symmetry. Blackwell Publishers, Cambridge, Massachusetts, 1992.

5. Thompson, D. W., Growth and Form, 2nd edn. Cam­bridge University Press, Cambridge, 1963.

6. Weyl, H., Symmetry. Princeton University Press, Princeton, 1952.

7. Gallian, J. A. Symmetry in logos and hubcaps. American Mathematical Monthly. 97, 1990, 235-238.

8. Ashwin, P., Melbourne, I. Symmetry groups of attractors. Archive for Rational Mechanics and Analysis, 126, 1994, 59-78.

9. Melbourne, I., Dellnitz, M., Golubitsky, M. The structure of symmetric attractors. Archive for Rational Mechanics and Analysis, 123, 1993, 75-98.

10. Mitchell, M. Genetic algorithms: an overview. Com­plexity, 1, 1995, 31-39.

11. Peitgen, H.-O., Jurgens, H. and Saupe, D., Chaos and Fractals. Springer-Verlag, New York, 1992.

12. Parker, T. and Chua, L., Practical Numerical Algo­rithms for Chaotic Systems. Springer-Verlag, New York, 1989.

13. Brisson, G. and Reiter, C , Parallel Processing in J. Vector, 13, 1996, 86-95.

APPENDIX A5. PARAMETER VALUES FOR THE IMAGES Each table row contains the information giving an

equivariant function in the plane. In the first column is the integer n which specifies the rotation in the C„ or D„ symmetry; the second to fourth and fifth and sixth columns contain matrices that give the coefficients of PI(M,V) and P2(M,V), respectively. Recall the symmetry is dihedral when the coefficients are real and cyclic when the coefficients are complex. The groups of rows are paired: the first gives the parameters for the outer symmetry and the second gives the parameters for the inner symmetry. Table 2 shows the parameters used for Figs 2, 3, 5 and 6; Table 3 gives the parameters used for Fig. 7; Table 4 shows the parameters used for Fig. 8; Table 5 shows the parameters used for Fig. 9; Table 6 gives the parameters used for Fig. 10; and Table 7 gives the parameters used for Fig. 11.

Page 68: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 69

Chaos and Graphics

A NEW FEATURE IN HENON'S MAP

M. MiCHELiTSCH and O. E. ROSSLER Institute for Physical and Theoretical Chemistry, University of Tubingen, 7400 Tubingen, West Germany

Abstract—An apparently new type of transients of high and varying periodicity is found for low-period point attractors in Henon's diffeomorphism.

INTRODUCTION

Henon's map[l ] is one of the simplest 2-dimensional invertible maps—an explicit 2-dimensional taffy-puller, so to speak.

While many results about this map, including com­puter-graphical pictures are known[2], apparently still previously unknown types of behavior can be discov­ered. In the following we present a candidate for such a feature.

RESULTS

Using the technique of plotting the escape times from a repellor in different colors[l ] , the picture of Fig. 1 was obtained in a certain region of parameter space. Fig. 2 shows a blow-up of the left-hand "eye" in Fig. 1. The colors match those of Jupiter's "red spot" by happenstance only. However, we do not know yet why the shape is also similar.

Fig. 3 was obtained in a different way. It shows the evolution in time of a single initial point (the origin). One of the two parameters was slightly changed to turn the former repellor into an attractor (an explicit reversal of the map's equation would also have been possible instead). Obviously the "same" features as seen in Fig. 1 show up again. One sees a period-7 transient that "turns about" many times before reaching the attractor.

For the sake of comparison, Fig. 4 shows a very similar picture obtained in a different region of param­eter space. Again, there is this "turning about" of a high-period transient. For example, the periods 83 and 118 are easy to determine from the picture. Much higher periods may be lurking in the light portions.

DISCUSSION

In a discrete invertible system, Henon's[2] map, we have described an apparently new type of transient. A similar shape may be expected to be found for basin boundaries separating different point attractors in this map. The new transients remind one of a "foliation" of phase space. In the limit of arbitrarily high transient periods—if such a thing should occur—indeed a so-called Reeb foliation in the sense of topology [3] would be obtained.

The closest pictures we have seen to those reported above were found in the Poincare cross section through a periodically forced oscillator, Duffing's equation, by Pezeshki and Dowell[4] (see their plate XV and Figs. 17, 18).

We expect further numerical and analytical inves­tigations to be justified.

Acknowledgements—We thank A. Murle and W. Metzler for kindly sharing with us their computer programs, as well as for stimulating discussions.

REFERENCES M. Henon and Y. Pomeau, Lecture Notes in Math, Springer-Verlag, New York (1976). H.-O. Peitgen and P. H. Richter, The Beauty of Fractals, Springer Verlag, New York (1986). C. Ehresmann and G. Reeb, Sur les champs d'elements de contact de dimension p completement integrables dans une variete continuement integrable. C. R. Acad. Sci. Paris 21S, 955-957 (1944). C. Pezeshki and E. R. Dowell, On chaos and fractal be­havior in a generalized Duffing system. Physica 32 D, 194-209(1988).

Reprinted from Comput. & Graphics Vol. 13, No. 2, pag. 263-275, 1989

Page 69: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

70 M. MiCHELITSCH and O. E. ROSSLER

Fig. 1 Computer scan of initial conditions in Henon's map, x„^, = \-^y„- axl y„^, = bx„. Parameters: ^u" uu ?"^ ^ = l-?^' ^^>s: X from - 5 to 5, y from - 6 to 7. Maximal iteration number: 450; explosion threshhold value: x^-^ y'= 450. Points for which these values reach the threshhold were plotted in black

others in color depending on the number of iterations reached until the explosion value was exceeded

Fig. 2. A subregion of Fig. 1, in different colors. Axis x from 0 to 3.5, ;; from - 4 to -0.01.

Page 70: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

A new feature in Henon's map 71

Fig. 3. Evolution of an initial point (x = 0, y = 0), over 20000 iteration steps. Parameters: a- 0.2 and b = 0.9991. Axis: x

from -4.5 to 4.2, y from - 5 to 5. Fig. 4. Evolution of an initial point (x = 0, y = 0) at a com­pletely different set of parameter values, a = 0.2, b - -0.9999.

Axis: X from -1.2 to 0.1, y from -1.3 to 0.3.

Page 71: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 73

Chaos and Graphics

LYAPUNOV EXPONENTS OF THE LOGISTIC MAP WITH PERIODIC FORCING

MARIO MARKUS' and BENNO HESS Max-Planck-Institut fiir Emahrungsphysiologie, Rheinlanddamm 201, D-4600 Dortmund I, FRG

Abstract—The iterative map x„+i = r„x„ (1 - jc„) is investigated with r„ changing periodically between two values A and B. Different periodicities are assumed, e.g., {r„} = {BABA ...} or {r„} = {BBABA BBABA ...}. The Lyapunov exponent (a measure of average stability) is displayed with high resolution on the A-5-plane. The resulting images have aesthetically appealing self-similar structures. Furthermore, these images allow with one glimpse the identification of a number of system properties: coexistence of attractors, superstable curves, order by alternation of chaotic processes, and chaos by periodic resetting from a stable into an unstable fixed point.

INTRODUCTION

A number of natural phenomena can be described by one-dimensional maps of the kind Xn+\ -f(x„),n- I, 2, 3, . . . , where/: [a, b] -^ [a, b] with/(a) = / (6 ) = a and with one parabolic maximum in[a, b]. Ex­amples of such maps are found in oscillations of the enzymatic sugar breakdown [ I ], the Belousov-Zha-botinskii reaction [ 2 ], snail neurons [ 3 ], as well as ep­idemics and animal populations (see [4-6]). It can be shown that maps with the properties of / are topolog-ically conjugated with the logistic map x„+i = rx„(l - Xn) and thus exhibit qualitatively the same dynamic features (see [7] and references therein). The bifur­cation parameter r, which describes the ambient con­ditions of the system and is held constant in previous investigations[6, 8], is changed periodically in the present work. We thus write r„ instead of r. For the sake of simplicity and easy graphical representation, we make a dichotomic hypothesis: r„ may assume only two values A and B.

We investigate the dynamics of the map as a function of A and B for different sequences {r„}, namely: {BA-BABA }, {BBABA BBABA }, {BBABABA BBABABA }, {B^A^ B^A^ }, {B^A^ B^A^

METHOD

For each parameter pair {A, B) we calculated the Lyapunov exponent

X = lim -- 2 log2 dx„. dXn

(I)

[A^^B A'"B } and {A^'B A^'B . .}• We encourage the reader to try out other sequences of r„, as well as other intervals of 4 and B as those ap­pearing in this paper.

We emphasize that in contrast to most graphical representations of dynamical systems, our plane is de­fined by bifurcation parameters and not by phase vari­ables. Thus, in our display the points do not wander on the plane as the dynamic process goes on. Instead, the dynamic process is calculated here at each point {A, B) on the plane and the Lyapunov exponent[9] is calculated as a time average over the iteration process. The Lyapunov exponent quantifies the average stability of the resulting oscillatory modes, which may be pe­riodic or chaotic. For instructive discussions on chaos see [6, 8-10] and references cited there.

' To whom correspondence should be addressed.

where dx„^i/dx„ = r„- 2r„Xn in our special case. We use double-precision arithmetics. Since the approach to the limes in Eq. (1) is highly irregular, a reliable convergence criterium could not be found. However, a constant iV = 4 X 10- all over the plane yielded satisfactory results. In order to allow transients to die away, 600 iterations were performed before Eq. (I) was applied.

The logarithmic function was tabulated as an array in order to reduce computing time. This array consisted of y = 5000 values with equidistant arguments in the interval ]0, 4] . For storage and addressing, the array indices were determined after real multiplication of the arguments with 7/4 and subsequent rounding to the next integer. The results were displayed with a maximum resolution of 1280 X 1024 pixels and 8 bit per pixel for grey shading and colouring.

Each pixel in the graphical displays corresponds to one (A, B)-pair, and the grey shading (or colouring) at each pixel indicates the values of X for that pair. In general, chaos is characterized by X > 0 and periodicity (order) by X < 0. In Figs. 1 and 2 a colour discontinuity is used to mark the transition between order and chaos. In Fig. 1 (resp. Fig. 2) the colour changes from black to yellow as X changes from -oo to zero, and from black to red (resp. blue) as X changes from zero to its maximum value. Grey shadings instead of colours are used in Figs. 3 to 7. In Figs. 3 to 5, the shading changes from black to white as X changes from - x to zero, and all pixels with X > 0 are black. Analogously to the colour pictures, a shading discontinuity is used in these figures to visualize drastically the transition from order to chaos. In contrast. Figs. 6 and 7 do not show such a discontinuity: grey levels change from black to white as X grows from — oo to zero, and they change smoothly

Reprinted from Comput. & Graphics Vol. 13, No. 4, pag. 553-558, 1989

Page 72: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

74 MARIO MARKUS and BENNO HESS

back from white to black as X grows from zero to its maximum value. In contrast to Figs. 3 to 5, the dis­tribution of shadings in Figs. 6 and 7 permits to vi­sualize structures not only in the periodic but also in the chaotic regions.

For an optimal representation of a rectangular sec­tion whose edges are not parallel to the A- and 5-axes, we rotated the coordinates in Fig. 7.

CONCLUSIONS

Because of the impossibility to obtain analytical so­lutions, the features of nonlinear dynamic systems are usually found either by numerical searching proce­dures, or by chance. In contrast, we present here a graphical method that permits a straightforward iden­tification of system features by a simple glimpse over the plane.

In all pictures of this paper, the mostly lighter regions in the foregrounds correspond to periodicity (X < 0), while the picture backgrounds correspond to chaos (X > 0). Within the periodic regions, one readily identifies the (dark) superstable curves (X -*- -oo) . At some points, a crossing of one or more of these curves is detected.

Fig. I clearly shows the self-similar structure of the patterns: a ''swallows-shaped motif appears over and over at smaller and smaller scales. The patterns clearly differ both in shape and in meaning from other well-known self-similar structures[9, 11, 12]. Another sys­tem property, which is revealed by Fig. I, is the co­existence of two attractors, as indicated by the crossing of two branches (around A = B = 3.85). Coexistence means that different attractors exist in the [0, 1]-in­terval for the same values of the control parameters A and By depending on the initial condition ^o- At the crossing, one branch covers the other. The branch above is visible here in the coexistence region because it is the one which is reached with our particular initial value Xo = 0.5. The branch below becomes visible for other initial values. Nevertheless, the branch below is detected here because of the visibility of its continua­tions into regions where only one attractor exists. Thus, our overall representation on the A-B-plane permits us to show the existence of attractors which are not reached with our particular choice of.Xo. Furthermore, this graphical technique permits us to determine the number of coexisting attractors in a simple way, namely by counting the number of crossing branches: e.g., two branches in Fig. 1, three branches slightly to the right of the center of Fig. 3, five branches at the center of the right margin of Fig. 3, and seven branches close to the center of the right margin of Fig. 2. In our inves­tigations on oscillatory glycolysis we found up to four coexisting attractors [ 13 ] using tedious searching pro­cedures.

Fig. 1 allows the visualization of another remarkable feature, namely the generation of order by alternating values of .4 and B, each of which generates chaos if taken alone. This type of cross talk can be seen at the upper right of Figs, la and lb, namely on the periodic (yellow) branch at the right of the branch-overlapping

coexistence region. Here, there are pairs (A, B) such that the map with alternating A and B is periodic, al­though the maps with r„ = A = const and with r„ = B = const (which both correspond to points on the di­agonal of Fig. 1) lead to chaos. (A typical example is given by A = 3.85232, B = 3.84971.)

Figs. 2 to 7 illustrate the richness of structures ob­tained by varying the periodicity of r„. In particular. Figs. 5 and 6 show the effect of periodic interruptions by 5 in a sequence of A's, i.e., {r„} = [A '^B .•{''B...]. In Fig. 5, ' = 21. With the help of our graphical display, we discovered in this case chaotic behaviour (black ''horn" pointing downwards and towards the right of Fig. 5) at values of ^ and B well below the commonly known threshold for chaos at constant r„, which is TQ = 3.5699 . . . . Chaos appears here, e.g., 2iX A = 3.34 and J5 = 1.199. This "early chaos" is explained as fol­lows. The parameter A alone leads to a stable oscillation between two values x~ and A" , while B drives the sys­tem periodically from this stable regime into the vi­cinity of the coexisting unstable fixed point .v* = 1 - \ /A. In fact, X* ^ Bx~{ 1 - .v" ) . The contributions to X which make X positive occur while the system moves away from A* towards A" and x^. Similar pro­cesses as in Fig. 5 but for ' = 12 and higher values of B are visualized in Fig. 6.

Summarizing, we can say that the graphical repre­sentation described in the present work allows the identification or discovery of complex dynamic prop­erties by simple visual inspection of a two-dimensional parameter space. Changes of parameter periodicities and areas of display lead to a never ending cascade of surprisingly structured domains.

Acknowledgements—We thank Prof Miguel Kiwi and Prof Jaime Rossler for fruitful suggestions. Also, we thank Mrs. Gesine Schulte for the photographic work. We gratefully ac­knowledge the financial support of the Stiftung Volkswagen-werk.

REFERENCES 1. M. Markus, D. Kuschmitz and B. Hess, Properties of

strange attractors in yeast glycolysis. Biophysical Chen^-/5/r>'22, 95-105(1985).

2. J.-C. Roux, R. H. Simoyi and H. L. Swinney, Observation of a strange attractor. Physica 8D, 257-266 (1983).

3. H. Hayashi, S. Ishizuka, M. Ohta and K. Hirakawa, Cha­otic behaviour in the 'onchidium' giant neuron under sinusoidal stimulation. Phys. Lett. 88A, 435-438 (1982).

4. W. E. Ricker, Stock and recruitment. / Fish. Res. Board Canada 11,559-623(1954).

5. W. M. Schaffer, Can nonlinear dynamics elucidate mechanisms in ecology and epidemiology? IMA J. of Math. Applied in Med and Biol. 2, 221-252 (1985).

6. R. M. May, Simple mathematical models with very com­plicated dynamics. Nature 261, 459-467 (1976).

7. S. J. Chang, M. Wortis and J. A. Wright, Iterative prop­erties of a one-dimensional quartic map: Critical lines and tricritical behaviour. Phys. Rev. A24, 2669 (1981).

8. P. Collet and J. P. Eckmann. Iterated Maps on the Interval as Dynamical Systems, Birkhauser. Boston (1980).

9. H. G. Schuster. Deterministic Chaos. Physik-Verlag. Weinheim(1984).

10. C A. Pickover, Mathematics and beauty: Time-discrete phase planes associated with the cvclic system. {.x{t) = - /(y(0). v(/) =fixit))\. Comp. & Graphics. 11(2),

Page 73: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Lyapunov exponents of the logistic map 75

(a) (b) Fig. 1. Lyapunov exponent (indicated by different colours) for the parameter sequence {r„} = {BAB ABA . . . } . Abscissas: B, ordinates: y4. (a): 3.817 < ^ , ^ < 3.868, with "swallow"-shaped periodic domain (yellow);

(b): enlargement of a section of (a), 3.836 <A,B< 3.858.

Fig. 2. Lyapunov exponent for the parameter sequence {r„} = {BBABABA BBABABA ...]. Abscissa: 2.759 <B< 3.744, ordinate: 3.21 < /I < 4. Note the "swallow"-pair at the upper right part (compare with

Fig. la).

217-226 (1987); and C. A. Pickover, A note on rendering 12. 3-D strange-attractors. Comp. & Graphics 12(2), 263-267(1988). 13. B. B. Mandelbrot, The Fractal Geometry of Nature, W. H. Freeman and Co., New York (1982).

H. O. Peitgen and P. H. Richter, The Beauty oj Fractals, Springer-Verlag, Beriin (1986). M. Markus and B. Hess, Transitions between oscillatory modes in- a glycolytic model system. Proc. Natl. Acad. Sci. USA 81, 4393-4398 (1984).

Page 74: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

76 MARIO MARKUS and BENNO HESS

a67-

3.54-3.45 3.61

Fig. 3. Distorted "swallow"-pair appearing for the parameter sequence {r„} = {BBABA BBABA}.

3.46-1 3.65

Fig. 4. Lyapunov exponent for the parameter sequence {r„} = {B^A^ B^A^ . . . } .

Page 75: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Lyapunov exponents of the logistic map 77

3.6-

3.2-1.27

Fig. 5. Lyapunov exponent for the parameter sequence {r„} = {y^^'BA^'B...}.

3.59 -

3.24 i

Fig. 6. Lyapunov exponent for the parameter sequence {r„} = {A^'B A^^B}. In contrast to Figs. I to 5, the shading changes continuously at X = 0.

Page 76: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

78 MARIO MARKUS and BENNO HESS

2.84^3.44 Fig. 7. Lyapunov exponent for the parameter sequence {r„} = {B^A^ B^A^ . . . } , with continuous grey shading change at X = 0 and with clockwise rotation of the graphical coordinates with respect to the parameter

coordinates by 61°.

Page 77: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 79

Chaos and Graphics

TOWARD A BETTER UNDERSTANDING OF FRACTALITY IN NATURE

MICHAEL KLEIN and O T T O E . ROSSLER Institute for Physical and Theoretical Chemistry, University of Tubingen, 7400 Tubingen, FRG

J C R G E N PARISI* and JOACHIM PEINKE Physical Institute, University of Tubingen, 7400 Tubingen, FRG

G E R O L D BAIER Institute for Chemical Plant Physiology, University of Tubingen, 7400 Tubingen, FRG

CLAUS K A H L E R T Electronics Research Laboratory, University of California, Berkeley, CA 94720

and

J O H N L . H U D S O N Department of Chemical Engineering, University of Virginia, Charlottesville, VA 22901

Abstract—Boundaries of coexisting attractor basins are a common source of fractal structures in discrete maps. Chaotic attractors in continuous systems of ordinary differentiable equations also have a fractal mi-crostructure. A generation mechanism for self-similar fractal boundaries is proposed, which gives a closer connection between "chaos" and "fractals." We discuss the role of analyticity, critical points, chaotic forcing, and bistability as some of the elements needed to answer the major, still unresolved question of whether nature is fractal because, or in spite of, the existence of differentiable systems.

1. INTRODUCTION

Seldom have scientific ideas enjoyed such a wide­spread interest in so many different fields as "nonlinear science" does. "Chaos" and "fractals" seem to bridge the gap between physics and philosophy, mathematics and nature, and computer and art. The Fractal Ge­ometry of Nature [1], Fractals Everywhere [2], The Beauty of Fractals [3], or Does God Play Dice? [4] are only some of the very promising current book titles. One reason for the success of Chaos—Making a New Science [ 5 ] is the fact that it deals with a classical the­ory. There is an easily understandable geometric and visual approach to most of the phenomena of dynam­ical systems theory. But one must be careful. The terms "chaos" and "fractals" are frequently used inter­changeably, and there exist as many definitions as in­terpretations, although the mathematical relationship is far from obvious. Fractals were originally invented as pure mathematical structures generated as graphical computer outputs. The question "Fractals: Where's the physics?"[6] means that the Unk between fractal ob­jects and physical experiments or natural structures has yet to be found. Several different approaches to answering this question can be distinguished.

If one adopts a topological and measure-theoretical approach, the comparison of graphically generated fractals and experimentally gained data suggests a common source[7]. This source might be a "chaotic dynamics of a special flavor and character" [2]. An­other approach is "diffusion-limited aggregation," which uses stochastic dynamics as a generation mech­anism for artificial as well as natural dendritic forms,

* To whom correspondence should be addressed.

as found in the growth of crystals or in electric break­down [8]. The method of "iterated function sys­tems" [9], based on a combination of fundamental mathematical set theory and affine transformations in­volving dilation, translation, rotation, and contraction, became another construction principle for the deter­ministic construction of a fractal geometry.

In this study, we discuss the connection between continuous dynamical systems and discrete mappings to find a generation mechanism of nontrivial fractal boundaries. Fractal boundaries arise in nonlinear dy­namical systems as borderUnes separating coexisting attractor basins. Attractor basins are defined as the do­main within which all continuous trajectories or dis­crete orbits tend to the same limit set as time proceeds. Self-similar, nondifferentiable structures have, for a long time, resisted reproduction in generic continuous systems which form the main class of dynamical sys­tems that are of appUcational interest. On the one hand, one knows that all chaotic hmit sets (chaotic attractors) arising in differentiable dynamical systems have fractal aspects because they possess fuzzy and nested (box-within-a-box) [ 10 ] Cantor set structures in some cross-sections. On the other hand, all of the more spectacular fractal structures (self-similar, etc.) are found within complex analytic maps (see [2, 11]).

2. TOP-DOWN STAIRCASE FROM PHYSICAL MODELS TO MAPS

Classical physics tries to find a one-to-one mapping between reality, as represented by physical experiments, and mathematical models (Fig. 1). Simulating ideal models should lead to insight into natural phenomena.

Since the invention of the differential calculus in the late 17th century, differential equations became the

Reprinted from Comput. & Graphics Vol. 15, No. 4, pag. 583-596, 1991

Page 78: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

80 MICHAEL KLEIN et al.

Fig. 1. The motivation for physical modeUng. A good classical theory ideally gives one a one-to-one mapping between nature

and model.

dominating tool to model nature and simulate dy­namical behavior. Besides classical Hamiltonian me­chanics, which describe energy-conserving dynamical processes, the study of attractive states in dissipative, nonenergy-conserving systems yields insight into the relation between model and reality on the level of mi­croscopic multiparticle systems [12].

When looking for mathematical models of complex natural systems, one is first led to partial differential equations. These are complicated both in analysis and in simulation. But with the concept of the center man-ifold[13], it became evident that the dominating dy­namical behavior of virtually any system can be mod­eled with systems of ordinary differential equations (ODEs). Dynamical behavior is, thus, governed by flows or trajectories in an n-dimensional state space. Many fundamental physical models are represented by linear and, therefore, analytically solvable ODEs. Today, more exciting types of dynamical behavior are found in nonlinear ODEs. Formerly little known dy­namical properties, like deterministic chaos [14a], or even hyperchaos[14b], extended the hierarchy of at­tractive dynamical states[15]. Multiple fixed-point and periodic as well as quasiperiodic attractors are already to be found in the classical (near-linear) paradigms, whereby the intuition gained with two-dimensional systems sufficed. With three and more dimensions,

strange—meaning chaotic and hyperchaotic—generic attractors are found to be common in nonlinear ODEs that model, for example, chemical reactions [16] or physical experiments[17]. Nevertheless, the solution of continuous nonlinear equations with the help of numerical integration is time consuming, and the computer-graphical representation is limited to, at most, three-dimensional systems. Poincare's idea[18] of looking at an (« - 1)-dimensional cross-section through an «-dimensional flow (for an example, see Fig. 2) gives one the possibility to replace a continuous ODE system by a time-discrete mapping. The "same" dynamical behavior is then accessible with the simple iteration scheme of a discrete map, cf. Fig. 2.

So far, the top-down idea has led to the connection between discrete systems and continuous models. But there is an important constraint. All flows of ODEs and their Poincare cross-sections are invertible in time. Therefore, the corresponding return maps have to be diffeomorphisms (or at least homeomorphisms that are almost everywhere diffeomorphic). Mathematically speaking, these maps are differentiable to a sufficient degree, and their Jacobian determinant should be monotonic and nowhere equal to zero (see [20] for more mathematical details).

3. BOTTOM-UP FACTS FOR FRACTAL MAPS

The most astonishing geometric structures in maps are found as borderline of two or more coexisting at-tractor basins in complex analytic maps. Julia sets[21 ] and the Mandelbrot set [22] of the complex quadratic map (see Fig. 3), and related sets of complex poly­nomials as well as rational [23 ] or transcendental [24] functions, tend to be self-similar fractal structures that are nowhere differentiable.

Curiously enough, these aesthetically appealing boundaries seem to be restricted to the complex ana­lytic case. All of the well-studied nonlinear complex analytic maps are endomorphisms, however. They have

j^]:\ j*^"fA -'

Mj'i/

w '

X" -'

f^^''^^y:^'r^':i ' - ' ' • • " ' " > ' - • . '

- :-:<^'.,-^f.,.' ' '• ~*'-"'l;:,f '

' & ; • •

-.;i'-^,',!''•';•'^;, [-y^ / ' .

% f e i & i ^

'• ' S A ' >

- '• -;"'v~^^

>. • V ^ S v ' ^

• - • . ' . - < • ; . 1 . ' . '

. ; ^ ^ i ^ "

#^

(a)

Fig. 2. Flow and Poincare cross-section of the probably simplest strange attractor of a three-dimensional ODE X = ~y - z, y = a - az^ - by, z = X (cf [19]). Parameters: a = 0.27675, b = 0.2 (for technical details, see Table 3 in Appendix), (a) Projection of the three-dimensional flow of the ODE. The trajectory is dotted for a better visibility of the position of the cross-section at the left side, (b) Poincare cross-section of the flow of (a) at z = -0.15, revealing the typical Cantor set structure found in chaotic flows, (c) Close-up of the Poincare cross-section of (b). Note that the Cantor set structure seen is closely related to the striped

structure found in the Henon map [eq. (8)].

Page 79: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fractality in nature 81

Fig. 3. Boundary lines of the complex quadratic map [eq. (2)] (for technical details, see Tables 1 and 2 in Appendix), (a) Mandelbrot set in parameter space as the collection of all nonexploding orbits, (b) A fiUed-

in Julia set, corresponding to the attractive orbit of period 11.

"critical points" with locally infinite contraction which are essential in generating the corresponding fractal sets. In addition, these maps are noninvertible in con­trast to Poincare maps.

To link the "bottom-up" and the "top-down" line of inquiry, it is essential to acknowledge that there exists a gap between the "artificial fractals" generated by complex analytic mappings, at the one end, and the "natural fractals" generated by physical models, on the other end. Closing the gap would mean that it should become possible to find Julia set-like, self-sim­ilar structures, and nowhere difFerentiable boundaries in nonanalytic invertible maps and, furthermore, in continuous systems. A first encouraging sign comes

from studies on «-dimensional real invertible maps. Even though the basin boundaries found therein are comparably smooth (except for one direction, see Fig. 4), they nevertheless are fractal in the sense of pos­sessing a Cantor set structure in one direction [25].

In the following, we will discuss more closely the role of analyticity. First, we destroy analyticity by an arbitrary perturbation. Second, we study the effects of special transformations. Third, we investigate the role of the critical points. Thereafter, we shall look at a probable mechanism for generating fractality, inspired by the fact that nonlinear dynamics has, in the past, revealed simple features being sufficient for the creation of chaos.

Fig. 4. Striated fractal basin boundary in an ordinary nonanalytic, discrete mapping {dissipative Henon map [eq. (8)]} x„+i = 1 + >;„ - axl, y„+\ = bXn- The parameters are so chosen as to yield a chaotic attractor a= 1.4, Z? = -0.3 (for technical details, see Table 2 in Appendix), (a) The basin of attraction of the chaotic

Henon attractor. (b) Close-up of the lower-left part of (a), (c) Close-up of the lower-right part of (b).

Page 80: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

82 MICHAEL KLEIN et al.

4. DESTROYING ANALYTICITY

The complex logistic map

(1)

(with Zn, cEiC) can, using the canonical transform

/ ( z ) = ( / i (x,j;) , /2(A:,y)) ,

be considered as a function of two real variables,

(2)

(with x„, y„, Ci, C2 E 7?) such that the Cauchy-Riemann differential equations

^fx{x,y)ldx=df2{x,y)ldy

dfx{x,y)/dy = -df2{x,y)ldx (3)

are satisfied. The prototypic map, eq. (2), is of special interest because it already generates fractal boundaries. The Mandelbrot set in parameter space and a filled-in Julia set in the plane of variables are presented above in Fig. 3 a and b, respectively.

There are several ways to study the effects of de­stroying analyticity in the complex analytic logistic

map, eq. (1). The straightforward way is to simply introduce a real perturbing term into eq. (2)

Xn+\ = xl- yl^- Cx^ axn

y^+x = IXnyn + C2 (4)

(with Xn,yn,Cx,C2,aE:R) and study the effect of an increase in the perturbation, a, on the structure of the resulting "generalized" Mandelbrot set and Julia set­like basin boundaries. See Fig. 5 for differently per­turbed Julia sets of a period 11 attractor. Kahlert and Rossler[26] found two new features in the basin boundaries of this perturbed system. With a small per­turbation, they still found a self-similar, "hook-like" structure (Fig. 6) that lacked smooth parts. With in­creasing perturbation, they found a self-similar (self-repetitive) structure that is fractal in two directions, but nevertheless contains smooth segments, which they called the "wild goose" (Fig. 7). Peinke et /.[27] who looked at parameter space, found smooth segments arising on the boundary beside the remaining self-sim­ilar structures. Fig. 8 presents numerical evidence that vortex-like structures resembling those of "sea horses" in the original Mandelbrot set may survive {cf. Fig. 3a). A corresponding Julia set (Fig. 9) shows striking analogies to the structure seen in parameter space.

It seems that destroying analyticity generates differ­ent structures, characterized especially by smooth parts.

Fig. 5. Effect of an increasing perturbation on the Julia set-like boundary of eq. (4) (for technical details, see Table 2 in Appendix), (a) The undisturbed Julia set of eq. (2), respectively, eq. (4), with a = 0. (b-f)

Perturbed Julia set of eq. (4), with increasing perturbation parameter a < 0.

Page 81: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fractality in nature 83

Fig. 6. Blow-ups of Fig 5b, the self-similar "hook" structure (for technical details, see Table 2 in Appendix), (a) Relative magnification 2.5 • 10 . (b) Relative magnification 2.5 • 10*. (c) Relative magnification 2.5 • 10 .

McDonald et a/. [25], therefore, stated that "bifrac-tal"[28] basin boundaries are limited to "very special cases of two-dimensional maps," whereas, in normal two-dimensional maps, "striated" fractal boundaries, which means fractals that are locally stripe-like and smooth as described in Fig. 4, are the rule. The fact that a structure like that of Fig. 6 persists over an open, dense region in parameter space, therefore, came as a surprise.

On the other hand, it can be shown that analyticity of a map is definitely not a property that has any direct relevance on the dynamical behavior of a system. There exist infinitely many smooth automorphisms, which, even though violating the Cauchy-Riemann conditions [eq. (3)], possess structures indistinguishable from those obtained by the complex logistic map [eq. (2)]. For example, the maps

and

Xn + l xl-yl + cx

y„+l = IXnyn + y« + C2

(5a)

(5b)

(with x„, ;v„, Ci, C2 E i?) do not fulfill the Cauchy-Riemann equations [eq. (3)]. In the case of eq. (5a), we get

dfx{x,yMbx^ly ¥= bh{x,y)lby ^Ix,

and in case of eq. (5b), we have

dfx{x,y)ldx^lx + df2{x,y)ldy = lx + ly.

Both these maps generate geometrically distorted Mandelbrot sets (Fig. 10). The Mandelbrot set of eq. (5a), for example, is slightly stretched and rotated about the origin toward the first diagonal of parameter space (ci, C2). With an appropriate choice of the two free parameters, namely

c\ = C1-C2/V3

c'i= C1 + C2/V3, (6)

the Mandelbrot set can be shifted geometrically onto the original one, thus balancing the transformation in state space by a transformation in parameter space. Eqs. (5) are two examples from a whole class that is obtained by rotating and stretching eq. (2) in the plane [29].

Fig. 7. Blow-ups of Fig. 5f, the self-repetitive "wild goose" structure (for technical details, see Table 2 in Appendix), (a) Relative magnification 4.0* 10 . (b) Relative magnification 4.0* 10*. (c) Relative magni­

fication 4.0-10^

Page 82: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

84 MICHAEL KLEIN et al.

Fig. 8. View of a two-dimensional slice through the three-dimensional parameter space of eq. (4) (for technical details, see Table 1 in Appendix), (a) Total view of the Mandelbrot-like set in parameter space.

(b) Close-up of a vortex structure at the top of (a), (c) Close-up of the central part of (b).

Another even more surprising map [ 30 ] :

x'„+x = 2x'n{ 1 - pix'^ + y'n) + PA

/ „ + , = ( 1 - p,X'^ + y'„Y - pWn + P3 - 1

+ ;?,(2x'„(l -p,x'„2 +>;'„)+p4)' (7)

(with x'ny y'n,Piy. . . ,P4E:R)is nothing but a non­linear transform of the complex logistic map [eq. (2)] via the Henon map

X = I - pix'^ + y'

y = Pix' (8)

(with X, y, jc', y', pi, p2E:R). The basin of attraction of an attractive cycle of period 11 is shown in Fig. 11.

Fig. 9. Julia set-like boundary of eq. (4). Despite the pertur­bation, the equivalence of the structures found in parameter space {Ci,C2, a) and variable space {x„,y„)is not destroyed, compare Fig. 8a with Fig. 9 (for technical details, see Table

2 in Appendix).

5. LINEAR NONCONFORMAL TRANSFORMATIONS

To our knowledge, there exists no theorem which allows one to decide whether or not a noninvertible dynamical system can be transformed into a complex analytic one. Even the question of the existence of such a bijection [e.g., in the case of eqs. (4) ] is open. We are not going any deeper into the problem of general transformations, except for showing that a criterion for linear transforms may be found easily [30] .

Any homogeneous linear automorphism in two real dimensions, T, may, neglecting trivial shifts, be written as

/ I 0 \ / c o s 0 - s in </> \ ^ \a b)\sin(l) cos</>/

aSC. (9)

The constant factor, a, together with the second matrix, C, possess the general form of a conformal linear transform and, hence, do not change the analyticity of a map. In contrast, the matrix, S, can destroy (or re­introduce) analyticity if it is no longer (or becomes) a diagonal matrix with b = ±1. Via S, any general two-dimensional map

x'„+i = F'(x'„, y'n)

y„+, = G'{x'„, y'n)

can be transformed into

(10)

Xn + i = FiX„, yn)

= F'{x„, axn + byn)

y„+l = G(Xn, yn)

= -(a/b)F'(x„, aXn + by„)

-\-(l/b)G'ix„,aXn-^by„). (11)

In order for the Cauchy-Riemann equations [eq. (3) ] to be satisfied for the transformed dynamics F(Xy y), G(x,y), the conditions

F',. + aF'y •• -aF'y + G'y (12a)

Page 83: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fractality in nature 85

Fig. 10. Different examples of Mandelbrot sets in nonanalytic maps (for technical details, see Table 1 in Appendix), (a) Stretched and rotated Mandelbrot set of eq. (5a). (b) Deformed Mandelbrot set of eq. (5b).

and

bF'y = {alb)F',. 4- {a^lb)F'y

-{\/b)G',.-{alb)G'y (12b)

(where F^- = dF'/dx', etc.) must be fulfilled. These equations can be solved easily, yielding

G'y - F'x' 2F'.

as well as

b = ± aF'x' + a^F'y - 2G'^> - aO'y

F'. r v'

(13a)

(13b)

This gives one a general criterion to check on the an-alyticity of those dynamics [e.g., eqs. (5)] in which coordinates are just stretched and rotated geometri­cally.

6. ON THE ROLE OF CRITICAL POINTS

One possible definition of the Mandelbrot set relies on the important role of critical points, defined as zeros of the Jacobian determinant. The Mandelbrot set of a map is the collection of all points in parameter space whose orbits stay finite under iteration of the finite critical point[ 3 ]. The complex quadratic map [eq. (1)] has only two critical points, one at infinity and one at the origin, whereby the latter can be taken to generate the set. Two interesting questions arise: what happens if there exists more than one finite critical point?, and— more important to us—what happens if there is no critical point present? In case of the cubic complex analytic map with its two finite critical values, one gets two separated Mandelbrot-like sets (see [31]), which should be no surprise.

We wish to present another astonishing map which gives rise to a three-dimensional rotated Mandelbrot set. Eqs. (5) and (7) were designed under the assump­tion that the Mandelbrot set and Julia sets may be treated as well-defined sets of the two-dimensional

Fig. 11. The basin of attraction of eq. (7) (for technical details, see Table 2 in Appendix), (a) Total view of the transformed Julia set. (b) Close-up of the lower-right part of (a), (c) Close-up of the vortex structure

of(b).

Page 84: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

86 MICHAEL KLEIN et al.

plane. That gave one of us (M.K.) the idea to simply rotate the fundamental dynamics about the real axis, as in

•^« + l "~ ^n yn ^n + C\

(14)

(with x„, yn, Zn, Cu C2, Ci Ei R). The Jacobian reads Sx(x^ + y^ -\- z^). For x = 0, there are infinitely many finite critical points [the whole (y, z) plane generates a zero Jacobian ]. But only when using the origin as initial condition, one will generate the original Man­delbrot set. This is because the origin is the "point of maximal decoupling" between parameter and variable space. Decoupling means that the whole iteration se­quence is given by the parameter values independently of the initial condition, and vice versa. The map itself reveals curious structures as, for example, a rotationally symmetric Mandelbrot set. Slices in the three-dimen­sional parameter space enable us to take "tomograms" through the set at arbitrary points (Fig. 12).

We designed a second prototypic map in three di­mensions close to the dynamics of the original two-variable quadratic form. Its Jacobian is globally un­equal to zero, so that it possesses no finite critical point:

Xrt+i = -axn - (1 - a)xl - yl-\- Ci

y„+l = IXnyn + hZn + C2

«+i ~ yn (15)

(with x„,yn, z„, Ci, C2, a, bE: R). The Jacobian reads bia-\-3y^). Although the origin no longer is the critical point, we used it to analyze the arising Mandelbrot­like set, since it still represents the point of maximal decoupling between parameter space and variable space. Fig. 13 shows the deformed Mandelbrot-like set which still somewhat resembles the original structure. Fig. 14 shows some corresponding Julia-analogous sets. For the time being, we can only give numerical evi­dence of self-similarity and fractality. It seems possible that the fractals generated with eqs. (14) and (15) in­clude striated structures not found in the complex an­alytic case.

7. GENERATING MECHANISM OF FRACTAL BOUNDARIES

Now the question arises of whether one can find a general mechanism creating fractal boundaries inde­pendently of analyticity. We propose that any bistable system with two different basins of attraction, when combined with a chaotic forcing acting on the bound­ary, generates nontrivial fractal boundaries. To moti-

(d) (e)

Fig. 12. Two-dimensional slices through the rotationally symmetric Mandelbrot set of eq. (14) (for technical details, see Table 1 in Appendix), (a) Slice in the (ci, C2) plane of parameter space of eq. (14). This is the "original" Mandelbrot set found also in eq. (2) (compare with Fig. 3a). (b) Slice parallel to the (02, c^) plane at Ci =0.31 of (a), (c) Slice parallel to the (02, 3) plane at Ci = 0.375 of (a), (d) Slice parallel to the (ci, C2) plane at C3 = O.I of (a), (e) Slice parallel to the (cj, C2) plane at C3 = 0.25 of (a), (f) Slice parallel

to the (ci, C2) plane at c^ = 0.55 of (a).

Page 85: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fractality in nature 87

Fig. 13. Deformed Mandelbrot-like set of eq. (15) (for tech­nical details, see Table 1 in Appendix).

vate this idea, we transform eq. (2) into polar coor­dinates. With X = r cos (j) and y = r sin 0, the two-dimensional map now reads

r„+i = Vr + 2rlici cos 20„ + C2 sin 20„) -\- c]-\- d

rl sin 20„ + C2 </)„+!= arctan

r cos 2<t)n + Ci (16)

(with 0 < 0„ < 27r, r„, Ci, C2 E i?). The Julia set of the basin of attraction of a cycle of period 11 (Fig. 5a) now becomes Fig. 15a in the (</>, r) plane. In the limiting case of both real parameters C\, C2 being equal to zero, this two-dimensional map separates into two indepen­dent one-dimensional maps: the bistable quadratic map of the radius variable (with one attractor at zero and the second at infinity separated by r = 1) and the well-known modulomap generating the chaotic dynamics of the Bernoulli shift:

'*«+! — 1" n

<t)n+\ = 20„ mod ITT (17)

Fig. 14. Julia-like sets of eq. (15) (for technical details, see Table 2 in Appendix), (a) Total view of a Julia set with parameters chosen on the right of Fig. 13. (b) Close-up of the center of (a), (c) Total view of a Julia set with parameters chosen on the left of the main body of Fig. 13. (d) Close-up of the spiral of

Fig. (c).

Page 86: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

88 MICHAEL KLEIN et al.

Fig. 15. Julia sets in the (0, r) plane (for technical details, see Table 2 in Appendix), (a) Julia set of eq. (16) in the (</), r) plane, (b) Julia set of eq. (18) in the (</>, r) plane.

(with 0 < 0„ < 27r, !•„ E i?). After a further transform, the underlying mechanism of the map, eq. (16), with parameters (ci, C2) not equal to zero, can be seen somewhat more clearly. The substitution r = -\-\r\ cf) = 072 into eq. (16) yields

r'n+i = r'^ 4- 2r'„(ci cos </>'„ +

</)„+, = 2 arctan -; - — — . r„cos0„ + Cx

C2 sin 0^) -\- c\ -\- cl

(18)

(with 0 < 0'„ < 27r, r'„, Ci, C2 E i?). When restricted to nonnegative values, this automorphic nonlinear transformation does not destroy the qualitative dy­namical structure of the map (though making it non-analytic). The new map, eq. (18), reveals the proposed mechanism (compare Fig. 15a and b which are ob­viously diffeomorphically related). The complicated coupling between the bistable radius variable, r\ and the chaos-generating angle variable, 4>', is accomplished in a transparent way via the two parameters Ci, C2.

In order to test the idea, we replace the quadratic bistability in eq. (16) by a cubic expression F(r),

8. SIMILARITIES IN DISCRETE AND CONTINUOUS SYSTEMS

After now having obtained a better understanding of one possible mechanism for the emergence of non-trivial fractal basin boundaries, more realistic systems can be studied[32]. Rossler etal\3t'^] described a four-variable ODE system that was originally designed to illustrate chaos generation via the reinjection princi-ple[15]:

X = w{-y - c) -f (1 - w){z + c)

y=w{x-\-a-l)-\-y{\- w)(z -f- c)/ix + ^ - 1)

i = wz{-y - c)/(x - b) -\- {\ - w){a - x)

w= ( l / 0 ( w ( l - w){w- 1 + x ) - 5 ( w - 0 . 5 ) )

(20)

(with X, y, z, w, a, b, c, e, 6 G R). This system gives rise to a hyperchaotic attractor which has two directions of exponential divergence, respectively, two positive Lyapunov exponents. With larger values of the control

<j)n+\ - arctan

yF(r„y + 2Fir„)ic, cos 2(f>„ + C2 sin 20„) + d + d

F{r„)sm 2(f)„-\- C2 F{rn) cos 2(/)„ + Ci

(19)

where i (r„) = (1 - fl)r„ + arl and (0 < 0„ < lir, r„, tz, Ci, C2 E i?). With the parameters Ci = C2 = 0 and a <• 1, it is easy to see that there is once more no finite critical point present. Nevertheless, we again find the shadow of the Mandelbrot set (Fig. 16).

parameter b(b>2),the attractor becomes unstable with two diverging directions, thus producing a double-drained region. The underlying dynamics (basic set) of this region is still chaotic. Analyzing the region of

Page 87: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fractality in nature 89

Fig. 16. Mandelbrot-like set of eq. (18) (for technical details, see Table 1 in Appendix).

Fig. 18. Self-similar basin boundary in eq. (21), compare with Fig. 17 (for technical details, see Table 3 in Appendix).

interest with the help of a two-dimensional set of initial conditions in the four-dimensional state space reveals a Sierpinsky-type fractal boundary separating the two directions of divergency (Fig. 17) (for more details see [33]).

This system is of special interest, because the cor­responding Poincare return map can be modeled ex­plicitly by coupling two logistic maps into a three-di­mensional invertible map [ 34 ]:

Xrt+i = ax„(l - x „ ) + bz„

yn+i = ay„i\ -y„) + bx„ Zn + l = yn ( 2 1 )

(with x„, yn, z„, a, bG R). In case the parameter a is larger than 4.0, the corresponding hyperchaotic at-

Fig. 17. A scan of initial conditions in the {y, z) plane of eq. (20) (for technical details, see Table 2 in Appendix).

tractor (folded-towel attractor[15]) explodes in two directions as in the case of the ODE of eq. (20). Anal­ysis of the bistable region shows a self-similar boundary of the two intertwined basins (Fig. 18) of the same type as Fig. 17.

9. CONCLUSIONS

Are there self-similar or even nowhere difFerentiable structures in continuous systems? Starting with well-known discrete complex analytic maps, we found that analyticity of a map—even though important for a mathematical treatment—is not a necessary condition for generating bifractal structures. The same seems to hold true for critical points which, for arbitrary maps, do not play the same decisive role as for complex an­alytic examples. One possible generating mechanism for bifractal boundaries consists in letting a chaotic forcing act on a bistable subsystem, so that a boundary between two coexisting basins of attraction (or regions of divergence, respectively) is formed [35]. A closer look on the existing examples, nevertheless, still reveals some open questions. "Typical fractals are not pretty" (see [2], p. 108). What is the essence of those aes­thetically appealing, infinitely complex, though highly ordered, sets known as the Mandelbrot set and the corresponding Julia sets of the complex analytic qua­dratic map? We are confident that the underlying, spe­cially organized chaotic dynamics and the internal ge­ometry of the Riemannian sphere will give the answer eventually. The study of ordinary maps on closed spaces (like the sphere or the torus), presently in prep­aration, may also contribute to further narrowing the gap that still exists between models of nature and fractal maps.

Acknowledgements—We thank Brigitte Rohricht, Wolfgang Metzler, and Michael Michelitsch for their fruitful collabo­ration.

Page 88: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

90 MICHAEL KLEIN et al.

REFERENCES 1. B. B. Mandelbrot, The Fractal Geometry of Nature, Free­

man, San Francisco (1982). 2. M. F. Bamsley, Fractals Everywhere, Academic Press,

Boston (1988). 3. H. -O. Peitgen and P. H. Richter, The Beauty of Fractals,

Springer-Verlag, Beriin (1986). 4. I. Stewart, Does God Play Dice?, Basil Blackwell-Penguin,

Oxford (1989). 5. J. Gleick, Chaos—Making a New Science, Viking-Pen­

guin, New York (1987). 6. L. P. KadanofF, Fractals: Where's the physics? Physics

Today (FehmsLvy 1986). 7. G. Mayer-Kress (Ed.), Dimensions and Entropies in

Chaotic Systems, Springer-Veriag, Beriin (1986). 8. T. A. Witten and L. M. Sander, Diffusion-limited aggre­

gation. Physical Rev. B27, 5686-5697 (1983). 9. M. F. Bamsley and S. Demko, Iterated function systems

and the global construction of fractals. Proc. Roy. Soc. London A399, 243-275 (1985).

10. C. Mira, Chaotic Dynamics, World Scientific, Singapore (1987).

11. H. -O. Peitgen and D. Saupe (Eds.), The Science of Fractal Images, Springer-Verlag, Berlin (1988).

12. G. Nicolis and I. Prigogine, Self-Organization in Non-equilibrium Systems, Wiley, New York (1977).

13. H. Haken, Advanced Synergetics, Springer-Verlag, Berlin (1983).

14a.T. Li and J. A. Yorke, Period three implies chaos. Am. Math. Mon. 82, 985-992 (1975).

14b.O. E. Rossler, An equation for hyperchaos. Phys. Lett. 71A, 155-157(1979).

15. O. E. Rossler, The chaotic hierarchy. Z Naturforsch. 38a, 788-801 (1983), reprinted in: A Chaotic Hierarcy, G. Bair and M. Klein (Eds.), World Scientific, Singapore (1991).

16. J. L. Hudson, O. E. Rossler, and H. Killory, A four-vari­able chaotic chemical reaction. Chem. Eng. Comm. 46, 159-166(1986).

17. B. Rohricht, J. Parisi, J. Peinke, and O. E. Rossler, A simple morphogenetic reaction-diffusion model describing nonlinear transport phenomena in semiconductors. Z. P/z);5. 653,259-266(1986).

18a.H. Poincare, Sur les courbes definies par des equations difierentielles. /. Math. PureetAppl. 1, 167-224 (1885).

18b.H. Poincare, Les Methodes Nouvelles de la Mechanique Celeste, Guthier-Villas, Paris (1892).

19. O. E. Rossler, An equation for continuous chaos. Phys. Lett. 51A,397-39S (1976).

20. R. L. Devaney, An Introduction to Chaotic Dynamical Systems, Benjamin/Cummings, Menlo Park, CA (1986).

21. G. Julia, Sur iteration des fonctions rationnelles. / Math. Pure et Appl. 4, 47-245 (1918).

22. B. B. Mandelbrot, Fractal aspects of the iteration of z -»' X( 1 - z) for complex X, z. Ann. NY Acad Sci. 357, 249-259(1980).

23. R. Mane, P. Sad, and D. Sullivan, On the dynamics of rational maps. Ann. Sci. Ec. Norm. 16(suppl.), 193-217 (1983).

24. R. L. Devaney, Julia sets and bifurcation diagrams for exponential maps. Bull. Am. Math. Soc. 11, 167-171 (1984).

25. S. W. McDonald, C. Grebogi, E. Ott, and J. A. Yorke, Fractal basin boundaries, Physica 17D, 125-153 (1985).

26. C. Kahlert and O. E. Rossler, Analogues to a Julia boundary away from analyticity, Z Naturforsch. 42a, 324-328(1987).

27a.J. Peinke, J. Parisi, B. Rohricht, and O. E. Rossler, In­stability of the Mandelbrot set. Z Naturforsch. 42a, 263-266(1987).

27b.J. Peinke, J. Parisi, B. Rohricht, O. E. Rossler, and W. Metzler, Smooth decomposition of generalized Fatou set

explains smooth structure in generalized Mandelbrot set. Z Naturforsch. 43a, 14-16 (1988).

27c.J. Peinke, J. Parisi, B. Rohricht, O. E. Rossler, and W. Metzler, Non-differentiable structure in the generalized Mandelbrot set. Z Naturforsch. 43a, 287-288 (1988).

28. B. Rohricht, W. Metzler, J. Parisi, J. Peinke, W. Beau, and O. E. Rossler, The classes of fractals. In The Physics of Structure Formation: Theory and Simulation, W. Gut-tinger and G. Dangelmayr (Eds.), Springer-Verlag, Beriin, 275-281(1987).

29. M. Klein, Mandelbrot set in a non-analytic map, Z Na­turforsch. 43a, 819-820 (1988).

30. C. Kahlert and M. Klein, On the role of transformations destroying analyticity, Z Naturforsch. 43a, 1091-1093 (1988).

31. B. Branner, The parameter space for complex cubic poly­nomials, Proc. of the Conference on Chaotic Dynamics, Georgia Tech, Atlanta, GA (1985).

32. O. E. Rossler, J. L. Hudson, and M. Klein, Chaotic forcing generates wrinkled boundary, /. Phys. Chem. 93, 2858-2860(1989).

33. O. E. Rossler, J. L. Hudson, M. Klein, and C. Mira, Self-similar basin boundaries in a continuous system. In Non­linear Dynamics in Engineering, W. Schiehlen (Ed.) Springer-Veriag, Beriin (1989).

34a.O. E. Rossler, C. Kahlert, J. Parisi, J. Peinke, and B. Rohricht, Hyperchaos and Julia sets, Z Naturforsch. 41a, 819-822(1986).

34b.O. E. Rossler, J. L. Hudson, M. Klein, and R. Wais, Self-similar basin boundary in an invertible system (folded-towel map). In Dynamics Patterns in Complex Systems, A. S. Kelso et al. (Eds.), World Scientific, Singapore, 209-218(1988).

35. F. Peinke, M. Klein, A. Kittel, G. Baier, F. Parisi, R. Stoop, F. L. Hudson, and O. E. Rossler, Nowhere Dif-ferentiable Boundaries in Differentiable Systems—A Proposed Explanation, Europhys. Lett. 14, 615-620 (1991).

APPENDIX The Mandelbrot sets and Mandelbrot-like sets are the collec­tion of all parameter states which have nonexploding iterative orbits. A grid of 400 X 400 initial points is iterated. Attractive states are plotted black, diverging states are plotted white. The applied criterion for divergence is x^ -^ y^ '^ 100 or x^ + y'^ + z ^ 10(K), respectively. The maximum number of iteration steps per point was set to 100. The triangles in Fig. 8a and b) mark the area of the successive close-ups. The lines in Fig. 12a show the position of the slices of Fig. 12b-f.

The filled-in Julia sets and Julia-like sets are basins of at­traction in variable space. A grid of 400 X 400 initial points is iterated. Attractive states are plotted black, diverging states are plotted white. The applied criterion for divergence is x^ + y^ ^ 100 or x^ + >' + z^ ^ 1000, respectively. In case of attractive states, the maximum number of iteration steps per point differed between 100 and 5000, depending on whether or not picture stabilization is obtained. The triangles mark the position of close-ups of the following figures. In Fig. 18, a different criterion for coloring is used. Initial points that explode (y^ + z^ ^ 10,000) with y :^ z are plotted white, those which explode with y^zart plotted black.

The ODEs are calculated with a one-step Runge-Kutta-Fehlberg numerical integration method of 7th order with au­tonomous stepsize control. The allowed local error was set to 10'^. The Poincare cross-sections of Fig. 2b and c are cal­culated with a backward integration algorithm using the same integration method. The cross-section is set to be at z = -0.15. Fig. 17 shows a scan of initial conditions in the (y, z) plane of eq. (20), while, initially, x = 0.0 and w = 0.01. The criterion used for coloring was: black, when y{t) > 0.2 while w{t) ^ 0.8 and x(t)< 0.2; white, when z{t)> 0.2 while w{t) < 0.2 and x ( / )>0 .8 .

Page 89: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fractality in nature 91

Table Al. Technical details of the parameter space figures.

Fig^

3 a

8 a

8 b

8c

10a

10b

12a

12b

12c

12d

12e

12f

13

16

E g .

(2)

(4)

(4)

(4)

(5a)

(5b)

(14)

(14)

(14)

(14)

(14)

(14)

(15)

(18)

Initial conditions

Xo = 0.0 yo = 0.0 xb = 0.0 >'o = 0.0 ;cb = 0.0 yo = 0.0 Xo = 0.0 yo = 0.0 Xo - 0.0 yo = 0.0 xb = 0.0 yo = 0.0 Xo = yo = 0.0 zo = 0.0 Xo = yo = 0.0 Zo = 0.0 Xo = yo = 0.0 Zo = 0.0 • 0 = yo = 0.0 Zo = 0.0 xo = yo = 0.0 Zo = 0.0 Xo = yo = 0.0 Zo = 0.0 xb = yo = 0.0 Zo = 0.0 00 = 0.0 ro = 0.001

Special parameters

— fl = 0.3

fl = 0.3

a = 0.3

— — — —

C3 = 0 .0

c, = 0 . 3 1

c, = 0.375

C3 = 0.1

Ci = 0.25

C3 = 0.55

a = 0.01 b = 0.99 a = 0.95

Abscissa ordinate

Ci

Cl

C\

C2

Cl

Cl

C\

Cl

C\

Cl

Cl

Cl

Cl

Cl

Cl

C3

Cl

Ci

Cl

Cl

C\

Cl

C\

Cl

Cl

Cl

C\

Cl

Miminum value

- 2 . 0 - 1 . 2 5 - 2 . 0 - 1 . 2 5 -0 .035

0.745 -0 .0287

0.75145 - 2 . 0 - 2 . 0 - 2 . 0 - 1 . 5 - 2 . 0 - 1 . 2 5 - 1 . 2 5 - 1 . 2 5 - 0 . 6 5 - 0 . 6 5 - 2 . 0 - 1 . 2 5 - 2 . 0 - 1 . 2 5 - 2 . 0 - 1 . 2 5 - 1 . 2 5 - 1 . 2 5 - 2 . 0 - 1 . 2 5

Maximum value

0.5

1.25 0.5

1.25 -0 .025

0.755 -0 .0286

0.75155 1.0

1.0

1.0

1.5

0 .5

1.25 1.25 1.25 0.65 0.65 0.5

1.25 0.5

1.25 0.5

1.25 1.25 1.25 0.5

1.25

Table A2. Technical details of the variable space figures.

Fig.

3 b

4 a

4 b

4 c

5 a

5 b

5c

5 d

5e

5f

6 a

6 b

6 c

7 a

7 b

7c

E g .

(2 )

(8)

(8)

(8)

(4 )

(4)

(4 )

(4 )

(4)

(4)

(4)

(4)

(4)

(4)

(4)

(4)

Special parameters

Cl = 0.32 Cl = 0.043 fl= 1.4 b = - 0 . 3 fl= 1.4 b = - 0 . 3 fl= 1.4 b = - 0 . 3 c, = 0.32, a = 0.0 Cl = 0.043 c, = 0.32, a = - 0 . 0 1 Cl = 0.043 c, = 0.32, a = - 0 . 0 5 Cl = 0.043 Cl = 0.32, a = - 0 . 2 5 Cl = 0.043 Cl = 0 . 3 2 , fl = - 1 . 2 5 Cl = 0.043 Cl = 0 . 3 2 , fl = - 1 . 5 7 Cl = 0.043 c, = 0.32, a = - 0 . 0 1 Cl = 0.043 c, = 0 . 3 2 , a = - 0 . 0 1 Cl = 0.043 c, = 0 . 3 2 , fl = - 0 . 0 1 Cl = 0.043 c, =0 .32 , f l = -1 .57 Cl = 0.043 c, = 0.32, fl = - 1 . 5 7 Cl = 0.043 Cl = 0 . 3 2 , a = - 1 . 5 7 Cl = 0.043

Abscissa ordinate

Xn

yn

x„ yn Xn

y« Xn

yn Xn

yn

Xn

yn Xn

yn Xn

yn Xn

y» Xn

yn Xn yn Xn

yn Xn

yn Xn

yn Xn

yn Xn

yn

Minimum value

- 1 . 2 - 1 . 2 - 4 . 0 - 3 . 0 - 2 . 0 - 2 . 5 - 0 . 5 - 2 . 5 - 1 . 2 - 1 . 2 - 1 . 2 - 1 . 2 - 1 . 2 - 1 . 2 - 1 . 2 - 1 . 2 - 1 . 5 - 2 . 0 - 1 . 5 - 2 . 0 -0 .555

0.27575 -0 .554084

0.2767458 -0.55408378485

0.276746428333 1.4448 0.3394 1.445726 0.3397765 1.44572652 0.339777176

Maximum value

1.2

1.2

4 . 0

17.0 0 .0

1.5

0 .0

- 1 . 5 1.2

1.2

1.2

1.2

1.2

1.2

1.2

1.2

2 .5

2 .0

2 .5

2 .0 -0 .554

0.27675 -0 .554083

0.2767468 -0.55408378385

0.276746429333 1.4458 0.3404 1.445727 0.3397775 1.44572653 0.339777186

Page 90: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

92 MICHAEL KLEIN et al.

Table A2. {Continued).

Fig.

9

11a

l i b

l i e

14a

14b

14c

14d

15a

15b

18

Eg.

(4)

(7)

(7)

(7)

(15)

(15)

(15)

(15)

(16)

(18)

(21)

Special parameters

cx = - 0 . 0 3 , a = 0.3 C2 = 0.75 c, = -0 .32 , C2 = 0.043 /7, = 1.4,/72 = 0.3 P3 = 0.3,/74 = 0.143 c, = - 0 . 3 2 , C2 = 0.043 Pi = 1.4,/72 = 0.3 /73 = 0.3,/74 = 0.143 Ci = - 0 .32 , C2 = 0.043 /7, = 1.4,/72 = 0.3 ;73 = 0.3, A = 0.143 c, = 1.095,^ = 0.01 C2 = 0.01, Z7== 0.99 c, = 1.095,^ = 0.01 C2 = 0 . 0 1 , ^ = 0.99 c, = -0 .64 , a = 0.01 C2 = 0.0\,b = 0.99 c, = -0 .64 , a = 0.01 C2 = 0.01,/? = 0.99 c, = 0.32 C2 = 0.043 c, = 0.32 C2 = 0.043 fl = 4.1,z„ = 0.0 b = 0.001

Abscissa ordinate

x„ yn Xn

yn

x„ yn

x„ yn

x„ yn Xn

yn Xn

yn Xn

yn <t>n r„ <t>n

r'n x„ yn

Minimum value

- 1 . 5 - 1 . 5 - 4 . 0 - 2 . 0

0.3 - 0 . 9

0.896 0.55

- 1 . 5 - 1 . 5 - 0 . 5 - 0 . 5 - 1 . 3 - 1 . 0 -0 .4863

0.22 0.0 0.001 0.0 0.001

-0 .1 -0 .1

Maximum value

1.5 1.5 4.0 18.0

1.1 1.1

' 0.936 0.65

1.5 1.5 0.5 0.5 1.2 1.0

-0 .3384 0.33 IT

1.5 4ir 1.5 1.1 1.1

Table A3. Technical details of the ODE figures.

Fig.

2a

2b

2c

17

Eq. Initial

conditions Special parameters

a = 0.275 b = 0.2

a = 0.275 b = 0.2

a = 0.275 ^ = 0.2

a = 0.5, b = c= 1.3,5 =

1.55 € = 0.005

Abscissa ordinate

X

y z X

y

X

y

y 2

Minimum value

- 1 . 5 - 0 . 8 - 1 . 7 -1 .41 -0 .45

- 1 . 0 0.568

- 1 . 0 -2 .28

Maximum value

1.9 0.7 1.9

-0 .86 0.65

-0 .85 0.593

0.1 0.1

See fig. caption

See fig. caption

See fig. caption

(20)

xo = 5.0 yo = 5.0 Zo = 0.1 JCo = 5.0 yo = 5.0 Zo = 0.1 Xo = 5.0 y^ = 5.0 Zo = 0.1 Xo = 0.0 Wo = 0.01

Page 91: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 93

Chaos and Graphics

ON THE DYNAMICS OF REAL POLYNOMIALS ON THE PLANE

A R T U R O . LOPES* t Institute for Physical Science and Technology, University of Maryland, College Park, MD 20742

Abstract—We analyze the dynamics of the map/(z) = z - 5z where 5 E C is a constant and z E C is a variable. For some values of 5, we can have invariant measures of density with respect to the two-dimensional Lebesgue measure. For other values of 5 we can have fractal repellers or the X-trange attractor. This problem is related to a Triple Point Phase Transition Model (Potts Model).

1. INTRODUCTION

We will analyze computer experiments and present several conjectures on the dynamics of real polynomials on the plane of the form f{x, y) = (x^ - y^ — ax — by, 2xy - bx -\- ay), where a BR and ^ E R are constants. In a compact form /can be written as/(z) = z^ — sz, where z G C and s = a-\- bi. Some strange attractors appear for some values of the parameter s. In one of these cases, the attractor has the geometrical shape of the letter X. For other values of the param­eters, there exist an invariant measure with density with respect to the two-dimensional Lebesgue measure. We use the computer to analyze the bifurcation set of pa­rameters and the dynamics of these maps.

The physical motivation for analyzing such classes of maps is related to a dynamical system model recently introduced for understanding an old problem: triple point phase transition (Potts Model). In our case the model applies to a semi-infinite one dimensional spin lattice 1 with four spin components in each site of the lattice.

The Yang-Lee zeros are part of a very important area of study of concrete physical problems related to sudden magnetization of ferromagnetic systems. In the dynamical system model we consider here, we will ex­hibit the locus of points of the set that is the analog of the set of Yang-Lee zeros. This is relevant for the phe­nomena of triple point phase transitions where it is useful to know for each values of s whether the maps fs are expanding or not.

2. REAL POLYNOMIALS IN THE PLANE

In this note we will consider the family of real poly­nomials on the plane of the form

fix, y) = (x^ - y^ — ax ~ by, Ixy — bx -\- ay),

a^U, /> E IR.

In complex coordinates such map can be written in the form

/ (z ) = z^ - sz, where s = a-\- bi.

* Partially supported by AFOSR. t Permanent address: Intituto de Matematica UFRGS, Av.

Bento Goncalves 9500, 91500-Porto Alegre-RS, Brazil.

Reprinted from Comput. & Graphics Vol. 16, No. 1, pag. 15-23, 1992

For the parameter s = 2,the dynamic of this map is very well understood. This map was first considered by M. E. Hofman and W. D. Withers in [ 8 ] and [ 15 ], and is also known as the Generalized Chebyshev Poly­nomial on the plane (see also [12]). In this case the map /has an invariant measure, absolutely continuous with respect to the 2-dimensional Lebesgue measure. This measure is the measure of maximal entropy. The support of this invariant measure is the interior of the deltoid curve given by

4(z^ + z^) - (zz)^ - 18zz + 27 = 0.

The picture of the deltoid region is shown in Fig. 1 (a). The analytical expression of the density is

; (4(Z^ + Z 3) - (ZZ)^ - \^ZZ + 11)-"^.

All these results are presented in [8] and [15]. We refer the reader to these two papers for other interesting properties of such map.

The real polynomial on the real fine g{x) = x^ -2x also has an invariant measure absolutely continuous with respect to the one-dimensional Lebesgue measure. This map is conjugated with the map 1 — 2x^.

The family of real polynomials gdx) = 1 - cx^ was analyzed by several authors (see [2] for references).

There exists a value a such that the set A of param­eters c such that the family gc has an absolutely in­variant measure, is contained in (a, 2). The value a is known as the Feigenbaum point[5].

M. Yakobson showed that the set A has positive Lebesgue measure in the set of real parameters[9].

For values of c larger than 2, the critical point goes to 00 under iterations ofgc. In this case the map gc is expanding, and the nonwandering set has a Cantor set structure (see [2]).

It is conjectured that the set of parameters values c, where gc is expanding is dense in (A, 2). An important result about the bifurcation set of the family gc was obtained by Feigenbaum [ 5 ].

The analysis of the family/(z) = z^ - 5z on the plane is a natural extension of the problem considered above for the family gc on the real line. Another natural

Page 92: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

94 ARTUR O. LOPES

1 (a ) s=2 De l to id 1(b) Cardioid

1 (c ) s=C.5 1(d) s=0.5

1 (e ) s=0.5 1 ( f ) s=0.5

Fig. 1. Portraits of dynamics, (a) 5 = 2 Deltoid, (b) Cardioid, (c) s = 0.5, (d) s = 0.5, (e) s = 0.5, (f) s = 0.5.

extension for the plane of the family gc is the family of maps of the form

Vciz) •• + c, cEC.

In this case the bifurcation set is also known as the Mandelbrot set [13].

In recent years several papers on the dynamics of polynomials on the plane appeared in the literature, [1] and [6]. Most of these papers are related to the Henon map[7].

We became interested in the dynamics and the bi­furcation set of the familyX(z) = z^ - 5z because this is related to a model associated with a triple point phase

transition and Yang-Lee zeros. In this model the value s = 2 corresponds to the point of triple point phase transition. Other values of 5 should correspond to dif­ferent external magnetic fields. We will explain more carefully now the physical problem to which our mathematical model is related.

It is well known that certain materials present mag­netic properties at low temperatures. In first order transition, the transition from nonmagnetic state to the magnetic state is noncontinuous. In fact, there exist a certain transition value of the parameter temperature where suddenly the magnetization occurs. For the physics literature on this subject, we refer the reader to [9]. Note that the free energy (or pressure) is con­tinuous with the temperature /. For each t there exist

Page 93: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Dynamics of real polynomials 95

an equilibrium state (sometimes more than one) also known as Gibbs State. Suppose now we decrease the temperature t of a ferromagnetic material. Until we reach a certain transition value to, equilibrium states are unique. For this value to, there exist more than one equilibrium state. This means a discontinuity (in the set of probabilities) of the equilibrium state with the variation of Mn the Ising Model, two equilibrium measures can coexist in the transition temperature (double point transition). In the Potts Model, three equilibrium measures can coexist in the transition temperature (triple point transition).

In [ 11 ] we present a mathematical model for double transition and in [12] we show that/(z) = z - 2f represents a model for triple transition. Suppose now we also want to change the magnetic field and not only the temperature around the bifurcation point of triple transition.

The Yang-Lee zeros appears in the concrete physical problem as the locus of points where coming from very large values of a ''complex'' magnetic field, there exist transition from one equilibrium state to more than one equilibrium state[13]. It is well known that for ex­panding systems equilibrium states are unique [10, 11].

The existence of more than one equilibrium state in "thermodynamic formalism" terms (see [11]) is re­lated with nonexpansive maps. This happens, for in­

stance, for/(z) = z - 2z where for a certain value of the external parameter t, three equilibrium states co­exist.

We will explain now in a more rigorous way what we mean by equilibrium state. Consider a certain fixed map /and Af ( / ) the set of invariant probabilities for / . Consider now t an external parameter {t plays the role of temperature) and for each t we will be interested in finding the probability nt that attains the supremum for the following variational problem:

sup {h(v)-t f log|det(/)/(z))|t/t;(z)}.

We will call the probabilities that attain such supre­mum of equilibrium states. The term h(v) isthe en­tropy oft; (the kinetic energy term) and the term J log # det I Z)(/(z)) I fi?t;(z), is the Liapunov number of the probability v (the potential energy term).

For expanding systems such equilibrium states are unique for every t. Suppose now we decrease the value nn a continuous fashion. For some nonexpanding sys­tems as, for example,/(z) = z^ - 2z (see [12]), there exist a unique equilibrium state nt, until we reach a transition value of parameter t = to where there exist three equilibrium states. This is the phenomena of tri­ple point transition.

2(a) s=1.68 2(b) 5=1.68

2(c) s«-6 2(d) s=1.68

Fig. 2. (a) s = 1.68, (b) s = 1.68, (c) s = -6, (d) s = 1.68.

Page 94: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

96 ARTUR O. LOPES

Now we have to analyze the other parameter 5 E C and consider the maps^ and the equilibrium proba­bilities Ht associated with each of these maps j^(z) = z^ - sz for s close to 2. In a neighbourhood of 2, some of the s are such that fs is expanding and for other values of s the map fs is not expanding. In the first case, equilibrium states nt are unique for all t, and in the second case, perhaps for some values of ^ equilib­rium states are not unique (see [12]).

The natural question is the following: Is there, in the parameter space, 5 E C, an analytical curve rep­resenting the locus of points where there exist the tran­sition from one case (one equilibrium state for every /) to the other case (more than one equilibrium state for some value of 0? In this case we think that different values of s represent different values of ''complex^' magnetic fields.

Using the computer we were able to obtain the car-dioid curve shown in Fig. 1 (b) as the natural candidate to be the Yang-Lee zeros set related to our model.

For values of s close to 2 and outside the cardioid

curve, the system seems to be expanding. The reason is that the critical set goes to infinity (and also geo­metrical aspects observed in the pictures). We refer the reader to [10-12 ] for references related to the Ising and Potts model of statistical mechanics.

Another justification for the study of polynomial and rational maps on the variable z and z is related to convergent algorithms of the Newton type [14].

We will present here several pictures obtained in the computer that we believe are worthwhile for a better understanding of the topological dynamics of such maps. We hope these pictures can stimulate other peo­ple for a rigorous mathematical analysis of the problem. We will present several open questions. The family of such maps presents a very rich dynamics and a certain analogy with real quadratic polynomials in the line.

The critical set of fs is, by definition, the set of points of the plane where the determinant Jacobian of X is zero. This set is the circle of center zero and radius

-— . For values of s such that \\s\\ < 1, the point (0,

-3H'* Hillll , . /

..'"

V Ills....

3(a) s = -1.4 3(b) s=-1.3

-.r ^|ri««««.««««j.r

> [ii

V iillK

Y--..-: 3 ( c ) S=-l 3(d) s = - 0 . 9

i!

!iin!l

!!,.

Ill*

3(e) 5=0.2 3 ( f ) s=0. H

Fig. 3. (a) s = -1.4, (b) s = -1.3, (c) 5 = -1 , (d) 5 = -0.9, (e) s = 0.2, (f) s = 0.4.

Page 95: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Dynamics of real polynomials 97

0) is attracting. For all other values of 5, the point (0, 0) is repelling. For values of 5 with large modulus, the critical set goes to oo under iterations of^.

The nonwandering set in this case has a Cantor set structure as shown in Fig. 4(g) and 4(h).

The set of bifurcation points in the 5-parameter space (coming from oo) is the cardioid with extremes in - 6 an 2, shown in Fig. 1 (b). For values of 5 outside the interior of the cardioid the critical set goes to oo. For values of 5 inside the cardioid, some critical points may not go to 00 under iterations of j ^ .

In Fig. 2(c) we show the picture for s = -6 of the critical set (a small circle), the image of the critical set (a deltoid shape figure) and part of the second image of the critical set (the three curves that are outside the deltoid). This situation is a limit one, for s < -6 the

image of the critical set will not intersect the second image, and for s> -6 the opposite will happen.

The filled-in set offs is, by definition, the set of points z that does not go to oo under iterations offs. In the pictures presented here the filled-in set is always shown with a uniform pattern of dots. The evolution of the filled-in set is shown in the sequence of pictures shown in Fig. 3. For values of 5 larger than 0.3, the filled-in set looks like a delta-wing airplane (see Fig. 1(c)). The boundary of the filled-in set seems to have a fractal nature, but for the value s = 0.5, a closer and closer look shows that this property perhaps is not true. The pictures 1 (d) to 1 (f) show closer and closer views of part of the left side of the "wing."

Open-Problem. Is the boundary of the filled-in set a fractal for values of 5 G R different from 0 and 2?

4(a) s=1.5

^ ^

4(c) s=1.61

4(e) s=1.68

4(g) s=2.2 n=3

K J ^ ^ - ^ : >

f:-'.

4(b) s=1.6

4(d) s=1.64

4 ( f ) s=1.93

4(h) s=2.2 n=4

Fig. 4. (a) 5 = 1.5, (b) 5 = 1.6, (c) 5 = 1.61, (d) 5 = 1.64, (e) s - 1.68, (f) s = 1.93, (g) 5 = 2.2, « = 3, (h) 5 = 2.2, « = 4.

Page 96: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

98 ARTUR O. LOPES

For small values of s (close to zero), the filled-in set is a topological disk. All points in the filled-in set seems to converge to zero. This situation looks similar to the one presented for the complex polynomial family £s{z) = z 2 - 5 z [ 3 ] .

In Fig. 3, we show the evolution of the filled-in set with the changing of the parameter s. For values of 5 with modulus larger than one, a nontrivial attractor appears in the filled-in set. For values of s close to 2, it seems to exist an open region attracting all points of the filled-in set. For 5 = 2, the attractor is equal to the filled-in set.

In Fig. 2(a), we show that for 5 = 1.68, the attracting region is strictly contained in the filled-in set. Attractors here will be shown with a random pattern of dots. Fig­ure 2(b) shows a closer look of the upper-left side of

Fig. 2(a). In Fig. 2(d), we show the critical set, the first and second images of the critical set, and also the filled-in set.

Conjecture. For a set of positive measure of real val­ues of s close to 2, there exist an invariant-measure absolutely continuous with respect to the two-dimen­sional Lebesgue measure.

For values of s between 1 and 1.641, it seems to exist nontrivial attractors with two-dimensional Le­besgue measure zero.

Conjecture. For values of 5 between 1.4 and 1.61, the attractor set has dimension 1.

The evolution of the attractor with the changing of the parameter s is shown in Fig. 4(a) to 4(f). The evolution of part of the attractor for values of 5 between 1.4 and 1.6 is shown in Fig. 6.

r-^-irA

i r.>^

€•'••

5(a) s=1 + 0.178 i 5(b) S'1 -t 0.178 1

5(c) s=1.7 +0.178 1 5(d) s=1 + i

V '•>>, «*" */•> ^?rz.

5(e) s«1.3 +0.178 i 5 ( f ) s « 1.6

Fig. 5. (a) 5 = 1 + 0.178/, (b) 5 = 1 + 0.178/, (c) 5 = 1.7 + 0.178/, (d) 5 = 1 + /, (e) 5 = 1.3 + 0.178/, (f)5=1.6.

Page 97: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Dynamics of real polynomials 99

First the attractor can be a point, but around 5=1.5 looks like a curve that turns out in a distorted hypotro-coid. For larger value of 5 « 1.6, it seems to exist dis­torted circles that attract the points of the filled-in set.

The pictures of Fig. 6 are produced by magnifying part of the attractor. In fact, some of these curves are in an orbit of period 2 (see Fig. 5(f)).

For values of s larger than two, the nonwandering set seems to have a fractal nature and a Cantor-set structure. For s = 2.2 the nonwandering set has an appolonian packing shape (see [4]).

In Fig. 4(g) and 4(h) the shaded areas show the points that remain in a square centered in (0, 0) with size 8 after 3 and 4 iterates, respectively.

Conjecture. For values of s close to 2 and outside the cardioid shown in Fig. 1 (b) the nonwandering set is expanding. Note that Fig. 4(g) and 4(h) seems to indicate the existence of a Cantor set with expanding dynamics. The above question is related with the triple

point phase transition and Yang-Lee zeros problem mentioned in [12].

Suppose now that s - a -\- bi with b different from zero. For small values of ^ a similar pattern of the case ^ = 0 seems to happen.

We followed the evolution of a, with a fixed value oi b = 0.178. For values of a around 1, it seems to exist three points that attract the all filled-in set. It seems to exist invariant curves connecting such points. The attracting periodic points are shown in the points of accumulation of dots in Fig. 5(b). The curves con­necting these points are shown in the accumulation of dots in Fig. 5(a). We believe there exist three other saddle periodic points such that the unstable manifolds of such points are the curves mentioned above.

For larger values of A, a similar situation like the one shown in Fig. 6 happens. For values of a around 1.7 the attractor has dimension two. The heavy dot-line areas in Fig. 5(c) show a much larger frequency

zf i

6(a) s = 1.4

.J

*•

1 6(c) s=1.55

;••. \»

1 ' * '

1 6(e) s=1.59

..J

" v .

6(b) s= 1.5 1

J -^

1 ' i

6(d) s=1.58

^ . = . • :

' "^

6( f ) s= 1.6 1

Fig. 6. (a) s = 1.4, (b) S = 1.5, (c) S = 1.55, (d) S = 1.58, (e) S = 1.59, (f) S = 1.6.

Page 98: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

100 A R T U R O . LOPES

of iterates in some parts of the attractor of the initial point chosen in the fiUed-in set.

We also show the attractor for 5 = 1 + / in Fig. 5(d). The area without dots is probably related with stable manifolds of saddle periodic points mentioned before.

It seems to exist a relation of the attractors with the position of the iterates of the critical set. In Fig. 7(b), we show the critical set, the first and second iterates of the critical set, the fiUed-in set, and some attractors (of the kind in Fig. 6(c)) presented for the value 5 = 1.5 + 0.178/.

Figure 7(a) shows the fiUed-in set, the critical set, the image of the critical set, the attractor, and the po­sition of the four periodic fixed points centered in small

ellipses. Figure 7(d) shows the attractor and the second iterate of the critical set. Figure 7(e) shows the attractor, the critical set, and the first and second iterates of the critical set.

3. AN X-TRANGE ATTRACTOR

In Fig. 8(d) we show the attractor set for^ when s = 1 + 1.05/. The attractor has the shape of the letter X. We also show in Fig. 8 other kind of attractors for values of s very close to s = 1 + /. This value is a bifurcation parameter for the family, as it is shown in Fig. 8(b), 8(c), and 8(d).

In Fig. 8(a), the two line segments are in an orbit of period 2. The other X-trange attractor has period 1.

Fig. 7. (a) S = 1.68, (b) 5 = 1.5 + 0.178/, (c) 5 = 1.55 + 0.178/, (d) s = 1.55 + 0.178/, (e) 5 = 1.7 + 0.178/.

Page 99: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Dynamics of real polynomials 101

8 ( a ) s= 1 + i 8 (b ) s= 1 + 0.95 i

8 ( c ) s= 1.07 + i 8 (d ) s = 1 -»• 1 .05 1

Fig. 8. (a) 5= 1 - f / , ( b ) 5 = 1 +0 .95/ , (c )5= 1.07 + / , ( d ) 5 = 1 + 1.05/.

Acknowledgement—I would like to thank C. Leme for assis­tance in plotting the pictures presented in this paper.

REFERENCES 1. E. Bedford and J. Smillie, Polynomial difFeomorphisms

of C^: Currents, equilibrium measures and hyperbolicity Inventiones Math. 87 (1990).

2. P. Collet and J. Eckmann, Iterated Maps on the Interval as Dynamical System, Birkhauser, Basel (1980).

3. A. Douady and J. Hubbard, On the dynamics of poly­nomial-like mappings. Ann. Sci. Ecole. Norm. Sup. (4), 118,287-343(1985).

4. K. J. Falconer, The Geometry of Fractal Sets, Cambridge University Press, (1985).

5. M. Feigenbaum, Quantitative universality for a class of nonlinear transformations. /. Stat. Phys. 19, 25-52 (1978).

6. S. Friedland and J. Milnor, Dynamical properties of plane polynomial automorphisms. Ergodic Theory Dynamical Systems 9, 61-99(19^9)'

7. M. Henon, A two dimensional mapping with a strange attractor. Comm. Math. Phys. 50, 69-77 (1976).

8. M. E. Hoffman and W. D. Withers, Generalized Che-byshev polynomials associated with affine Weyl groups Trans. AMS, 308(1), 91-104 (1988).

9. A. Lopes, A first order level 2 phase transition in ther­modynamic formalism. / Stat. Phys. 60(3/4), 395-411 (1990).

10. A. O. Lopes, The dimension spectrum of the maximal measure, SIAM J. Math. Anal. 20(N5), 1243-1254 (1989).

11. A. O. Lopes, Dimension spectra and a mathematical model for phase transition. Adv. Appl. Math. 11(4), 475-502(1990).

12. A. O. Lopes, Dynamics of real polynomials on the plane and triple point phase transition. Math. Comput. Mod­elling, n(9\ 17-32(1990).

13. H. Peitgen and P. Richter, The Beauty of Fractals, Springer, Berlin, (1986).

14. M. Shub and S. Smale, On the existence of generally con­vergent algorithms.

15. W. D. Withers, Folding polynomials and their dynamics. Amer. Math. Monthly 95i'N5), 399-413 (1988).

Page 100: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 103

Chaos and Graphics

PHASE PORTRAITS FOR PARAMETRICALLY EXCITED PENDULA: AN EXERCISE IN MULTIDIMENSIONAL

DATA VISUALISATION

DAVID POTTINGER,* STEPHEN TODD and IAIN RODRIGUES IBM UK Scientific Centre, Athelstan House, St. Clement Street, Winchester S023 9DR, UK

and

TOM MULLIN and ANNE SKELDON Clarendon Laboratory, Parks Road, Oxford OXl 3PU, UK

Abstract—Data visualisation techniques are used to investigate the five dimensional phase space of a system of two pendula excited by an oscillatory force. A sequence of phase portraits is obtained that vividly illustrates the system undergoing a bifurcation as the frequency of the excitation is varied in a certain range. Such pictures provide valuable information on the topological transformations that the system undergoes as it approaches chaotic motion. This data visualisation method can also be applied to other multidimensional problems where a phase portrait analysis is helpful.

1. INTRODUCTION

It is becoming increasingly apparent that even relatively simple nonlinear dynamical systems can display an unexpectedly broad range of effects, including insta­bilities, bifurcations, and chaos[l, 2]. Due to their complexity, the mechanisms responsible for some of these effects are still not fully understood. Thus, there is great interest in studying model dynamical systems, with the aim of clarifying the role and relevance of typical nonlinear effects, e.g., the transition to chaos.

Recently, a detailed analytical and numerical study [ 3 ] of a familiar but still incompletely understood nonlinear system, a pair of pendula excited by an os­cillatory force, has been carried out. It is very useful to have a visual representation of these results as non­linear effects often have an illuminating geometrical interpretation. A very general way of doing this is by constructing 3. phase portrait. The examination of phase portraits can help understand how solutions evolve as an external parameter is changed. In turn, this can aid understanding of the mechanisms that give rise, for example, to chaos.

This provided the motivation for a joint project be­tween the Nonlinear Systems Group at the Clarendon Laboratory and the IBM European Data Visualisation Group at the IBM UK Scientific Centre. The aim was to develop methods for producing high quality phase portraits using the advanced (experimental) 3D com­puter graphics and data base facilities that have been developed at the Centre.

Finally, it is worth mentioning that the pendulum problem is also relevant from another point of view, as it provides an interesting example of multidimen­sional data visualisation. The visualisation methods used for the pendulum system are rather general and thus may also be applied to problems in other fields

* Present address: AEA Petroleum Services, Winfrith, Dor­set DT2 8DH, UK.

where phase portraits can be very helpful, e.g., control theory.

2. THE SYSTEM OF PARAMETRICALLY EXCITED P E N D U L A

The double pendulum consists of two rods, one sus­pended from the other in such a way that they may only swing in orthogonal directions (see Fig. 1). Such a system has two possible types of pure mode oscilla­tion. One of these modes involves the whole pendulum swinging as a rigid body about the top pivot point and the other has just the bottom pendulum swinging. The equations of motion for this system may be derived using a Lagrangian classical mechanics approach and damping can be added. The parametric excitation moves the top pivot point of the pendulum up and down sinusoidally and may be included in the equa­tions by considering a frame of reference in which the gravitational field, instead of taking the constant value g, varies sinusoidally about g. The result is five first order autonomous differential equations: two describ­ing how the angular positions of the rods vary with time; two describing how the angular velocities of the rods vary with time and one for the sinusoidal exci­tation.

The numerical study of the nonlinear equations in­volved the use of path following techniques[ 4, and Technical Note 1] to find where changes of stability of solutions occur as a function of the control parameters. These critical points are known as bifurcations and indicate where there is a transition from one type of behaviour to another [ 1, 2, 5 ]. Both stable and unstable solutions may be followed using these methods. In this way a number of different regions are found: regions where there is no side-to-side motion of the pendulum; regions where either one mode or the other is excited and areas of composite in phase motion of the pen­dulums. A particularly interesting part of the control plane is found where no stable regular solutions can be found using these techniques. A stable solution

Reprinted from Comput. & Graphics Vol. 16, No. 3, pag. 331-337, 1992

Page 101: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

104 DAVID POTTINGER et al.

must, of course, exist in this region, but they are pre­sumably too compHcated for the path following meth­ods to deal with. Therefore, in order to look at such regions a direct numerical integration of the equations of motion was carried out.

The numerical integration started from an arbitrary set of initial conditions and ultimately converged onto a stable solution, an attractor. There will be a transient phase associated with this convergence and we must integrate for a sufficiently long time to allow this tran­sient to die out in order to observe the correct final solution. Typically, for the value of the damping cho­sen, this takes around 30 cycles of the excite. In the chaotic regime we integrated over several hundred cy­cles to be sure that the transients had decayed. A further complication that may arise is there can be more than one solution for the same parameter values. Some of these solutions may be stable and some unstable. Un­like the path following methods, numerical integration will not detect unstable solutions. Although these so­lutions would not be observable in an experiment ei­ther, they can play an important role in determining the dynamics. Thus, a combination of both numerical approaches must be used to make a complete study of the solution set.

In the pendulum problem there are five first order differential equations so these numerical integrations produce a set of five values for successive points in time, as detailed above. Thus, each set gives the co­ordinates of a point in the space spanned by the two angles, their velocities and the excitation coordinate {i\\t phase space of the system). When successive points in time are joined up, the result is a curve or trajectory in this phase space and this gives a picture of the motion of the pendulum. For example, if the pendulum is simply moving up and down with the excitation then the picture obtained is just a line along the excitation axis, all other coordinates are zero. If we have a pure mode solution then one of the angles and its associated angular velocity are zero, whereas the other angle and its velocity vary sinusoidally, in phase with the exci­tation.

The pendulum repeats its motion exactly once every period T, where T'ls twice the period of the sinusoidal excitation. The corresponding phase picture is a loop passing through three of the five dimensions. Every time the pendulum goes through one oscillation the corresponding phase space point passes once around the loop. If both rods are oscillating in phase, the result is again a periodic attractor and the phase portrait is again a loop, but one which now passes through all five dimensions. If both pendulums oscillate, but the phase between them varies, then the trajectory sits on a torus (a doughnut shaped ring). As stated above, such a motion may be described by two frequencies. These are represented on the torus as the frequency of the motion around the hole of the torus and the fre­quency of the motion around the arm of the torus. If the two frequencies are not rationally related then the motion is quasiperiodic. The examination of phase portraits can help understand how the solutions evolve

as an external parameter is changed. In turn this can aid ones understanding of the mechanisms which give rise to chaotic motion.

Experimentally there has also been the development of phase portrait reconstruction techniques [6 ]. These methods reconstruct a phase portrait from a single time series and are proving invaluable in showing connec­tions between theoretical and experimental work in hydrodynamic stability [ 7 ].

3. COMPUTER GRAPHICS AND DATABASE TECHNIQUES

As a result of the numerical investigations, it is clear that a tool is required for the efficient processing of the resulting data. Here we describe a method for doing this centered on the use of a data base and graphics system linked by a bridge. In this approach, a user asks queries about his data and the result is displayed as a picture. For these exploratory purposes, the pictures generated can be rather crude, e.g., wire-frame repre­sentations. However, because of this, they are quick to generate (of the order of seconds) and can also be in­teracted with {e.g., rotated, zoomed, etc.) in real time (with the appropriate equipment). This data explo­ration process may be iterated until the user is satisfied with the final result. The final image can then be gen­erated using a presentation software package, which is more suitable for education or publication purposes. This method has shown itself to be an extremely pow­erful tool for visualising systems involving large amounts of data, such as those encountered in chem­istry. The specific system developed at the IBM UK Scientific Centre is known as WGS (Winchester Graphics System)[8], and its general structure is given in Fig. 2.

The data base holds the data and manipulates it according to user queries. The bridge takes the results of these queries and interprets them to draw a picture: Each row in the result of a query is mapped to one graphics primitive. The graphics displays the picture and lets the user interact with it. The driver takes user commands and routes them to the appropriate sub­system.

For the pendulum problem, the data consists of the values of the five phase space variables at successive time intervals. The typical number of time slices in the data files is about 6,000. The first task is to use the database to select which time slices to display. The full power of the database is not as important in this ap­plication as in many, and usually a complete file is used. It is sometimes useful to declutter the result by choosing only every nth time slice, or a range of time slices, or slices for which the coordinates lay within (or without) particular ranges.

As the system is five dimensional, one then needs to choose which three coordinates are to be used to construct the geometry of a picture, whether other co­ordinates should be used to control graphics attributes such as colour and line type, and, if so, what mapping from coordinate to attribute should be used. When this has been done, one issues a command that is in-

Page 102: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Phase portraits for parametrically excited pendula 105

driver-

bridge

data base

graphics

Fig. 2. The Winchester Graphics System.

Fig. 1. Snapshot of a double pendulum in motion (taken from video).

Fig. 3. Wire-frame image of two toroidal attractors.

Fig. 4. Before the bifurcation. Excitation frequency = 590 (in appropriate units).

Fig. 5. Before the bifurcation. Excitation frequency = 560 (in appropriate units).

terpreted by bridge as (a) joining up successive points (in the chosen three dimensions) and (b) using graphics to display the corresponding image onto a VDU. This process produces a wire-frame image, such as that in Eig. 3.

This figure corresponds to a 3D phase portrait of the double torus attractor. This picture has the follow­ing interpretation. Each pendulum oscillates at a slightly different frequency. The trajectory winds first

Fig. 6. Before the bifurcation. Excitation frequency = 530 (in appropriate units).

around one torus and then around the other. On one torus the pendulums oscillate almost in phase, and around the other in near anti-phase.

Such a picture is quick to generate and can be in­teractively rotated, zoomed, etc., in order to obtain a reasonable understanding of its three dimensional structure. However, whilst the overall shape is appar-

Page 103: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

106 DAVID POTTINGER et al.

Fig. 7. After the biftircation. Excitation frequency = 520 (in appropriate units).

Fig. 8. After the biftircation. Excitation ft-equency = 515 (in appropriate units).

Fig. 9. Before the bifurcation. Excitation frequency = 560 (in appropriate units). The colouring indicates the magnitude of

the second angular velocity.

Fig. 10. Before the bifurcation. Excitation frequency = 530 (in appropriate units). The colouring indicates the magnitude

of the second angular velocity.

Fig. 11. After the bifurcation. Excitation frequency = 520 (in appropriate units). The colouring indicates the magnitude of

the second angular velocity.

Fig. 12. After the bifurcation. Excitation frequency = 515 (in appropriate units). The colouring indicates the magnitude of

the second angular velocity.

Page 104: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Phase portraits for parametrically excited pendula 107

ent, important details are confused and misleading due to the overlap in the trajectories. For instance, it is difficult to distinguish between the back and the front of the image (although this can be partially overcome via interactive slicing along the z-axis). Moreover, a choice of projection can often introduce spurious in­tersections. This is analogous to the impossibility of drawing a knot on a piece of paper without any cross­ings. The problem of spurious intersections is made particularly difficult in the pendulum problem because the attractor sits in a five-dimensional space.

The visualisation problems just mentioned can be overcome by making a (more realistic) solid model of the "object." This was carried out using an experi­mental 3D computer graphics program known as WINSOM (WINchester SOlid Modeller)[9, see also Technical Note 2 ]. It is an example of a graphics system built on Constructive Solid Geometry (CSG)[10]. In this approach to 3D graphics, objects are defined as sets of points and the standard set-theoretic operations of union, difference, and intersection can be used to create new, more complex objects. WINSOM has a large set of basic shapes (primitives) that can be "called," e.g., sphere, cylinder, etc. For example, if one wants to draw a (piecewise-constant) continuous curve from an ordered set of points, one writes something like:

let curve = (cylinder (r, point2) at point 1) union (cylinder (r, point3) at point 2) union

(cylinder (r, pointn) at point (n + 1)); draw curve;

where r is the radius of the solid cylinder and the rest is hopefully self-explanatory. If a smoother curve is required, one can insert a sphere (of radius r) between every pair of cylinders.

This simple approach was applied to the pendula data. Thus, after a choice of projection, each 3D point became the centre of a sphere, and successive spheres were then unioned with a cylinder to give a smoothed out 3D solid segment. This process was repeated, point by point, until the end of the numerically determined trajectory was obtained. The radius was given a value such that there were no holes or gaps in the resulting solid object. This simulated, in a plausible way, the effect of including the extra data one would have ob­tained if one had computed even more points on the trajectory. A typical file contained about 25,000 graphics primitives.

The generation of the WINSOM files is performed by the same data base to graphics bridge program that constructs the initial interactive displays. The bridge is given an extra option requesting WINSOM output, and told what radius to give to the generated cylinders and spheres. This radius is usually constant over a complete picture, but may be derived from the data base coordinates if required. The bridge first displays an interactive version of the picture, which the user manipulates to find a good viewpoint. The WINSOM model file is then written, complete with this view in­formation.

Within WINSOM, there are also sophisticated fa­cilities for introducing a large range of effects to increase visual realism; these include highlighting, shading, multiple light sources, surface qualities (such as gloss), as well as perspective [11]. Such features are necessary if one wishes to obtain a convincing 3D "feel" to im­ages, thereby aiding the interpretation process.

In addition, this work has also motivated the de­velopment of more specialist graphics techniques to produce improved images of chaotic trajectories and of experimental data[7]. These methods have been extremely useful in highlighting the three dimensional structures obtained from fluid flow experiments and helped establish connection with finite dimensional models.

4. VISUALISATION AND INTERPRETATION OF THE 3D PHASE PORTRAITS

We now present the results of using WINSOM in the manner described above to create phase portraits for the pendulum system. The projection is obtained by picking three out of the five coordinates and plotting only these. As long as we pick a combination involving either the position or velocity of the top angle, and one relating to either the position or velocity of the bottom pendulum we should obtain a portrait that contains the most important features of the motion of the system. Different projections should show quali­tatively the same behaviour. For Figs. 4 to 12, the co­ordinates chosen are the top angle and its angular ve­locity and the bottom angle. The projection is chosen in this way to make the interpretation of the portraits easier. A brief, popular account of some of the following results can be found in [12].

4.1. The basic bifurcation sequence Firstly we show a sequence of portraits of two sep­

arate attractors colliding to form a single attractor (Figs. 4-8). The start of the sequence (Fig. 4) shows two separate tori coloured in different colours to indicate that they are distinct, i.e., they are separate solutions to the equations that occur for the same parameter values. The particular version obtained in the numer­ical simulation is dependent on the starting conditions. Each torus represents both pendulums swinging, but at a constantly changing phase to each other. The equations are invariant under reflection through an axis and this symmetry is apparent in these attractors.

Notice that each torus has two twists in it. The two separate attractors appear to intersect, but this is an artifact of the particular projection, as in the fufl five dimensional space it is known that there are no inter­sections [1,2]. For these two tori, although the attrac­tors sit in five dimensions it is clear that the projection onto two dimensions with some idea of a third di­mension through the use of WINSOM gives a good indication of the behaviour of each single attractor. We now investigate how these attractors evolve as we decrease the excitation frequency. Figures 5 and 6 con­tain portraits for successively lower excitation fre­quencies. They show that although these two tori are still two distinct attractors, the angle between them has become smaller and smaller and there is a thickening

Page 105: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

108 DAVID POTTINGER et al.

of the tori on one side. This corresponds to the pen­dulum spending more time in states along this edge. This thickening is interesting as it shows the presence of a saddle periodic orbit sitting between the two tori. A saddle orbit is attracting in some directions but re­pelling in others. This means that a numerical inte­gration may approach such a solution from the stable directions but will ultimately head away along the re­pelling directions.

When the frequency is reduced further, the two tori join to become one attractor as shown in Fig. 7. The trajectories have spent longer and longer on the thick­ened edge of the torus until the tori actually touch along this edge. The exact point where this occurs is very difficult to observe numerically or experimentally as it is structurally unstable and hence, any small change in the external parameters causes a topological change in the attractor. However, key indications of the presence of such an orbit are the very long time to pass once around the surface, and the trajectory spending a particularly long part of this time close to a fixed point or periodic orbit. In our case, this is the saddle periodic orbit mentioned above. This type of behaviour is known as a homoclinic connection[ 1,2]. If the excitation frequency is reduced further (Fig. 8) then this single attractor loses the rib or thickening, which was a sign of the homoclinicity.

Notice also that the twists in the original tori are essential to facilitate the sticking together process. The twisting allows one edge of one torus to stick to one edge of the other. The end result is still a torus (it can still be described by two frequencies), but one that is twisted in such a way that it cannot be observed without intersection in three-dimensions. Such a sequence of events is called a gluing bifurcation[ 13]: gluing because two separate attractors have been stuck together; bi­furcation because the number of distinct solutions has changed.

This sequence has also been investigated using a dif­ferent projection. The projection is again chosen by picking three of the five coordinates, this time these coordinates being the top angle, the bottom angle and its angular velocity. The sequence shows the same pat­tern of events, but this time the homoclinic thickening appears on the "inner" rather than the "outer" edge[14].

4.2. The bifurcation sequence in more detail It is clearly of interest to try to incorporate some

information about the behaviour of the system in the other two dimensions. This can be achieved, to a cer­tain degree, by incorporating colour. One way of doing this is to give a point on the surface a colour whose "value" is related to the corresponding value of the chosen variable. Obviously, this use of colour is mo­tivated by scientific rather than aesthetic considera­tions, and its practical usefulness should be interpreted in this light.

The results are shown in Figs. 9-12, which are re­finements of Figs. 5-8. The three coordinates projected onto the screen are the two angles defining the position of the pendulum and the velocity of the top pendulum. The colouring on the attractors represents the mag­

nitude of the velocity of the lower pendulum. For the first picture in the sequence the red-yellow torus is red where the velocity is smallest. We see that the torus has two bands of red. These patches represent the two points in one swing of the pendulum when the velocity goes through zero and the pendulum changes direction. For the blue-green torus, green plays a similar role to the red.

As the external parameter (the frequency) is changed and the two tori approach, we see that the rib that develops has a "slow" tinge to it. This becomes more pronounced as we get closer and closer to the touching of the two separate attractors. It therefore indicates that along this edge the attractors are approaching an orbit where the velocity of the bottom pendulum is zero and only the top angle varies. In a physical real­isation, we would observe the pendulum oscillating for a long period with just the top angle varying, and hence the whole pendulum swinging about the top pivot as a solid body. During this time the bottom angle and velocity would be almost zero. Then over a short time the bottom pendulum would begin to swing with larger and larger amplitude and then equally rapidly these oscillations would die away again and the motion would return to only the top angle varying. As the parameters are varied so that the system passes through the gluing bifurcation we see that this slowing down is associated with the ribbing and that as the rib is lost the slow colour along the edge is also lost.

Finally, a computer-generated movie of this inter­esting bifurcation effect has also been made [15] and is available on request. It shows, in detail, how (by an animation in time) a phase portrait is generated and also (by an animation in frequency) how the attractors come together and join.

If the external parameter is changed further, the smooth surface breaks up as the motion of the pen­dulum becomes chaotic. Figure 13 shows a Poincare

eSx. \

\

so

Fig. 13. Poincare Cross Section (non-chaotic motion).

Page 106: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Phase portraits for parametrically excited pendula 109

•.•.•:\;:v.

• " ''. ••' ••••/^•:'».:..-..\*«>r"".-.

Fig. 14. Poincare Cross Section (chaotic motion).

crossection through an attractor. This contrasts with a similar section shown in Fig. 14 of the attractor once the system has become chaotic. The chaos appears via the mechanism oi torus doubling and is the subject of current study [16]. In this regime, our visualisation methods no longer apply and new techniques need to be introduced.

5. CONCLUSIONS We have used a graphics/data base system to in­

vestigate the behaviour of two coupled pendula excited by an oscillatory force (whose frequency may be varied) by constructing phase portraits. An interactive wire­frame facility was used to search for interesting data configurations, and solid computer graphics were used to generate high quality images. In this way, a vivid visualisation of a bifurcation process in this system was obtained: two attractors joining into one at a cer­tain value of the excitation frequency. Such pictures give valuable insight into the topological transforma­tions that the sy^em undergoes before chaos sets in. In addition, by using colour to mimic the effect of a fourth dimension, an improved understanding of the bifurcation process could also be given. For instance, the interpretation of the "lip" around the edge of the two separate attractors as they approach each other was clarified.

The visualisation techniques that we have developed are rather general and could also be applied to practical problems in other areas, such as multivariable control theory, where phase space studies have a useful role to play.

Two outstanding challenges remain for the future. One is to devise methods for visualising the behaviour of the pendulum system when in its chaotic phase. In this case, the graphics techniques need to take into account that the geometry may be fractal in nature. The other is the development of practical methods for

visualising multidimensional systems. One possibility that is currently being investigated is the use of texture mappings to represent five dimensional systems [17]. Another is the implementation of real-time rotation of n-dimensional objects (n > 3), with real-time as­signment of graphics attributes [18].

Acknowledgements—A.S. is grateful to the Leathersellers Guild for their Scholarship. A.S. and T.M. acknowledge the support of the S.E.R.C. through the "Nonlinear Initiative."

REFERENCES 1. J. M. T. Thompson and H. B. Stewart, Nonlinear Dy­

namics and Chaos, John Wiley, New York (1988). 2. J. Guckenheimer and P. Holmes, Nonlinear Oscillations,

Dynamical Systems, and Bifurcations of Vector Fields, Springer, Berlin (1983).

3. A. C. Skddion, Bifurcations and chaos in a parametrically excited double pendulum. Doctoral thesis, Oxford Uni­versity (1990).

4. H. B. Keller, Numerical solutions of bifurcation and nonlinear eigenvalue problems. In Applications of bifur­cation theory, P. H. Rabinowitz (Ed.), Academic Press, New York, 359-384(1977).

5. G. looss and D. D. Joseph, Elementary Stability and Bi­furcation Theory, Springer, Berlin (1980).

6. D, S. Broomhead and G. King, Extracting qualitative dy­namics from experimental data. Physica D20, 217-235 (1986).

7. T. Mullin and T. J. Price, Nature M^, 294-296 (1989). 8. T. R. Heywood, B. N. Galton, J. Gillett, A. J. Morffew,

P. Quarendon, S. J. P. Todd and W. V. Wright, The Winchester graphics system: a technical overview, Com­puter Graphics Forum 3, North Holland, Amsterdam 6l~ 70(1984).

9. J. M. Burridge et al., The WINSOM solid modeller and its application to data visualisation, IBM Systems Journal, 28,548-568(1989).

10. M. Mantyla, An introduction to solid modelling. Computer Science Press, Rockville, MD (1988).

11. P. Burger and D. Gillies, Interactive Computer Graphics, Addison-Wesley, Reading, MA (1989).

12. T. Mullin, D. E. L. Pottinger and A. Skeldon, The Five-Dimensional Pendulum Picture Show, New Scientist, 1689, 46-47 (1989) and Front Cover.

13. J. M. Gambaudo, P. Glendinning and C. Tresser, Stable cycles with complicated structures. J. Phys. Lett. 46, 653-658(1985).

14. T. Mullin, D. E. L. Pottinger, and A. C. Skeldon, The five-dimensional pendulum picture show. A vv Scientist 1689,46-47 (1989). Reprinted in The New Scientist Guide to Chaos, N. Hall (Ed.), Penguin, London, 53-55 (1991).

15. D. E. L. Pottinger, I. Rodrigues and P. Quarendon, Pen­dula in Motion (IBM UKSC Video (1989).

16. A. C. Skeldon and T. Mullin, Mode interaction in a double pendulum. Phys. Lett. A (in press).

17. D. E. L. Pottinger, Texture and multidimensional data visualisation (in preparation).

18. S. J. P. Todd, Terminal for Real-Time Viewing of Mul­tidimensional Data, IBM Technical Disclosure Bulletin 33(3a), 202-204. (August 1990).

TECHNICAL NOTES

1. The path following was carried out using AUTO, a software package produced by Professor E. Doedel currently at Concordia University, Montreal, Can­ada.

2. WGS and WINSOM may be run on an IBM main­frame operating under VM/SP/CMS or VM/XA in 370 compatibility mode. The resulting WINSOM images may be displayed on an IBM 5080, or the more powerful IBM 6090, graphics workstation.

Page 107: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 111

Chaos and Graphics

SELF-REFERENCE AND PARADOX IN TWO AND THREE DIMENSIONS

PATRICK GRIM, GARY MAR, MATTHEW NEIGER, and PAUL ST. DENIS Group for Logic and Formal Semantics, Department of Philosophy, SUNY at Stony Brook,

Stony Brook, NY 11794

Abstract—The Liar paradox is a familiar sentence that asserts its own falsehood. Just slightly less familiar is the Dualist, involving a pair of mutually referential sentences. Here we consider variations on the Dualist and Triplist, modelling their dynamical semantics using iteration within an infinite-valued logic. Strange attractors and fractal escape-time diagrams appear in two dimensions for the Dualist and in three dimensions for the Triplist.

The Liar paradox is a self-referential sentence that as­serts its own falsity:

This sentence is false.

Its semantical dynamics are familiar to everyone who has ever had the misfortune of having been 10 years old: if true, it must be false, but if false, it must be true. Modelling "true" and "false" as 1 and 0, the dynamical semantics of the Liar is a simple oscillation between 0 and 1.

Just slightly less familiar is the Dualist, which in­volves not one sentence but two:

X: Sentence Y is false. F: Sentence X is true.

In this paper we focus on some variations of the Dualist conceived in an infinite-valued logic, in which sentences are allowed to take on any real truth-value in the [0, 1] interval. The dynamical semantics of self-reference can be mapped using iterated algorithms.

Consider for example:

X\ X is as false as Y is true. Y\ Y is as true as X is.

Given any pair of initial estimated values for X and y, these sentences force us to a pair of revised values. With those revised estimates in hand, however, we are forced to a further pair of revised estimates, and so on. As outlined in [1-3], the dynamical semantics of this variation on the Dualist can be modelled using the following algorithms:

x„+i = 1 - abs((l - yn) - x„)

j;„+, = 1 - abs(x„ - y„)

Plotted two-dimensionally, these give us a series of revised values (x, y) confined to the unit square above X = 1 — y. When we plot an escape-time diagram for these points—mapping the number of iterations re­quired for X and y to reach a certain "distance" from (0,0), or pure falsehood for both sentences—we obtain

the delicate fractal image shown in Fig. 1. (For this and all following images we use an escape distance of 1.03 from the origin.)

Here our image has been confined to the unit square, reflecting the fact that semantic values for X and Y within our logic are confined to the [0, 1] interval. Formally, however, this image is merely the central section of a larger one, shown for values between — 1.4 and +2.4 in Fig. 2.

If we replace x„ in the second algorithm above with x„+i, reflecting merely a sequential rather than simul­taneous pattern of reasoning, we get the attractor and escape-time diagram shown in Figs. 3 and 4.

Beyond the Dualist lies the Triplist. Consider for example a Triplist variation in which each of three sentences asserts that it is half as true as the difference between the other two. Using a sequential pattern of reasoning, the dynamical semantics of revised estimates for this triad of sentences can be modelled in our logic using the following algorithms:

Xn+\ = 1 - abs(.5*abs(y„ - z„) - x„)

y„+i = 1 - abs(.5*abs(x„+i - z„) - y„)

z„+i = 1 - abs(.5*abs(x„+i - y„+i) - z„)

These give us an attractor we call the Minerva. Two stages of its development are shown in two dimensions in Figs. 5 and 6 (for initial input .6, .7, .6). A simpler form is rotated in three dimensions in Fig. 7.

A further variation of the Triplist, in which each of three sentences asserts that it is .25 as true as the dif­ference between the other two, gives us the attractor shown in two dimensions in Fig. 8 (for initial input .611, .789, .611) and rotated in three dimensions in Fig. 9.

For the Dualist above we went from attractors to escape-time diagrams. For Triplist variations we can similarly go on to construct escape-time solids, in which each point of a three-dimensional area is colored in terms of how many iterations are required for the initial set of values (x, y, z) it represents to reach a certain distance from (0,0,0) under iteration. Figures 10 and 11 show two views of an escape-time solid for the first

Reprinted from Comput. & Graphics Vol. 17, No. 5, pag. 609-612, 1993

Page 108: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fig. 1. Chaotic Dualist escape-time diagram, unit square.

Fig. 4. Chaotic Dualist variation, escape-time diagram.

Fig. 2. Chaotic Dualist escape-time diagram, expanded.

Fig. 5. Minerva attractor in two dimensions, early develop­ment.

Fig. 3. Attractor for Chaotic Dualist variation, overlay using initial values {x, y) in increments of .05. Fig. 6. Minerva attractor, later development.

112

Page 109: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fig. 7. Minerva attractor in three dimensions.

Fig. 8. Attractor for Triplist variation in two dimensions.

Fig. 9. Attractor for Triplist variation in three dimensions.

Fig. 10. Minerva escape-time solid at 0°. Fig. 11. Minerva escape-time solid at -55°

113

Page 110: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

114 p. GRIM, G. MAR, M. NEIGER and P. ST. DENIS

Fig. 12. Triplist variation escape-time solid at 0°.

Triplist variation offered above; Figs. 12 and 13 show two views of an escape-time solid for the second Triplist variation above.

The background logic of these images of course has its own points of interest, and suggests both further variations and a range of intriguing applications. These issues are more fully treated in the references. Here we have tried to concentrate briefly on the images them­selves.

All images were produced with the simplest possible equipment: programs are in basic on low-end PCs, with images captured and printed on a laser printer or taken directly from the monitor using a 35 mm camera.

Fig. 13. Triplist variation escape-time solid at 20°.

REFERENCES P. Grim and G. Mar. Chaos, fractals, and the semantics of paradox. Research Report 91-01, Group for Logic and Formal Semantics, Department of Philosophy, SUNY at Stony Brook (1991). P. Grim and G. Mar. Paradox and chaotic dynamical semantics. Association for Symbolic Logic, Carnegie-Melon. Abstract / Symbolic Logic 57, 358 (1992). P. Grim. Self-reference and chaos in fuzzy logic. IEEE Transactions on Fuzzy Systems (in press). G. Mar and P. Grim. Paradox, randomness, and chaotic dynamical semantics. Association for Symbolic Logic, San Francisco. Abstract, Journal of Symbolic Logic, 57, 369 (1992). G. Mar and P. Grim. Pattern and chaos: New images in the semantics of paradox. Nous, XXV, 659-693 (1991). 1. Stewart. A partly true story. Mathematical Recreations, Scientific American, 268, 110-112 (1993).

Page 111: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 115

Chaos and Graphics

VISUALIZING THE EFFECTS OF FILTERING CHAOTIC SIGNALS

MICHAEL T. ROSENSTEIN^ and JAMES J. COLLINS NeuroMuscular Research Center and Department of Biomedical Engineering, Boston University, 44

Cummington Street, Boston, MA 02215, USA

Abstract—It is well-known that filtered chaotic signals can exhibit increases in observed fractal dimension. However, there is still insufficient knowledge regarding the underlying causes of this phenomenon. We provide further insight into this problem through the use of computer animations and three-dimensional ray-tracings. Specifically, we show that lowpass filters can induce a nonuniform convergence to a dynamical system's mean state-space location. With chaotic attractors, this convergence distorts the attractor's normal geometrical configuration such that the observed system acquires increased dimensionality.

1. INTRODUCTION

Since the early 1980s, the field of chaos has enjoyed a remarkable growth in popularity. With origins pri­marily in physics and mathematics, chaos has gained the attention of researchers from largely disparate dis­ciplines {e.g., physiology, communications, econom­ics). Unfortunately, this popularity has not been free of undesired side effects. Some experimentalists, for instance, use the tools (/.e, numerical algorithms) of chaos without familiarity of their theoretical limita­tions. (See[1,2] for examples of potential problems.) For this reason, a great deal of recent dynamical-sys­tems research has focused on the practical use of nu­merical algorithms for examining systems suspected of displaying chaos.

Since experimentally obtained data are usually fil­tered (possibly unintentionally), one should be aware of the effects of filtering chaotic signals. Although, sev­eral research groups [3-6] showed that lowpass filters can increase the observed fractal dimension of a chaotic system, there is still insufficient understanding of this phenomenon.* Hence, this paper provides further in­sight into the mechanisms underlying the effects of fil­tering chaotic signals. In particular, we show that the dimension increase results from a nonuniform scaling of the observed system's geometry. With this purpose in mind, we found data visualization via three-dimen­sional ray-tracings to be an intuitive and effective re­source.

2. SIGNAL GENERATION AND PROCESSING

For the examples presented in Section 4, we per­formed numerical experiments using the Lorenz at-

^ Present address: Dynamical Research, 15 Pecunit Street, Canton, MA 02021, USA.

* When estimating fractal dimension, one typically evaluates a relevant quantity {e.g., the correlation sum[7]) over a spec­ified range of length scales. With lowpass-filtered data, an in­crease in observed dimension is apparent over length scales dominated by the chaotic signal. However, on length scales dominated by noise, one may actually observe a decrease in fractal dimension.

tractor[8], which is defined by the following three coupled differential equations:

X = (7{y - x)

y = x{R - z)- y

z = xy — bz.

In order to examine the Lorenz system in the chaotic regime, we chose parameter values of a = 16.0, R = 45.92, b = 4.0. The differential equations were solved numerically using a fourth-order Runge-Kutta inte­gration with a step size equal to 0.005 s; the numerical integration was calculated from an arbitrary initial condition, and a sufficient number of transient points were discarded. Finally, three 1275-point time series (one for each of the x-, y-, and z-coordinates) were generated for subsequent processing.

Signal processing consisted of lowpass filtering the time series using a first-order {i.e., single-pole) filter with the following impulse response {h):

h[n] = a"' u[n],

where a is the filter parameter (0 < ^ < 1), w is the unit step function, and n represents discrete time. To force the DC gain to unity, the filter was implemented as the difference equation

y[n] = a- y[n - 1] + (1 - a)'x[n],

where x is the input and y is the output. (The term 1 — a divides the z-transform of /z[«] by the sum of its coefficients, \ -\- a + a^ -^ a^ + • • '.) Notice that y[n] depends upon previously computed values of the filter output; that is, the chosen filter is an infinite-impulse response (IIR) filter. The corresponding fre­quency response of this lowpass filter is

1 H{en

where a; is the radian frequency.

Reprinted from Comput. & Graphics Vol. 18, No. 4, pag. 587-592, 1994

Page 112: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

// axes.inc ... a POV-Ray include file for implementing 3D coordinate axes

// first define a unit arrow along the x-coordinate axis #declare Arrow_X = object

union // join a cylinder and a cone {

intersection // an infinite cone truncated by a plane

quadric{<-0.25 1.0 1.0> <0.0 0.0 0.0> <0.500 0.0 0.0> -0.250} plane{<1.0 0.0 0.0> 0.75 inverse}

intersection // an infinite cylinder truncated by a plane

quadric{<0.0 1.0 1.0> <0.0 0.0 0.0> <0.0 0.0 0.0> -0.002500} plane{<1.0 0.0 0.0> 0.75}

}

bounded_by{box{<0.0 -0.13 -0.13> <1.0 0.13 0.13>}} // used to speed up rendering clipped_by{box{<0.0 -0.13 -0.13> <1.0 0.13 0.13>}} // truncates rest of infinite quadrics

}

// now rotate Arrow_X to get unit arrows along the y- and z-coordinate axes #declare Arrow_Y = object{Arrow_X rotate<0.0 0.0 +90.0>} #declare Arrow^Z = object{Arrow_X rotate<0.0 -90.0 0.0>}

// define the surface characteristics of the axes #declare Axes_Texture = texture {

color Yellow metallic ambient 0.25 reflection 0.10

} // form a composite object from the three arrows and a sphere at the origin #declare Axes_XYZ = composite

object{Arrow_X texture{Axes_Texture}} object{Arrow_Y texture{Axes_Texture} } object{Arrow_Ztexture{Axes_Texture}} object{sphere{<0.0 0.0 0.0> 0.0500} texture{Axes_Texture}} bounded_by{box{<-0.13 -0.13 -0.13> <1.0 1.0 1.0>}}

}

Listing 1. Example of the POV-Ray scene description language (SDL).

/* NOTES:

1. The radius of the tube is stored in the global variable r.

2. HasLinks and HasColors are Boolean global variables set by the user, 3. This code shows minimal use of bounding objects. If faster rendering is needed, form a composite object from several successive segments and use another bounding object for the entire composite object. (This strategy can be extended to multiple levels by forming a larger composite object - with its own bounding object - from two or more composite objects from the previous "level.")

#define M_180_OVER_PI 57.29577951

void ConstructTube(FILE *dataFile)

int i;

if(HasLinks) {

/* first define a unit segment along the x-axis */ fprintf(dataFile, "#declare Seg_X = intersection\n"); fprintf(dataFile, "{\n"); fprintf(dataFile," quadric{<0.0 1.0 1.0> <0.0 0.0 0.0> <0.0 0.0 0.0> %f}\n", -r*r); fprintf(dataFile," plane{<1.0 0.0 0.0> -1 inverse}\n"); fprintf(dataFile," plane{<1.0 0.0 0.0> l}\n"); fprintf(dataFile, "}\n\n");

/* position a lone sphere for one of the endpoints */ WriteSphere(dataFile, 0);

/* now loop through the rest of the points and position a segment */ for(i=l; i<npts; i++)

WriteSegment(dataFile, i);

else {

Listing 2. Principle C source code for describing a 3D "tube" in terms of the POV-Ray SDL.

116

Page 113: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

/* position a sphere at each point without any links */ for(i=0; i<npts; i++)

WriteSphere(dataFile, i); }

}

void WriteSphere(FILE *dataFile, int index)

/* position a sphere at the proper XYZ location */ fprintf(dataFile," object\n {\n"); fprintf(dataFile," sphere{<%f %f %f> %f}\n", x[index], y[index], z[index], r); if(HasColors) /* write red, green, and blue color components stored in R, G, & B arrays */

fprintf(dataFile," texture{color red %.5f green %.5f blue %.5f}\n }\n", R[index], G[index], B[index]);

else fprintf(dataFile," }\n");

}

void WriteSegment(FILE *dataFile, int index) {

/* first calculate the necessary transformations for the unit segment and */ /* store the results in the global variables length, theta, phi, mx, my, and mz */ CalculateTransformations(index);

/* now form a composite object from a sphere and a properly positioned segment */ fprintf(dataFile," composite\n {\n"); fprintf(dataFile," object\n {\n"); fprintf(dataFile," sphere{<%f %f %f> %f}\n", x[index], y[index], z[index], r);

if(HasColors) /* write the red, green, and blue color components */ fprintf(dataFile, " texture{color red %.5f green %.5f blue %.5f}\n",

R[index], G[index], B[index]); fprintf(dataFile," }\n");

/* the next several lines put the unit segment into the proper position */ fprintf(dataFile, " object\n {\n"); fprintf(dataFile," intersection\n {\n Seg_X\n"); fprintf(dataFile," scale <%f 1.0 1.0>\n", length/2); fprintf(dataFile," rotate <0.0 %f %f>\n", theta, phi); fprintf(dataFile," translate <%f %f %f>\n }\n", mx, my, mz);

if(HasColors) /* average two data points to get the segment color */ fprintf(dataFile," texture{color red %.5f green %.5f blue %.5f}\n",

(R[index]+R[index-l])/2, (G[index]+G[index-l])/2, (B[index]+B[index-l])/2); fprintf(dataFile," }\n");

/* define a bounding box for the completed segment */ fprintf(dataFile," bounded_by\n {\n"); fprintf(dataFile," box\n {\n"); fprintf(dataFile," <%f %f %f> <%f %f %f>\n", -(length/2+r), -r, -r, length/2+r, r, r); fprintf(dataFile," rotate <0.0 %f %f>\n", theta, phi); fprintf(dataFile," translate <%f %f %f>\n", mx, my, mz); fprintf(dataFile," }\n }\n }\n");

}

void CalculateTransformations(int index) {

float xl, x2, yl ,y2,zl ,z2; float dx, dy, dz, signFlag;

/* first store the necessary data in local variables */ xl = x[index]; x2 = x[index-l]; yl = y[index]; y2 = y[index-l]; zl = zfindex]; z2 = z[index-l];

/* calculate scale factor */ dx = x2-xl; dy = y2-yl; dz = z2-zl; length = sqrt(dx*dx + dy*dy + dz*dz);

/* calculate rotations about the y-, and z-axes */ if(length < le-15) {

theta = 0; phi = 0;

} else {

if(dx<0) signFlag = -1.0;

else signFlag = 1.0;

theta = -signFlag*asin(dz/length); phi = signFlag*M_180_OVER_PI*asin(dy/length/cos(theta)); theta *= M_180_OVER_PI;

};

/* calculate x-, y-, and z-coordinate translations */ mx = (xl+x2)/2; my = (yl+y2)/2; mz = (zl+z2)/2;

117

Page 114: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

118 M. T. RosENSTEiN and J. J. COLLINS

// lorenz.pov ... POV-Ray scene for rendering the data set described by lorenz.inc

// first load the basic POV-Ray include files #include "shapes.inc" #include "colors.inc" #include "textures.inc"

// now load the include file from Listing 1 and the .inc file describing the data #include "axes.inc" #include "lorenz.inc"

// position the camera camera {

location <-100.0 -10.0 130.0> direction <0.0 0.0 1.25> up <0.0 LO 0.0> right<-1.5 0.0 0.0> look at <0.28-12.0 44.0>

}

// position the axes composite {

Axes_XYZ scale <40.0 40.0 40.0> translate <12.82 -28.0 -100.0>

}

// position a checkered "floor" object {

plane{<0.0 1.0 0.0>-39.0} texture {

checker color Gray50 color Gray55 scale <50.0 50.0 50.0> ambient 0.9 diffuse 0.2 reflection 0.20

} }

// position a light source object{ light_source {<-80.0 60.0 54.0> color White} }

Listing 3. POV-Ray scene file used to generate Figs. 1-6.

During the filtering process, the x-, y-, and z-coor-dinate times series were separately filtered via the above difference equation. The value of« was computed from the desired cutoff frequency, cocutofr, {e.g., see the cap­tions to Figs. 3-5) using the following equation:

(2 = 2 - c o s COcutofT • VcOS^OJcutofT - 4 COS Wcutoff + 3 .

(This relation was derived from the assumption that

tt cutoff corresponds to the — 3 dB point, i.e., the half-power point, of the filter.) Each set of filtered time series was then used to create a three-dimensional ray-traced image.

3. GRAPHICS GENERATION

As a graphics engine, we chose the Persistence of Vision Raytracer (POV-Ray)[9,10], which is available for a number of computer platforms: Macintosh, MS-DOS, Amiga, UNIX, X-Windows, and VAX. (Other

Fig. 1. Unfiltered Lorenz attractor. The theoretical Lyapunov dimension is 2.067.

Fig. 2. Several frames from a computer animation which il­lustrates the effects of filtering chaotic signals.

Page 115: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Visualizing filtered chaotic signals 119

platforms, e.g., Silicon Graphics, Sun, are supported by compiling the C source code on the desired system.) POV-Ray images are represented using a rich scene description language (SDL), and Listing 1 gives a brief example of a limited number of the SDL's features.

A software utility was developed to convert a three-dimensional time series into a model compatible with the POV-Ray SDL. This utility generated an ASCII "include" file, which defined a sphere for everv 3D data point and a truncated cylinder as a link between successive spheres. (A similar utility[11] is available from the same sources that distribute POV-Ray.) Moreover, a color was associated with each sphere and its link to the previous sphere. (Section 4 describes the color-coding scheme.) This gave the data set the ap­pearance of a multi-color, winding "tube." Listing 2 shows the core C functions needed to define a tube.

Once the POV-Ray include file was created, th^ data set was rendered using the scene file described in Listing 3. Running on an Apple Quadra 700 computer, POV-Ray required approximately 16 hours of computation time to generate a 1023- X 682-pixel image. However, through the generous use of POV-Ray "bounding ob­jects," we were able to speed up the ray-tracing by 500-800%. (The computational savings results from POV-Ray's ability to eliminate the calculations asso­ciated with a group of objects, except when a given light ray intersects the group's bounding object.)

4. RESULTS

Figure 1 shows a ray-traced model generated from the unfiltered Lorenz data set. The color scheme used in the figure conveys supplemental information about the system's history. Specifically, a violet-blue hue refers to the oldest states of the system, whereas an orange-red color indicates the system's most recent output. Note that the system trajectory, i.e., sequence of states, is bounded in space; therefore, the trajectory tends to pass repeatedly near previously traversed regions of state space. This trait is important because similar temporal patterns are necessary if two points are to be nearby in state space. Thus, one can expect spatially

F'ig 3. Filtered Lorenz attractor with lowpass cutoff frequency ('• cutoff) of 0.2513 rad (8.0 Hz). The theoretical Lyapunov

dimension is 2.067.

Fig. 4. Filtered Lorenz attractor with lowpass cutoff frequency (cocutoff) of 0.0628 rad (2.0 Hz). The theoretical Lyapunov

dimension is 2.119.

close points to behave similarly under the influence of a temporal filter.

Figure 2 shows several frames from a computer an­imation that was developed for pedagogical purposes as well as a research tool for examining and under­standing the effects of filtering chaotic signals. By as­sociating higher degrees of lowpass filtering (i.e., lower cutoff frequencies) with elapsed time, the animation illustrates the primary features of filtered chaotic sig­nals. For example, as one lowers the cutoff frequency, energy is removed from a signal until only the DC component remains. Hence, in terms of the geometry, the attractor collapses toward its mean position with increased amounts of filtering. (However, a given point actually moves toward its local mean^ before converg­ing upon the global mean. Thus, some points may first drift away from the global mean.)

For presentation purposes, we magnified three rep­resentative frames of the animation to produce Figs. 3-6. Like Fig. 1, these images communicate additional information through a color scheme. Specifically, we related the colors to a scale factor, Fscaie, which was based on the spatial effects of the filter:

disti

disto '

where disti is the distance from a filtered point to its original, unfiltered location, and disto is the distance from the unfiltered position to its global mean. As in­dicated by the legends in Figs. 3-6, a scale factor be­tween 0.0 and 1.0 is associated with a change in color from violet to red, whereas a scale factor greater than 1.0 corresponds to a reduced saturation (i.e., a whi­tening) of the red hue. With minimal filtering, one observes little change in the geometry of the attractor and, therefore, little change in the system's fractal di-

^ "Local mean" here refers to the mean value calculated from a window of data centered about a given point.

Page 116: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

120 M. T. RosENSTEiN and J. J. COLLINS

Fig. 5. Filtered Lorenz attractor with lowpass cutoff frequency ( cutoff) of 0.0157 rad (0.5 Hz). The theoretical Lyapunov

dimension is 2.477.

mension.^ This fact is supported by the predominantly violet-blue color of the filtered attractor in Fig. 3. With increased filtering (Figs. 4 and 5) , however, the at-tractor's geometry undergoes a scale change and the appropriate colors shift closer to the red end of the spectrum.

Perhaps the most important feature to notice in Figs. 3-5 is the nonuniform coloring of the filtered attractor. We interpret this result as a shape change regardless of overall scale. Thus, different portions of the attractor move (as a function of cocutoff) toward the global mean at varying rates. This phenomenon is due to the filter's selective attenuation of points associated with the highest frequencies. As best revealed by Fig. 6, the at­tractor is transformed from its normal configuration (roughly two planar lobes for the Lorenz system) to one that is more convoluted or space-filling (over a smaller volume).* Thus, filtering causes a nonuniform scale change, i.e., a shape change that manifests itself as a dimension increase for chaotic systems.

5. SUMMARY We demonstrated that data-visualization techniques

are useful as a novel means to understanding existing problems in nonlinear dynamics. Specifically, we uti­lized three-dimensional ray-tracings to examine the ef­fects of filtering chaotic signals. The images presented in this paper were derived from a computer animation that was designed to show the mechanisms underlying the observed increase in fractal dimension. We found

^ For comparison with previous work [3-6], the captions to Figs. 1, 3, 4, and 5 present the closely-related "Lyapunov dimension" in lieu of the ft-actal dimension. The Lyapunov dimension (as calculated using the Kaplan-Yorke conjec­ture [12]) relates fractal dimension to the stretching and folding quantified by a dynamical system's Lyapunov exponents.

* Figure 6 also best illustrates the filter's "end effect" (which becomes more apparent as one lowers the cutoff frequency): the first data point (violet-colored) remains anchored to its original location.

Fig. 6. Magnification of the image in Fig. 5.

that lowpass filters can induce a nonuniform conver­gence to a system's mean state-space position. With chaotic systems, this convergence results in a distortion of the attractor's geometry such that the observed sys­tem acquires greater complexity and, therefore, in­creased dimensionality.

Acknowledgements—We would like to thank L. S. Rosenstein for providing CPU time on the Quadra 700 computer. This work was supported by the Rehabilitation Research and De­velopment Service of Veterans Affairs and the National Science Foundation (Grant BCS-9308659).

REFERENCES 1. J.-F. Colonna, The subjectivity of computers. Comm.

^CA/36(8), 15-18(1993). 2. J.-P. Eckmann and D. Ruelle, Fundamental limitations

for estimating dimensions and Lyapunov exponents in dynamical systems. Physica D 56, 185-187 (1992).

3. R. Badii, G. Broggi, B. Derighetti, and M. Ravani, Di­mension increase in filtered chaotic signals. Phys. Rev. L^//. 60(11), 979-982 (1988).

4. F. Mitschke, M. Moller, and W. Lange, Measuring filtered chaotic signals. Phys. Rev. ^ 37( 11), 4518-4521 (1988).

5. A. Chennaoui, K. Pawelzik, W. Liebert, H. G. Schuster, and G. Pfister, Attractor reconstruction from filtered cha­otic time series. Phys. Rev. /4 41(8), 4151-4159 (1990).

6. D. S. Broomhead, J. P. Huke, and M. R. Muldoon, Linear filters and non-linear systems. J. R. Stat. Soc. B 54(2), 373-382(1992).

7. P. Grassberger and I. Procaccia, Characterization of strange attractors. Phys. Rev. Lett. 50(5), 346-349 (1983).

8. E. N. Lorenz, Deterministic nonperiodic flow. J. Atm. Sci. 20(2), 130-141 (1963).

9. POV-Ray is available free of charge from a number of commercial online sources, as well as from the Internet by anonymous FTP to alfred.ccs.carleton.ca (134.117.1.1).

10. T. Wenger, Image Lab, Waite Group Press, Corte Madera, CA(1992).

11. Connect The Dots Smoother (CTDS), version 2.20 by Truman Brown (1993).

12. J. Kaplan and J. Yorke, Chaotic behavior of multidi­mensional difference equations. In Functional Differential Equations and the Approximation of Fixed Points, Lecture Notes in Mathematics, Vol. 730, H. O. Peitgen and H. O. Walther (Eds.), Springer, Berlin, p. 228 (1979).

Page 117: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 121

Chaos and Graphics

OSCILLATING ITERATION PATHS IN NEURAL NETWORKS LEARNING

R A O L ROJAS Freie Universitat Berlin, Institut fiir Informatik, Takustr. 9, Berlin 14195, Germany

Abstract—In this paper we show that finding optimal combinations of learning and momentum rate for the standard backpropagation algorithm used to train neural networks involves difficult trade-offs. Gradient descent can be accelerated with a larger step size and momentum rate, but the stability of the iteration process is affected by certain combinations of parameters. We show in which cases backpropagation produces an oscillatory behavior and how its simple feed-back nature can lead to chaotic iterations. Some graphics illustrate the kind of problems which can be found when applying backpropagation and which are often disregarded.

1. INTRODUCTION Neural networks can be defined as directed graphs of computing elements in which the nodes of the network evaluate a certain primitive function of their input [ 1 ] . Information flows through the edges of the network, where it is multiplied by the corresponding edge's weight. Learning in neural networks consists of finding the appropriate weights so that a given function can be approximated by the network as closely as possible. Starting with random weights, an iterative process re­fines the network's parameters until a good enough approximation to the given function has been found. The function to be approximated is known usually only from a set of input-output examples, i.e., the training set. The error function of the network measures the deviation between desired and current output for a given input from the training set. In most cases it is a continuous and differentiable function of the network's weights, and a simple strategy, like gradient descent, can lead to optimal weight combinations. The standard backpropagation algorithm is just a straightforward implementation of gradient descent on the error func­tion. If the weight adjustments are done immediately after each pattern presentation we speak of on-line backpropagation. If the weight adjustments are done after all input patterns have been processed with the network and all deviations have been measui*ed, we speak of off-line or batch backpropagation. The size of the correction step in the negative gradient direction is determined by a constant called the learning rate.

A popular variation of the basic learning algorithm is the introduction of a momentum term. The gradient of the error function is computed for each new param­eter combination but instead of just following the neg­ative gradient direction, a weighted average of the cur­rent gradient and the previous correction direction is computed at each step. This average is used as the new correction direction. Theoretically, this approach should provide the search process with some inertia and could help to avoid excessive oscillations in narrow valleys of the error function. However, there is empir­ical evidence that trying to adjust the learning and mo­mentum rate to minimize the processing time is a hard

computational problem. It has also been shown that backpropagation leads to chaotic behavior in the case of continuous uni ts [2] . In this paper we show what are the trade-offs involved in choosing a specific learn­ing and momentum rate, and that chaotic behavior can also be observed in the discrete case with the back-propagation feed-back rule and large momentum rates. We show, moreover, that such large momentum rates are necessary when the optimal size of the learning step is unknown and the form of the error function is highly degenerate.

In standard backpropagation, as explained before, some input-output patterns are fed into a network, and the error function E is determined at the output. In a network with n different weights Wi, W2,. . . , w„ the /-th correction step for weight Wk is given by

dE Awkii) = -JT—-^ aAwkii- 1),

dWk

where 7 and a are the learning and momentum rate, respectively. Normally we are interested in accelerating the convergence to a minimum of the error function, and this can be done by increasing the learning rate up to an optimal value. Several fast learning algorithms for neural networks work by trying to find the best value of 7, which still guarantees convergence. The introduction of the momentum rate allows the atten­uation of oscillations in the iteration process.

Adjusting both learning parameters to yield the best possible convergence is normally done by trial and er­ror, or even some kind of random search [ 3 ] . Since the optimal parameters are highly dependent on the learning task, no general strategy has been developed to deal with this problem. In this paper we show why some parameter combinations yield poor results.

2. THE LINEAR ASSOCIATOR Let us first consider the case of a linear associator,

that is, a single computing element with associated weights Wi, W2, .. ., Wm and, which for the input Xi, X2, ..., Xnt produces WiXi -\- • • • -\- w^Xm^s output.

Page 118: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

122 R. ROJAS

The input-output patterns in the training set are the p ordered pairs (xi, >^i),..., (x ,, y^), whereby the input patterns are vectors of dimension m and the output patterns are scalars. The weights of the linear associator can be ordered in an m-dimensional column vector w and the learning task consists of finding that w, which minimizes the quadratic error

m

£ = 2 l|x,w-j;,P.

By defining a p X m matrix X whose rows are the , Xp and a column vector y whose ele-vectors Xi,

ments are the scalars yi, ..., yp, duces to the minimization of

the learning task re-

E= | | X w - y P

= ( X w - y ) ^ ( X w - y )

= w^(X^X)w - 2y^Xw + y^y.

Since this is a quadratic function, the minimum is found at w = X^y, where X" is the pseudoinverse of the matrix X. A solution can also be found using back-propagation.

The quadratic function E can be thought of as a paraboloid in m-dimensional space. The lengths of its principal axes are determined by the magnitude of the eigenvalues of the covariance matrix X^X. Gradient descent is most effective when the principal axes of the quadratic form are all of the same length. In this case, the gradient vector points directly toward the minimum of the error function. When the axes of the paraboloid are of very different size, the gradient direction can lead to oscillations in the iteration process[4],

Let us consider the simple case of the quadratic function ax'^ + by^. Gradient descent yields the iter­ation rule

Ax{i) = -2yax + aAx{i - 1)

in the x direction and

Ayii) = -2ybx + aAy{i - 1)

in the y direction. An optimal parameter combination in the x direction is 7 = \/2a and a = 0. In the y direction the optimal combination is 7 = I/2b and a = 0. Since the iteration proceeds with a single 7 value, we have to find a compromise between these two op­tions. Intuitively an intermediate 7 should do best, when the momentum term is zero. Figure 1 shows the number of iterations needed to find the minimum of the error function to a given precision as a function of 7, when a = 1.5 and b = I. The optimal value for 7 is the one found at the intersection of the two curves. The global optimal 7 is larger than the optimal 7 in the X direction and smaller than the optimal 7 in the y direction. This means that there will be some oscil­lations in the y direction and slow convergence in the X direction, but this is the best possible compromise. It is obvious that in the m-dimensional case we could have oscillations in some of the principal directions and slow convergence in others. A simple strategy that is used by some fast learning algorithms to avoid these problems consists of using a different learning rate for each weight, that is a different 7 for each direction in weight space [ 5 ].

3. MINIMIZING OSCILLATIONS

Since the lengths of the principal axes of the error function are given by the eigenvalues of the covariance matrix X^X, and since one of these eigenvalues could be much larger than the other ones, the range of pos­sible values for 7 reduces accordingly. Nevertheless, a very small 7 and the oscillations it produces can be neutralized by increasing the momentum term. A de­tailed discussion of the one-dimensional case provides

Fig. 1. Optimal 7 in the two-dimensional case.

Page 119: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Oscillating iteration paths 123

divergence zone

0,5

Momentum rate

Fig. 2. Convergence and nonconvergence regions.

us with the necessary insight for the understanding of more complex cases.

In the one-dimensional case, that is when minimiz­ing functions of type kx^, the optimal step length is

given by 7 = \ /2k. K step length of 7 = {/k produces an oscillation between the initial point XQ and —XQ. Any 7 greater than 2//cleads to an "explosion" of the iteration process. Figure 2 shows the main regions for parameter combinations of 7 and a. These regions were determined by iterating in the one-dimensional case and integrating the length of the iteration path. Param­eter combinations in the divergence region lead to the explosion of the iteration process. Parameter combi­nations in the boundary between regions lead to stable oscillations.

Figure 2 provides us with some interesting infor­mation. Any value of 7 greater than four times the constant 1/2/c cannot be balanced with any value of a. Values of a greater than 1 are prohibited since they lead to a geometric explosion of the iteration process. Any value of 7 between the explosion threshold Xjk and 2 / / : can be made to lead to convergence by a large enough a. For any given 7 between 1 /k and 2/A: there exist two points in which the iteration process falls in a stable oscillation, namely at the boundaries between regions. For values of 7 under the optimal value

Fig. 3. Paths in weight space for backpropagation learning (linear associators).

Page 120: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

124 R. ROJAS

Fig. 4. Bounded nonlinear error function and the result of several iterations.

1/2A:, the convergence speed is optimal for a unique a. The optimal combinations of a and 7 are the ones represented by the jagged line in the diagram.

The more interesting message we get from Fig. 2 is the following: In the case where in some direction in weight space the principal axis of the error function is very small compared to another axis, we should try to achieve a compromise by adjusting the momentum rate in such a way that the oscillating directions become less oscillating and the directions with slow convergence improve their convergence speed. Obviously when dealing with n directions in weight space, this com­promise could be dominated by a single direction in weight space.

4. CRITICAL PARAMETER COMBINATIONS

Backpropagation is normally used in those cases in which we do not have an analytic expression of the function to be optimized. A learning rate 7 has to be chosen without any previous knowledge of the co-variance matrix of the input. In on-line learning the training patterns are also not always defined in advance, and are generated one by one. A conservative approach is then trying to minimize the risk by choosing a very small learning rate. But in this case backpropagation can be trapped in a local minimum of a nonlinear error function. The learning rate should then be in­creased.

In the case of a covariance matrix X^X with some very large eigenvalues, a given choice of 7 could lead to divergence in the associated direction in weight space (assuming for simplicity that the principal directions of the quadratic form are aligned with the coordinate axis). Let us assume that the selected gamma is near to the explosion point 2/k found in the one-dimen­sional case and shown in Fig. 2. In this case only values of the momentum term near to one can guarantee convergence, but oscillations in some of the directions in weight space can become synchronized. The result is oscillating paths in weight space, reminiscent of Li-sajous figures. Figure 3 shows some paths in a two-dimensional weight space for several linear associators trained with momentum rates close to one and different 7 values. In some cases the trajectories lead to con­vergence after several thousand iterations. In others a momentum rate equal to one precludes convergence of the iteration process. In many cases in which back-propagation does not converge, at least it diverges with elegance.

The adjustment of the learning and momentum rate in the nonlinear case is even more difficult than in the linear case, because there is no fast explosion of the iteration process. At least in the quadratic case when­ever the learning rate is excessively large, the iteration process leads rapidly to an overflow that alerts the pro­grammer that the step size should be reduced. But in the nonlinear case the output of the network and the error function are bounded and no overflow occurs there. In regions far from local minima the gradient of the error function nearly becomes zero and the weight adjustments also. The divergence regions of the quadratic case can now become oscillatory regions. In this case even with larger and larger step sizes the it­eration returns to the convex part of the error function. Figure 4 shows the possible shape of the error function for a linear associator with sigmoidal output and the associated oscillation process for this kind of error function in the one dimensional case. The jagged form of the iteration curve is reminiscent of the kind of learning curves shown in many papers about learning in nonlinear neural networks.

5. CONCLUSIONS

In this paper we have shown that backpropagation with momentum can exhibit a highly oscillating be­havior under some parameter combinations. Presum­ably this is the kind of situation found in some appli­cations when the learning rate is just too large. Al­though in the quadratic case mainly large momentum rates lead to oscillations, in the nonlinear case a gamma which is excessively large can also produce oscillations even when no momentum rate is present.

Researchers in the field of neural networks should be concerned not only with the possibility of getting stuck in local minima of the error function when learning rates are too small, but also with the possibility of falling into the oscillatory traps of backpropagation when the learning rate is too big. Learning algorithms should try to balance the speed-up they are attempting to obtain with the risk of divergence involved in doing so. Two different kind of remedies are available: adap­tive learning rates and statistical preprocessing of the learning set in order to decorrelate the input patterns trying to avoid the deleterious effect of too large eigen­values of the covariance matrix [6 ]. In the case of highly correlated input patterns the analysis of the conver­gence regions for backpropagation becomes more

Page 121: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Oscillating iteration paths 125 complex and the iteration paths become more irregular than those shown in Fig. 3.

REFERENCES 1. R. Rojas, Theorie der neuwnalen Netze, Springer-Verlag,

Berlin (1993). 2. H. van der Maas, P. F. Verschure, and P. Molenaar, A

note on chaotic behavior in simple neural networks. Neural Networks 3, 119-122 (1990).

3. J. D. Schaffer, D. Whitley, and L. J. Eshelman, Combi­nations of genetic algorithms and neural networks: A sur­vey of the state of the art. In International Workshop on

Combinations of Genetic Algorithms and Neural Net­works, IEEE Computer Society Press, Los Alamitos, 1-37(1992).

4. M. Pfister, On data correlation and neural networks. Technical Report B-11/93, Freie Universitat Berlin, Fachbereich Mathematik und Informatik (1993).

5. R. A. Jacobs, Increased rates of convergence through learning rate adaptation. Neural Networks 1, 295-307 (1988).

6. L. B. Almeida and F. M. Silva, Speeding-up backpropa-gation by data orthonormalization. In T. Kohonen, K. Makisara (Eds.), Artificial Neural Networks, North-Holland, Amsterdam, 943-948 (1991).

Page 122: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 127

Chaos and Graphics

THE CRYING OF FRACTAL BATRACHION 1,489

CLIFFORD A. PICKOVER

IBM Watson Research Center, Yorktown Heights, NY 10598, U.S.A.

Abstract—^This essay describes a class of integer sequences with unusual graphical behaviors and histories. Simple graphical methods are presented in order to encourage student/teacher involvement and future exploration.

INTRODUCTION

''The rationality of our universe is best sug­gested by the fact that we can discover more about it from any starting point, as if it were a fabric that will unravel from any thread."*'— George Zebrowski (1994).

Batrachions are a class of bizarre and infinite mathematical curves which hop like frogs from one "lilypad" to the next as they parade along the number system. These httle-known curves derive their name from batrachian which means frog-Hke. (To pronounce the word, note that the "ch" has a "k" sound.)

In addition to hopping in a strange manner from integer to integer, they also have other interesting properties. For example, they are often fractal, exhibiting an intricate self-similar structure when examined at different size scales. Also, they evolve from very simple-looking recursive formulas involving integers.

As background, perhaps the most common exam­ple of recursion in programming and in mathematics is one that that defines the Fibonacci numbers. This sequence of numbers, called the Fibonacci sequence, plays important roles in mathematics and nature. These numbers are such that, after the first two, every number in the sequence equals the sum of the two previous numbers:

Fn = FN-\ + FN-1 for iV > 2, Fo = Fi - 1.

This defines the sequence: 1, 1, 2, 3, 5, 8, 13, 21, . . . With this brief background to recursion, consider

my favorite Batrachion produced by the simple, yet weird recursive formula

a{n) = a{a{n - ! ) ) + « ( « - a{n - 1)).

The formula for the Batrachion is reminiscent of the Fibonacci formula in that each new value is a sum of two previous values, but not of the immediately previous two values. The sequence starts with fl(l) = l, and a(2) = 2. The "future" values at higher

values of n depend on past values in intricate recursive ways. Can you determine the third member of the sequence? At first, this may seem a little compHcated to evaluate by hand, but you can begin slowly by inserting values for n, as in the following:

a{3) = a{a{2)) ^ a{3 - a))

a{3) = a{l)-^ a{3 - I) =

a{3) =3 1 + 1 = 2.

Therefore, the 3rd value of the sequence, a(3), is 2. The sequence a{n) seems simple enough: 1,1,2,2,3,

4,4, 4, 5 , . . . Try compting a few additional numbers. Can you find any interesting patterns? The prolific mathematician John H. Conway presented this recursive sequence at a recent talk he gave at AT&T Bell Labs entitled "Some Crazy Sequences" [1]. He noticed that the value a{n)/n approaches 1/2 as the sequence grows, and n becomes larger. Table 1 lists the first 32 terms of the Batrachion and the ratio a{n)/n.

I first became interested in this sequence after reading Schroeder's delightful book Fractals, Chaos, Power Laws [2], but, alas, there were no graphics included to help readers gain insight into the behavior of the Batrachion. It turns out that this sequence has an incredible amount of hidden structure. Figure 1 is a plot ofa{n)/n for values of« between 0 and 200. Notice how the curve hops from one value of 0.5 to the next along very intricate paths. Each hump of the curve appears to be slightly lower than the previous, as if a virtual frog were tiring as it explored higher and higher numbers. As the frog nears infinity, will it stop its hopping and lie dormant at a{n)/n = 0.5? Figure 2 is a plot for the first 1000 values of the sequence. Notice that it is very similar to Fig. 1. More and more humps evolve with an intricate self-similar arrangement of tiny jiggles along the path.

$10,000 CASH AWARD

Let us consider how fast the frog approaches its 0.5 destination at infinity. For example, can you find a value of « beyond which the value of a{n)/n is so tiny that it is forever within 0.05 from the value 1/2? (In

Reprinted from Comput. & Graphics Vol. 19, No. 4, pag. 611-615, 1995

Page 123: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

128

0.70

0.65

:0.60

0.55

0.50

Table 1. First 32 terms of the Batrachion.

C. A. Pickover

0.60

a{n) a{n)/n

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32

1 1 2 2 3 4 4 4 5 6 7 7 8 8 8 8 9 10 11 12 12 13 14 14 15 15 15 16 16 16 16 16

1.0 1.0 .666 .5 .6 .666 .5714 .5 .5555 .6 .6363 .5833 .6153 .5714 .5333 .5 .5294 .5555 .5789 .6 .5714 .5909 .6086 .5833 .6 .5769 .5555 .5714 .5517 .5333 .5161 .5

200

Fig. 1. Batrachion a{n)/n for 0 n 200.

1000

Fig. 2. Batrachion a(n)/n for 0 n 1000.

Fig. 3. Batrachion a{n) for 0 n 10,000.

Other words, \a{n)/n - 1/2| < 0.05. The bars indicate the absolute value.)

A difficult problem? John Conway, the British mathematician, offered $10,000 to the person to find the first value of n such that the frog's path is always less than 0.55 for higher values of n. A month after Conway made the offer, Colin Mallows of AT&T [3] solved the $10,000 question: «= 1,489. Figure 3 shows this value on a plot for 0 > « > 10,000. (For a variety of minor technical reasons, a less accurate number is published in Schroeder's book.) As I write this, no one on the planet has found a value for the smallest n such that a{n)/n is always within 0.001 of the value 1/2, that is (|a(«)/« - 1/2| < 0.001). (No one even knows if such a value exists.)

Looking at the curves, we can see the following. The frog hits the pond periodically. In fact, a{n)/n "hits" 0.5 at values corresponding to powers of 2, for example, at 2^, /:= 1, 2, 3, . . . Does each hump reach its maximum at a value of n halfway between the 2^ and 2^^^ endpoints?

Tal Kubo from the Mathematics Department at Harvard University is one of the world's leading experts on this Batrachion. He notes that the sequence is subtly connected with a range of seemingly unrelated topics in mathematics: variants of Pascal's triangle, the Gaussian distribution, combinatorial operations on finite sets, and Catalan numbers. Tal Kubo and Ravi Vakil have developed algorithms to compute the behavior of the Batrachion as it nears infinity. Indeed, they have found that the frog tires rather slowly! For example, the frog's jumps are not always less than 0,52 until it has jumped 809,308,036,481,621 times! On the following page is a table of values for different frog jump heights. These values were found by Tal Kubo and Ravi Vakil using a Mathematica program running on a Sun 4 computer.

Colin Mallows, the statistician who conducted the first in-depth study of this class of curves, notes that no finite amount of computations will suffice to prove that the regularities we see in the curve persist indefinitely. He does note that the differences between successive values are either 0 or 1. Is this true indefinitely?

Page 124: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

1/20 1/30 1/40 1/50 1/60 1/70 1/80 1/90 1/100

The crying of fractal Batrachion 1,489

Last n such that a(n)/n-l/2e

1489 (found by Mallows in 1988) 758765 6083008742 (found by Mallows in 1988) 8093080364481621 1684539346496977501739 55738373698123373661810220400 15088841875190938484828948428612052839 127565909103887972767169084026274554426122918035 8826608001127077619581589939550531021943059906967127007025

129

VISUALIZING INFINITY

I have found that Figs 1-3 give students and researchers an intuitive feel for the Batrachion, its self-similar structure, and Conway's contest. How might we apply other simple graphical tools to better display the behavior of the Batrachions? I was particularly interested in how we can best illustrate the fractal (self-similar) structure of the various humps. One way is to renormalize each hump by shifting them on the x-axis each time a 2^ value is reached. In addition, the x-values can be scaled between 0 and 1 by multiplying by 1/2 . (This effectively normalizes the curves so that the range 2k to 2 "'" is squeezed into the range of 0 to 1.) Figure 4 illustrates my visualization and shows the beautiful but intricate relationships between successive humps. This plot was computed for the first 2048 points in the Batrachion, and I placed dots at the vertices of the first few humps. As the frog hops closer and closer to infinity, these curves become more squat and begin to hug the ;; = 0.5 line.

Interestingly, it is not clear how one hump in the Batrachion is generated from the previous hump. As Colin Mallows of AT&T has pointed out, «(100), which is located in the sixth hump, is com­puted as a(fl(99) + a(100 - a{99)) = a(56) + ^(44) = 31+26 + 57. This shows that a point in hump 6 is generated from two points in hump 5 which are far apart. Fve chosen one way to represent the complex

0.70

0.65 h

;0.60

0.55

0.50 0.4 0.6

(n - 2' ) / 2^

relationship between the two terms by plotting a(a{n - 1)) (i.e. the first term of the Batrachion formula) and a{n — a{n — 1)) {i.e. the second term) as X and y in an x-y plot (Fig. 5). (The terms are normalized by dividing by n prior to plotting.) Notice the unusual clustering of points toward the bottom of the plot corresponding to the decay of the Batrachion as it jumps to infinity.

OTHER BATRACHIONS

When I first became interested in this class of curves, I thought there surely would be other famous Batrachions. I was right. Figure 6 shows a Batra­chion computed from a very similar looking, recursive integer sequence:

Q{n) = Q{n - Q(n - 1)) + Q{n - Q{n - 2)).

This sequence was mentioned in Hofstader's [4] famous Goedel, Escher, Bach, but no figure was given to show its magnificent and bizarre behavior. (The sequence of numbers produced by this formula are sometimes called Q-numbers.) The first few hundred values show striking regularity, but I do not know if the regularities persist. There is obviously some subtle pattern that is difficult to define. The behavior of this function as it approaches infinity is not known. Does a{n)/n eventually converge to 0.5? The virtual frog seems to be rather nervous, or perhaps high on LSD. There are periodic bursts

0.45

0.40 h

0.35 h

0.20 0.15 0.20 0.25 0.30

a[a(r>-1)]/n 0.35 0.40

Fig. 4. Renormalized Batrachion to show fractal structure. (See text and program code for more information.) Fig. 5. First and second terms of the Batrachion as x and y.

Page 125: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

130 C. A. Pickover

0 500 1000 1500 2000 n

Fig. 6. Visual representation of Hofstadter's Batrachion.

which noisily decay to around 0.5 until another rapid hop starts again. How could such a simple integer formula give such complexity?

Finally, another Batrachion, Mallows' Batrachion, is defined by:

a{n) — a(a{n — 2)) + a{n — a{n — 2))

This also has an intricate humped structure. No one knows if a{n)/n tends to some limit for this Batrachion.

THE CRYING OF FRACTAL BATRACHIONS

Various authors, such as Manfred Schroeder [2], have discussed how mathematical waveforms sound when converted to time waveforms and played as an audio signal. For example, Weierstrass curves (which

are continuous but quite jagged) are a rich mine of paradoxes. They're produced by:

oo

w{t) = ^ A^ COS B^t k=\

where AB > 1 + 3n/2. If recorded on a musical tape, and replayed at twice the recording speed, the human ear will unexpectedly hear a sound with a lower pitch. Other fractal waveforms do not change pitch at all when the tape speed is changed. It is rumored (but I have not confirmed) that the first Batrachion described in this paper produces a windy, crying sound when converted to an audio waveform. I would be interested in hearing from readers who have conducted such audio experiments on any of the Batrachions. For other musical mappings of number sequences and genetic sequences to sound, see my book Mazes for the Mind: Computers and the Unexpected [5]. The BASIC and C program codes in the current paper are a launchpad for future exploration [6].

REFERENCES 1. J. Conway, Some crazy sequences. Videotaped talk at

AT&T Bell Labs, July 15 (1988). 2. M. Schroeder, Fractals, Chaos, Power Laws, Freeman,

New York (1991). 3. C. Mallows, Conway's challenge sequence. American

Mathematics Monthly January, 5-20 (1991). 4. D. Hofstadter, Goedel Escher Bach, Vintage Books, New

York (1980). 5. C. Pickover, The drums of Ulupu. In Mazes for the

Mind: Computers and the Unexpected. St Martin's Press, New York (1993).

6. C Pickover, Keys to Infinity. Wiley, New York (1995).

The BASIC and C Program Codes are Given Opposite

Page 126: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

The crying of fractal Batrachion 1,489 131

w c o

• H ^ ^

o ^ • td • o 4-) ,n; -H (d -p 13 ffl (d -p

•^ (U a;

o o

II « II

o <u ^

g fd H >H - P . - .

•^ G rj I •* CO O ^ + , K '^ o 'IT '^ n

o •- o ""• o < „ •H iH rH II OJ <U "

fd

0)

t i II CD td H 5

-p g

fd

fd >

V W H fd

H O H -H .^

fd •H M-i

< ^ - X. H H rH 3 * M-I O *

II

CN

td

•-H II

H

fd

,_

+ c •-00

o

V

c , ro II

y\ O

I H

\ * o

• H

O fd H +J fd

m

«. > i fd

> c o o

* \

T-\

II II <L>

fd c <u

> H 13 U

—' »P • H

1 — 1

1 — 1

H 1

fd 1

+ ' '

1

"fd

fd II

^ (d

W

H 0) 4-> n3 td +J w m o K

* \

c\ II II 0)

1 c Q)

> H !3 O

^-^ m - H

1

c "fd

Id

+

^ 1

c 1

^ II

"c" fd

\ * w :? o

rH rH fd

s •K

\

m II II 0)

C 0)

> H :3 u

^ m - H

n-n O r- , CO

7 c

'""' H ^ o

7 fd (u

—' +J fd S II P4

r - g C O

•—' U fd ^,

\

" ,- II II

g H O

c (U H

" M-I • H

+ r-n + -H - H . _ .

O o CN O

II C.

• <H

: 4-1 g

\ c • r-n - H C O fi^ O

td ' Q

•p g -p

Q II cu II

td M fd M -k H O H O ^

II (L) c a» C ^ O P! <U C (U °

(d -K 1+-I * m ^ H \ - H \ - H

i

1

o o o o o o o o O O C T i O i - H C N r o ^ L D H r H C N C N C N C N C N C N

O O O (X) O H CN ro m

O O CN m CO f^

o o o 'sT in vD m m ro

Page 127: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 133

Chaos and Graphics

EVALUATING PSEUDO-RANDOM NUMBER GENERATORS

RICHARD L. BOWMAN Department of Physics, Bridgewater College, Bridgewater, VA 22812, USA,

e-mail: r.l.bowman @bridgewater.edu

Abstract—The graphing and computational capabiUties of Mathematica provide a quick and visual route to evaluating various characteristics of pseudo-random number generators. This paper is a tutorial on using some simple statistical and graphical techniques for studying the output of such generators. In addition, a simple congruential generator with modulus TT, whose output is shown to be reasonably uniform and independent (according to the tests described here), is introduced.

1. INTRODUCTION

The ability to construct a sequence of random numbers is crucial to a variety of computing tasks, from design­ing arcade games, to generating fractals, to using Monte Carlo techniques. The graphing capabilities of Mathematica (a software package for solving a variety of mathematical problems in algebra, graphics, statis­tics and calculus) [1] provide a quick, visual route to evaluating some of the characteristics of pseudo­random number generators. This paper is a tutorial on some simple statistical techniques for testing the out­put of such generators.

The study of the practical and theoretical aspects of the generation of random numbers dates at least back to the invention of dice. In this century, a number of tables of random digits were produced from census figures (by L. H. C. Tippett in 1927) and by other means (such as the machine ERNIE in the 1930s) [2]. Only in the past few decades has this area of research taken leaps forward with the advent of fast electronic computers and various stochastic modelling programs needing good algorithms for generating se­quences of random numbers.

Only such physical processes as the decay of the nucleus of a radioactive element, the selection of a colored ball from a well-stirred container of different colored balls, and the noise in an electronic circuit are technically considered random events. However, the amplitude of several components of electronic noise are now known to depend on the frequency of the signal. Thus the distinctions between random and pseudo-random numbers will be left to the theoreti­cians. In the remainder of this article, the usual con­vention of using the term "random number" to refer to an element of a sequence of pseudo-random num­bers generated by a numerical algorithm will be fol-lowed[3].

In this paper, I limit my discussion to random num­bers on the interval [0, 1) and to algorithms that ap­proximate a sequence of statistically independent ran­dom numbers distributed uniformly over this interval. First, I examine tests of the uniformity of the distribu­tion of a sequence of random numbers. Then I look at several techniques for probing how independent any element of a random number sequence is from the

preceding and following elements of that sequence. The output from several random number generators will be explored including that from congruential gen­erators with integer parameters, a generator with an irrational modulus, the RND function in BASIC on a Commodore 64, and the Random[] function in Math­ematica.

2. LINEAR CONGRUENTIAL GENERATORS

Linear congruential random number generators [4, 5] produce a sequence of non-negative numbers in [0, 1), {f/i}, where

Xi = (aXi^i + c)modM (1)

Ui=Xi/M (2)

and the multiplier a, the shift c, modulus M, and seed, XQ, are integers in the range [0, M ~ 1]. Press[3] refers to these generators as ' 'quick and dirty'' since the necessary code requires only a couple lines in a FORTRAN program.

A number of choices for parameters (for "good" and "bad" generators) are presented in several sources [2 -8 ] . As a running example to show my testing techniques, a generator labelled as a "Linear Congruential Generator eXample" (LCGX) will be used. The LCGX has a = 157, c = 1, Xo = 2 and M = 2048. Other examples will be examined after the tests have been developed.

3. TESTS FOR UNIFORMITY OF THE DISTRIBUTION

3.1. Bar chart plots There are a number of nonuniform distributions of

random numbers that are useful in the physical sci­ences, computer science and mathematics. However in an electronic computer these are generally approxi­mated starting with a uniformly distributed random number generator[3]. So to limit the scope of this article, I restrict the discussion to uniformly distrib­uted sequences of random numbers.

A finite set of uniformly distributed numbers is one in which each possible number has an equal probabil­ity of occurring in the set[2]. Since the interval of study is infinite and the random number sequences are

Reprinted from Comput. & Graphics Vol 19, No. 2, pag. 315-324, 1995

Page 128: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

134 R. L. BOWMAN

In[5] : = rd[x_] := (rani = Take[ran,x];pts x;)

Fig. 1. Bar chart of the counts of random numbers, for the first 500 numbers produced by the Hnear congruential generator example (LCGX) described in the text, in each of ten equal

subintervals in the interval [0, 1).

finite, this definition can be tested by subdividing the range of the random number sequence into equal sub-intervals and counting the number of elements in each such subinterval. As the sample size of the sequence gets larger, the interval can be divided into smaller and smaller subintervals. A simple bar chart will help in visualizing the degree of uniformity of the random number sequence.

Loading a graphics package in Mathematica will enable the displaying of bar charts. Two statistical packages will also be loaded for later use.

In[ l ] : = ((Graphics' Graphics' ((Statistics' Descripti veStatistics' ((Statistics' HypothesisTests'

Next, a list of 6144 random numbers is created as output by the LCGX. The operator Short[] provides a shortened printing of a list (array) in Mathematica. In the case below, only the first sixteen elements and the last eight elements are printed. The remaining 6120 numbers in the middle of the list are represented by " ( ( 6 1 2 0 ) ) . "

I n [ 3 ] -ptsmax = 6144; rnd = 2; Short [ran = Table [rnd = 1 ] , 2 0 4 8 ] ;

rnd/2048, {i,ptsmax} ] ,6 ] Out[4] / /Shor t=

{0.153809, 0.148437

Mod[N[157 rnd +

0.35498, 0.399902, 0.788574, ( ( 6 1 2 0 » , 0.307617, 0.000976562

0.732422, 0.785156, 0.806641, 0.282715, 0.296387,

0.305176, 0.990723, 0.27002, 0.643066, 0.386719, 0.533203,

0.913086, 0.543945, 0.393555, 0.961914, 0.715332, 0.713379,

A function is then defined that will pick different quantities of these numbers as are suitable for the various tests to be performed.

The first 500 numbers in this list are then selected, sorted into ten subunits in the interval [0, 1), and plotted in a bar graph (Fig. 1).

I n [ 6 ] : = rd[500] ; rs = Sort [ ran] ; j = 1; subint = 0.1; nint = Table [ l , { l / subint} ] ; n int [ [ l ] ] = 0; D o [ I f [ r s [ [ i ] ] < ( j subint), n int[ [ j ] ]=nint[ [ j ] ] + l , j = j + l ] ,

{ i ,pts}]; nint Out[124] =

{50, 54, 55, 56, 51, 44, 49, 51, 43, 47} In[125] : =

BarChart[nint]

The flatness of the histogram in Fig. 1 will be tested later with a chi-squared procedure. What happens qualitatively to the flatness of the plot if more random numbers are included?

In[126] : = pts = 2000; rnd = 2; ran = Table [rnd = Mod [N [157 rnd + 1] , 2048];

rnd/2048, { i ,pts}]; rs = Sort [ ran] ; j = 1; subint = 0.1; nint = Table[1,{1/subint}]; n int [ [ l ] ] = 0; D o [ I f [ r s [ [ i ] ] < ( j subint), n int[ [ j ] ]=nint[[ j ] ]

+ l j = j + l ] , { i ,pts}]; nint

Out[131] = {203,201,201, 197,200, 197, 198, 198,203,202}

In[132] : = BarChart[nint]

The resulting histogram for 2000 points (Fig. 2) appears even flatter than that for 500 points. In fact its flatness is misleading since the generation of 2000

Fig. 2. Bar chart of the counts of random numbers, for the first 2000 numbers produced by the LCGX, in each of ten

equal subintervals in the interval [0, 1).

Page 129: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Evaluating pseudo-random number generators 135 numbers brings the generator very close to completing one cycle. The quantity of random numbers produced by a generator before it repeats the whole sequence is called the period of the generator. Even bad linear congruential generators should produce a uniformly flat histogram during any complete period. This will be more fully explored later.

3.2. Mean and standard deviation of the sequence Can the uniformness of the distribution of random

numbers in a sequence be quantified? Certainly Math-ematica can calculate the mean and standard deviation of a sequence of random numbers with the package

Statistics" DescriptiveStatistics".

Out [146] = 200.

Out[147] = 0.25

The meaning of this value of x^ can be investigated by finding the probability of this value arising from pure chance selection. The Mathematica package. Sta­tistics" HypothesisTests", must be loaded to quickly calculate this quantity.

In[181] : = ChiSquarePValue [ chisq,! /subint-1]

Out[181] = OneSidedPValue -^ 1.48902 10"^

In[17] : = u = Mean [rani] sigsq = StandardDeyiation[ranl]^2

Out [17] = 0.485846

Out[18] = 0.0816118

For a uniform infinite distribution in the interval [0, 1), /x should be \ and G^ should be n- For a uniform finite sequence of 2000 numbers, these values can be calculated in Mathematica.

In[19] : = theory = Table[N[x/2000], {x,0,1999}]; utheory = Mean [theory] sigsqtheory = StandardDeyiation[ theory] ^2

Out[20] = 0.49975

Out[21] = 0.083375

So it appears, from a comparison of the sample fi and G^ with the above theoretical values, that the out­put from the LCGX is adequately uniform (but re­member that it is abnormally so because of having nearly completed one period).

This can be quantified further by using a chi-squared test or the Kolmogorov-Smimov test[5, 9] . In using the x^ test, the null hypothesis is assumed, i.e., the experimental numbers and the theoretical numbers are assumed to be drawn from the same set, and thus any differences between the two are due to chance alone. A large value of x^ means that this null hypothesis can be rejected with some level of confidence, x^ can be calculated for frequencies of numbers in subintervals by summing up the quantity (observed frequency-expected frequency)^/(expected frequency) for each subinterval. x^ values can be readily calculated in Mathematica.

In[146] : = expect = pts subint chisq = Apply [Plus, (nint expect )^2I expect ]

ChiSquarePValue [] is a hypothesis test which gives as output a probability that the value of x^ (given the number of degrees of freedom) could be as large as it is if the hypothesized model is true and the deviations are due to random errors [11]. In this particular case, the degrees of freedom for this model are given by the term (1/subint-1) = ( l / . l ) - 1 = 9. This test is implemented such that the output ranges from 0 to 0.5 and back to 0 again instead of from 0 to 1. So for small /?-values associated with small x^ values, the /?-values need to be subtracted from 1 to match the usual table of x^ values {e.g., 9] . In the above calculation, the table /?-value is really 0.9999985.

One must take care when interpreting this value of probability in the x^ test because 2000 points are near one complete period for the LCGX. Morgan[10] has suggested that some generators may have too good of a fit as well as some may have too poor of a fit. In addition, if the output from a linear congruential generator such as the LCGX is studied for one full period, then x^ will equal zero since the actual fre­quency of numbers in each subinterval will be equal and will match the expected frequency [5]. The period of a linear congruential generator will need to be looked at more closely.

3.3. Periodicity of the generator The theoretical periods over which different types

of linear congruential generators repeat their sequence of numbers have been extensively studied and deter­mined [2]. The LCGX is a full-period generator, and thus its period is equal to its modulus, 2048. The bar chart for a sequence of 2000 numbers should therefore appear nearly flat.

Fast Fourier transforms (FFT) can be used to study the periodicity of a data set and are readily calculated and plotted using Mathematica. To make certain that the first term does not dominate the output, the mean of the sequence (theoretically this is 0.5) must be subtracted from each random number. The first term is simply the sum of all of the elements of the sequence divided by the square root of the number of elements in the sequence, i.e., in this case, the mean value of

Page 130: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

136 R. L. BOWMAN

Fig. 3. Fourier coefficients calculated using Fast Fourier Transforms indicating the periodic structure of the random number sequence (6144 elements) generated by the LCGX.

Fig. 4. Plot of 5000 random numbers in the order in which the LCGX generated them already suggesting a lack of ran­

domness.

the sequence (0.5) multiplied by Sqrt[6144] which is approximately 39. (See Wolfram[12] for the form of the equation that Mathematica uses to calculate the EFT.)

In[33] : = ListPlot [ Abs [ Fourier [ ran-.5 ] ] , PlotJoined-^True,

PlotRange^{ { 0,pts/2} 11} ]

Only half of the FFT is plotted, since, due to aliasing, the other half contains no new information on the periodicity of the random number sequence.

The structure in this plot (Fig. 3) indicates that there is more periodicity in the output of the LCGX than just its full period of 2048. In fact the Fourier coefficients for several other periods are just as large as that for 2048. The solid section at the bottom of the graph arises from the fact that some periods are not present at all in the sequence and thus have a value of zero. Connecting all 3072 points, including the zeros, on one graph makes this apparent solid region. This periodic structure is actually an indication that each number is not as independent as had been hoped. Better random number generators appear to have some contribution from most all of the possible periods. Thus, since there will be no periods with Fourier coef­ficients of zero, the dark region will appear suspended in the middle of the graph. These better generators also have smaller Fourier coefficients, often 0.6 or less.

4. TESTS FOR INDEPENDENCE

4.L Plots of 2-and 3-tuples If the individual numbers in a sequence of random

numbers are uniformly spread over the interval, the sequence is then said to be "1-distributed." But as seen above, a sequence can be uniform and still not be very random. So, one can check to see how inde­pendent one number in the sequence is from its prede­cessor. In other words, is the sequence "2-distrib-uted"? A plot of {(f/j, Ui+i)} will give a visual indi­cation of any such dependence. Similarly, a plot of

[(Ui,Ui+u Ui+2)} will show how close to being " 3 -distributed'' a sequence of random numbers is.

Before looking at the plots of the 2-tuples and 3-tuples (as these pairs and triplets are called), a plot of the random numbers in the order of their generation may show us some lack of randomness even at the 1-distributed level.

In[37] : = rd[5000]; ListPlot [rani]

Fig. 4 demonstrates that the output from the LCGX already shows structure at the 1-distributed-level indi­cating that each random number generated depends closely on the previous number generated. The plots of the 2-tuples and 3-tuples (Figs. 5 and 6) shows even more definite structure.

In[40] : = ListPlot[Traiispose[{Drop[ranl, - 1 ] , Drop [rani,!]}]]

In[41] : = Show [ Graphics3D [ Map [ Point, Partition [ rani, 3, 1]]]]

Note that the Partition [] function could have been used to generate the 2-tuples as well as the 3-tuples.

Fig. 5. Graph of the 2-tuples for the 5000 random numbers generated by the LCGX.

Page 131: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Evaluating pseudo-random number generators 137

Fig. 6. Cartesian plot of the 3-tuples for the 5000 random numbers generated by the LCGX.

However, the formalism using Drop[] is at least as fast, and it provides an alternative coding example.

Generators of the LCGX type show structure at the 2, 3 and higher tuple level. The better generators of this type do not show obvious structure at the 1-distrib-uted-level and have less distance between the hyper-planes containing the tuples. Much work has been done on this topic, called lattice structure analysis [4, 5 and refs. therein].

One interesting fact concerning the linear congru-ential generators is that if the period of the generator is iV, then there can only be N fe-tuples for any k. Thus a generator with a near infinite period will have a chance of having little or no lattice structure. This can be observed in several of the generators examined later.

4.2. Spherical plots of 3-tuples An alternative way of displaying the 3-tuples is to

make a "noise sphere" plot as described by Pick-over [13, 14]. Each 3-tuple is mapped to spherical coordinates (instead of cartesian coordinates), and then a small sphere is placed at each point location. The coordinate transformation of {(Ui, L^^+i, Ui+2)} to {(ri,Oi,(t>i)} is:

0

•if

(3)

(4)

(5)

To implement this algorithm efficiently in Mathemat-ica, I converted the spherical coordinates to cartesian coordinates and made a simple 3D plot instead of positioning spheres at the points.

In[19] : = disp = Table[ th - 2 Pi r a n l [ [ i ] ] ;

ph = P i r a n l [ [ i + 1 ] ] ; r = S q r t [ r a n l [ [ i + 2 ] ] ] ; X = r C o s [ t h ] S in [ph] ; y = r S i n [ t h ] S i n [ p h ] ; z = r Cos [ph] ; Point [N[{x ,y ,z} ] ] , { i , p t s - 2 } ] ;

In[20] : = Show [ Graphics3D [ disp ] ]

The various tendrils seen in Fig. 7 are indicative of a random number generator that has problems with the independence of a generated number from those previously produced in the sequence. Sometimes, it helps to see a 3D graphic from a different perspective. For this example, the "noise sphere" is so highly structured that little new information is gained, but the technique coded below (and shown in Fig. 8) may be useful in other cases.

In[21] : = Show [ Graphics3D [ disp,

Viewpoint^{0.086, -2 .728 , 2.000}]]

This type of rotation may be helpful in viewing the 3D Cartesian plots, too. In many instances Pickover's "noise spheres" are superior to the Cartesian plots because they require fewer trial rotations to see any structure.

4.3. Autocorrelation The fc-tuples plots give information on the local

effects of immediate neighbors. Calculation of the au-

Fig. 7. Graph of Pickover's "noise sphere" for the 5000 random numbers generated by the LCGX using Mathemat­

ical s default orientation of the 3-D graphic.

Page 132: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

138 R. L. BOWMAN

'ft..??

i 5 ^

Fig. 8. Pickover's "noise sphere" (Fig. 9) rotated so as to view more of its structure (accomplished by specifying a

different ViewPoint in the Mathematica code).

tocorrelation of the sequence of random numbers will give information of a more global nature, i.e., how much the nature of the sequence of random numbers as a whole depends on the value of the preceding member in the sequence. If two data sets, {X ] and {y ) , with zero means exist, then the correlation coef­ficient between the two sets is given by [ 9 ] :

r = ixy/(Zx'Lr')' (6)

The correlation coefficient must be in the range - 1 ^ r < 1. The two data sets of interest here would be the entire sequence of random numbers and the sequence beginning with one particular element of the sequence. The autocorrelation of { Ut ] is the set of all such correlation coefficients for 0 ^ / < (A^ - 1) if the sequence has A random numbers. The first element of the autocorrelation is from the sequence correlated with itself. The second element is the correlation of the sequence itself with the sequence where the ele­ments lag by one element, and so forth. A modified list of random numbers is created by subtracting 0.5 (this theoretical mean is very close to the actual mean for all of the examples in this paper) from each num­ber in order to form a series of random numbers with a zero mean, and an equal number of elements with a value of zero are added to this sequence (without affecting the results here) to facilitate later calcula­tions.

In[22] : = rd[100]; rm = J o i n [ r a n l - . 5 , Table[0 ,{pts} ] ] ;

In[24] : = sumsq = Apply [Plus, rm rm];

Short [ Table [ N[Apply[Plus ,Drop[rm,- i ] Drop[rm,i ] ] / sumsq],

{ i , 0 , p t s - l } , 7 ] Out[24]/ /Short=

{1., 0.0362677, -0.0807374, -0.0497768, -0.0713839, -0.00412415, 0.300523, 0.131343, -0.0205783, 0.0311595, -0.185502, -0.0979904,

0.143689, 0.0808925, 0.025406, -0.054287, 0.0410849, «75)) , -0.0365932, 0.00268043,

-0.0140809, 0.00170648, -0.025088, -0.00605305, -0.00274483, 0.00321278}

The above output is a list of the autocorrelation coefficients for the first 100 numbers of the sequence of random numbers under study. Only the first 17 coefficients and the last eight are printed. The re­maining 75 coefficients are indicated in standard Mathematica form by the symbol " ( ( 7 5 ) ) . "

The calculation of the autocorrelation can be made more efficient by using FFTs. Again, the sequence must have a zero mean, and the results will have to be normalized by dividing each coefficient by the zero-lag coefficient since any sequence of numbers must have perfect correlation with itself, i.e., a correla­tion coefficient equal to 1. To eliminate end effects from a sequence that is not periodic, the padding with zeros is necessary (as was already done in form­ing r m ) .

In[27] : =

correl = Chop[InverseFourier[Abs[Four-ier[rm]]^2]] ; Short [cor = correl /correl[[ l ] ] , 7 ]

Out[28]/ /Short= {!., 0.0362677,

-0.0713839, -0.00412415, -0.0205783, 0.0311595,

0.143689, 0.0808925, 0.0410849, ((175)), 0.300523, -0.00412415,

-0.0807374, 0.0362677}

-0.0807374, -0.0497768, 0.300523, 0.131343,

-0.185502, -0.0979904, 0.025406, -0.054287,

-0.0205783, 0.131343, -0.0713839,-0.0497768,

The two methods generate identical values except, that in the hhT case, the autocorrelation set is almost twice as large with ai = a„, a2 = a„-i, etc. Obviously the sequence should have absolute correlation with itself, hence the zero-lag term has a value of 1. Again, a plot will help in visualizing the results.

In[29] : = ListPlot[ Take [cor, pts ] ,

{PlotRange-^AU, PlotJoined^True} ]

Figure 9 shows the graph of the correlation coeffi­cients with lines connecting all of the graphed points.

Knuth[2] suggests that the correlation coefficients (except for the zero-lag value) should be in the range {-[2/(N- 1)][A^(A^- 3)/(A^+ 1 ) ] ' ' ' - [l/iN-l)]to[2/(N- imN(N - 3)/{N + l)V'^- [l/(N

Page 133: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Evaluating pseudo-random number generators 139

Fig. 9. Autocorrelation coefficients for the first 100 random numbers generated by the LCGX. Points are connected with

straight lines to aid in visualization.

- 1)]} at least 95% of the time for good generators where N is the number of random numbers in the sequence. In the case of the LCGX, this means that the correlation coefficients should be in the interval ( - 0 . 2 1 , +0.19) for at least 94 of the 99 coefficients. Only one of the 99 values is outside of this range. Since the autocorrelation test examines how a se­quence as a whole correlates to the same sequence offset by a fixed number of elements, the LCGX does well on the global scale. However, since the plots of the 2-tuples and 3-tuples tests how each number separately correlates with its predecessors, the LCGX does not do well on a local scale.

5. IMPROVEMENTS

5.1. Shuffling One modification that can be used to improve the

independence of a random number generator algo­rithm is to use some form of shuffling [ 3 - 5 ] . This is essentially a method whereby one random number sequence is used to shuffle another random number sequence. This does require more computer code and therefore is somewhat less efficient.

5.2. "Turning the Crank" n times Another alternative to reducing near-neighbor de­

pendence would seem to be simply to take only every nth output value from a generator. In other words, the generator is "cranked" n times for every output random number. This can be simply done in Mathe-matica using a Do [ ] loop.

In[91 : = pts = 5000; rnd = 2; ran = Table [

Do[rnd = Mod[N[157 rnd + 1] ,2048] , {5} ] ; rnd/2048,

{ i ,pts}]; In[12] : =

disp = (material deleted) In[13] : =

Show [ Graphics3D [ disp ] ]

Fig. 10 is a plot of the resulting "noise sphere" for the above example in which only every fifth generated point is used to form the sequence of random numbers. The plot suggests that this procedure did not help the problem of dependency. In fact since LCGX-type of generators have a finite period, this procedure only changes the structure of the dependency. It does not destroy it. Compare this plot with the similar one pre­viously shown in Fig. 7. (See also Pickover[6].)

5.3. An irrational modulus generator How would the results change if a noninteger modu­

lus were used? As an example let a = 13, c = 1 and M = 27r in Eqs. (1) and (2 ) . The calculations were done on a NeXT computer using Mathematica's de­fault precision of 16 digits. Only selected data will be shown. (The necessary Mathematic coding is the same as shown earlier for the LCGX generator unless other­wise noted.)

Since this generator with infinite precision does not appear to be periodic, its bar chart of 2000 points (Fig. 11) has more realistic variations than that of the LCGX near the completion of one period (Fig. 2 ) . The mean and square of the standard deviation (0.505296, 0.0844273) for these 2000 points are comparable to the theoretical values (0.49975, 0.083375).

The FFT analysis of this sequence (Fig. 12) shows less periodic structure than did the corresponding plot for the LCGX (Fig. 3 ) . The Fourier coefficients are generally smaller, and essentially all periods contrib­ute to the resulting sequence of random numbers, i.e., very few of the periods have a zero Fourier coefficient as compared to the coefficients for the LCGX.

Further evidence of the independence of the ele­ments of the sequence from each other comes from

Fig. 10. Pickover's "noise sphere" for the sequence produced by ' 'cranking'' the LCGX five times for each random number

generated.

Page 134: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

140 R. L. BOWMAN

Fig. 11. Bar chart of the counts of random numbers, for the first 2000 numbers produced by the linear congruential generator with modulus IT^ (see text for details), in each of

ten equal subintervals in the interval [0, 1).

Fig. 14. Graph of the 2-tuples for the 5000 random numbers generated by the linear congruential generator with modulus

27r.

i l l i l [U.ii.ll ih .iLiiillliiil dl

number generated provides a more random appearing plot of the "noise sphere" (Fig. 16). The results of all of the other analyses (described earlier for the LCGX) are also suggestive of a good random number generator. For example the 2-tuple plot of 5000 points (Fig. 17) displays no obvious structure.

liillkiit^lilll-hi4lli^iiJlilltJ;|-Fig. 12. Fourier coefficients calculated using Fast Fourier Transforms for the first 6144 numbers produced by the linear

congruential generator with modulus In.

the plot of the random numbers in the order in which they were generated (Fig. 13). This plot shows less structure than the corresponding plot for the LCGX. However, the plots of the 2-tuples (Fig. 14) and the "noise sphere" plot of the 3-tuples (Fig. 15) all show obvious structure. The global independence as mea­sured by the autocorrelation is still within the bounds described by Knuth[2] and will not be shown here.

Since there is no apparent fixed period for the se­quence, the "«-crank" technique does help produce more local independence. Selecting every second

5.4. A more efficient irrational modulus generator My search finally led to a generator that does not

require a "crank" to meet the conditions described in this paper. This generator is similar to the one just described but with a = 157, c = 1 and M = n in Eqs. (1) and ( 2 ) . The tests for uniformity looked very good as do those for independence. The x^ test gives a /?-value of 1 - 0.41 = 0.59, meaning that the null hypothesis can be rejected only with 4 1 % confidence. Different seed values do give slightly different statis­tics, but at least for seeds (rnd) 0, 1,2, and 3 all of the tests were favorable.

Fig. 13. Plot of 5000 random numbers in the order in which the linear congruential generator with modulus ITT generated

them.

Fig. 15. Graph of Pickover's "noise sphere" for the 5000 random numbers generated by the linear congruential genera­

tor with modulus ITT.

Page 135: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Evaluating pseudo-random number generators 141

Fig. 16. Pickover's "noise sphere" for the sequence produced by "cranking" the linear congruential generator with modu­

lus 27r two times for each random number generated.

Fig. 19. Cartesian plot of the 3-tuples for the 5000 random numbers generated by the linear congruential generator with

modulus TT.

Fig. 18. Graph of the 2-tuples for the 5000 random numbers generated by the linear congruential generator with modulus

TT as described in the text.

As an example of the results of the tests for indepen­dence. Fig. 18 is the plot of the 2-tuples, and Fig. 19 is a Cartesian plot of the 3-tuples. (A seed value of 2

was used to form a sequence of 2000 random num­bers.) The plot of the autocorrelation (Fig. 20) also supports the acceptability of this generator.

5.5. Other generators As a point of comparison, the output from Mathe­

matical s own Random[] function and the output from the RND function in BASIC on the Commodore 64 will be studied. Pickover[13] shows a "noise sphere" for output from IBM-PC BASIC Version A2.10 which shows definite structure and thus local dependency. However, the Commodore 64 BASIC did not show any obvious structure in a similar plot. Its x^ l^st for a 2000-number sequence gave a/?-value of 0.14, meaning that the null hypothesis can be rejected only at the 86% confidence level. And in the tests of inde­pendence, it did as well as the best generator above.

The output from Random[] in Mathematica also looked good when subjected to all of the above tests.

Fig. 17. Graph of the 2-tuples for the sequence produced by "cranking" the linear congruential generator with modulus

l-K two times for each random number generated.

?V^MwWvHV ' -vr°°

Fig. 20. Autocorrelation coefficients for the first 100 random numbers generated by the linear congruential generator with modulus TT. Points are connected with straight lines to aid in

visualization.

Page 136: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

142 R. L. BOWMAN

But interestingly, its appearance in these tests was no better than that of the best irrational modulus generator and the C-64 BASIC generator in these tests. Of course, there are additional tests, not discussed in this tutorial, which may be conducted to assess the quality of these random number generators.

6. CONCLUSION The graphical and computational capabilities of

Mathematica make it an excellent choice for visualiz­ing the randomness (or lack thereof) of a sequence of numbers that is the output of a particular random num­ber generator. Some of the limitations of linear con-gruential generators with integer parameters were readily observable with these techniques. However a congruential generator with a modulus of TT did very well in the tests outlined here and will hopefully be of use to others needing a quickly programmable random number generator. The generators used by Mathemat­ica and Commodore 64 BASIC also equally passed.

There are many more tests that could be applied to the generated sequences [ 5 ] . Students and researchers may wish to investigate the use of such tests when programming in Mathematica.

Acknowledgements—The author wishes to thank Dr. Nelson Blachman for extensive Internet conversations and Dr. Clif­ford Pickover for his suggestion of the "noise sphere" plots. This study was supported in part by a sabbatical grant from Bridgewater College.

REFERENCES 1. Wolfram Research, Inc., Mathematica, Version 2.2,

Wolfram Research, Inc., Champaign, ILL (1993). 2. D. D. Knuth, The Art of Computer Programming, Vol.

2, 2nd ed., Addison-Wesley, Reading, MA (1981). 3. W. H. Press, S. A. Teukolsky, W. T. Vetterling, and

B. P. Flannery, Numerical Recipes in FORTRAN, 2nd ed., Cambridge University Press, Cambridge, England (1992).

4. B. D. Ripley, Stochastic Simulation, John Wiley, New York (1987).

5. J. Dagpunar, Principles of Random Variate Generation, Oxford University Press, New York (1988).

6. C. Pickover, Random number generators: pretty good ones are easy to find. The Visual Computer, in press.

7. W. H. Press and S. A. Teukolsky, Portable random num­ber generators. Computers in Physics 6, 522-524 (1992).

8. G. Marsaglia and A. Zaman, Some portable very-long-period random number generators. Computers in Physics 8, 117-121 (1994).

9. J. B. Kennedy and A. M. Neville, Basic Statistical Meth­ods for Engineers and Scientists, 3rd ed.. Harper & Row, New York (1986).

10. B. J. T. Morgan, Elements of Simulation, Chapman and Hall, London (1984).

11. P. Boyland, A. Chandra, J. Keiper, E. Martin, J. Novak, M. Petkovsek, S. Skiena, I. Vardi, A. Wenzlow, T. Wick-ham-Jones, D. Withoff, et ai. Guide to Standard Mathe­matica Packages, Version 2.2, 3rd ed.. Wolfram Re­search, Inc., Champaign, IL (1993).

12. S. Wolfram, Mathematica: A System for Doing Mathe­matics by Computer, 2nd ed., Addison-Wesley, Reading, MA (1991).

13. C. A. Pickover, Picturing randomness on a graphics su­percomputer. IBM J. Res. Develop. 35, 227-230 (1991).

14. C. A. Pickover, Computers and the Imagination, St. Mar­tin's Press, New York (1991).

Page 137: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved

Part III. Cellular Automata, Gaskets, and Koch Curves

Cellular automata are a class of simple mathematical systems that are becoming important models for a variety of physical processes. They can exhibit random-looking behavior sometimes and highly ordered behavior at others - depending on the rules of the game. Generally speaking, cellular automata are mathematical idealizations of physical systems in which space and time are discrete. Interesting previous applications include the modeling of the spread of plant species, the propagation of animals such as barnacles, and the spread of forest fires. One notable recent application of cellular automata is in traffic engineering (Gaylord, 1995). Referred to variously as "cellular automata", "homogenous structures", "cellular structures", and "iterative arrays", cellular automata have been applied to, and reintroduced for, a wide variety of purposes.

Ofl;en, cellular automata consist of a grid of cells that can exist in two states, occupied or unoccupied. The occupancy of one cell is determined from a simple mathematical analysis of the occupancy of neighbor cells. Mathematicians define the rules, set up the game board, and let the game play itself out. One popular set of rules is set forth in what has become known as the game of "Life" (Poundstone, 1985). Though the rules governing the creation of cellular automata are simple, the patterns they produce are very complicated and sometimes seem almost random, like a turbulent fluid flow or the output of a cryptographic system. Cellular automata have also played important roles in the developments in the field of artificial life - an early example is the use of cellular automata to simulate the origin of life (Tamayo, 1989). A good survey of relations between cellular automata and complexity is provided in (Gutowitz, 1996).

Recent research has shown that some cellular automata exhibit self-organization, lifelike cellular patterns, and self-similarity (Barbe, 1996). Other researchers have recently related linear cellular automata to iterated function systems (Haesler, 1992) and cellular automata to chaos (Codenotti, 1996).

This book section also discuses fractal gaskets. In everyday life, the term gasket refers to a piece of material from which sections have been removed. Mathematical gaskets, such as Sierpinski gaskets, can be generated by removing sections of a region according to some rule. Usually the process of removal leaves pieces which are similar to the initial region, thus the gasket may be defined recursively. The resulting shapes are of interest mathematically, and they reveal a visually striking and intricate class of patterns which make up a family of regular, fi'actal networks.

For me, the most interesting gasket patterns are self-similar; for example, if we look at any one of the triangular motifs within Pascal's triangle mod 2 (as in Jim Nugent's paper in this section), we notice that the same pattern is found at another place in another size. The two- and three-dimensional networks revealed in several of this section's figures are known as Sierpinski gaskets which share important geometrical features with percolation problems and cellular automata. The Sierpinski gasket consists of triangles nested in one another like Chinese boxes or Russian dolls. This kind of dilation symmetry has been discovered and applied in different kinds of phenomena in condensed matter physics, diffusion, polymer growth, and percolation clusters. One example given by Kadanoff is petroleum-bearing rock layers. These typically

145

Page 138: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

146

contain fluid-filled pores of many sizes, which, as Kadanoff points out, might be effectively understood as Sierpinski gaskets.

Fractal gaskets have a practical importance in that they can provide models for materials scientists producing new structures with novel properties. For example, Gordon et al. (1986) have created wire gaskets on the micron size scale. The area of the smallest triangle in their microscopic gasket was 1.38d=0.01 |im^, and they have investigated many unusual properties of their superconducting Sierpinski gasket network in a magnetic field. Because of gaskets' dilation symmetry, statistical-mechanical and transport problems are exactly solvable on these fractals - making them attractive candidates as model systems.

For Further Reading

(1) Barbe, A. (1996) Coarse-graining invariant orbits of one-dimensional Zp-linear cellular automata. Bifurcations and Chaos. 5: 2237-2297.

(2) Barbe, A., Haeseler, F, Peitgen, H., and Skordev, G. (1995) Coarse-graining invariant patterns of one-dimensional two-state linear cellular automata. Bifurcation and Chaos 5: 1611-1631.

(3) Brown, D. (1987) Competition of cellular automata rules. Complex Systems. 1: 169-180. (4) Codenotti, B. and Margara, L. (1996) Transitive cellular automata are sensitive. American

Mathematical Monthly. January, 103: 58-62. (5) Conway, J., Berlekamp, E., Guy, R. (1982) Winning Ways for Your Mathematical Plays.

Academic Press: New York. (6) Dixon, R. (1992) The pentasnow gasket and its fractal dimension. In Fivefold Symmetry,

I., Hargittai, ed. World Scientific: River Edge, New Jersey. (7) Gaylord, R. and Nishidate, K. (1995) Traffic engineering with cellular automata,

Mathematica in Education and Research 4: 35-39. (8) Gordon, J., Goldman, A., Maps, J. (1986) Superconducting-normal phase boundary of a

fractal network in a magnetic field. Physical Review Letters. 56: 2280-2283. (9) Gutowitz, H., ed. (1991) Cellular Automata: Theory and Experiment, MIT Press:

Cambridge, Massachusetts. (10) Gutowitz, H. (1996) Cellular automata and the sciences of complexity, I and II, Complexity

1, 5: 16-22; 6: 29-35. (11) Haeseler, F, Peitgen, H., and Sokordev, G. (1992) Linear cellular automata, substitutions,

hierarchical iterated function systems and attractors, pp. 2-23 in Fractal Geometry and Computer Graphics, J.L. Encamagao, H.-O. Peitgen, G. Sakas, and G. Englert, eds. Springer-Verlag: New York.

(12) Holter, N, Lakhtakia, A., Varadan, V, Vasundara, V, and Messier, R. (1986) On a new class of planar fractals: the Pascal-Sierpinski gaskets. Journal of Physics A: Mathematics General 19: 1753-1759.

(13) Kadanoff, L. (1986) Fractals: where's the physics? Physics Today February, 6-7. (14) Lakhtakia, A., Vasundara, V, Messier, R., and Varadan, V (1987) The generalized Koch

Curve. Journal of Physics. A: Mathematics General 20: 3537-3541. (15) Levy, S. (1985) The portable universe: getting to the heart of the matter with cellular

automata. The Whole Earth Review Magazine. Winter issue, 42-48. (16) Maeder, D. (1987) The free energy concept in cellular automaton models of solid-solid

phase transitions. Complex Systems. 1: 131-144. (17) Peterson, I. (1987) Forest fires, barnacles, and trickling oil. Science News. 132: 220-221. (18) Pickover, C. (1996) Fractal Horizons: The Future of Fractals. St. Martin's Press: New

York. (19) Poundstone, W. (1985) The Recursive Universe. William Morrow and Company: New

York.

Page 139: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

147

(20) Reiter, C. (1997) The game of life on a hyperbolic domain. Computers and Graphics, 21(5): 673-683.

(21) Schrandt, R., S. Ulam (1970) On recursively defined geometrical objects and patterns of growth. In Essays on Cellular Automata, A. Burks, ed. Univ. of Illinois Press, Chicago.

(22) Tamayo, R and Hartman, H. (1989) Cellular automata, reaction-diffusion systems and the origin of life, pp. 105-124, in Artificial Life, C. Langton, ed., Addison-Wesley: New York.

(23) Wolfram, S. (1983) Statistical mechanics of cellular automata. Review of Modern Physics. 55: 601-644.

Page 140: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 149

Chaos and Graphics

SENSITIVITY IN CELLULAR AUTOMATA: SOME EXAMPLES

MICHAEL FRAME Mathematics Department, Union College, Schenectady, NY 12308-2311

Abstract—We study how the final pattern produced by particular one-dimensional cellular automata can depend on the starting configuration of live and dead cells. In particular, we show that slight changes in the initial state can lead to different universality classes (in the sense of Wolfram) for the final state. A peculiar anthropomorphic pattern appears in one of our experiments. Finally, for two example automata we investigate a small part of the initial condition space, a map of which initial conditions lead to which Wolfram classes.

One-dimensional cellular automata are simple to un­derstand and easy to simulate, yet can produce inter­esting—even surprising—patterns. In this note we consider examples of how slight changes in the initial state of some automata can give rise to considerably different final states.

Since it suffices for our examples, we restrict our attention to one-dimensional, binary automata with the neighborhood of a cell consisting of the two cells immediately on either side of it. The cell space is a line of boxes (the cells), and each cell is in one of two states ("hve" and "dead"). Often it is convenient to consider the cells as indexed by the integers. The dynamics of the automaton can be viewed by taking the initial ar­rangement of live and dead cells as the first generation, and then producing the second generation, determining the state of each cell from the states of its neighbors. In particular, some collection of neighborhood config­urations, or templates, is specified and the automaton can be viewed as a reader, progressing down the line of cells. At cell n, the automaton compares the ar­rangement of live and dead cells in the neighborhood of cell n (for our examples, this neighborhood is cells n — 2, n — \, n, n -\- 1, and « + 2) with the collection of templates. If the neighborhood configuration matches one of the templates, then cell n is alive in the next generation of the cell space, otherwise cell n is dead in the next generation. By the same process, we go ft*om the second to the third generation, from the third to the fourth, and so on.

The collection of templates is the rule for the au­tomaton. A rule is called totalistic if the templates of a rule are determined by only the number of live cells in the neighborhood, not by their particular positions. Denoting live cells by 1 and dead cells by 0, the rule with templates (1,0,0,0,0), (0,1,0,0,0), (0,0,1,0,0), (0,0,0,1,0), and (0,0,0,0,1) is an example of a totalistic rule: any template with exactly one live cell gives rise to a live cell. Totalistic rules can specify any combi­nation of zero through five live cells.

Giving a special role to the central cell of the neigh­borhood, totalistic rules are augmented to outer total­istic rules, the form of all our examples. Excluding the

central cell, a neighborhood consists of four cells. A rule is outer totalistic if it can be cast in this form: specify numbers of the four neighboring cells must be alive with the central cell dead, and specifying perhaps diflferent numbers of the four with the central cell alive. We express this type of rule by a 10-tuple: (do,dud2,d3,d4\ao,ai,a2,a3,a4). A 0 in location dt means if the central cell is dead and exactly / of the four neighbors are alive, then the central cell dies in the next generation; a 1 in location di means if the central cell is dead and exactly / of the four neighbors is alive, then the central cell becomes alive in the next generation. The entries for at have the corresponding interpretations when the central cell is alive. For ex­ample, the outer totalistic automaton (0,1,1,0,0; 0,0,1,0,0) gives a live cell in the next generation if the central cell is dead and exactly one or two of the four neighbors is alive, or if the central cell is alive and exactly two of the four neighbors is alive.

Though cellular automata seem very simple—almost transparent—the number of rules is surprisingly large, so large that for the more general automata analysis by inspection is completely impossible. If there are k states per cell and m cells in a neighborhood, then there are k^ neighborhood configurations and hence /c^ rules. For binary automata with five cell neighborhoods there are 2^' = 4,294,967,296 different rules. Of course, the outer totalistic automata are much more restrictive: there are only 1024 rules. On the other hand, binary automata with seven cell neighborhoods have 2^ = 340,282,366,920,938,463,463,374,607,431,768, 211,456 different rules, clearly more than can be searched case-by-case. In the face of these staggering numbers, are there any general conjectures about broad classes of automaton behavior?

Stephen Wolfram has conjectured long-term behav­ior of automata is organized into just a few classes. For growth from a single live cell, there are only three possibilities: 1. the pattern becomes homogeneous; 2. a pattern of fixed size evolves; 3. a pattern with boundary expanding at a fixed rate

evolves.

Reprinted from Comput. & Graphics Vol 18, No. 5, pag. 733-737, 1994

Page 141: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

150 M. FRAME

Type (3) can be subdivided further as

(3a) the pattern inside the boundary is uniform; (3b) the pattern inside the boundary is fractal; (3c) the pattern inside the boundary is chaotic.

Better-known, though not relevant to the examples we consider here, is Wolfram's classification for evolution from random initial configurations:

I. the pattern becomes homogeneous; II. the pattern evolves to a fixed periodic configura­

tion; III. a chaotic pattern forms; IV. complex, localized structures form.

Christopher Langton has proposed a parameter, X, for predicting the class into which an automaton falls. For binary automata, X is given by

number of neighborhood configurations giving live cells

total number of neighborhood configurations

As X increases from 0 to ^, the automaton behavior passes from Class I to II, through IV, and finally to III. (Every automaton with X > ^ corresponds to one with X < 5 with the roles of "live" and "dead" cells inter­changed.) Langton argues that class I and II are anal­ogous to solids, class III to fluids, and class IV to the phase transition, with X playing the role of temperature. The correspondence is subtle, however, but is more faithfully represented in examples as the denominator of X becomes larger

Instead of pursuing these global issues, we consider four examples illustrating how small changes in the initial configuration can lead to considerably different behavior, changing the Wolfram class of the pattern. Example 1: Consider the automaton given by the rule (0,l,l,0,0;0,0,l,0,0).ThetopofFig. 1 shows the pattern evolving from a single live cell. As usual, each successive generation is plotted below its predecessor, so time in­creases down the picture. Also as usual, the boundary conditions involve a wraparound: the left edge of the picture is identified with the right edge. The bottom of Fig. 1 shows the pattern evolving from two adjacent live cells. Until the "interference" from the wraparound returns the original pattern, we observe a version of the Sierpinski gasket. If this automaton had infinite extent (no wraparound), the patterns shown at the top part of each picture would persist forever and we see the addition of a single live cell to the initial configu­ration changes the asymptotic pattern from Wolfram class 3c to 3b. Taking three adjacent live cells as initial state gives a gasket even with the wraparound. Example 2: For the automaton given by the rule (0,1,1,0,0; 0,0,1,1,0), the top of Fig. 2 shows the pattern evolving from a single live cell, while the bottom of the figure shows the pattern evolving from two adjacent live cells. Again a gasket emerges, even after the wra­paround (though note the appearance of some pertur­bations after the wraparound). Here the addition of a single live cell changes the final state from Wolfram class 3a to 3b.

Example 3: In Fig. 3 we see patterns generated by the rule (0,1,1,1,0; 0,0,1,1,0). The top is the pattern evolv­ing from a single live cell, the bottom, the pattern

Fig. 1. The pattern evolving for the outer totalistic automaton with rule (0,1,1,0,0; 0,0,1,0,0). Top: from a single live cell. Bottom: from two adjacent live cells. Adding the additional live cell to the initial configuration

changes the Wolfram class from 3c to 3b.

Page 142: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Sensitivity in cellular automata 151

Fig. 2. The pattern evolving for the outer totalistic automaton with rule (0,1,1,0,0;0,0,1,1,0). Top: from a single live cell. Bottom: from two adjacent live cells. Adding the additional live cell to the initial configuration

changes the Wolfram class from 3a to 3b.

evolving from two adjacent live cells. Until the wrap­around, the change in final states is especially striking— from Wolfram class 3c to 3a. After the wraparound, we observe the appearance of yet another gasket.

From these three examples, we might be led to some hypotheses (perhaps about the ubiquity of gaskets), but considering the number of different automata mentioned above, we know such speculations are silly.

Fig. 3. The pattern evolving for the outer totalistic automaton with rule (0,1,1,1,0,0,0,1,1,0). Top: from a single live cell. Bottom: from two adjacent live cells. Adding the additional live cell to the initial configuration

changes the Wolfram class from 3c to 3a, before the wraparound.

Page 143: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

152 M. FRAME

Fig. 4. The pattern evolving for the outer totalistic automaton with rule (0,1,1,0,0;0,1,0,1,1). Top: from a single live cell. Bottom: from three adjacent live cells. Adding the additional live cells to the initial configuration does not change the Wolfram class, but does give rise to a "laughing skull" near the middle of the picture.

In fact, in our final example, the automaton exhibits completely different behavior. Example 4: Consider the rule (0,1,1,0,0;0,1,0,1,1). The top of Fig. 4 is the pattern evolving from a single live cell. From two adjacent live cells, a similar pattern grows—no different final state, no gasket. The bottom of Fig. 4 shows the pattern from three adjacent live cells. We chose to show this instead of the two-cell pat­tern of the earlier figures because of a surprise: notice the "laughing skull," which has appeared about two-thirds of the way below the initial live cells (Fig. 5). Outer totalistic rules produce bilaterally symmetric patterns from symmetric initial conditions, and human forms are (approximately) bilaterally symmetric, but

the appearance of this skull looking out of the screen was unexpected.

Without the wraparound, in Example 1 we observe Wolfram state 3c evolving from a single live cell, while 3b evolves from two adjacent live cells. In Example 2 we see 3a and 3b from one and two live cells. In Ex­ample 3 we see 3c and 3a from one and two live cells. Where do the patterns of Example 4 fit into this clas­sification? Letting the automaton run long enough, the lacy structures and laughing skulls eventually disappear, leaving only the periodic background. That is, the in­teresting structures we see in this example are just transient phenomena.

From these observations we are led to the natural

Fig. 5. Left: the laughing skull excised from the bottom of Figure 4. Right: a magnification of the skull, set against a grey background for contrast.

Page 144: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Sensitivity in cellular automata 153

Fig. 6. A portion of initial configuration space for the automata of Examples 2 and 3. The initial configurations sampled consist of two blocks of n live cells, separated by a block of/c dead cells, for 1 < n, k < 20. Here

black represents class 3a, white 3b, and grey 3c.

problem of constructing a "map" of which initial con­figurations give rise to which final states. How to rep­resent this map is another problem: the array of initial conditions is so vast that a low-dimensional represen­tation of the all possibilities cannot be achieved. Here we shall content ourselves with a small slice of initial condition space, two blocks of n live cells, separated by a block of A: dead cells, for 1 < « , / : < 20. The results for Examples 2 and 3 are presented in Fig. 6. Here black represents class 3a, white 3b, and grey 3c. While the final states are intertwined in a complicated way, we have not examined a large enough section of initial condition space to conclude the sets leading to a par­ticular state (the basin of attraction of that final state) have fractal boundaries. The evidence of this small sample does not support that notion, but then perhaps we have seen an unrepresentative choice of section through initial condition space.

Typical experiments with cellular automata usually focus on patterns evolving from a single live cell or from a random distribution of live cells. Readers may find some interest in the type of exploration suggested by these examples: compare the final states arising from starting configurations differing by a small amount. Though nevy; behaviors from individual conditions are unlikely, the global structures revealed in initial con­dition space may exhibit considerable complexity.

In the absence of an analytic formulation of autom­aton evolution, this type of graphical exploration, per­haps augmented by automated initial condition selec­tion and final state pattern recognition, is the best av­enue for studying final state sensitivity in cellular automata.

Automaton Pseudocode (outer totalistic, radius = 2, binary, linear)

Outer totaUstic rule (do^dudj^d^,d^^\OQ,«I,^2,^23,<24) Rule Number = t/o + 2 * ^ , + 4*^2 + 8*^3 + 16*^/4 + 32*(ao + 2*a, + 4*fl2 + 8*^3 + 16*^4) A = number of automaton cells to be presented Cell states are represented by c[/] for / = 3 to A + 3,

with "edge cells" c[ 1], c [2] , c[N -\- 4 ] , and c[N + 5] to accommodate wraparound. If cell / is alive, c[i] = 1; if cell / is dead, c[i] = 0. For / = 3 to A/ + 3, Z?[/] are buffer cells, keeping track of the next generation of cells without changing the current generation. The generation number (number of iterations of the automaton rule to the entire configuration) is repre­sented by the integer gen.

Assign initial configuration to c[/] for / = 3 to TV + 3 gen = 1

Plot For /• = 3 to A/ + 3 plot a dot at pixel (/, gen) if c[i] = 1

Assign edge cells c[\] = c[N+2],c[2] c[A^+ 5] = c[4]

c[A^+3],c[A^+4] = c[3],

Evolve For / = 3 to A + 3 Nbhd Number = (2A(c[ / - 2] + c[i - I] + c[i + l] + c[/ + 2]))*(c[ / ]*32) Nbhd Number is a power of 2. If this power of 2 occurs in the binary representation of the Rule Number, then b{i] = 1, else b[i] = 0. gen = gen + 1

Rename For / = 3 to A + 3 c[i] = b[i]

Repeat: Plot, Assign edge cells. Evolve, Rename.

REFERENCES A. K. Dewdney, The Armchair Universe An Exploration of Computer Worlds, W. H. Freeman, New York (1988). C. Langton, et al. (Eds.), Artificial Life II, Addison-Wesley, Redwood City, CA (1992). S. Wolfram, Theory and Applications of Cellular Automata, World Scientific, Singapore (1986).

Page 145: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 155

Chaos & Graphics

ONE TUB, EIGHT BLOCKS, TWELVE BLINKERS AND OTHER VIEWS OF LIFE

JOHN E. PULSIFER* and CLIFFORD A. REITER^^

400 Liberty Valley, Danville, PA 17821, U.S.A. ^Department of Mathematics, Lafayette College, Easton, PA 18042, U.S.A.

e-mail: [email protected]

Abstract—The time evolution of Conway's Game of Life is visualized in three dimensions by stacking the states at each generation. The color associated with each cell is determined by the number of neighboring live cells. Views generated by square initial configurations and classic configurations are considered. Copyright © 1996 Elsevier Science Ltd

1. INTRODUCTION

The Game of Life, created in 1970 by John Conway [1] is a favorite of computer users because of the rich behaviors that occur and the visual appeal of showing successive generations using animations. Initial configurations are known that move them­selves through space and others generate infinite streams of such configurations. Descriptions of the behaviors and dehghtful initial configurations are available from a variety of sources including [1-6]. A computer archive of initial configurations is described in the Appendix.

The Game of Life is a 2-D binary cellular automata. That is, at each generation there is an infinite "checker board" (2-D square lattice) of cells where each cell is either alive or dead. The states of the cells evolve from generation rto generation t+\ according to the local rules given below. It turns out that these rules depend only on the state of the cell and the number of its eight neighbors that are aHve.

• A cell that is alive at t will be alive at ^+1 if, and only if, it has 2 or 3 live neighbors at t.

• A cell that is dead at t will be aUve at r+1 if and only if 3 of its neighbors are aUve at time t.

While it is traditional to view the Game of Life using animations, the successive generations can be stacked and viewed in 3-D. In fact, any 2-D automaton can be viewed in this way [7, 8] or examples\life.m in [9]. Of course, single generations of a 3-D automaton can be viewed in 3-D as well [10, 11]. It is also traditional to show each cell as dead or alive by using two contrasting colors; however, we will use several colors to distinguish the number of alive neighbors for each alive cell. In particular, dead cells are transparent, aHve cells with no aUve neighbors are shown in black, those with 1 aUve

^ Author for correspondence.

neighbor are shown in red, and so on using green, blue, yellow, and magenta; lastly, cyan corresponds to 6, 7 or 8 alive neighbors. Thus, black and red cells die, blue and green cells persist to the next genera­tion, and yellow, magenta and cyan cells die.

2. EVOLUTION OF SQUARES

We first consider the long-term behavior of initial configurations consisting of a filled square of aUve cells. Various common configurations appear often in the long-term evolution of the Game of Life. Figure 1 shows several such configurations. The first row of configurations contains a block, a tub, a pond and a snake. These are all stable configurations. The first configuration in the second row is called a honey farm. It consists of 4 beehives and is also stable. The second and third entries in the second row form a traffic hght. It consists of 4 bUnkers which alternate

Table 1. The long-term behavior of the Game of Life when the initial configuration is a filled square with sides of

length n.

n = 1 dies immediately n = l is stable from r = 0 (it is a block) « = 3 dies at r = 9 n = A dies at / = 4 n = S terminates in the honey farm at t=\\ n = 6 forms a pond at r = 5 n = 7 makes a traffic light at / = 11 n = 8 dies at f = 6 n = 9 turns into 4 traffic lights and 1 tub at r= 17 n= 10 forms 1 pond at ^= 17 n = 11 becomes a traffic light at r=33 n=12 fades at r=9 n = 13 makes a tub at r = 18 n = 14 turns into a pond at /=9 n=15 diesatr=22 n = 16 forms 4 ponds and 4 beehives at t=l\ n=n makes 1 tub, 8 blocks, and 12 blinkers at r = 33 n= 18 turns into 8 blocks, and 1 pond at t=n /!= 19 makes 5 traffic lights at r=21 n = 20 dies at r= 12

Reprinted from Comput. & Graphics Vol. 20, No. 3, pag. 457-462, 1996

Page 146: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

156 J. E. Pulsifer and C. A. Reiter

Si 1 i(

M 1

L i i * < * M M M t I l l l l l l l l l l

• * ^ : | -.-1^.

1 ^ ^ : i

y^

H * 1

fcs .Ai%%s ^^^H^Kv.<Cs.s%; •»vw ^ v s * ^ ^ ^ ^ ^ B Nnifdsi

Fig. 1. Some common configurations.

between a vertical and horizontal position as shown. The last row of Fig. 1 shows the result of 4 generations of the Game of Life applied to a glider. Notice that after 4 generations the initial configura-

Fig. 2. Evolution of a 13 by 13 square. Fig. 3. Evolution of a 17 by 17 square.

Page 147: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Conway's Game of Life 157

Fig. 5. Evolution of the B-heptomino.

Fig. 4. Evolution of a random initial configuration.

tion reappears displaced one cell vertically and horizontally. Thus, a glider, in the absence of any interference from other cells, will move off toward infinity.

Table 1 gives the long-term behavior for small square initial configurations. These configurations sometimes die out but often show a simple long-term behavior. For example. Fig. 2 shows the time evolution of an initial 13 by 13 square for 60 iterations. The square base is visible and the growth of the outer edge continues for some time. The interior becomes a jumble, all parts dying out except a tub, shown as a green tower in the center. Of course the figure has the symmetry of the square (the Dihedral group, D4) since the initial configuration does and because the Game of Life preserves that symmetry. Figure 3 shows 60 iterations on an initial 17 by 17 square. Here the base square is visible along with some symmetric jumble.

but there is considerable stable long-term behavior— namely, one tub (the green tower in the center), eight blocks (the blue towers) and twelve blinkers (the green and red towers). That configuration inspired the title of this note.

3. CLASSICAL CONFIGURATIONS

Animations displaying the Game of Life frequently use an initial configuration where the initial states are randomly selected between alive and dead. Figure 4 shows 151 generations of the Game of Life on a 20 by 20 random configuration (the probability of initially being alive is one-third). Notice that the region of alive cells seems to expand—often some organized behavior such as ponds or blocks appear for a time but then these are disturbed by neighboring activity. As the number of generations increases, there is a general tendency toward more organized behavior. This is consistent with the view of the Game of Life as being slightly on the organized side of chaos.

Page 148: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

158 J. E. Pulsifer and C. A. Reiter

Fig. 6. Evolution of thunderbird.

Nonetheless, very small configurations can have very complex long-term behavior. For example, Fig. 5 shows 130 generations of the B-heptomino. This is a small, somewhat vigorous configuration that begins with 7 alive cells and results in 2 gliders and 3 blocks after 148 generations. In the figure, two of the blocks are visible as the blue vertical towers. Both gliders are visible moving off at diagonals to the right and the left. Notice the gliders are blue and green on the bottom, where they will persist, and red on the top, where they dre. Also notice the regions where the qualitative feel is very similar to the random case. The B-heptomino configuration and all the remain­ing configurations can be accessed electronically (see Appendix).

Fig. 7. Evolution of the bi-gun.

Figure 6 shows 145 generations of "thunderbird", a configuration that runs a bird-like symmetric pattern around a spiral until ending in a traffic Ught. Along the way, several blinkers are "fed" to the birds. Figure 7 displays 120 generations of the "bi-gun". This configuration is periodic except that gliders are spewn out. Notice the gliders moving off" to the left and right and the blocks forming blue towers that bound the periodic part of the image. Lastly, Fig. 8 shows 120 generations of the "pulsar puffer train" which moves off" to the right leaving behind a trail of pulsars. The pulsars are shown as the large towers.

4. CONCLUSIONS

The time evolution of 2-D automata can be visualized using stacked cells in three dimensions. In particular, the evolution of the Game of Life can be visuaHzed using a color scheme to provide information about the number of alive neighbors each cell has at each generation. The qualitative behavior of random initial configurations can be viewed and common configurations, such as ponds, blocks, blinkers and gliders can be recognized. Interesting initial configurations are viewed. These

Page 149: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Conway's Game of Life 159

Fig. 8. Evolution of the pulsar puffer train.

include one which is periodic except for the genera­tion of streams of gliders and another where the generator moves leaving a trail of periodic behaviors.

10. A. K. Dewdney, The Armchair Universe, W. H. Free­man and Company, New York (1988).

11. C. A. Pickover, Lava lamps in the 21st century. The Visual Computer 10, 173-177 (1993).

REFERENCES 1. M. Gardner, The fantastic combinations of John

Conway's new solitare game of "life". Scientific American 223, 120-123 (1970).

2. E. Berlekamp, J. Conway and R. Guy, Winning Ways For Your Mathematical Plays, Academic Press, New York (1982).

3. M. Gardner, On cellular automata, self-replication, the Garden of Eden and the game "life". Scientific American 224, 112-117 (1971).

4. William Poundstone, The Recursive Universe: Cosmic Complexity and the Limits of Scientific Knowledge, Contemporary Books, Chicago (1985).

5. E. Rietman, Creating Artificial Life: Self Organization, Windcrest/Mcgraw-Hill, New York (1993).

6. T. Toffoli and N. Margolus, Cellular Automata Machines: A New Environment for Modeling, MIT Press, Cambridge, MA (1987).

7. C. A. Reiter, Fractals, Visualization and J, Iverson Software, Inc., Toronto (1995).

8. S. Wolfram, Theory and Applications of Cellular Automata, World Scientific, Singapore (1986).

9. S. Wolfram, Mathematica, a System for doing Mathe­matics by Computer (2nd edn), Addison-Wesley Pub­lishing, Redwood City, CA (1991).

APPENDIX

Implementation and Resources The figures shown in this note were created by

implementing the Game of Life and the color scheme in the programming language J. All the examples here were run on large enough initial fields so that the boundary conditions played no role. The results of those computa­tions were then formatted for, and rendered by the freeware ray tracing program POVRAY. The J language is available by anonymous FTP from archive.uwaterloo.ca in the directory languages/j. POVRAY is available from alfred.ccs.carleton.ca. One of the largest on-line collections of initial configurations for the Game of Life is the pattern collection lifep.zip that is designed for use by Al Hensel's shareware version of the Game of Life which is archived in lifel6.zip. These files are available for FTP from wuarchive.wustl.edu in the directory systems/ibmpcj simtel/msdos/simulatn. We used the pattern collection for some of our examples. In particular. Figs 5-8 have initial configurations stored in bhepto.lif tndrbird.lif, bi-gun.lif and psrtrain.lif

Below we list the J code required to apply the Game of Life to a 13 by 13 filled square. Complete J script files which

Page 150: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

160 J. E. Pulsifer and C. A. Reiter

create the appropriate color scheme and format the results for POVRAY are available from the authors. First we define a function f i l t that executes the Game of Life on a single 3 by 3 neighborhood. For example, the neighborhood M dies.

L

1 1 1

1 9 1

1 1 1

filt=.

M

0 1 0

O i l

1 1 0

filt M

0

e.&3 1112@(+/)@. @(L&*)

Next we define a function filter which apphes f i l t to each 3 by 3 neighborhood; here it is apphed to a matrix M.

f i l t e r= . 3&(3&(f i l t \ )@| : \ ) M

0 1 0 1 0 0 1 1 1 0 1 1 0 0 1 1 0 0 0 0 1 1 1 1 1

f i l terM 0 0 1 0 0 1 0 0 0 To implement a step of the Game of Life we extend the matrix periodically in both directions. Then A is defined to be a 33 by 33 array whose center 13 by 13 block is aHve and A60 is defined to be a 3-D array containing 60 iterations of l i f e on that configuration. p e r e x t = . { : , ] , { . life= . f ilter@perext@ : (perexfl) A=. 33 33{ ._23_23{ . 13 13$1 A60=. life : (i.60) A A60=. life : (i.^0) A

Page 151: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 161

Chaos and Graphics

SCOUTS IN HYPERSPACE

SHERRI SHEPARD and ANDREW SIMOSON* King College, Bristol, TN 37620

Abstract—A one-person, checkers-like pegboard game in M-space is described. The goal of the game is to advance a peg as far as possible from an initial configuration of pegs. Using an argument based on the golden mean, we demonstrate bounds for how far a peg can travel as well as how many pegs are needed to achieve a particular goal. Finally, the game is viewed as automata moving about so as to achieve their collec­tive goal.

INTRODUCTION

"Scouts in Hyperspace" is a variation of a pegboard game which has been attributed to an unfortunate Frenchman who whiled away his time by moving peb­bles around on his flagstone cell floor in the Bastille. The game uses a single simple rule and produces sur­prising results. The game is played on an unbounded n dimensional checkerboard which has been parti­tioned by a hyperplane into two regions, called the desert and the oasis (Fig. 1). The object of the game is to advance a peg (a scout) as far into the desert as is possible, starting from a configuration of pegs (an army of soldiers) in the oasis. In the play of the game, no more than one peg can occupy any hypercube-shaped cell of the board simultaneously; and a move consists of a peg jumping in any of the 2n natural di­rections over a neighboring peg onto a previously va­cant cell, after which the jumped over peg is removed from play.

When first approaching this game, and especially after a few experiments in dimensions 2 or 3, the player might expect that a sufficiently large, strategically moved army should attain appreciable penetration into the desert. However, we demonstrate that a scout can advance at most 3w-2 cells {paces) into the desert, and also determine a good lower bound on the approximate sizes of the armies needed to attain such goals. Finally we show that the game can be viewed as pegs moving themselves as automatons so as to achieve their col­lective goal of stepping out into the desert.

PACE SOLUTIONS FOR DIMENSIONS ONE THROUGH FOUR

Before establishing the general result, we demon­strate the play of the game in dimensions one through four. In the figures, black dots represent initial peg po­sitions and open circles represent final peg positions.

For 1-space, two pegs advance a scout one pace into the desert (see Fig. 2(i)). For 2-space, the reader can verify that 20 soldiers are sufficient to advance a scout four paces into the desert (see Fig. 2 (ii)). See [1,211-215] and [2, 712-717] for an analysis of this two di­mensional case, which provided the inspiration for this paper. (See also [3] and [4] for variations on the two dimensional game.)

' Author to whom correspondence should be addressed.

To configure an army in 3-space allowing a scout to advance seven paces into the desert, consider the plane configurations of Fig. 3 (called Platoon A and B). As the reader can verify, the eight pegs of Platoon A are sufficient to advance a scout three paces, and the 36 pegs of Platoon B are sufficient to advance three scouts, one, two, and three paces, into linear array.

Assemble two A platoons and six B platoons for a total of 232 soldiers as indicated in Fig. 4(i), so that the scouts advanced by each platoon are all in the same plane. The rectangles labelled A and B in the figure are intended to be side views of their respective pla­toons. See the color figure of this paper to better vi­sualize this configuration (Fig. 4').

To see that this configuration enables a scout to ad­vance seven paces into the desert, move the pegs in the five vertical B platoons to resuh in Fig. 4(ii). Then make a series of jumps with these pegs in the desert and also move the pegs in the remaining B platoons to result in Fig. 4(iii). Now make a series of jumps

/:7\

."nW,

Desert

"•"l 1 y

asti

Fig. I. A representation of the playing board in three space.

(i) Hi)

Fig. 2. Configurations enabling a scout to respectively advance one and four paces into a one and two dimensional desert.

Reprinted from Comput. & Graphics Vol 13, No. 2, pag. 253-260, 1989

Page 152: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

162 SHERRI SHEPARD and ANDREW SIMOSON

0 [o] [o] [oj

• • u

'Siaiomf^ A TCaicofvB

Fig. 3. Subconfigurations for a three dimensional configura­tion.

with these pegs and move the pegs in the two A platoons to result in Fig. 4(iv). Then make the final grand se­quence of jumps to result in Fig. 4(v), thus getting a scout seven paces into the desert.

We construct a solution for 4-space, building the solution out of groupings of soldiers as we did for 3-space. Let Company C be the three dimensional army illustrated in Fig. 5. Following an argument similar to that illustrated in Fig. 4, the reader may verify that the 672 soldiers of Company C are sufficient to advance three scouts two, three, and seven paces (or four scouts two, three, five, and six paces).

We also use other 3-dimensional companies in our solution. For example, let Company BBB be three lay­ers of platoon B. As illustrated in Fig. 6, the first tier of Company BBB allows three scouts to occupy the three cells as indicated with open circles, whereupon the third tier jumps over the second tier, reoccupying the first tier. Companies AAA and BAA function sim­ilarly.

Now assemble platoons and companies of platoons for a total of 3912 soldiers as indicated in Fig. 7(i).

To see that this configuration enables a scout to ad­vance 10 paces into the desert, move the pegs in the five vertical C companies to result in Fig. 7(ii). Then make a series of jumps with these pegs and move the pegs in the right hand companies BBB and AAA, re-suhing in Fig. 7(iii). (An open circle indicates where the next series of jumps will leave a scout.) Then make a series of jumps and move the pegs in the remaining B and A platoons on the right to result in Fig. 7(iv). Then make a series of jumps and move the pegs in the left hand companies BBB and BAA and platoons B and A, resulting in Fig. 7(v). Make a series of jumps and move the pegs in the remaining B and A platoons

. ^

LIZ

[#[

J Z J

Fig. 4. A sequence of snapshots in advancing a scout 7 paces into a three dimensional desert. (See the text for supporting details.)

Page 153: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Scouts in hyperspace 163

Fig. 4'. A three dimensional, color rendition of the configu­ration of Fig. 4i. Note that the pegs of each platoon are the

same color.

to result in Fig. 7(vi). Finally, make a series of jumps to result in the configuration in Fig. 7(vii), upon which one last series of jumps gets a scout out 10 paces into the desert.

THE BOUND IN /i-SPACE

Surprisingly enough, the golden mean dictates that a scout can advance no more than 3n — 2 paces into an «-dimensional desert. To see this, embed the desert/ oasis playing board of hypercubes in /?" so that each hypercube has

• side length one; • all of its sides aligned with the axes of/?"; and • its center at integer coordinates.

Hence each hypercube is referenced by its center and so when a peg at (mi, . . . , m„) jumps over a peg at (/?!, • • •, P/i) landing at (^i,. . . , ^„), then there exists a j with nij, pj, QJ being sequential integers and m, = Pi = Qi for all /• with i <. i < n and i¥'J. Generalizing a two dimensional pagoda function as in [ 2 ], we assign each hypercube a value so that

• the value of an army of pegs is the sum of the oc­cupied hypercubes; and

• the value of an army never increases whenever a move is made.

An assignment which satisfies this last condition is achieved by assigning the hypercube with center (mi, . . . , m„) the value 5- .+i'"2t-Mm3i + - • • + im„i ^ ^^^^^ ^ -

VJ - 1 the golden mean, namely s = — - — ^ 0.618. As the

reader may verify, no move yields an increase in the value of an army. Let L be the axis {x E R"\Xj = 0, 2 < j <, n}. Then in particular whenever a move is made in the positive L direction or "towards" L, the value of s^'^^ 4- s^"^^ is exchanged for the value of 5^

for some integer/?, in the valuation of the army. (This transaction also defines s, i.e., s^ + s = 1.) With this assignment of hypercube values, the sum of hypercube values over all hypercubes whose first component (of their centers) is less than or equal to —37 + 1 is 1, as demonstrated by the following string of equalities (which uses the geometric series formula and the iden­tity ^ + 5= 1).

2 2 -m,+ |m2l + -

mi = -3rt+l m2=-oo m3=-oo

= 2 y'C 2 s"")"-' m=3n-l m=-oo

00 OO

= {s'"-')({/(\ -sm-i + ( 2 / ( 1 - 5 ) ) ) " - '

= (5^"-'5-2)((i -{- s)/s''r-'

= 1.

Now imagine that the oasis is the set of all hypercubes whose first component (of their centers) is no more than —3n + 1. Then the sum of the hypercube values over all oasis hypercubes is exactly 1, which means that no finite sized army positioned in the oasis can have a value as large as 1. But if it were possible for an army positioned in the oasis to send out a scout 3n — 1 paces into the desert to occupy the hypercube con­taining the origin and which has the value 1, then (since the value of an army can never decrease) the value of this army must have been at least 1, a contradiction. Therefore a scout can advance no more than 3« — 2 paces into the desert.

A COMBINATORIAL TOOL

In this section we develop a combinatorial tool which will enable us to determine lower bounds on the army

B 8 B B S B

B B

O

0

B

A

8

A

S

/4

B B 8 B B B B

Canvpa^yj C

Fig. 5. A subconfiguration for a four dimensional configura­tion.

Page 154: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

164 SHERRI SHEPARD and ANDREW SIMOSON

Fig. 6. Another subconfiguration for a four dimensional configuration.

sizes needed to advance a scout 3« - 2 paces into the n dimensional desert.

The combinatorial problem is this: How many points with integer coordinates lie on the surface of the n dimensional prism whose 2n vertices are ±Mei, where ei is the unit vector in the /''' natural direction (1 : / : «) and Af is a nonnegative integer? This prism is also the set of points in R" such that the sum of the magnitudes of the point's components is M. To answer this question, \QX h(n, M) be the number of points in R" with positive integer coordinates summing to M. By a straightforward inductive argument

h(n,M)

fC::) whenever n <> M and M > 0,

0, otherwise.

Also note that

k-=0

(1)

(2)

•TTT B A A

^

g B B B A A

a aa

c c

B B B BB B

T Y i />^A

1 S B 8 4 6 A A

i B < ^ 1 A .

1 ^ I I '

1 • • S » • • B 1 M l A 3

vu

Hi

8 B B B A A

_A L iv

B ^

f

Vt

Fig. 7, A sequence of snapshots in advancing a scout 10 paces into a four dimensional desert. (See text for supporting details.)

Page 155: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Scouts in hyperspace 165

another straightforward inductive argument. Let/(^i, ^(^\ k^\-^ K "-^ l^'^ ^\ k^^^ M) be the number of points in R" with integer coor- ^ l U Z ^ ( ^ , P ) + Z I |2 2 h(k, p). dmates such that the sum of the magnitudes of these coordinates is iV/. That is,/(«, A/) counts the integer r» /-. i.-

. ,, *u • - J u A By (2) this expression becomes coordinates on the pnsm as mentioned above. As can ^ ^ be seen

" ln\ "'^^ In -k- \\ 2 , 2*/z(A:+ l ,A/)+ 2 . 2^/i(^+ 1,A/).

k'-'(i\'^l ik-O \ ^ /

(7)

of points in i?" with integer coordinates, n- k of which are 0. In addition,

f{n + 1, M) =f{n, M) + 2 2 / ( « , A:) (4)

/ ( ^ , M ) = 2(^)2^/ i ( / : ,M); (3)

note that each term j ] 2 *"//( A:, Af) counts the number \ k ) \k) \k—l) mation expression of (7) can be written as

h(UM)-^ 2 (2)2*/i(A:+ 1,A/)

+ 2 I ' |2^/z(A:+ l ,M) + 2''^'/z(« + 2, A/). :-i \ ^ - 1/ fc-i

because component x„+i of points counted in/(rt + 1, M) can vary from - M to M; when x„.^ = 0, then/(A2 Substitution of this expression in (7) and simplifying + 1, A/) includes precisely/(«, A/) of these points; yjei^s when Xn^i = ±{M - k),0 <, k ^ M - 1, then/(« + 1, A/) includes precisely 2/(/I,/:) of these points. « / \

These four formulas are enough to yield the Fibo- 2 ( |2*"^'/i(it+l. A/) nacci-like recursive relation A:-O \ /

2A/ + 2 l |2'=/z(A:4- l,Af). (8) / ( « + 2,A/) = - — - / ( « + l , A / ) + / ( A 2 , A / ) , / c T , U - l /

Al + 1

with/(0, A/) = 0,/( 1, M) = 2, where Af > 0. Re-indexing the first summation expression in (8) as

2 1 12^/i(/c, A/) and simplifying yields -1 \ " 1 /

(5) y ( " b*/. fc-l

To prove equation (5), it is clear that/( 0, M) - 0 and ^ / ( 1 , A/) = 2. Applying (4) twice on the left side of (5) ^ ( ^ \2''{h(k, M) + h(k + 1, A/)). yields j^., \ f c - 1/

/ ( « + 2, A/) = / ( « + 1, Af) + 2 2 /('I + 1, ^) By (1) this expression becomes A:=0

= / ( « , A/) + 2 2 ( /(«, k) + / ( « + 1, ^)). ^^ [j, _ J 2 M/c + 1, A/ + 1). fc=0

Hence to prove (5) it is equivalent to show that By ^ e factorial structure in (1) again, this expression becomes

A/-1

2 (An,p}+f(n-l,p)) p-O

2'('':']-^2*/,(..A/).

M = ;^Tr^^"'^^*^^ ^""^ ''^^' ^^^ Lastly by (3) we have

By (3) the left side of (6) becomes / ( ^ + 1 M). n-h 1

2 ( 2 ilY'hik, P) + 2 C t ^ Y'hik, p)] . So by (5) , / (2 , M) = 4A/;/(3, M) = 4A/2 + 2;/(4, P-o\k^o\kJ k^o\ k / ) A/) = 8A/V3+ 4A/ /3+ 4A/;andsoon.

Let g(n, M) be the number of points counted in Interchanging the order of summation in this expres- f(n, M) whose first component is less than or equal sion yields to 0. As can be seen by the "proof without words" of

Page 156: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

166 SHERRI SHEPARD and ANDREW SIMOSON

Fig. 8. A pictorial argument showing that the number of points with integer components on the half prism in dimension AZ -I- 1 is half the number of points with integer components on the « + 1 and the n prisms

combined.

Fig. 8, dissecting an (« + 1, A/) prism (Fig. 8(i)) into three parts leads to Fig. 8(ii): two halves of an {n + 1, M) prism without bottom and top, respectively, and an («, M) prism; subtracting the (w, M) prism leads to Fig. 8(iii), and then dividing by two leads to Fig. 8 (iv); finally, adding back the (/?, M) prism yields Fig. 8(v).Thatis,

which means that

g(n + 1, M) = ^ {fin + 1, M) -^f(n. A/)).

It is this last formula which we will utilize in the next section.

ARMY SIZE ESTLMATES

The formulas for (Az, M) and f{n, M) easily yield the number of cells of a particular value in the oasis and thus can be used to obtain a bound on the minimal size of an army needed to advance a scout 3« — 2 paces into the desert (n > 1). For example, we apply the formulas for the case « = 4. Let the cell labeled by the origin be 10 paces above the hyperplane partitioning the desert from the oasis. We want to sum the highest oasis cell values until the sum is at least as large as 1.

To sum these values, we need to know how many cells have value 5'°, j ", 5 '*, and so on. The number of such cells corresponds to the number of points with integer coordinates on the sequence of nested half prisms as suggested by Fig. 9. And this task is precisely what function g performs. Formula (9) yields

^(4,A/) = / (4 , M ) + / ( 3 , .V/)

(8/3)A/^ + (16/3).V/ + 4A/2 + 2

(4/3)A/^ + 2i\P + (8/3)A/ + 1.

Fig. 9. A representation of nested half prisms.

Page 157: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Scouts in hyperspace 167

Table 1.

Dimension

1 2 3 4

5 6 7

Paces into the desert

I 4 7

10 13 16 19

Lower bound on army size

2 20

193 2009

21,282 228,002

14,910,005

Our best army size

2 20

209 3912 — — —

Computing g{4, k) (or 0 ^ k ^ S yields the following sequence: 1, 7, 25, 63, 129, 231, 377, 575, 833. Hence to obtain a lower bound on the army size we sum 1 cell as l5'°, 7 cells as ls^\ 25 cells as 255*^ 63 cells as 635'^ 129 cells as [29s^\23l cells as 2315^^ 377 cells as 377J'^ 575 cells as 575j '^ and 601 out of 833 cells as 6015*^, the sum of which is slightly larger than 1. Thus no fewer than 2009 soldiers are needed to advance a scout 10 paces into the desert.

The other values in the third column of Table 1 are obtained in the same manner. For a configuration of army size of 209 allowing a scout to advance seven paces into a three dimensional desert, write the authors. We conjecture that the bound of 3n - 2 paces is re­alizable for « > 4, but we leave the development of an algorithm as an open problem for the reader.

SCOUTS AS AUTOMATA

In order to view this game as automata moving themselves about on the board we define a ranking of the cells on the board by using nested half prisms (see Fig. 9) along with a lexicographic-like order on the coordinates of the cells in those prisms.

In particular for « = 2, we superimpose the nested half prisms (using dashed lines) on the checkerboard as in Fig. 10. Label each prism with the row number of the cell on the apex of the prism. For any two cells A and B, we say that A ranks higher than B if A is on a "higher" prism than B or if A is "lower down" on

Coluttttts

1 \ K \ \

k

1 • ' • | \m

[• it

V

K

\ N

\ \

X • >i

• • ^ < • * v

r— "

V

\ • #

^ m • n

•.

J

N

\ ^ v

r ^ ^ X

• •

N V

s

\ J.—\ • X

N •

V >i

^

«;— \ \ \ \

>t

> X > ¥

V

\ \ V

\ ^ X iX # # • %,

r——1

' '' • •

* » • m

^•' *#' ¥ ^^ V

/ /

• ^ /• J^

m

m

* 4 > P

c

7

/ /

/ f( P ;» V ¥ P

> •

/

4

P • M P •" >

/

/ P

P > • • m

?^ •

c

—7 / /

/

# m

y

^ #

P ^ p'

^ •

'~7

/ •

/ / /

A m'

A J* , • y • P

/ \ /• j / j

/

f\

m\

• l

A p \

• J • 1

o -1

•7 8 •9

11

-7 \

\

k

r« k k ''

• k k

k k '

i l

-b K —

\—' \

\ \

- 5 'v

\ \ \ \

^ 1 \ \ \

\ \ % \

\ \ N

\ \ ^

'V k

1 \ [\

k

,X ^—

\ \ v

\ y \ \

' 3 \ \ \ \ \

-I ^—

\

3 \

\

"•; \

\

\ \ -•

\ \ <;

\ \

>i

\

x.

- / \

v

\ \ \

\

y_

0

m "/

1 — 7

V

"vT m

I — i

«C—f

p' *x

^ / P!

X^ /

/ / •

/ / M\

/ / P /

z /

/

3 • / / /

/ 1/ •

/

/ /

/ p

/ / •

/

/ /

P •

/ .

^ /

/

^ >

1 /

m / /

/ >J / •

/ /

/ •

/ /

/ P /

/ /

^ /

/ / /

/

7 / /

/ j

• 1 ^ 1

^ \ ^ \ /

/ /

/

/

• A

A •

/

•1

't

-3

'5 • Vb -1 '» -9 -JO

- ^

j v

J \ 1 \ jv

J ^

1 \ J \

j \

•J \

\ \ •

X

\

-I \

\ \

• \

1*

'• , ^ •

-1 \

\_

)»,

' •

^«i

\ i

0 1 o'l / '

>•/•

'/ > • /

^9

/ /

/ p

r • •

0 /

t /

/ 1

/ / 1

/ \

P\ P\ ,#

Fig. 11. The result of implementing the automata rules for the configuration of Fig. 10.

0 -1

'7

Fig. 12. A configuration for which the automata rules achieve success, enabling a scout to advance four paces into the desert.

the same prism as B. That is, let cell A lie on row a,, column ^2, and prism ^3; and let cell B lie on row bx, column 62, and prism 63. Cell A ranks higher than cell B if and only if any of the following conditions hold.

• a3> bi

• a:i'= b^ and a\ < bi • a-i^ b-i and ax - bx and a^ > bz.

Table 2.

Fig. 10. The half prism structure superimposed on the two dimensional playing board, along with a rectangular array of

pegs in the oasis.

From

(-5, 0) (-4, 2) (-4, 0) (-4, -2 ) (-7, 0) (-5, 2) ( - 6 , - 1 ) (-6, 2) (-6, 0) (-5, -3 ) ( - 5 , - 1 ) (-4, -4) (-7, -2 ) (-3, -2 ) (-4, 0)

To

( -3 , 0) (-4, 0) (-2, 0) (-4, 0) ( -1 , 0) (-5, 0) ( - 4 , - 1 ) (-6, 0) (-4, 0) ( - 5 , - 1 ) ( - 3 , - 1 ) (-4, -2) (-3, -2) (-3, 0) ( 0, 0)

(in 3 jumps)

(in 2 jumps)

(in 2 jumps)

Page 158: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

168 SHERRI SHEPARD and AXVDREW SIMOSON

Define ^feasible move as a jump in which the jumping peg either moves nearer to column zero (thereby de­creasing the magnitude of its column number) or fur­ther up the board (thereby increasing its row number).

Allow an army of pegs positioned on the board to move according to the following rule. Locate the peg residing in the cell of highest rank which is also part of a feasible move; perform that jump (wherein a jump towards column zero has precedence over a jump up the board).

Applying this iterative procedure to the rectangular array of soldiers in Fig. 10 results in the somewhat chaotic arrangement of pegs as in Fig. 11.

However, this iterative procedure achieves success with the configuration of Fig. 12, as the listing of moves in Table 2 attests. (Each line of Table 2 lists the initial and final coordinates of the jumping peg. The first component of each ordered pair is the row number, and the second component is the column number.)

We suspect that for higher dimensions, there exist sets of analogous rules for which various configurations of soldiers can collectively advance 3« - 2 paces into an n dimensional desert. But finding these rules and configurations is no easy task, even when /i = 3.

Acknowledgement—We wish to thank Dr. Clifford Pickover for producing the fine color plate as well as for his encouraging words in the refinement of this paper.

REFERENCES 1. J. D. Beasley, The Ins & Outs of Peg Solitaire, Oxford

University Press, Oxfordshire (1985). 2. E. R. Berlekamp, J. H. Conway and R. K. Guy, Winning

Ways for Your Mathematical Plays, Academic Press, London (1982).

3. A. Simoson, Scouting out tilings. / Recr. Math. 20, 81-86(1988).

4. A. Simoson and S. Woolley, More scouts in the desert. J. Recr. Math. 20, 27-31 (1988).

Page 159: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 169

Chaos and Graphics

SIERPINSKI FRACTALS AND GCDs

CLIFFORD A. REITER Mathematics Department, Lafayette College, Easton, PA 18042, USA, e-mail: [email protected]

Abstract—The Sierpinski triangle, carpet, and pyramid, along with the Menger sponge, are well known two-and three-dimensional fractals. The fact that these fractals are constructed in a similar fashion is made evident by showing that discrete versions of these all arise using inner products involving greatest common divisors and least common multiples on matrices involving base two and three addresses. These constructions admit generalization to arbitrary dimension and base.

1. INTRODUCTION

The Sierpinski triangle is a well known fractal that ap­pears as a triangle with a triangular central region missing and smaller triangles removed from the re­maining ones (Fig. 1). The Sierpinski triangle was de­scribed years ago [ 13 ] as a limit of curves. Discrete ver­sions can be constructed from Pascal's triangle mod 2 and, hence, via one-dimensional finite automata. For further discussion and generalizations of Pascal's tri­angle see [2, 8, 9, 12, 15]. The discrete Sierpinski tri­angle has also been constructed and generalized using simple bit operations and modular arithmetic [ 5, 6, 9-12]. It is also is often viewed as the attractor of an iterated function system [1]. This paper connects the construction of the Sierpinski triangle with other clas­sical fractals. One of these is the Sierpinski carpet, which has missing squares instead of triangles. The Sierpinski carpet also has interesting topological prop­erties! 8, 14]. Likewise, three- and higher dimensional fractals related to the Sierpinski triangle and carpet have also been considered[3, 7, 8, 10] and will also be constructed later in this paper in a way consistent with the two-dimensional case. Among these three-dimen­sional generalizations are the Menger sponge and the Sierpinski tetrahedron.

There are operators called ''inner products" defined in the programming languages APL, J, and Mathe-matica that generalize the usual matrix product. These are generalized matrix products in the sense the op­erations may be specified: so instead of the sums of pairwise products computed with the usual matrix product, we may use other functions in place of the sums and the products. Generalizations of the Sier­pinski Triangle and other fractals using elementary operations organized into an inner product of a matrix with its transpose have been investigated [11]. While that work showed the Sierpinski triangle is constructed as an inner product in many ways, this note uses a particular inner product, not appearing in there, that involves the number theoretic functions GCD (greatest common divisor) and LCM (least common multiple). This inner product is used to construct the classical Sierpinski triangle as a 0-1 matrix. First, an auxiliary

matrix which contains the base-two representations of the row addresses is constructed. That is, the auxiliary matrix has rows that are the base-two representations of 0, 1, 2, etc. The Sierpinski carpet arises from exactly the same computation but using base three addresses in the auxiliary matrix. Using addresses in other bases give generalizations of these fractals. Moreover, these GCD-LCM constructions can be extended to «-di­mensional fractals in natural ways where the Sierpinski tetrahedron and the Menger sponge arise in dimension three.

2. TWO DIMENSIONS

We will use the language J to describe our ideas since the notation is precise, it allows inner product constructions, and it is readily available on many plat­forms. See [4] and Appendix A for details on J and its availability. The language J uses ASCII symbols, sometimes with a dot or colon as a suffix, to designate common mathematical functions. The reader unfa­miliar with J may want to browse the brief glossary (Table 1).

We begin with some numeric examples that are smaller cases of the images we will consider. The sym­bol +. is used for GCD and *. is used for LCM. Notice that on Booleans, GCD is the same as "or" and LCM is ''and." Some small examples:

0 1 + / 0 1 NB. Plus t a b l e 0 1 1 2

C 0 1 1 1

C 0 0 0 1

0 l + . / O 1 NB. GCD t a b l e

0 l * . / 0 1 NB. LCM t a b l e

Next, we construct the auxiliary matrix whose rows are the base-two addresses of the numbers zero to seven. Then, we take the regular matrix product and the GCD-LCM product of that matrix with its transpose.

Reprinted from Comput. & Graphics Vol 18, No. 6, pag. 885-891, 1994

Page 160: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

170 C. A. REITER

i.8

0 1 2 3

X = .1

X

0 0 0

0 0 1

0 1 0

O i l

1 0 0

1 0 1

1 1 0

1 1 1

|:x 0 0 0 0

0 0 1 1

0 1 0 1

x+/ 0 0 0 0

0 1 0 1

0 0 1 1

0 1 1 2

0 0 0 0

0 1 0 1

0 0 1 1 0 1 1 2

X +..

0 0 0 0

0 1 0 1

0 0 1 1

0 1 1 1

0 0 0 0

0 1 0 1

0 0 1 1

0 1 1 1

4 5 6 7

^:i.8

1 1 1 1

0 0 1 1

0 1 0 1

. * I: X 0 0 0 0

0 1 0 1

0 0 1 1

0 1 1 2

1 1 1 1

1 2 1 2

1 1 2 2

1 2 2 3

/ . *. I: 0 0 0 0

0 1 0 1

0 0 1 1

0 1 1 1

1 1 1 1

1 1 1 1

1 1 1 1

1 1 1 1

NB. first 8 addresses

NB. rows of X are 3 digit base 2 addresses

NB. transpose of x

NB. Matrix product of x with its transpose

X NB. The GCD-LCM inner product

The zeros in the matrix resuking from the GCD-LCM inner product mark the positions of the discrete Sierpinski triangle that would be lit if the array were to be viewed as a graphics image. Notice we can think of each entry in the matrix as being the GCD of the list of pairwise LCMs of the base-two representation of the row and column indices (starting with index 0).

In general, it is convenient to introduce a function, g i t , for constructing these GCD-LCM products of a matrix with its transpose. The function g i t takes the auxiliary matrix as its right argument. The auxiliary matrix lists addresses in the desired base. Thus g i t #: i . 8 would duplicate the GCD-LCM inner product example given above.

glt=. +./ . *. |: 0 1 2 +./ 0 1 2

0 1 2

1 1 1

2 1 2

0 1 2 *./ 0 1 2

0 0 0

0 1 2

0 2 2

|:x=.3 3#:i.9

0 0 0 1 1 1 2 2 2

0 1 2 0 1 2 0 1 2

git X

0 0 0 0 0 0 0 0 0

0 1 2 0 1 2 0 1 2

0 2 2 0 2 2 0 2 2

0 0 0 1 1 1 2 2 2

0 1 2 1 1 1 2 1 2

NB

NB

NB

NB

NB

define the function git base 3 GCD table

base 3 LCM table

Transpose of 2 digit base 3 addresses

GCD-LCM product on addresses in x

(Cont'd.)

Page 161: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Sierpinski fractals and GCDs 171

{Cont'd.)

0 2 2 1 1 1 2 2 2 0 0 0 2 2 2 2 2 2 0 1 2 2 1 2 2 1 2 0 2 2 2 2 2 2 2 2

Notice above that when the same inner product that gives the Sierpinski triangle is applied to matrices giving the base-three representations of the row and column indices, the Sierpinski carpet results in the sense that the Is mark the holes. A glance back at the base-three GCD and LCM tables makes apparent the special role played by the Is in this matrix. Fig. 1 shows the Sier­pinski triangle constructed with 11-digit binary rep­resentations: g i t # : i . 2 ^ 1 1 . Fig. 2 shows the result of 6-digit base-three computation: g i t ( 6#3 ) # : i . S'^e . Here, black, white, and orange correspond to 0, 1, and 2, respectively. Notice this is the classical Sierpinski carpet with additional internal structure highlighted. The fabric has a preponderance of red along with a fractal black component. It is easy to look at other bases as well. A matrix arising from 2-digit base-four representation of addresses is shown next.

git 4 4#

0 0 0 0 1 2 0 2 2

0 3 6 0 0 0 0 1 2 0 2 2

0 3 6 0 0 0 0 1 2 0 2 2

0 3 6 0 0 0 0 1 2 0 2 2 0 3 6

0 3

6 3 0 3 6 3

0 3 6 3 0 3 6 3

0 0 0 0 1 1

1 1 2 2 2 2

3 3 3 3

0 1 2

3 1

1 1

1 2 1 2

1 3 1 1 3

:i

0 2 2

6 1

1 1

1 2 2 2

2 3

1

1 3

A' 0 3 6 3 1

1 1

1 2

1 2

1 3 3 3 3

2 0 0 0 0 2 2 2 2 2 2 2 2

6 6 6 6

0

1 2 3 2

1 2

1 2 1 2

1 6

1 2 3

0 2 2 6 2

2 2

2 2 2 2 2

6 2 2 6

0 3 6

3 2 1 2 1 2 1 2 1 6 3 6 3

0 0 0 0 3 3 3

3 6 6 6 6

3 3 3 3

0 0 0 1 2 3 2 2 6

3 6 3 3 3 3 1 1 3 1 1 3 3 3 3

6 6 6 1 2 3 2 2 6 3 6 3 3 3 3 1 1 3 1 1 3 3 3 3

Notice that the base-four matrix forms a pattern very similar to the Sierpinski carpet with wider holes, if the Is and 2s are viewed as forming the "holes." Also notice that while the addresses are base four, the GCDs of the LCMs include 6 as a possible outcome. Fig. 3 shows this construction for base four, and Fig. 4 shows it for base seven. Fractional bases can also be used. The frac­tional base 2.5 forms a jumbled woven pattern.

g i t 2 . 5 2 . 5 # !

3. THREE DIMENSIONS

The construction in 2 dimensions was to take the GCD of pairwise LCMs of the digits of the row and column addresses of the position considered. There are multiple generalizations of this to 3 and higher dimensions. In three dimensions, there are 3 addresses that need to be combined to correspond to any given position. The first generalization we consider is to con­struct GCDs of triple-wise LCMs. The function g l , given in detail in Appendix A, takes a left argument giving the dimension of the fractal, while the right ar­gument is the auxiliary matrix whose rows give the addresses in whatever base is desired. Below, base two is used. The expression <" (2) boxes the 2-dimensional cells of the resulting 3-dimensional array since it is convenient to view a 3-dimensional array as a boxed vector of matrices. Notice there are a large number of Os which correspond to the fractal in this example.

< " ( 2 ) 3 g l # : i . 4

O O O O p O O O 0 0 0 0 0 0 0 0 0 0 0 o p 1 0 1 0 0 0 o p 1 0 1 O O O O p 0 0 0 0 0 1 1 0 0 1 1 0 0 0 0 0 1 0 1 0 0 1 1 0 1 1 1

NB. 3 - d i m e n s i o n a l b a s e 2 c o n s t r u c t i o n

Fig. 5 shows the result of 3 g l # : i . 2 ^ 6 which uses 6-digit base-two addresses in three dimensions. Notice that there are four primary faces that contain the Sier­pinski triangle, as do all the sub-faces. This Sierpinski "cliff dwelling" can also be imagined as arising from an iterated function system that uses 7 distance halving transformations. Figs. 6 and 7 show this for base three addresses. Zeros are shown in yellow and Is in green. Notice in particular, that while these are generalizations of the Sierpinski triangle and carpet to 3-dimensions, these do not give the classical Menger sponge.

For the Menger sponge, we need something like the carpet, in all pairs of dimensions. Thus, looking at GCDs of LCMs of all possible pairings of the addresses is needed (there will be n addresses for each point in n dimensions). Here, we use the function g g l , which also is given in Appendix A. This function computes the pairwise LCM of all possible pairings of addresses and the GCD over all possible pairings is taken. That is followed by taking GCDs over all the digits as in the earlier constructions, thus GCDs are applied at two levels and, hence, the name g g l . Again, the left ar­gument is the dimension and the right argument is the matrix of addresses in whatever base is desired.

<"(2) 3 ggl

0 0 0 0 0 1 0 1 0 0 1 1 0 1 1 1

0 1 0 1 1 1 1 1

0 1 1 1 1 1 1 1

#:i.4

0 0 1 1

0 1 1 1 1 1 1 1

1 1 1 1

0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1

NB. 3-dimensional base 2 construction

Page 162: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

X + y X * y x^'y X +. y X *. y x + / y x + . / y +/y + ./y |:y X +/ . * y x + . / . *. y

<y <"2y X # y

{y

Table 1. Brief J glossary.

X plus y X times y X to the power y GCD of X and y LCM of X and y an addition table a GCD table sum of items in y GCD of items in y transpose of y matrix product of x and y GCD - LCM inner product make a boxed scalar of y box the rank 2 cells of y make x copies of y Cartesian product

EFEFEPTPTFFPYFEFEVEFEF I L L F P^^ V V V V V V^ V r lJ

E F E T vFVy vWVy vVPy p ^ ^ p - p ^ ^v | r |jr wr hr

P^ |r p^ I Vfr rjr Wr MT w'^ p r Fig. 3. GCD-LCM product base four.

I I n ,^#0 .C |4 'OO- l 4 ^ , ^ * , . ; iQf q-l^l^^-

*4 ^,

^0 J4„ i-'U-* r-il liU.

t i J-1' -fi:

Fig. 1. Sierpinski Triangle: GCD-LCM product base two.

Fig. 4. GCD-LCM product base seven.

Fig. 2. Sierpinski Carpet: GCD-LCM product base three. Fig. 5. Sierpinski cliff dwelling: GCD of triple-wise LCMs

base two.

172

Page 163: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Sierpinski fractals and GCDs 173

Fig. 6. GCD of triple-wise LCMs base three. Fig. 9. Menger Sponge: GCDs of pairs of LCMs base three.

Fig. 8 shows this for 6-digit base-two addresses. This is what might be called the Sierpinski tetrahedron, seen in many places, for example [7, 8, 10]. This can also be thought of as the attractor under four distance-halv­ing functions. Fig. 9 shows this in base three: 3 ggl (4#3)#: i .3^4 . In this case, the 0, 1, and 2 entries are shown in red, transparent, and cyan. As in the two-dimensional Fig. 2, some inner structure of the sponge part is seen. There is a preponderance of cyan, and fractal edging is shown in red. Fig. 10 shows this con­struction for base four. Here 0, 1,2, 3, and 6 are red, transparent, transparent, cyan, and magenta, respec­tively. Notice the oversized holes and the rich inner structure visible in the sponge. A few additional re­marks about higher than 3-dimensional versions are given in Appendix A.

Fig. 7. GCD of triple-wise LCMs base three with interior.

Fig. 8. Sierpinski tetrahedron: GCDs of pairs of LCMs base two. Fig. 10. GCDs of pairs of LCMs base four.

Page 164: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

174 C. A. REITER

REFERENCES 1. M. Barnsley, Fractals Everywhere, Academic Press

(1988). 2. B. A. Bondarenko, Generalized Pascal Triangles and

Pyramids, The Fibonacci Association, Santa Clara CA (1993).

3. M. S. El Naschie, On turbulence and complex dynamic in a four-dimensional Peano-Hilbert space. Journal of the Franklin Institute 330, 183-198 (1993).

4. K. E. Iverson, J. Introduction and Dictionary Iverson Software Inc., Toronto (1993).

5. A. Lakhtakia and D. Passoja, On congruence of binary patterns generated by modular arithmetic on a parent array. Computers & Graphics 17(5), 613-617 (1993).

6. G. Langlet, Toward the ultimate APL-TOE. APL Quote Quad 23(\), 118-134(1992).

7. B. B. Mandelbrot, The Fractal Geometry of Nature, W. C. Freeman and Company (1982).

8. H.-O. Peitgen, H. Jiirgens, and D. Saupe, Chaos and Fractals. Springer-Verlag (1992).

9. C. A. Pickover, Computers Pattern Chaos and Beauty, St. Martin's Press (1990).

10. C. A. Pickover, Mazes for the Mind, St. Martin's Press (1992).

11. C. A. Reiter, Fractals and generalized inner products. Chaos, Solitons and Fractals 3, 695-713 (1993).

12. A. M. Reiter, Determining the dimension of fractals gen­erated by Pascal's triangle. Fibonacci Quarterly, 31(2), 112-120(1993).

13. W. Sierpinski, Sur une courbe cantorienne dont tout point est un point de ramification. Comptes Rendus Acad. Sci. Pflm 160, 302-305(1915).

14. W. Sierpinski, Sur une courbe cantorienne qui contient une image biunivoquet et continue detoute courbe don-nee. Comptes Rendus Acad. Sci. Paris 162, 629-632 (1916).

15. M. Sved, Divisibility—with visibility. The Mathematical Intelligencer 10(2), 56-64 (1988).

APPENDIX A: CODE FOR SIERPINSKI FRACTALS IN /i-DIMENSIONS

In order to duplicate the experiments in this paper, the reader is encouraged to get a copy of J. Versions of J for the Amiga, Mac, OS2, Next, PC, PC386, Windows, Sparc and many other platforms are available via anonymous ftp from w a t s e r v l . u w a t e r l o o . c a in l a n g u a g e s / a p l / j / e x e c . The source code in C is also available. The windows version has the most advanced interface. While the ftp versions are free shareware (but copyrighted), J users are wise to pur­chase the documentation [4] for a small cost.

The first function we define is g l , that is used to create Sierpinski objects in A7-dimensions by taking GCDs of the n-wise LCM of the «-address vectors. This is implemented as shown.

arising from 11-digit base-two representations of addresses, as in Fig. 1. The data of Fig. 2 is constructed using 2 g l (6#3)# : i .3^6 . The 3-dimensional data of Figs. 5-7 are constructed with 3 g l # : i . 2 ^ 6 , and 3 g l (4#3)#:i.3'^4. Four-dimensional examples with even a small number of digits contain a large amount of data, but here is a small 4-dimen-sional example generalizing the Sierpinski triangle and cliff dwelling using 2-digit base-two addresses.

< " ( 2 ) 4 g l # : i . 4

o o o o p o o o o o o o o o o o o o o o p o o o o o o o p o o o o o o o p o o o p o o o p o o o o o o o p o o o p o o o p o o o 0 0 0 o p 0 0 o p 0 0 o p 0 0 0 0 0 0 o p 1 0 1 0 0 0 o p 1 0 1 0 0 0 o p 0 0 o p 0 0 o p 0 0 0 0 0 0 o p 1 0 1 0 0 0 o p 1 0 1 o o o o p o o o p o o o p o o o o o o o p o o o p o o o p o o o o o o o p o o o p o i i p o i i o o o o [ o o o o [ o o i i p o i i o o o o p o o o p o o o p o o o 0 0 0 o p 1 0 1 0 0 0 o p 1 0 1 o o o o p o o o p o i i p o i i 0 0 0 0 0 1 0 1 0 0 1 1 0 1 1 1

The second generalization of the Sierpinski objects to n-dimensions is given by ggl , which computes the pairwise LCMs of all possible pairings of the «-address vectors, and then computes the GCD of those pairs, and then the GCD among all the digits.

g g l = . + . / " l@( [ ( + . / © ( + . / ) @

( < / ~ @ i . @ [ * . * . " l / ' - @ ] ) )"2>(^

>@{@(#<@(<"1@] ) ) )

This is also consistent with the 2-dimensional constructions. For example, 2 ggl #: i . 2^11 would give the data in Fig. 1 again. The data of the 3-dimensional images in Figs. 8-10 result from 3 ggl # : i . 2 ' ' 6 , 3 ggl (4#3)#:i .3^4, and 3 ggl (3#4)#: i . 4^3, respectively. Again, higher dimensional versions can computed by changing the left argument.

g l = . + . / " l @ ( * . / " 2 ) ( K#<@(<"1@] ) )

The reader interested in understanding each of the symbols used in this definition should consult the J dictionary, but the main steps are to box (<) and replicate the address data n times, compute a Cartesian product ({), to unbox (>) and then to apply LCMs and GCDs. Thus 2 g l # : i . 2 ^ 1 1 would give the classic Sierpinski triangle as a 2-dimensional array

APPENDIX B: TWO-DIMENSIONAL CONSTRUCTION IN PASCAL

The following program provides a starting point for readers who want to explore the two dimensional versions of these fractals using Pascal. This duplicates g i t (n#b) #:b^n with g l t = . + . / . * . I : when b is an integer. Procedural pro­grams analogous to g l and ggl would require a variable number of loops and are not given here.

Program GLTX; { Computes an array generalizing Sierpinski's Triangle } { using base b representations of indices of positions } var i, j,k, { loop indices }

d,g, { temp variables }

b,n,m : integer; { base, number of digits and rows }

Page 165: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Sierpinski fractals and GCDs 175

x: array [0 . . 1023, 0 . . 9] of integer;

{ X stores base b representations of 0 to b k—1 }

function gcd (a,b:integer):integer; var r0,r1,r2:integer; begin rl:=a; r2:=b; while not (r2 = 0) do begin rO:=rl; rl:=r2; r2 : =rO mod rl; end;

gcd:=rl end;

funtion lcm(a,b: integer) : integer; begin if a = 0 then 1cm: =0 else lcm:=a*b div gcd(a,b)

end;

function power (x, y: integer) : integer; begin power: =round(exp(y*ln(x) ) ) ;

end;

Begin { *** main *** }

b:=2: { base used } n:=4; { number of digits in representation } m:=power (b,n); { number of rows represented }

{ define x; the rows give base b representation of row index } for i: =0 to m—1 do begin d:=i; for j : =0 to n—1 do begin x[i,n—j—1] :=d mod b; d: =d div b end;

end;

{ create the gcd-1cm array } writeln; for i: =0 to m—1 do begin for j : =0 to m—1 do begin g:=0; for k:=0 to n—1 do g:=gcd(g,lcm(x[i,k],x[j,k])));

write(g:2) end;

writeln; end;

end. { main }

Page 166: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 177

Chaos and Graphics

COMPLEX PATTERNS GENERATED BY NEXT NEAREST NEIGHBORS CELLULAR AUTOMATA

WENTIAN LI Center for Complex Systems Research, Beckman Institute, University of Illinois, 405 North Mathews Avenue, Urbana, IL 61801 and Department of Physics, Columbia University, New York, NY 10027*

Abstract—A greater number of complicated patterns can be produced by cellular automata niles with next nearest neighbors in the updating, than those with only nearest neighbors couplings. Some patterns can be identified as gliders moving on the background, while other rules have more intriguing configurations called "creatures" which move irregularly on the background. Sometimes, even the distinction between creatures and the background disappears, and the patterns look strikingly similar to those generated by probabilistic rules, even though the rules used are strictly deterministic.

The question of how the complicated behaviors of bio­logical systems can be explained in terms of the simple laws of physics motivated Von Neumann and Ulam to propose the use oi cellular automaton[\], a, fully discretized dynamical system with local couplings. It is indeed found that some specially designed two-di­mensional cellular automata can mimic the least self-reproduction behaviors [ 2 ] . Although we lack the gen­eral criteria on what types of cellular automata rules can produce what behaviors, today it is is widely ap­preciated that simple rules can lead to compjex dy­namics [3, 4] .

The simplest type of cellular automata are on a one-dimensional lattice with two state values at each site, and with nearest neighbors couplings:

a'r'-fiaUi.aUaUi) (I)

where ai is the state value on site / at time r, and/( ) is some kind of function, usually in a tabular form, with the state values at previous time step on nearest sites as the variables. These cellular automata are thor­oughly studied, and their spatial-temporal patterns can be found in the Appendix of [ 5 ].

By looking at these spatial-temporal patterns one may feel a bit of disappointment because only one or two of them seem complicated, with most of the other patterns being either simply periodic in time direction or homogeneously random. The capability for these rules to produce more complicated dynamics is limited by the fewer number of state variables and neighbors involved in a updating. Here I ask the following ques­tion: what complicated dynamics can cellular auto­mata, still in one dimension and with two state vari­ables, generate when next nearest neighbors are in­cluded in the updating? This article partially answers this question by collecting some spatial-tempral inter­esting patterns generated by such cellular automata rules.

* Address after September I, 1989: Santa Fe Institute, 1120 Canyon Road, Santa Fe, NM 87501.

GLIDERS

Fig. 1 shows a pattern which cannot be produced by any nearest neighbor cellular automaton rule: a "net"! The line on the top is the initial configuration which is random with each site value chosen from ei­ther 0 (white) or 1 (black), with equal probability, and the successive lines are configurations updated by the rule presented by the following rule table:

110101011lOOOlOOl100000010011001. (2)

Each bit in this binary sequence represents the state value which a 5-neighbor configuration maps to. Start­ing from the right, the binary sequence can be decoded to a rule: 00000 — 1, 00001 -> 0, 00010 -* 0, • • •, l l l l O - * l,and 11111 -* 1.

There are many ways to condense this binary se­quence to shorter sequences with larger bases. For ex­ample, this 32-bit pattern can be rewritten in a sequence with 10 digits if the base is 10 {Le., 3586441369), 11 digits if the base is 8 {i.e., 32561140231), with 7 al­phabets if the base is 26, or with 4 numbers if the base is 256 {i.e., 213,196,192,153), etc. Unsure of which representation is the best, I will adopt the last approach, i.e., using 4 numbers with 256 as the base, throughout this paper. Take the rule in Fig. 1, for example; the way to do this is to split the 32-bit sequence into four segments: 11010101, 11000100, 11000000, 10011001, and use the decimal equivalences 213, 196,192,153 as the rule label.

The picture in Fig. 1 is typical for a class of rules with "gliders," i.e., stable configurations on the back­ground moving with certain speed. For example, if we look at the "thread" on the "net" carefully, we can find that one of the gliders in this picture is the con­figuration 01000 (on the background of Ts), which moves to the left by one site after each updating. The "knots" are the collisions between gliders.

Will the dynamics in Fig. I run into an equilibrium state, causing the pattern to be boring? The readers can activate their own numerical simulation as a test. Al­though most of the time two gliders emerge when two

Reprinted from Comput. & Graphics Vol. 13, No. 4, pag. 531-537, 1989

Page 167: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

178 VVENTIAN LI

Fig. 1. Pattern produced using rule (313,196.192,153). Another vvav of writing this rule is: 11010101110001001100000010011001 (see text).

gliders meet, occasionally, only one glider survives such a collision. Besides, it is never observed that extra numbers of gliders are produced. As a consequence, the number of total gliders is decreasing, and the "holes" in the net become larger and larger, though with an extremely slow expansion rate.

CREATURES

Fig. 2 shows the pattern generated by rule (78,158,206,33). It looks like a pine tree. If we wait long enough, all the branches of the tree stop growing, and only the background remains. It is quite common for cellular automata rules to have nontrivial patterns in the transients. Two other cellular automata rules with the similar amazing structures in transients are shown in Figs. 3 and 4. Fig. 3 is generated by rule (130,36,202,62) and Fig. 4 is by rule (123,140, 162.141).

The purpose for including these pictures is to show that not all the complicated structures produced by the cellular automata are glider activities. It is possible to have configurations, distinctive from the background, moving in irregular ways, rather than the fixed speeds for gliders. In most of the cases, these are transient behaviors. I call these moving objects in the transients creatures. The source for the irregularity of the crea­tures' movement is the structures in the back­

ground, such as the checkerboard-like configuration • • • 1 lOl 1011 • • • in Fig. 2. The interaction of the creatures with the background makes their movement irregular. If the background is homogeneously all O's, the objects will only moved with fixed speeds.

RANDOMNESS AND REGLLARfTV Fig. 5 shows the pattern generated by rule

(166,252,133,49). For this pattern, the background (dark area), instead of being of periodic patterns, is as complicated as the creatures themselves (light area). It might be more appropriate, at least during the tran­sient period, to describe them as two different phases than as background and creatures.

Another feature I want to point out is the practical unpredictability for the details of the pictures, even though the rule is purely deterministic. Of course, one has to be reminded that the initial configuration is ran­dom, but without some aspects of the cellular autom­aton rule itself, the complex structures will not nec­essarily be generated or maintained. Fig. 6. for rule (205.233,162,25), shows another example for a deter­ministic cellular automaton rule to generate pictures typical for nondeterministic rules.

Sometimes, even when the initial configuration is random, the pattern generated can be astonishingly regular. Fig. 7 is generated by rule ( 195,188,227.144).

Page 168: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Complex patterns 179

Fig. 2. Pattern produced using rule (78,158,206,33).

Fig. 3. Pattern produced using rule (130,36,202,62).

Page 169: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

180 WENTIAN LI

Fig. 4. Pattern produced using rule (123,140,162,141).

Fig. 5. Pattern produced using rule (166,252,133,49).

Page 170: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Complex patterns 181

Fig. 6. Pattern produced using rule (205,233,162,25).

Fig. 7. Pattern produced using rule (195,188.227,144).

Page 171: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

182 WENTIAN LI

It gives an impression that 3-dimensional tetrahedrons are piled up one next to another. This illusion is achieved partly by the existence of the "third color," grey, which is actually checkerboard configurations • • • 00110011 • • •. The amazing thing about this rule is that it accomplishes the fractal-like arrangement of the tetrahedrons from a random initial configuration! (By the way, this rule was discovered accidentally.)

There are other patterns generated by some rules which are less spectacular than the one in Fig. 7, but the readers can also see large-scale structures emerging from random configurations [e.g.. Fig. 8, for rule (206,176,186,98)].

CREATE YOUR OWN PRETTY PICTURES

The number of cellular automata rules with next nearest neighbors couplings is very large. Since there are 2^ = 32 possible 5-neighbor configurations, and each of them can map to either 0 or 1, there are 2^" = 4294967296 possible rules. Even if we can produce a spatial-temporal pattern from each rule in 1 second, it is going to take about 138 years to run through all the rules. Considering the redundancy due to the equivalence between rules upon 0-to-l transforma­tions, which will cut the time by half, it still requires a solid 69 years. Obviously, I did not look at all of them. There are chances that other interesting patterns will be discovered by searching further.

There are two empirical tricks, though, which I use to enhance the possibility to get interesting pictures in this seemingly hopeless random searching. First, do not fill the rule table with too many 1 's or too many O's. Actually, for the next nearest neighbor cellular au­tomata rules, something close to half O's and half I's is about appropriate. The reason can be explained as the following: if there are too many O's in the rule table, there is a greater chance that any 5-neighbor configuration will be mapped to state value 0. Con­sequently the pattern generated tends to have a lot of O's which can hardly be an interesting situation. The same argument can be applied to the situation with too many 1 's. A more quantitative study has been car­ried out in [6, 7], which shows that the optimal filling density in the rule table for interesting rules is not ac­tually 0.5, and this optimal density moves away from 0.5 when more and more neighbors are included in the coupling. The above statement is correct only in the statistical sense. For next nearest neighbors cellular automata rules, I still recommend anyone starting the simulation from rules with half-filled rule tables.

The second trick: once you observe a pattern you consider to be interesting, record the rule in the form of 32-bit sequence and gather new rules by randomly flipping one or more bits in the rule table. Sometimes, flipping even one bit can alter the features of the orig­inal pattern completely. Other times, the new pattern

Fig. 8. Pattern produced using rule (206,176,186,98).

Page 172: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Complex patterns

Fig. 9. Pattern produced using rule (195J 88,227 J 46). This is a close relative of the rule for Fig. 7, produced by flipping the third bit from the right in the rule table (from 0 to 1).

is almost the same with the old one, but there are chances that you might end up with fresh pictures with interesting new looks. For example, the rule which produces the picture in Fig. 9 is a ''close relative'' of the rule in Fig. 7, by flipping the third bit from the right in the rule table from 0 to 1. [It is rule (195,188,227,146).] Comparing the two patterns, we see little similarities.

Some other pictures generated by next nearest neighbors cellular automata are collected in [8 ] . I saw even more patterns on the computer screen but I didn't have the chance to print them out. I wish that more wonderful ''cellular automata arts" will appear in the future.

Acknowledgements—This paper has grown from a Technical Report[8]. I would like to thank Stephen Wolfram for pro­viding the original graphic program, and Cliff Pickover for encouraging me to write the material in the present form. The work I have carried out at the Center for Complex Systems Research was partly supported by the National Center for Supercomputing Applications at the University of Illinois, and

partly by the National Science Foundation grant PHYS-86-58062.

REFERENCES 1. J. von Neumann, The theory of self-reproducing auto­

mata. In A. W. Burks (Ed.), Essays on Cellular Automata y University of Illinois Press, Champaign, IL (1966).

2. C. Langton, Self-reproduction in cellular automata. In D. Farmer, T. Toffoli and S. Wolfram (Eds.), Cellular Automata, North-Holland, Amsterdam (1984); [ reprint of Physica D 10(1/2), 135-144 (1984)].

3. J. Gleick, Chaos: Making a New Science, Viking, New York (1987).

4. S. Wolfram, Cellular automata as models of complexity. A fl/wr 311 (5985), 419-424 (1984).

5. S. Wolfram (ed.), Theory and Application of Cellular Au­tomata, World Scientific, Singapore (1986).

6. C. Langton, N. Packard and W. Li, Bifurcation-like phe­nomena in cellular automata rule space (in preparation) (1989).

7. W. Li, Problems in complex systems. Ph.D. Thesis, un­published, Columbia University, New York (1989).

8. W. Li, Pretty pictures generated by two-state five-neighbor cellular automata. CCSR Technical Report No. 15, Uni­versity of Illinois (1988).

Page 173: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 185

Chaos and Graphics

ON THE CONGRUENCE OF BINARY PATTERNS GENERATED BY MODULAR ARITHMETIC

ON A PARENT ARRAY

AKHLESH LAKHTAKIA Department of Engineering Science and Mechanics, Pennsylvania State University,

University Park, PA 16802-1401, USA

and

DANN E. PASSOJA 410 East 73rd Street, New York, NY 10021, USA

Abstract—Presented is the idea of the congruence of binary gaskets generated using modular arithmetic operations on a parent array. It is seen that the binary gaskets of prime orders are nontrivial, while the binary gaskets of nonprime orders are congruences.

Because material microstructure plays a vital role at nanoscopic scales [1-3], studies on gaskets have be­come of considerable importance in materials science (e.g., [4-6]). Inevitably, these and similar develop­ments in other fields have spawned interest in cellular automata and patterns for their own sakes[7, 8], and several reports (e.g., [9-11]) have come forth in the pages of this journal.

In a recent paper, we looked at the esthetics of square patterns generated by a simple rule involving modular arithmetic with reference to their CIE chromaticity diagrams! 12]. During that work, and a subsequent follow-up involving some variations of Khayyam's tri­angle [ 13 ], we chanced upon the concept of congruence of two or more gaskets. The present paper is motivated by a desire to communicate the results of our inves­tigations on congruence. We also note a paper by Sa­kamoto and Takagi[14], on patterns with residue arithmetic, that was brought to our attention recently.

Let .G/ be an array of positive integers <2 > 0 arranged on the nodes of a lattice in «-dimensional space, n > 1; here r is the positional «-index. From this parent array s^ we generate a second array ^(q) with ele­ments hXo) such that

and

^Xn) = 1 , if flrinod ^ = 0,

b,(g) = 0, if armodq¥^0,

where the integer ^ > 2; we call g the order of the binary gasket ^(q). For the graphical representation of ^(g), br(g) = 1 is depicted by a black pixel, and br(g) = 0 by a white pixel.

To serve as an example, we choose the 2-dimensional parent array s/ generated by the rule [13]

an,o = ao,n = 1 V« > 0,

but

^n,m — Cln-\,m-\ + ^n,m-\ + ^«-1 , /M»

the rule being easily implementable in modular arith­metic. The algorithm, as implemented in BASIC, is reproduced here. Shown in Figs. 1-3 are the corre­sponding ^ ( 3 ) , ^ ( 5 ) and ^ ( 1 5 ) .

Definition 1: We define the congruence (g\\g2) = {^(^i) ;^(^2)} of ( ^ i ) a n d ^ ( ^ 2 ) i n the following fashion:

Cr((l\\Q2) = br(gi)br(g2).

On recalling the binary natrue of br(g), it is easy to see that Cr(gi igi) is the result of an AND operation in the language of Boolean algebra. This definition can also be extended to higher congruences; thus, the ele­ment Cr(gi\g2\g3\ • • •) of ^(Q\\Q2\Qr, • • •) can be defined by cMuQiA^', • • •) = W^i)W^2)W^3)- • •; however, in the sequel we consider ^(g\',g2) exclu­sively, but without loss of generality.

Lemma 2. ^(^1,^2) = ^^(Q2\q\)^ Corollary 3: ^(q\g) = ^(g).

These two results follow from the commutative nature of the AND operation.

Let now p, pi, P2,... denote primes > 2; while /, ki,k2,... ,n,ni,n2,... ,rn,mum2,.. .are integers > 0. Then,

Lemma 4. ^(Pi;p2) = ^(P\P2), if P\ "^ P2' Consider that br(pip2) = 0, except br(p\P2) = 1 if fl^mod P1P2 = 0. But <2 mod P1P2 = 0 <=> {a^mod px = 0 and a^mod P2 = 0} , while a^mod piP2 ^ 0 <=» {artnodPi ^ 0 and/or «^modP2¥=0}. Hence, br(p\P2) = 1 «=> {br(Px) = 1 and WP2) = 1 } , while br(PiP2) = 0 <=^ {br(pi) = 0 and/or br(p2) = 0 } . An example of this lemma is afforded by Figs. 1-3, wherein it is easy to see that ^ ( 1 5 ) is the congruence of ^ ( 3 ) and ^ ( 5 ) .

Reprinted from Comput. & Graphics Vol. 17, No. 5, pag. 613-617, 1993

Page 174: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

186 A. LAKHTAKIA and D. E. PASSOJA

Fig. 1. ^ (3 ) obtained from .c/ defined as fl„,o = %„ = 1 VAZ ^ 0 and a„ Otherwise. Grays have been used in place of black for esthetic reasons.

Lemma 5. ^{p'"',p") = ^{p") where n^m. It is easily seen that fl^mod p" = 0 =» a mod p"" = 0. Consequently, Wp") = 1 =• Wp'") = 1, although the converse is not necessarily true. Therefore, all nonzero elements of ^(p") are contained in ^(p"") if « > m. Indeed, one can say that all nonzero elements of all ^(p"), n> 1, are contained in ^(p).

Lemmas 4 and 5 together give a special status to ^(q) with prime q. Any positive integer ^2 can be factored into its prime divisors. Let

qn = PVPTP?

and

Fig. 2. Same as Fig. 1, but ^ ( 5 ) .

Page 175: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Congruence of binary patterns 187

m fiiK « i wig mmt |»« # Kif n»«» | i » |i»i •«$ MftM i i « i f ftls mm §,»

: * . f . *-lfe!«E3«fe^ *"

"€ %* ! ,» " ^ '^ Fig. 3. Same as Fig. 1, but ^ ( 1 5 ) = <^(3;5).

wherepi , /72, • • • are primes. We exclude all primespi if m, = «/ = 0. Then,

Lemma 6. Excluding all primes /?/ such that m^ = Hi = 0, and with kj = max[« , , m , ] , ^{qn',Qm) =

The proof can be found by observing that c^(^„; Qm) = 1 iff {a^mod p?' = 0 and fl^mod pf" = 0} for all /. This, in turn, implies that c^(^«; Qm) = ^ iff a^mod p'i' = 0 for all /. Indeed, one can write ^(g„;gm) =

Corollary 7: ^{quQi) = ^{QiQi) if ^i and ^2 do not have a prime divisor in common.

Corollary 8: ^(g'";g") = M(g") where « > m. In closing, we have presented the idea of the con­

gruence of binary gaskets generated using modular arithmetic operations on a parent array. We have shown that the binary gaskets of prime orders are non-trivial, while the binary gaskets of nonprime orders are congruences.

REFERENCES R. Messier, Toward quantification of thin film morphol­ogy. J. Vacuum ScL Tech. A4, 490-495 (1986). D. E. Passoja, Fundamental relationships between energy and geometry in fracture. Adv. Ceramics 22, 101-126 (1988).

10.

11.

12.

13.

14.

J. J. Mecholsky, T. J. Mackin, and D. E. Passoja, Self-similar crack propagation in brittle materials. Adv. Ce­ramics 22, 127-134(1988). A. Lakhtakia, R. Messier, V. K. Varadan, and V. V. Va-radan, Use of combinatorial algebra for diffusfon on frac­tals. Phys. Rev. A34,2501-2504 (1986); errata: 35,1445 (1987). G. Jin, B. Feng, and D. Feng, Optical diffraction on Sier-pinski carpet. Chin. Phys. Lett. 5, 9-12 (1988). J. C. Lee and J. E. Main, Scale-dependent lacunarity and fractal Ising models. J. Phys. A: Math. Gen. 22, 3731-3735(1989). O. Martin, A. M. Odlyzko, and S. Wolfram, Algebraic properties of cellular automata. Comm. Math. Phys. 93, 219-258(1984). C. A. Pickover, Computers, Patterns, Chaos and Beauty, St. Martin's Press, New York (1990). A. Lakhtakia, A simple gasket derived from prime num­bers. Comp. & Graph. 13, 57-58 (1989). M. Szyszkowicz, A simple gasket derived from the logistic parabola. Comp & Graph. 14, 335-336 (1990). M. Szyszkowicz, Patterns generated by logical operators. Comp & Graph. 15, 299-300 (1991). D. E. Passoja and A. Lakhtakia, Carpets and rugs: An exercise in numbers. Leonardo 25, 69-71 (1992). [In this paper, Color Plate A No. 3 and its legend should be interchanged with Figure 2 and its legend.] D. E. Passoja and A. Lakhtakia, Variations on a Persian theme. J. Rec. Math. 25, 1-5 (1992). M. Sakamoto and M. Takagi, Residue patterns and their application to graphic design. Forma 6, 115-127 (1991).

Page 176: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

188 A. LAKHTAKIA and D. E. PASSOJA

APPENDIX

10 !! * n M ! n !! n ! ! ! ! ! ! ! ! ! M ! ! ! ! ! ! ! ! ! ! 2 ! ! ! ! ! ! n ! ! ! ! ! ! M U ! ! ! ! ! n ! ! ! ! ! ! 20 I ! ! * ! ! ! ! ! ! ! ! ! ! ! ! ! Program: Congruence !! ! ! ! ! ! ! ! ! ! > 1 ! ! ! ! ! ! ! ! ! ! ! ! ! U ! 30 ! ! ! ! n n ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! M ! ! ! ! ! ! ! ! ! ! n ! ! ! ! ! 2 ! ! ! 40 ! M U ! 2 2 ! ! ! U ! ! ! ! ! ! n ! ! ! ! M ! ! ! ! 2 ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! n ! ! ! 2! n ! ! n ! ! ! ! ! 50 OPTION BASE 1 60 U !!!!!! U !!! I!!!!!!!!!!!!!!!!! 2!! n !!!!!!!!!!!!!! 2 !!!! U 2!! n !!!!! 70 INPUT "What size matrix?",Size 80 ALLOCATE A(Size,Size),B(Size,Size) 90 INPUT "MOD(N) value?",Numl,Num2 100 !!! U !!! ! 2 n 2!!!! * !!!! 22 2! 2!!! 2 !!!!!!!!!!!!! 2! !!! n ! n !!!!! 2! 2!!!!! 110 OUTPUT 2 USING "#,K";C$ 120 GINIT 130 PLOTTER IS CRT,"INTERNAL";COLOR MAP 140 GRAPHICS ON 150 CLEAR SCREEN 160 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 170 INTEGER Row,Col,Size,Rowmax,Colmax 180 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 190 LINPUT "Do you want plotting (Y/N)?",Plot$ 200 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 210 MAT A= (0) 220 Rowroax=Size 230 Colmax=Size 240 PRINT Numl,Num2 250 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 260 2 2 2 2 2 2 2 2 2 2 I n i t i a l i z e A r r a y 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 270 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 280 FOR N=l TO Size 290 Base=l 300 A(N,l)=Base 310 A(l,N)=Base 320 NEXT N 330 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 340 MAT B= A 350 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 360 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 370 FOR Row=2 TO Rowmax 380 FOR Col=2 TO Colmax 390 A(Row,Col)=(A(Row-l,Col)+A(Row,Col-l)+A(Row-l,Col-l)) MOD Numl 400 B(Row,Col)=(B(Row-l,Col)+B(Row,Col-l)+B(Row-l,Col-l)) MOD Num2 410 NEXT Col 420 NEXT Row 430 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 440 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 450 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 460 FOR Row=l TO Rowmax 470 FOR Col=l TO Colmax 480 Rem=A(Row,Col) MOD Numl 490 Rem2=B(Row,Col) MOD Num2 500 IF Rem>0 THEN A(Row,Col)=0 510 IF Rem2>0 THEN B(Row,Col)=0 520 IF Rem=0 THEN A(Row,Col)=l 530 IF Rem2=0 THEN B(Row,Col)=l 540 NEXT Col 550 NEXT Row 560 22222 2 570 222222 580 2 2 2 2 2 2

122222222222 222222222222 222222 22222222222222 2 2222222222 22 12222222222 2 22222 2222222 22 2222 2222222222 2 2222 222222222222 12222 2222222222222222222 22222 2222 22 2 22222222 2222222222222

590 ALLOCATE C(Size,Size) 600 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 610 MAT C= A+B 620 22222I22222222222222I222222222222222222222222222222222222222222 630 2222222222222222Congruence if C(I,J)=2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 640 !222222222222222Anticongruence if C(I,J)=1222222222222222222222 650 222222222222222222222222222222222222222222222222222222222222222 660 FOR Row=l TO Rowmax 670 FOR Col=l TO Colmax 680 Rem=C(Row,Col) 690 IF Rem=2 THEN C(Row,Col)=l 700 IF Rem=l THEN C(Row,Col)=0 710 NEXT Col 720 NEXT Row 730 2222222222222222222222222222222222222222222222222222222222222222222 740 Ymax=100 750 Xmax=100 760 VIEWPORT .l*Xmax,.9*Xmax,.l*Ymax,.9*Ymax

Page 177: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Congruence of binary patterns 189

770 SHOW l,Colmax+l,Rowinax+l,l 780 IF Plot$="Y" THEN SET PEN 0 INTENSITY 1,1,1 790 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 800 H=l 810 FOR Row=2 TO Rowmax 820 FOR Col=2 TO Colmax 830 Suin=(C(Row-l,Col)+C(Row,Col-l)+C(Row-l,Col-l)+C(Row,Col)) 840 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!I!!M!!!!!!!!!I!!!!!II!!!!!!!I!!!!!! 850 MOVE Col,Row 860 !!!!!!!!!!!!MI!!!!!!!!!I!!!!!!!!!!!I!!!!!I!!!!!!!!!!!I!!!!!!!!!I!! 870 880 890 900 910 920 930 940 950 960 970 980 990 1000 1010 !!!!!!!1!!!!!!!!!!!!!!!!!!!!M!!!!!I!I!!!!!!I1!!!!!!!!!!!!!!!!!!!!! 1020 PAUSE 1030 !!!!!! !!!!!II!!1I!!!!I!!!I!II!!!!M!!M!I!!!1!!!!!!!!M!!!!!!!!1!!! 1040 •!!!!!!1!»!1Inkjet'printing'subroutine *!iI!11!! Ii1!!!! I! 11 i 1!! 1 i 1!! 1050 !!!!!!! M!M!I!!!!!!1!!!!!!!!!!!!I!!!!!!!!!!I!II!!I!I!!!!!!!!!!IM! 1060 FOR K=i TO 10 1070 LOADSUB ALL FROM "GDUMP_C" 1080 Gduinp_colored(CRT, 7 0 1 , "NORMAL" , 180 , "OFF" ) 1090 PAUSE 1100 NEXT K 1110 !!1I!M!!!!!!!!1!!!I!!!II!!!!!!!!!!!!!!!III!!!M!!!!!II!!!!!I!!!!!! 1120 !!!!I!!!!!I!!I!!!!!!!I!!!!!!M!!I!!!MMM!!!!!!!I!!!!I!I!!!!!I!!!! 1130 END 1140 SUB Printmat(A(*)) 1150 SUBEND 1160 !!!!!!!!!II!I!!!I!!!!!!II!I!!!!!!!II!!!!!!!!!!!!!!!I!!II!I!!!!!!!!!

IF IF IF IF IF IF IF IF IF IF IF IF

Suin=0 Suin=0 Suin=2 Suin=2 Sum=l Sum=l Suni=3 Suin=3 Sum=4 Suin=4

THEN THEN THEN THEN THEN THEN THEN THEN THEN THEN

A(Row,Col) = A(Row,Col) =

AREA GOTO AREA GOTO AREA GOTO AREA GOTO AREA GOTO

INTENSITY 980 INTENSITY 970 INTENSITY 970 INTENSITY 970 INTENSITY 970

1.1<

.75,

.5,,

.25,

0,0,

=1 THEN RECTANGLE H, =0 THEN RECTANGLE H,

NEXT Col NEXT Row

,1

-.75,,

.5,.5

-.25,.

-0

!White

.75

.25

1

,H,FILL ,H,FILL

IGrey 1

IGrey 2

IGrey 3

Black

Page 178: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Compiit & Graphics Vol. 13. No. 1. pp. 57-58. 1989 Primed in Great Britain.

191

Chaos and Graphics

A SIMPLE GASKET DERIVED FROM PRIME NUMBERS

AKHLESH LAKHTAKIA Department of Engineering Science and Mechanics, Pennsylvania State University,

University Park, PA 16802

World inside a world inside a world, without end. Uwa-t 'uwa, in our language. Chinua Achebe (Anthills of the Savannah)

Abstract—Well-known gaskets are fractal because increasingly larger voids are created as these structures evolve. As a counter-example, a gasket is constnicted using prime numbers, which does not appear to have larger voids as it evolves.

Generally, well-known gaskets, such as the Sierpinski gasket [1], are fractal because increasingly larger voids are created as these structures evolve. Given here is an example, however, which does not seem to have voids of indiscriminately larger sizes appear as the gasket grows.

Consider the rectangular array of numbers/y whose first row (/ = 1) is given as

fij = Pj\ 7 = 1,2, 3 , . . . , (1)

[Pj} being the sequence of all primes arranged in order of increasing magnitude with pi = 2. The other rows of this array are created using the rule

fi-i^\j Mij'fu (2)

which is either zero or a multiple of 2. However, it appears that/+ij = 1 for all / ^ 1, although that con­clusion has not been proved analytically [ 2 ] . The prime number gasket is defined by the triangular array g^ with (\)gij =fij, Ufij = 0, and (ii) ^/,= 1, if otherwise. The resuhing structure appears superposed on a right-angled triangle when the gasket is terminated at some / = /.

Shown in Fig. 1 is the initial 200 X 200 segment of the gasket for / = 669 (i.e., Pi = 4999). The zeros of the gasket are coded black. As can be observed from these figures, the gaskefs voids do not indiscriminately increase in size with increasing gasket size. Further­more, many of the voids have tails, and some inter-void connectivities also exist.

Suppose the gasket lies on a square lattice whose successive rows and columns are a unit distance apart; let m(r) be the sum of all gij contained in the quadrant of radius r and centered at the site i = j = 1. As per the power law m ^ r'^, ^ will be the "fractal" dimension of the portions of the gaskets thus explored. Given in Table 1 are the various measures of d obtained from curve-fitting the power law over various ranges of r.

The exponents fi? clearly indicate that this is a self-affine, and not a self-similar structure[3, 4] . This is because varying values of d would be obtained by sampling different portions of the gasket. As is also obvious from Table 1, the gasket grows Euclidean as it evolves, i.e., its asymptotic dimension could possibly equal its Eu­clidean dimension of 2. Since the number of primes is unbounded, as per a theorem due to Euclid [ 5 ] , this does not imply that more voids will eventually not appear as / increases; it could simply mean that the number of massless nodes would grow almost in con­stant proportion to the number of nodes with unit mass.

It is known that the number of primes less than a large integer n can be estimated as «/ln(«). Prime numbers appear as ordered pairs; e.g., the twins {3, 5} or {59,61} which are consecutive primes separated by a difference of 2, as quadruples {7, 11} or {13, 17} which are consecutive primes separated by a difference of 4, and so on. The author does not know, however, of any general patterns of twins and quadruples, etc. Hence, it may not be possible to analyze the presented gasket using number theory. Yet, despite the fact that the seeds {pj} are not stochastically determined, the various features of the gasket described here are similar to those of some cellular automata generated with re­cursion rules similar to (2) but with 'random' seeds[6]; in particular, comparison with the cover page of the premier issue of the journal Complex Systems is in­vited. Therefore, statistical analysis of this gasket may be of importance.

Table 1. For the prime number gasket.

Range of r used Dimension </ as per m ^ r''

1 ^ r :s 470 10 ^ r ^ 470 50 ^ r ^ 470

100 ^ r ^ 470 200 ^ r ^ 470

1.88460 1.93406 1.95315 1.96549 1.96926

Reprinted from Comput. & Graphics Vol. 13, No. 1, pag. 57-58, 1989

Page 179: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

192 AKHLESH LAKHTAKIA

Fig. I. The 200 X 200 lower left-hand segment of the prime number gasket.

REFERENCES B. B. Mandelbrot, The Fractal Geometry of Nature, Free­man, New York (1983). W. J. LeVecque, Fundamentals of Number Theory, Ad­dison-Wesley, Reading, MA, (1977). A. Lakhtakia, R. Messier, V. K. Varadan and V. V. Var-adan. Self-similarity versus self-affinity: The Sierpinski gasket revisited. / Phys. A: Math. Gen. 19, L985-L989 (1986).

4. B. B. Mandelbrot, Self-affine fractal sets, I, in Fractals in Physics, L. Pietronero and E. Tosatti, eds. North-Holland, Amsterdam (1986).

5. T. Nagell, Introduction to Number Theory. Almqvist & Wiksell, Stockholm (1951).

6. O. Martin, A. M. Odlyzko and S. Wolfram, Algebraic properties of cellular automata. Commun. Math. Phys. 93,219-258(1984).

Page 180: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Comput. & Graphics Vol. 17, No. 1, pp. 95-102, Printed in Great Britain.

193

Chaos and Graphics

DISCRETE APPROXIMATION OF THE KOCH CURVE

SAM CHUNG HWANG and HYUN SEUNG YANG* Department of Computer Science, Center for Artificial Intelligence Research, Korea Advanced Institute

of Science and Technology, 373-1, KooSung-dong, YooSung-ku, Daejon, Korea 305-701

Abstract—Existing algorithms for Koch curve generation do not consider the discrete environment of the computer. They do not define the termination condition explicitly. Therefore, generation of the curve must be terminated in ad-hoc manners. This paper describes a new algorithm for discretely approximated Koch curve generation which produces only the points on the limit Koch curve and describes the mathematically well defined termination condition.

1. PREVIOUS ALGORITHMS OF KOCH CURVE GENERATION

In computer graphics, various shapes of nature, mountains, terrains, trees and clouds, are represented by fractals[l, 2, 3]. Many fractal generation methods have been developed and used to create images of nat­ural scenes [4, 5,6, 7 ]. Cantor dusts as seen in Saturn's ring, Julia sets, Mandelbrot sets, and Koch curves are classical fractals[8]. Among these, the Koch curve is defined by initiators and generators and produced by recursively replacing each initiator by a generator. There are two representative algorithms for generating Koch curves.

1.1. Recursive substitution {Mandelbrot's genera-tion)[^]

Mandelbrot defined the Koch curve, as a rough model for coastlines, by initiators and generators. He generated the Koch curves by the following three steps

1. Select an initiator (arbitrary polygon). 2. Replace edges of initiator by generators (open poly­

gon). 3. Repeat 1, 2 until appropriate points are generated.

Because initiators are not a set of vectors but a set of edges, direction of the Koch curve generation is controlled implicitly and is difficult to manipulate. The termination condition of the Koch curve generation is not mathematically well defined. Thus, generation must be stopped in an ad-hoc manner.

1.2. Attraction method [ 9 ] Prusinkiewicz defined the initiator by a set of vectors

to easily control the curve generation direction. He also defined the generators by a set of transformations of the vectors. He characterized Koch curves as the smallest nonempty sets closed with respect to a union of similarities on the plane and named the smallest nonempty sets the limit Koch curve C o. He generated the Koch curves by the following three steps.

1. Start from a set ^o = {z} where z E CQO 2. Given set 5„, construct Sn+\ by applying all trans­

formations (/)/ in $ to all points z in Coo.

* To whom the correspondence should be addressed.

3. Repeat 1, 2 until the desired number of points ap­proximating Coo is reached.

In this algorithm, the termination condition is also not mathematically well defined. Generation of the Koch curve must be stopped in an ad-hoc manner. Because a pixel {x,y) of the image plane corresponds to the domain {x -\- x\ y -\- y') where —Ax/2 < x' < Ax/2, -Ay/2 < y' < Ay/2 and Ax, Aj; are the row and column length of a pixel, some of the generated points (x, y) of the image may be visited repeatedly.

To generate the Koch curve automatically without user interaction, the termination condition of the curve generation algorithm must be mathematically well de­fined. For termination conditions, we defined the tol­erable distance e between the limit Koch curve Coo and the approximated Koch curve Ck.

2. THE KOCH SYSTEM

The Koch system that generates the Koch curve is informally defined as follows [ 8 ]. The Koch curve is constructed by recursively replacing the initiator, which is a set of edges of a polygon with the generator, which is an open polygon. This section describes the formal definition of Koch system analogous to Mandelbrot's notion.

If a poly vector is an ordered set of vectors in a plane denoted by A = ^i • • • a„, and if we denote WSLSSL set of all vectors in the given plane and W* SLS the class of all poly vectors in the given plane, the Koch system may be defined as follows:

Definition 1: A Koch system is a pair K= (I^P} where the initiator / is poly vector Oi • • • i E W^ and the production Pis a pair (? , 3i • • ^Qm)^ ^X W*. The production P is defined by a set of vector transfor­mations (translation, rotation, scaling) 0/ E $, m = 1 , . . . , m, where p (f), = 5/ • The production P is denoted b y p - ^ 5 i - • • 5m wherep = (ixpi,ypi),ixp2,yp2)}, Qi = {(Xix, yix)AXi2, yti)) ^rid Xpx = Xi^ypi = yn, Xp2 — Xm2, yp2 — ym2-

Figure 1 describes the production P of the snowflake. The initiator is an arbitrary vector in a 2D plane and the production is a set of transformations of the ini­tiator.

Denote that the initiator and the generator of Man­delbrot are composed of polygons and in the Prusink-

Reprintedfrom Comput. & Graphics Vol. 17, No. 1, pag. 95-102, 1993

Page 181: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

194 SAM CHUNG HWANG and HYUN SEUNG YANG

wicz's production (corresponding to generator), the first point (x^i, y^i) and the last point {Xp2, ypi) of the predecessor p need not be the first point ( x n , > ii) of the first vector 5i and the last point (Xmi.ymi) of the last vector 5w in the successor. By constraining the first point (xxx,yn) of the first vector 5i and the last point (Xmi, ymi) of the last vector 5m in the successor is the first point {Xpx.ypi) and the last point {Xp2, ypi) of the predecessor, it is possible to generate the discretely ap­proximated Koch curve all of whose points are in the limit Koch curve Coo •

According to Definition 1, we can generate the Hmit Koch curve C^ by recursively applying the "produc­tion" to the initiator infinitely. But in a discrete en­vironment, we cannot and need not apply the pro­duction infinitely. A finite number of the production must be applied. How many times must it be applied? The limit Koch curve C^ (the ideal Koch curve) is the curve made by applying infinite number of pro­ductions to the initiator and is described as follows:

Let p ^ - 5i • * • 5m be the production of a Koch system K and ^ 0 / = 5/ where 0, E # . If p T = ^ and 5i • • • 5m = (^7 • • • Sm) 7". as in Fig. 1, then 'a is called to be directly transformed to 5i • • • 2 ^ denoted by d. =• ?i • • • 5;,,. In other words, when the production P is applied to an arbitrary vector a where pT = a and produced a set of vectors J i • • • J ^ , 5i * • • 5m = (^1 • * '^m)T. Similarly, when we apply the produc­tion to a poly vector ^i • • • ^i in the plane, we obtain a new poly vector ^,1 • • • 5 i ^ - • • J n • • • 2i;„ denoted by ^ 1 - • -^1 => 5 n - • -^im- • - S i i - • -J im.

As above, when the initiator is a polyvector / , and the production P is applied to / , we get the Koch curve of order one (Ci) denoted by / =• Ci. A Koch curve of order « + l(C„+i) is produced by applying production Pto the Koch curve of order n{C„) denoted by C„ =• C„+i. If the production P is infinitely applied to the initiator / , we obtain the limit Koch curve C^.

3. APPROXIMATED KOCH CURVE

In practice, we cannot apply an infinite number of productions to obtain the limit Koch curve C^. We must apply a finite number of productions and produce

(xi, yi) ( 2. yz) yv

(b)

W • ^ K

<t>i ¥i

qT •^T t Fig. 2. Relationship between production and direct transform.

an approximated Koch curve Q of the limit Koch curve Coo- For the approximated Koch curve Q , we must introduce some measure between the approxi­mated Koch curve Q and the limit Koch curve Coo • In this paper, we used the maximum distance between the approximated Koch curve Ck and the limit Koch curve Coo as the measure between the two curves. The maximum distance between the two curves is defined as follows:

A curve is a set of points and the distance between two curves can be defined in terms of the distance be­tween the two sets of points. When p(x, y) is the Eu­clidean distance between the two points x and y, the distance between a point x and a set Y{a line) is given by pix, Y) = inf p(x, y). The half-distance between

two sets (two curves) X and Yis equal to p'(X, Y) = sup p(jc, Y). And the distance between two sets Xand

y i s p ( X , Y) = rmix{p'{X, Y),p'{Y,X)}. If the contraction ratio of a production p -^ Qi

- • • U length (Qrm^) , ^ . , , ' ' ' Qmis given byy = where Qrnax is the

length(p) longest vector ofqi where / = 1, . . . , m, then the ap­proximated Koch curve Ck not separated from the limit Koch curve Coo over a predefined tolerable distance e can be obtained by Theorem 1. Theorem 1: Given a Koch system K = Ca, p, ^^ 5i * * •5m) and the tolerable distance e, if the contrac­tion ratio 7 is less than 1.0, X is the length of 'a and do is the distance between Co and Cx, then the approxi-

: i - 7 ) \ mated Koch curve Ck where k •• \og. '[- IS

not separated from the limit Koch C« tolerable distance e.

do over a predefined

Proof: Given a vector O/ E C„, O/ =• r, i • • • Tim whose relation is described in Fig. 2. Translation T is com­posed of rotation, scaling and translation. So, distance ratio

(d)

Fig. 1. Production of the snowflake curve, (a) ^, production predecessor of the production P; (b) 5i * * * 52, production successor of the production P; (c) a = p r , a vector in 2D plane; (d) Ji • • • ?4 = (5i • • • 'QA)T, production is applied

to a vector in (c).

dni

d.

p{di, 71

pip. Pi'

p(p,Qr •

'Tim) ^ length(o,)

length(p) •

length(p)

•5m)

'Qm)

^"^ do p(a,^r ' '^nt) X

The distance between C„ and C„+i has the following property;

Page 182: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Discrete approximation of the Koch curve 195

dn = p{Cn, C„+i) < m20^{Spni)dp ( / = 1, . . . , m )

= m2i\{Spni) Spado

max (length (o/) , = 1 ^0

By the way, o E C„, length {o) < X7"

p~\

For a integer p ( > « ) , p(C„, Q,) < 2 di = doy" i=n

1 - 7^~"

1 - 7 In the approximated Koch curve, tolerable distance is c, so

p(C„, Coo) ^ <o 1 - 7

< e.

log^

So the approximated Koch curve not separated from the limit Koch over the tolerable distance e is Q where

e(\_-y)-

do In Theorem 1, the contraction ratio 7 and do the

distance between Q and C\ can be measured auto­matically. So when the tolerable distance e is given, we can automatically determine the approximated Koch curve Ck not separated from the limit Koch curve over the predefined tolerable distance e. In case of the snow-flake in Fig. 3, the contraction ratio 7 is 1/3.

4. DISCRETELY APPROXIMATED KOCH CURVES This section describes the algorithm to generate the

images of discretely approximated Koch curves. All the points of the discretely approximated Koch curve must not be separated from the limit Koch curve over the tolerable distance e and must be connected.

When we call a point z is first on vector d, = ( ( x i , y\)^ (-^2, ^2) ) , if z = (xi , yx) and a point z is last on

X2

(xl, yl) i;t y2) .^yx

(a) (b)

(c)

f = <(xl, yl), (x2, y2)>

Xo = (xl, yl) Xl = Xo + (dx, dy)

X2 = Xl + (rx, ry) X3 = Xo + 2*(dx, dy) X4 = (x2, y2)

Fig. 3. Construction of the snowflake curve, (a) Initiator / = {{xu y,) , (X2, ^2)); (b) Production p => qoQxMi. (c) Cj,

snowflake of order 1; (d) C2, snowflake of order 2.

vector a = {{xx, >^i), {xi, yi)"), if z = (X2, yi). A point z is called on vector a if z is first on or last on a or if z E {/1 / i s a point at the line between {xx,yx) and (^2, ^2)} and a point z is on 5i • • • 5„, if z is on S, for some / = 1, . . . , «.

• Set Co = / . For each vector ^0, = <(-^on, yo/i), {xon, yon)) E Co,

drawpoint at {xot 1, yot 1) and (xo/2, yon)-

e{\ - 7 ) 1 • For k= 1 to A:: log^ do

Ck = C,_i$ For each vector a= ((Xkix, ykiOAxkn, ykn)} ^ Ck, drawpoint at (Xkix, ykn) and {Xkn, ykn)

• While Ck^ 0 _^ For each vector 3 = ((Xkix, ykn), (Xkn, ykn)) E Ck whose length > e Ck^l = Ck^X U{Jx'" 7m\'3^Jx- • Jm}

drawpoint at (x^x, ykn) and {Xkn, ykn)-k = k+ 1

According to Theorem 1, we can approximate the limit Koch curve C^o by the approximated Koch curve Ck within the tolerable distance e. By Theorem 2, the first and the last points of each vector in the approxi­mated Koch curve Ck is on the limit Koch curve. If the length of each vector in the approximated Koch curve Ck is less than one pixel length, then the vector is drawn by first and last points of the vector and we can draw the Koch curve only using the points in the limit Koch curve C^ and all the generated points are connected.

When the length of the vectors in the approximated Koch curve Ck is greater than one pixel, by applying the production until the length of the newly generated approximated Koch curve is less than one pixel length, we can draw the Koch curve only using the points in the limit Koch curve Coo • Then all the drawn points are connected.

Given a Koch system K= ( / , P ) , we represent the production P as a set of vector transformations $ (ro­tation, translation, scaling of a vector). When the tol­erable distance is e, image of the Koch curve is gen­erated as follows:

• Set Co = I. For each vector Uoi = ((xon, yon), (^0/2, ^0/2)) ^ Co drawpoint at (xot 1, yot 1) and (xo/2, yon)-

\, ^(1-7)1 • For k = 1 to /c < do

Ck = Ck-x^ For each vector a = ({Xkix,ykii), (Xkn, ykn)} ^ Ck drawpoint at (x/t/i, y;t/i) and (Xkn, ykn)

• While Ck^ 0 ^ For each vector 3 = ({Xkix, ykn), {Xkn, ykn)) ^ Ck whose length > 6

Ck^X = Ck^X U {Tr • 'Jm\'3=^7l- -Im)

Page 183: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

196 SAM CHUNG HWANG and HYUN SEUNG YANG

(b) (c)

Fig. 4. (a) Cs, the approximated snowflake curve with tolerable distance 1.0; (b) Ce, the approximated snowflake curve with tolerable distance 0.5; (c) The discretely approximated snowflake curve.

drawpoint at (Xkn, ykn) and (x^/2, ykii)-k = k-\- 1

5. EXPERIMENTAL RESULT

Ifdx = (X2 - x,)/3, dy = ( 2 - yi)/X rx = dx/2 - V 3 ^y/2 and r> = V 3 dx/2 + dy/2, the initiator / and the production P of the snowflake are described in Fig. 3. The contraction ratio 7 of the snowflake is 1/3. When the initiator / = <(0, 0), (0, 511 )> and the image size is 512 X 512, the distance do between Co and Cx is 512 V 3/6. If the tolerable distance between the limit Koch curve and the approximated Koch curve is 1.0 (one pixel length), the approximated curve C5 is not separated from the limit Koch curve over the tolerable distance 1.0. Figure 4a describes the image of the approximated snowflake curve C5 and Fig. 4b describes the image of the approximated snowflake curve Ce when the tolerable distance is 0.5. Figure 4c describes the discretely approximated snowflake curve.

The dragon curve in Fig. 6 is described by two trans­formations in Fig. 5. The contraction ratio 7 of the dragon curve is 1/V2. When the initiator / = <( 128, 256), (384, 256)), the distance do between Co and Cx is 128. When the tolerable distance e is 4.0, the ap­proximated curve is CM and the approximated curve with tolerable distance e = 1.0 is Ci 6.

Figure 7 describe the Sierpinski gasket by the initiator

/ of three vectors and the production of 3 transfor­mations of vectors. The contraction ratio 7 of the Sier­pinski gasket is 1/2 and the initiator / = {<(0, 0), (0, 511)>, <(0, 511), (443, 256)>, <(443, 256), (0,

- ^ y2)

(d)

-^ = <(xl .yl) ,(x2,y2)>

Xo = (xl, yl) X2= (x2, y2)

Xi = ( (x l+x2 + y 2 - y l ) / 2 , ( y l + y2 + x l - x 2 ) / 2 )

Fig. 5. Production of the dragon curve, (a) Initiator / = ((x 1, y\), (x2, >;2)>; (b) Production p => Mi ; (c) C,, dragon

curve of order 1; (d) C2, dragon curve of order 2.

Page 184: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Discrete approximation of the Koch curve 197

(a)

(b) (c)

Fig. 6. (a) C,6, the approximated dragon curve with tolerable distance 4.0; (b) CM, the approximated dragon curve with tolerable distance 1.0; (c) The discretely approximated dragon curve.

511))}. The distance do between Co and Ci is 256. When the tolerable distance e is 4.0, Fig. 8a describes the approximated curve is C-i. Figure 8b describes the approximated curve C9 with the tolerable distance £=1.0 .

Generalisation and randomisation of the plane Koch curve [10] can also be represented by some initiators and productions. Figure 9 describe a generalisation of the plane Koch curve by initiator / = {((0, 256), (511,

(x3, y3)

(xl, yl) (x2,y2) Xo

X2

X3

(a) (b)

-f = <(xl. yl), (x2. y2)>

Xo = (xl, yl) Xl =((xl+ x2) / 2, (yl+ y2) / 2)

X2 =(x2+V5/2(y2-yl ) , y2-V5/2(x2-xl))

X3 =(x2,y2)

Fig. 7. Production of the Sierpinski gasket, (a) Initiator / = <(xl, y 1), {xl, y2))\ (b) Production p => Mi^2.

256))} and a production. The distance do between Co and Ci is 512/3 and the contraction ratio 7 is 1/3. Figure 10 describe the images of the approximated and the limit curves.

Figure 11 describe a randomisation of the plane Koch curve by initiator / = { < ( 0 , 256),(511,256)>} and two productions. The maximum distance of the distance dpi (=512/3) between Co and Ci produced by P\ and the distance dp2 (=512/5) between Co and Ci produced by P2 is dp2. The contraction ratio is the maximum value of the contraction ratio 71 (= 1/3) of the production PI and the contraction ratio 72 ( = 1/ 5) of the production P2. Figure 12 describes the images of the approximated and the Umit curves.

6. CONCLUSION

To generate the Koch curve automatically without user interaction, the curve generation must be stopped in a finite number of steps and the termination con­dition must be defined. In this paper, we demonstrated the approximated Koch curve and the discretely ap­proximated Koch curve that are not separated from the limit Koch curve over predefined tolerable dis­tances. We also proposed a termination condition for the generation of the approximated Koch curves. We think this approximation method can be applied to many fractals.

Page 185: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

198 SAM CHUNG HWANG and HYUN SEUNG YANG

(b) (c)

Fig. 8. (a) C7, the approximated Sierpinski gasket with tolerable distance 4.0; (b) C9, the approximated Sierpinski gasket with tolerable distance 1.0; (c) The discretely approximated Sierpinski gasket.

(xl, yl) (x2, y2)

(a)

X 2 ^ X3

qo

Xo

(b)

% q4

X4 X5

^ = <(xl, yl). (x2, y2)>

dx = (x2-xl)/3, dy = (y2-yl)/3, rx = -dy, ry = dx

Xo = (xl,yl) Xl = Xo + (dx. dy) X2 = Xi + (rx, ry)

X3 = X2 + (dx, dy) X4 = Xl + (dx,dy) X5 = (x2. y2)

Fig. 9. A generalisation of the plane Koch curve, (a) Initiator / = ({x\, yl), (xl, y2)); (b) Production p

Page 186: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Discrete approximation of the Koch curve 199

(b) (c)

Fig. 10. (a) C4, the approximation of a generahsation of the plane Koch curve with tolerable distance 4.0; (b) C5, the approximation of a generalisation of the plane Koch curve with tolerable distance 1.0; (c) The

discrete approximation of a generalisation of the plane Koch curve.

(xl, yl) (x2, yl)

(a) (b)

•f = <(xl, yl), (x2, y2)>

dx = (x2-xl)/5, dy = (y2-yl)/5, rx = -dy, ry = dx

Xo = (xl,yl) Xi=Xo + (dx,dy) X2 = Xi + (rx, ry)

X3 = X2 + (dx, dy) X4 = Xl + (dx,dy) X5 = X4 + (dx,dy)

X6 = X3 + (dx,dy) X7 = X6 + (dx,dy) Xs = X5 + (dx,dy)

X9 = (x2, y2)

Fig. 11. A randomisation of the plane Koch curve, (a) Initiator / = ({x\, y\), (xl, y2)); (b) Production

r M i M 3 ^ 4 ( i n F i g . 9 ) - P l

or

7oT,r2T37475T6r7T8 —P2

Page 187: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

200 SAM CHUNG HWANG and HYUN SEUNG YANG

(b) (c)

Fig. 12. (a) C4, the approximation of a randomisation of the plane Koch curve with tolerable distance 4.0; (b) C5, the approximation of a randomisation of the plane Koch curve with tolerable distance 1.0; (c) The

discrete approximation of a randomisation of the plane Koch curve.

REFERENCES 1. A. Fournier, D. Fussel, and L. Carpenter, Computer ren­

dering of stochastic models, Comm. ACM 25(6), 371-384(1982).

2. A. Norton, Generation and display of geometric fractals in 3-D, Comp. Graph. 16(3), 61-67 (1982).

3. A. Smith, Plants, fractals, and formal languages, Comp. Graph. 18(3), 1-10(1984).

4. G. Gardner, Visual simulation of clouds, Comp. Graph. 19(3), 297-303(1985).

5. M. Barnsley, Fractals everywhere, Academic Press, New York (1988).

6. M. Barnsley, R. Devaney, B. Mandelbrot, H. Peitgen, D.

10.

Saupe, and R. Voss, The Science of Fractal Images, Springer-Veriag, Berlin (1988). F. Musgrave, C. Kolb, and R. Mace, The synthesis and rendering of eroded fractal terrains, Comp. Graph. 23(3), 41-50(1989). B. Mandelbrot, The Fractal Geometry of Nature, W. H. Freeman, San Francisco (1982). P. Prusinkiewicz and G. Sandness, Koch curves as at-tractors and repellers, IEEE Comp. Graph. Appl. 8(6), 26-40(1988). A. Lakhtakia, Generalisations and randomisation of the plane Koch curve, / Phys. A: Math. Gen. 20,3537-3541 (1987).

Page 188: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 201

Chaos and Graphics

VISUALIZING CANTOR CHEESE CONSTRUCTION

CLIFFORD A. PICKOVER Visualization Systems Group, IBM Thomas J. Watson Research Center, Yorktown Heights, NY 10598

and

KEVIN MCCARTY ROLM Systems M/S 336, 4900 Old Ironside Drive, Santa Clara, CA 95054

Abstract—This note introduces the reader to Cantor cheese, an artistically interesting analog of the Cantor set described by Mandelbrot. A related object, the solenoid, is also explored. Computer programs are given for Cantor cheese and solenoid construction.

1. CANTOR CHEESE

The term Cantor cheese was used by Stewart[l] to de­scribe an artistically interesting analog of the Cantor set described by Mandelbrot[2]. As background, a Cantor set can be constructed by taking an interval of length 1 and removing its middle third (but leaving the end points of this middle third). This leaves two smaller intervals, one-third as long. The middle thirds of these smaller segments are removed and the process is repeated:

The fractal dimension of this particular Cantor dust after many iterations is less than I since £> = log 2/ log 3 = 0.63. Cantor dusts with other fractal dimen­sions can easily be created by removing different sizes (or numbers) of intervals from the starting interval of length I.

A topologically similar set starts with a circular disc. Everything except for two smaller discs is removed. Here we use pairs of circles rather than pairs of lines, and the subdivisions are repeated as with the Cantor set described above. We retain only those points inside the circles. Fig. I is a picture of this Cantor cheese with each circle's radius slightly less than half of the previous generation's radius. (The term "generation" refers to the nesting level of the circles; see pseudocode in Pro­gram I.) If we consider just the line along the diameter, the fractal dimension for the set of points is close to 1. Smaller fractal dimensions are obtained by using circles which are further shrunken and separated, e.g.:

Fig. 1 is a cross section taken at the front of the object in Fig. 2. In Fig. 2, the nested circles are rep­resented as nested cylinders for artistic purposes. (Some generations are represented by cones to show the in­terior nested structures.) A graphics supercomputer, such as a Stellar GSIOOO, allows models of the Cantor cheese to be rotated, shaded, and magnified in real time.

For readers who wish to display cross-sections of the Cantor Cheese, a computer program pseudocode is given in Program I. Note that if recursive computer program languages are used, the pseudocode for gen­erating the cheese cross sections can be simplified (Program 2).

2. DESCRIPTION OF A VARIABLE DIMENSION CHEESE

It is possible to create a 3-D representation of the Cantor cheese such that the fractal dimension corre­sponding to the cross-section continuously decreases

Reprinted from Comput. & Graphics Vol 14, No. 2, pag. 337-341, 1990

Page 189: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

202 CLIFFORD A. PICKOVER and KEVIN MCCARTV

Fig. 1. Cross section of the Cantor cheese in Fig. 2 (Scale Factor, 1.000).

Program 1. Program Code for Generating Cantor Cheese Cross-Sections

m - a 1-D array containing the midpoints of each circle. gen - the number of generations. DrawCircleAt - draws a circle at (x,y) with a given radius. The picture boundaries go from 0 to 100 in the x and y directions.

m(1)=50; count=l; radius=50; frac=1; DrawCircleAt(m(count),50,radius); do gen = 0 to 10;

bot = 2**gen; top=(2**(gen+1))-1; radius=radius/2 ; l=radius; do i = bot to top;

m(count+1)= m(i) - frac*l; DrawCircleAt(m(count+1),50,radius); m(count+2) = m(i) + frac*l; DrawCircleAt(m(count+2),50,radius); count=count+2;

end; end;

Page 190: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Visualizing Cantor cheese construction 203

Fig. 2. 3-D Representation of Cantor cheese. Fig. 4. Solenoid, second stage. The mapping is iterated to the second level of nesting.

Fig. 3. Solenoid, first stage. The initial torus is shown as a mesh cage.

from front to back of the figure. Instead of cylinders, nested spire-like objects can be used which taper along the z-direction. If one were to slice into such a figure, each cross-section has a different fractal dimension. The front face, corresponding to D '^ I, looks like Fig. 1. The back cross-section resembles the second in-line figure in this paper. Nested circles still form the cross-sections of nested spires, but the nested circles separate as the dimension decreases. The first enclosing circle does not change size, and so it generates a cylinder. The two smaller circles inside change their sizes in di­rect proportion to the shrinkage factor, and so form cones. At the next level, the shrinkage factor is applied twice, so the diameters vary as the square of the shrinkage factor. This form, instead of a cone, resembles a conical-shaped spire similar to a surface of revolution generated by a parabola—like a tall tent. As the nesting level of cirlces increases, the shapes formed along the third dimension are narrower spires with proHles generated by cubics, quartics, and so on. The spires are not, strictly speaking, surfaces of revolu­tion. The centers of circles of cross-section, as would-be centers of rotation, are not in general straight line segments. We call these centers of the spires spines.

As mentioned above, the enclosing circle does not change size, so its center does follow a straight line

along the z-axis. The centers of the two circles at the next level, also lie along straight lines parallel to the z-axis. At each succeeding stage, the two centers of the next stage are located along a diameter, halfway be­tween the center and the edge. Thus the centers are located according to the following scheme:

Level

0

1

2

3

k

Center coordinate

0

±i K±i±z) {(±i±z±z^)

|(±1 ±z±z^± • V ±z<^-'>)

Each choice of sign in one of these formulas locates a particular spire's center, and describes the spinal curve as a function of z. Clearly the location of the spine of a spire at level k is given by a polynomial of degree (k — 1) in the shrinkage factor z. The radius of the cor­responding cross-section circle is z .

We have created a 3-D representation of variable-dimension cheese, but the rendering of these spires is not particularly striking or informative, and so is omit­ted. A simple two-dimensional plot of the polynomial curves above is sufficient to give a correct impression of the shape. Indeed, a similar figure appears in Man­delbrot [2] (p. 81).

3. THE SOLENOID, A COUSIN OF THE CANTOR SET

The solenoid is a topological construction which arises from, and is related to, the Cantor set. It is one of the principal examples of a strange attractor in dy­namical systems theory. In this paper, we do not dwell on its intersting topological properties, for that would run to too many pages (see [ 1,5,6 ] for further reading). Instead, we develop some formulas which help to elu­cidate its self-similar structure, and allow computer graphical generation of images which are pleasing in their simplicity and grace, yet sufficiently complex to intrigue the eye.

Page 191: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

204 CLIFFORD A. PICKOVER and KEVIN MCCARTY

Program 2. Program Code for Cantor Cheese Cross-Sections (Recursive)

The pseudocode for generating cheese cross-sections can be simplified in a manner which more clearly reveals the recursive nature of the construction.

frac -I eve I -

size reduction factor, < 0.5 number of generations (recursive depth)

Procedure DoCircle(x, y, radius, level : integer); begin

(* first draw the enclosing circle *) DrawCircleAt(x, y, radius);

(* if there are further levels, then work *) (* on the left circle, then the right circle *) if (level > 1) then begin

DoCircle(x - radius/2, DoCircle(x + radius/?*,

end; end;

y, frac * radius, level-1); y, frac * radius, level-1);

The starting point of the solenoid is the solid torus, and a mapping from the torus to itself. The mapping squeezes the tube of the torus to half its original di­ameter, stretches it out to twice its original length, and wraps this length twice around, inside the skin of the original. In wrapping around twice, one coil sits next to another one with no overlap, just as one would coil up lengths of a garden hose. The coil makes a half-twist as it wraps around once, joining back up to itself after tvo turns.

We have found that the representation of nested tori provides quite a visualization challenge. Our first at­tempts portrayed these complicated objects using var­ious degrees of transparency, but we found that the resulting figure was too complicated to understand. The representation we settled on uses both shaded fac­ets and wire meshes. The first stage is illustrated in Fig. 3. The initial torus is shown as a mesh cage. Again, note that we can rotate and shade the objects in real time. Three colored lights were used to illuminate the object.

This operation of stretching, winding and twisting is repeated indefinitely. As the mapping carries the original torus to an image of itself wrapped twice around, it also carries the twice-wrapped image to one wrapped four times around. Each iteration produces another tube nested inside the previous one. At each stage, the number of windings doubles and the thick­ness halves. This process converges in the limit to a connected set of infinitely thin windings, called a so­lenoid.

The easiest way to describe the way this mapping works is to use complex numbers. A point inside the solid torus is located by a pair of complex numbers (z, w). The z coordinate represents the longitude angle, and locates a point on the unit circle in the complex plane which will be the center or spine of the torus. The w coordinate locates a point inside a disk of radius 5, considered as a piece of the complex plane. The disks are imagined to be threaded on the unit circle like a necklace. With these coordinates, the mapping which wraps the torus twice around inside itself is

f:(z,w)^{z\wl2^- z/A).

The term z simply wraps the unit circle twice around itself as z traverses the unit circle once. The term w/ 2 shrinks the original w coordinate to half its size, while the z/4 term moves it away from the w = 0 origin, so the image does not intersect itself on the second loop. The simple algebraic formula allowed by complex number representation makes it easy to compute re­peated iterations of the mapping. (See Program 3 for an algorithm to iterate this calculation.)

The connection with the Cantor cheese is seen by considering a cross-section of the solenoid construction perpendicular to the windings. A sequence of nested disks is seen; each disk contains two smaller disks just as in the Cantor cheese construction. When the lon­gitude angle is zero (z = 1 + Oi), all nested disks line up, but for other longitude angles the varying amounts of twist cause the disks to become separated. This sep­aration can be seen in Fig. 4, which shows the mapping iterated to the second level of nesting.

4. HISTORY

For readers interested in some historical background on the Cantor set, the set was discovered, by Henry Smith in 1875. (Henry Smith (1826-1883) was a pro­fessor of geometry at Oxford [2].) The founder of set theory, George Cantor, made use of Smith's invention in 1883. IBM Fellow Benoit Mandelbrot has charac­terized and made use of this set in the field of fractal geometry, and readers should consult his book The Fractal Geometry of Nature for some elegant drawings of this set and for some closely related curves such as the Devil's staircase. Ian Stewart's book Does God Play Dice? {The Mathematics of Chaos) provides an excel­lent introduction to the Cantor set as well as chaos theory and fractals, and the book is highly recom­mended. Hofstadter[3] explains how the cross-section of various strange attractors, such as the Henon at-tractor, can be considered as Cantor sets.

For those readers interested in a mathematical no­menclature for the Cantor set, see Barnsley's book Fractals Everywhere[4]. For example, the Cantor set can be considered a subset of the metric space [0, 1].

The Cantor set C can then be defined as C n /„ M=0

Page 192: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Visualizing Cantor cheese construction 205

Program 3, Program Code for Generating Solenoid The following pseudocode computes (x, y, z) coordinates for the centers of the nested tubes in the solenoid construction.

level: nesting level circlepts: number of steps around longitudinal circle zr, zl: longitudinal angle, as a complex number pair wr, wi : location inside the cross-sectional disk, as

a complex number pair.

circlepts = 36; pi = 3.14159;

for i 0 to circlepts do begi n angle = 2 * pi * 1 X = cos(angle); y = sln(angle); zr = x; zi = y; wr = 0; wi = 0; for j = 1 to 1 eve 1

begin wr = wr + wi = wi + zx = zr *

/ circ

do

zr / U; zl / U; zr - z 1

zy = 2 * zr * zi ; zr = zx; zi = zy; end;

x = zr * (1 + wr); y = zl * (1 + wr); z = wi ;

(* Initial longitudinal *) [ * angular position *) (* as a complex number *) (* cross-section location *)

(* complex squaring (* of z *)

end;

(* The radius of the cross-sectional disk centered at *) (* the point (x,y,z) Is 1/(2**(level+1)) *)

where

/o=[0, 1],

/i = [ 0 , l ] U [ i | ] ,

/2= [ 0 , i ] U [ i , | ] U [ f J ] U [ f , | ]

Notice that the point x = 0 is in the Cantor set, as well as many other points.

For additional background on the solenoid, Stephen Smale identified this kind of object as an example of a strange attractor in his seminal 1967 paper "DifTer-entiable Dynamical Systems" [ 7 ] .

For additional artistic representations, see [ 8 ] .

REFERENCES 1. I. Stewart, Does God Play Dice? {The Mathematics of

Chaos), Blackwell, New York (1989). 2. B. Mandelbrot, The Fractal Geometry of Nature, Freeman,

New York (1982). 3. D. Hofstadter, Metamagical Themas, Bantam, New York

(1985). 4. M. Barnsley, Fractals Everywhere. Academic Press, New

York (1988). 5. D. Ruelle, Strange attractors. Mathematical Intelligencer

2, 126-137(1980). 6. R. L. Devaney, An Introduction to Chaotic Dynamical

Systems. Menlo Park: Benjamin (1989). 7. S. Smale, Differentiable dynamical systems. Bull. Am.

Math. Soc. 73, 748-817 (1967). 8. C. Pickover, Computers, Pattern. Chaos, and Beauty. St.

Martin's Press, New York (1990).

Page 193: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 207

Chaos and Graphics

NOTES ON PASCAL'S PYRAMID FOR PERSONAL COMPUTER USERS

JIM NUGENT 614 West Hanssler Place, Peoria, IL 61604

Abstract—A lattice of octahedra and tetrahedra (called an "oct-tet lattice") is a useful paradigm for under­standing the structure of Pascal's pyran\id, the 3D analog of Pascal's triangle. Notation for levels and co­ordinates of elements, a standard algorithm for generating the values of various elements, and a ratio method that is not dependent on the calculation of previous levels are discussed. The figures show a bell curve in 3D, the association of elements to primes and twin primes, and the values of elements mod(.x) through patterns arranged in triangular plots. It is conjectured that the largest factor of any element is less than the level index.

1. INTRODUCTION

In a 1966 Scientific American column, M. Gardner mentions in passing that there are, " . . . endless vari­ants on the (Pascal's) triangle, and many ways to gen­eralize it, such as building it in tetrahedral form to give the coefficients of trinomial expansions" [ 1 ].

One of the illustrations of Pascal's triangle, included with that article, shows the first 100 rows of the triangle with odd and even numbers represented as dots. The pattern of dots representing odd and even numbers in the 2D Pascal's triangle correspond to the octahedral and tetrahedral sections of an "oct-tet lattice" (Figs. 1 and 2). The octahedron faces of the lattice map to the even dots while the tetrahedron faces map to the odd dots.

If we construct a 3D Pascal's triangle, will the dis­tribution of odd and even values for the elements in the interior correspond to the octahedral and tetra­hedral components of an oct-tet lattice?

A Galton board [ 2 ] simulation, which rolls marbles through a triangular maze, generates values that ap­proximate the values of coefficients of a binomial ex-

Fig. 1. A tetrahedron subdivided into 4 tetrahedra and 1 oc­tahedron. The top tetrahedron is likewise subdivided into 5 parts and the top tetrahedron in that group is subdivided

again.

A ooeo

0 4 6 4 0 0 0 10 10-00

0 6 0 20 0 6 0 00000000 Fig. 2. Pattern of odd and even numbers in Pascal's triangle.

Elements with odd values are plotted as black circles.

pansion. At each fork in the maze, the marble has a 50-50 chance to go either way until it falls into bins at the bottom of the maze in proportions that roughly approximate a bell-shaped curve. The Galton Board can be simulated with a computer program that is a variation of the one used to generate the 3D analog of Pascal's triangle.

2. PRECURSORS

S. Mueller published an article in 1969 entitled Re­cursions associated with Pascal's pyramid. In Mueller's definition:

Pascal's pyramid is the three-faced pyramidal array of coef­ficients in the expansion of the trinomial, {a^- b + c)\ such that the coefficients of (a + ^ + c) are systematically placed beneath those of(<2 + /7 + c)^"\ resulting in a Pascal triangle on each of the three faces [ 3 ].

Mueller labels the initial plane, containing one term, as level 0 (Fig. 3) which turns out to be a good choice of notation. Terms on higher levels are expressed as the product of two binomial coefficients.

J. Staib and L. Staib[4] pubHshed The Pascal pyr­amid in 1978. Like Mueller, the Staibs also used a stack of successively larger triangles to form a pyramid

Reprinted from Comput. & Graphics Vol 15, No. 2, pag. 303-311, 1991

Page 194: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

208 JIM NUGENT

(0,2.2)

10

(0,2,0)

(0,1,0)

(0,0,0)

(2,2,2)

(2,0.2)

Fig. 5. Tetrahedral coordinates in relation to Cartesian cube Fig. 3. Levels or slices of tetrahedron in 3D analog of Pascal's corner,

triangle.

(see Fig. 3). They developed a coordinate notation for each point on each triangular level, a system for de­termining which of the small triangles were centered above a point on the next level, that the sums of the trinomial coefficients associated with the vertices of an upper triangle were equal to the trinomial coefficient found directly below that triangle, that a trinomial ex­pansion could be generalized from a binomial expan­sion and that a BASIC computer program could be written to generate the coefficients of (x -\- y -\- z)" in the form of layers of a pyramid. In a 1938 book, Stein-

haus[5] gives a short example of a method of deter­mining winners in a/hree-way election with a similar notation except that he breaks the triangle into hex­agonal cells.

In 1986, Bollinger attempted to lay pyramid power to rest with:

It would seem that in spite of the appeal of an array for mul­tinomial coefficients similar to the triangle for binomials, one is better off for most purposes using a convenient algorithm to generate the m-part compositions of n, from which the exponents on the x, and the multinomial associated with a given term are immediately available[6].

3. THE PROPER PARADIGM

Two key concepts needed for a clearer understanding of the 3D analog of Pascal's triangle are missing from these earlier works.

(0,4,0)

,1,3)

Fig. 4. Components of oct-tet lattice between levels 6 and 7 of 3D analog of Pascal's triangle. Fifteen point-down tetrahedra nest into 15 voids on the top of the 21 octahedra array while 28 point-up tetrahedra nest into the 28 voids on the bottom

of the octahedra.

,(0,0,4)

Fig. 6. Tetrahedral coordinates for level 4 of 3D analog of Pascal's triangle. The sum of the coordinates for each element

of the level equals the level index of 4.

Page 195: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Pascal's pyramid for PC users 209

Fig. 7. A 3D "Bell" curve. A plot of the values of the elements of level 74 of the 3D analog of Pascal's triangle. Coefficients

of the trinomial expansion of (x + >' + yy^^.

Fig. 8. A 3D plot of log values of elements of level 74 of the 3D analog of Pascal's triangle.

First, the octahedron-tetrahedron lattice is a more accurate 3D analog for the 2D Pascal's triangle. A tri­angular base pyramid is descriptive of outward shape but lacks any ability to illuminate the interconnect-edness of multiple subdivisions. The levels of the 3D

analog of Pascal's triangle are connected by an octa­hedron-tetrahedron lattice. Some of the tetrahedra are oriented with a point up and some with a face up (Fig. 4). Loeb states it clearly:

It is not possible to fill space with regular tetrahedra [or pyr­amids] only; four tetrahedra and an octahedron are necessary to produce a tetrahedron having eight times the volume (twice the linear dimension) of the original tetrahedron [ 7 ].

In order to fill space, octahedra are used in combination with tetrahedra (see Fig. 1). Subdividing the pyramid into these two components makes it a simple task to model the 3D analog of Pascal's triangle.

Second, Pascal's pyramid (or tetrahedron) can be modeled with ordinary Cartesian coordinates. A tet­rahedron is point-for-point congruent to a cube corner Fig. 5). If you visualize the X, Y, and Z axes as the three legs of a collapsible photo tripod, the transfor­mation from cube corner to oct-tet lattice is like changing the angle between legs from 60° to 90°. As you raise the tripod, the legs get longer but the angles between them grow more acute.

Exploring the values, levels, and properties of ele­ments of this tetrahedron appears to be as worthwhile as the investigation of Pascal's triangle has been. Do observations made of Pascal's triangle, or its 3D analog made at low levels (less than 75), hold at higher levels?

4. THE OCTAHEDRON-TETRAHEDRON LATTICE

Like Bollinger[6], Staib and Staib[4] state that, ". . . the three-dimensional nature of the Pascal pyr­amid makes it awkward to use for hand calculating the trinomial coefficients." Staib and Staib[4] and Mueller[3] both use illustrations of pyramids con­taining planes and levels with no interconnections be­tween levels. Drawing a tetrahedron, let alone a sub­divided tetrahedral lattice, can be difficult. Without actual physical models, it can be daunting to visualize how tetrahedra in combination with octahedra might provide the needed paradigm for interconnecting the pyramid's levels (see Figs. 3 and 4). Oct-tet lattices are also harder to picture in 2D figures and illustrations because most of our drawing conventions are based on viewing cubic forms.

3158520 1113100436 0614152112 9416707854 0749659792 4275595964 4346611040 2268342487 8923538886 9419550997 1447892350

0923418832 6006054656 2087828085 5880581896 1432857049 9757224426 3851673285 7449304096 3227288006 5002384307 9673803277

6449009051 3892900319 1668009822 5420699122 5211766082 9390879557 4199119254 2954040152 5208474718 6400281140 0404026245

7128478066 3585986788 5372108490 8080576571 1434290687 1324136271 7432409512 3434568466 5069699240 1388647731 1371236566

3819294363 5311712455 1432900398 1528777016 7071388682 5208821850 6631770548 5206928522 9953476144 0505323489 5068070000

Fig. 9. The value of the central element of level 1152 of 3D analog of Pascal's triangle.

Page 196: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

210 FACTORS of 227 FACTORS

2 3 5 7 13 23 41 67 97 103 131 149 193 211 227 241 271 389 409 421 439 449 463 479 499 509 541 557 571 599 619 653 683 727 757 797 827 859 887 937 971 1009 1033 1063 1097 1129

547 Digit

2 3 5 7 17 29 43 71 97 107 137 151 197 211 229 251 277 397 409 431 439 457 463 487 499 521 541 563 571 601 631 659 691 733 761 809 829 863 907 941 977 1013 1039 1069 1103 1151

JIM NUGENT

Central Element

2 3 5 7 23 31 43 79 101 109 137 157 197 223 229 257 281 397 419 431 443 457 467 487 503 521 547 563 577 607 641 661 701 739 769 811 839 877 911 947 983 1019 1049 1087 1109

Level 1152

2 3 5 11 23 31 59 79 101 113 139 163 199 223 233 263 283 401 419 433 443 461 467 491 503 523 547 569 587 613 643 673 709 743 773 821 853 881 919 953 991 1021 1051 1091 1117

end of factor list

3 3 7 11 23 37 67 83 103 131 139 193 199 227 239 269 389 401 421 433 449 461 479 491 509 523 557 569 593 617 647 677 719 751 787 823 857 883 929 967 997 1031 1061 1093 1123

Start = 06:00:22 Stop = 07:35:58 IBM PS/2 Model 50Z

Fig. 10. The 227 factors of the 547 digit number in Fig. 9. Factored in 11 hours on a standard IBM PC.

Looking for patterns among 2000 or 3000 40-digit numbers is not easy work. "Computer graphics is an excellent method by which patterns in Pascal's pyramid can be made obvious to both the mathematician and interested layperson," according to Pickover[8]. The figures in the following sections are computer generated visualizations that highlight certain information while masking other things. To decide if a 50-digit number is odd or even we only need to examine one digit, the last one.

The oct-tet lattice provides not only a mental model but also a physical model of a 3D analog of Pascal's triangle. A group of small models made of toothpicks,

soda straws, or cardboard can prove useful in order to "think" about tetrahedra.

5. BASIC NOTATION

The notation in Fig. 6 is suitable, it agrees closely with Staib and Staib's notation for coordinates on any level while it uses Mueller's scheme for numbering the levels. The first level is set at zero. This is convenient because the value of the second element in the first row at higher levels is equal to the level and the sum of the coordinates for each point on a level is equal to the level index.

Page 197: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Pascal's pyramid for PC users 211

(a) (b)

(c) (d)

Fig. 11. Mod values of elements on various levels, (a) Level 127 mod(2); (b) level 55 mod(5); (c) level 55 mod(4); (d) level 55 mod(8).

6. SOME INTERESTING PROPERTIES

6.1. A fully rounded bell curve Any row in Pascal's triangle yields the coefficients

of a binomial expansion. A plot of the coefficients gives us the familiar, flat, 2D "bell" curve. This normal dis­tribution can be modeled with a Galton board simu­lation or with a series of heads or tails coin tosses, each with a probability of 1/2.

The triangular levels of the 3D analog yield the coef­ficients of trinomial expansions. A plot of the coeffi­cients gives us a 3D "bell" curve (Figs. 7 and 8). The 3D version can also be modeled. By constructing the edges of the octahedra and tetrahedra in an oct-tet lat­tice with hollow tubes, it would be possible to construct a working 3D version of a Galton board. Here we would have a series of decisions with three possible outcomes, each with a 1 /3 probability.

The three edge rows of the 3D "bell" curve (see Fig. 7) and three flat faces of the log plot (see Fig. 8) are 2D "bell" curves. The elements on three of the four

faces of the tetrahedral 3D analog are the same as the elements of the 2D Pascal's triangle. Pascal's triangle is contained in the 3D version.

6.2. Factoring elements It appears that each element of a level factors into

values that are less than the level number. A random example. The value of the central element on level 1152 is a 547-digit number (Fig. 9). It has 227 factors, the largest being 1151. This 547-digit number has fac­tors that included 85% of the primes below its level index of 1152 (Fig. 10).

It took 23 hours to come up with this central ele­ment's value and another 11 hours to factor it, on a standard IBM/PC. For example, Pomerance states:

. . . factoring is hard. It has been estimated conservatively

. . . that to factor certain composite n with 75 decimal digits, using the fastest factoring algorithm known on an imaginary computer faster than any now in existence would take about

Page 198: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

212 JIM NUGENT

lip' ...:ii'

(a) (b)

(c)

Fig. 12. Elements that are -1-1,

(d)

-1, or -}- and - (between twin primes) the value of a prime, (a) Level 25; (b) level 35; (c) level 45; (d) level 128.

15 weeks. For certain numbers with 100 digits it could take a life time.[9]

The elements of the 3D analog of Pascal's triangle are exceptions to Pomerance's statement.

The numbers mentioned above are so large that few personal computer languages can handle them. The True BASIC language along with two language exten­sion packages, the 3-Dimensional Graphics and the Mathematician's Toolkit, were used to compute the examples in this article. The Hugelib library allows for arithmetic of arbitrary precision, up to 100,000 digits by packing numbers into strings.

6.3. Odds and evens A number of interesting 2D (and 3D) patterns can

be generated by representing the values of the elements of a level with colored dots. These are similar to the patterns of odd and even distribution within Pascal's triangle [10]. In the 3D analog, the odds and evens are distributed into octahedral and tetrahedral com­ponents. When we plot the distributions of other mul­

tiples for various levels, we obtain other interesting patterns (Fig. 11).

The mod(2) patterns for the slices of levels 7, 15, 31, 63, 127 • • • are the same as the patterns for the three "exterior" faces of the tetrahedron (see Fig. 2). For a tetrahedron that is one level less than a power of two, all four faces have the same pattern.

6.4. Plus or minus one The values of the elements of this 3D analog of Pas­

cal's triangle factor into many small primes, they are divisible by a high percentage of integers. These same element values ± 1 have few divisors and few factors. Upon investigation we find that many of them are prime. Many elements are one more or less than a prime number. Some are between twin primes (Fig. 12).

Because computer languages for personal computers can handle about 15 significant digits, one can calculate values for elements up to about level 35 in a straight­forward manner. Program and array size limitations

Page 199: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Pascal's pyramid for PC users 213

1 # ^

Fig. 13. Each element of any level is related to its neighbors by simple ratios. Level 7 is shown here.

in many popular languages such as BASIC limit ex­ploration of the 3D analog of Pascal's triangle to the first 18 levels. Brute force factoring methods also be­come unbearably time consuming at these levels.

To explore above level 18, I switched from using brute force factoring as a prime test to using Fermat's Little Theorem with a base of 2 as a composite test. This can be stated: if Z?" - ^ is a multiple of «, then n is a composite number. Above level 18, the composites I have identified are composite, the primes are another story. Some may be pseudoprimes, some may be Charmichael numbers. It will take more than a personal computer to be able to tell which is which.

There have been some estimates of the number of

pseudoprimes. "The scarcity of pseudoprimes to the base 2 among all the numbers smaller than 20 billion suggests that any number that passes the Fermat test to base 2 is likely to be prime," according to Pomerance [10]. Of course, a good proportion of the values from the 3D analog of Pascal's triangle that I have looked at, are above Pomerance's 20 billion limit. The central values of level 74 are approximately 3.4 X 10 " .

Exploration above level 18 would benefit from faster algorithms and computer systems that are more pow­erful. Since any element, from one of the levels of the tetrahedral array, is easy to factor (all factors have been less than the level index for every element factored to date). It might be possible to use Dixon's [11] algorithm which is based on a complete factorization of n — 1, or other newer algorithms based on partial factoriza­tions of « — 1 or « + 1.

6.5. The oct-tet algorithm The first line of code sets point (0, 0, 0) equal to 1

by definition. Next we assign a value of 1 to any point (on a vertex) that has 2 coordinates of zero. If an ele­ment is not the initial point or a vertex point, then we check to see if it is on the tetrahedral face. If it is, we sum the two values from the level above for any ele­ment that is on the edge of a level. The final ELSE statement assigns a value for all the points not on an edge or vertex, setting them equal to the sum of the 3 elements from the level above.

Let PT(0,0,0) = 1 FOR level = 1 TO top

FOR X = level TO 0 STEP -1 FOR y = (level - x) TO 0 STEP -1

FOR z = (level - {x-^y)) TO 0 STEP -1 IF X = 0 AND y = 0 OR jc = 0 AND z = 0

Calculation Time 1000

0.01 *

LEVEL OF TETRAHEDRON

Fig. 14. Log plot of calculation times for first 75 levels of the 3D analog of Pascal's triangle and checking +1 and — 1 values with Fermat composite test.

Page 200: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

214 JIM NUGENT

Element Values Plus/Minus One

-/lev • +/lev \

RATIO OF PRIMES TO LEVEL

Fig. 15. Ratio of + 1 and -1 primes to level index up to level 76.

OR y = 0 AND z = 0 THEN LET pt{x,y,z) = 1

ELSE IF X = 0 LET pt(x,> ,z) = pt{z,y-\,z) + pt{x,y,z-{)

ELSE IF y = 0 THEN LET pt(x,> ,z) = pt(x-l,> ,z) + pt(jc,y,z-l)

ELSE IF X = 0 THEN LET pt(jc,> ,z) = pt(x-l,>',z) + pt(A:,> -l,z)

ELSE LET pt(jc,> ,z)=pt(x-1 ,y,z)-^pt(x,y-1 ,z)-\-pt{x,y,z-1)

NEXTz NEXT>;

NEXTx NEXT level

6.6. An alternate algorithm In order to explore above level 18 of the 3D analog

of Pascal's triangle on a PC, it is necessary to use a language that uses more than 64K of memory and can handle more than 16-digit integers. Since each level is dependent on only one previous level it would also be possible to explore higher levels if we could find an algorithm that made more sparing use of computer memory.

Alternating between two flat arrays rather than cre­ating one large cubic array would be one solution. The drawback is that it would involve lots of coordinate manipulation. On the other hand, mapping an octa­hedron-tetrahedron lattice onto the standard x, y, z cubic coordinate system is wasteful of computer mem­ory because we can only store 5456 elements in the 27,000 storage locations in an array 30 X 30 X 30.

Another method of reaching higher levels in the 3D analog of Pascal's triangle (also true of Pascal's triangle) is based on the fact that each element of the tetrahedral

array is related by a simple whole number ratio to the 12 elements around it (Fig. 13). The value of any ele­ment can be calculated from any one of its neighbors. We can start at any vertex element (which has a value of 1, by definition) on any level and apply a ratio cal­culation, proceeding from element to element, each time incrementing the denominator and decrementing the numerator of the interval ratio by 1. Using this system, the need for array storage is cut drastically.

Even with shortcuts, the time needed to calculate the values of elements and run the Fermat test quickly rises (Fig. 14). Level 75 took 7 hours to compute on a personal computer with a 10-mHz 80286 processor. For the first 75 levels, the ratio of primes that are equal to the value of an element ± 1 appears to hold steady (Fig. 15).

6.7. Some other properties The value of any element is equal to the number of

different paths from the apex of the tetrahedron to that element. In Pascal's triangle, this is the basis of "Tax-icab" geometry.

The sum of the unique elements on any level equals 3 to the power of the level index. For instance, level 7 has eight unique elements: 1, 7, 21, 35, 42, 105, 140, and 210. These add up to 2187 or 3 to the seventh power.

7. SUMMARY The 3D analog of Pascal's triangle is of interest for

the same reasons that Pascal's triangle is of interest. It touches on number theory, the distribution of primes and twin primes, divisors, factors, combinatorics, and geometry.

Page 201: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Pascal's pyramid for PC users 215

The patterns to be found in Pascal's triangle and its 3D analog seem endless.

REFERENCES 1. M. Gardner, The multiple charms of Pascal's triangle.

Scientific American 128-132 (December 1966). 2. A. K. Dewdney, Five easy pieces for a do loop and ran­

dom-number generator (Computer Recreations). Sci­entific American 22 (April 1985).

3. S. Mueller, Recursions associated with Pascal's pyramid. Pi Mu EpsilonJ4{ 10), 417-422 (1969).

4. J. Staib and L. Staib, The Pascal pyramid. Mathematics Teacher 505-560 (September 1978).

5. H. Steinhaus, Mathematical Snapshots, G. E. Stechert & Co., New York, 30(1938).

6. R. C. Bollinger, A note on Pascal-t triangles, multinomial coefficients, and Pascal pyramids. The Fibonacci Quar­terly \40-\44 {May 1986).

7. A. Loeb, Contribution to synergetics. In Synergetics, R. Buckminster Fuller (ed.), Macmillan, New York, 837 (1975).

8. C. Pickover, Computers, Pattern, Chaos, and Beauty, St. Martins Press, New York (1990).

9. C. Pomerance, Recent developments in primality testing. Math Intelligencer 3 97-105 (1981).

10. C. A. Pickover, On the aesthetics of Sierpinski gaskets formed from large Pascal's triangles. Leonardo, 23(4).

11. C. Pomerance, The search for prime numbers. Scientific American 141 (June 1982).

12. J. D. Dixon, Asymptotically fast factorization of integers. Math. Comp. 36, 255-260 (1981).

Page 202: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 217

Chaos and Graphics

PATTERNS GENERATED BY LOGICAL OPERATORS

MiECZYSLAW SZYSZKOWICZ 1157-6 Rockingham Avenue, Ottawa, Ontario KIH 8A6, Canada

Abstract—Iterations with logical operators are demonstrated to create aesthetic patterns.

Logical operators return a bit-wise result which is either true (nonzero) or false (zero). The following examples demonstrate how logical operators may be used: 4 OR 3 = 7 (4 = binary 100 and 3 = binary 11, so 4 OR 3 = 7, binary 111),-1 AND 18 = 18, N O T X = -(X + 1), I X O R l =0, 1EQV0 = 0,0IMP1 = l.(XOR means "exclusive or," EQV means "equivalence," IMP means "implication"). Here we use the logical oper­ators to create interesting patterns. As an example two patterns are presented (see Figs. 1 and 2).

a„+i = {a„ + bn)/2, b„. ^^n

where ao = a > 0 , o = ^ > 0 . We assume that a and b are positive integers. The above iteration process was used to define the following iteration with the logical operators OR and AND

= a„ OR Z?„, bn^, = VflTAND^ .

PATTERN I After a few executions of this iteration (say « = 2, 3), This pattern is generated on the basis of the arith- the obtained value a„+\ + bn+\ is displayed at the initial

metic-geometric mean iteration point (a,b). Fig. 1 illustrates a^ + b^ modulo 2. Other

Fig. 1. The arithmetic-geometric mean iteration with OR and AND.

Reprinted from Comput. & Graphics Vol 15, No. 2, pag. 299-300, 1991

Page 203: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

218 MiECZYSLAW SZYSZKOWICZ

Fig. 2. The simple gasket with (>'o,'', ) = (0.25, 3.569, 128) and with the logical operator EQV.

iterations can be used, for example an+i = ia„-\- 3^„)/ 4, b„+i = (b„-\- ya„b„)/2, or similar.

PATTERN II

Consider the rectangular array of numbers/y whose first row (/ = 1) is determined as

fij = Pj, ; = 1,2, 3, . . . ,

where {pj} is calculated as follows

Pj = 128JC;,

Xj+i = rxj{\ - xj).

The initial value used is Xi = yN, where

yk^i = ryUl-yk), /: = 0, 1,2, . . . , 7 V - 1.

The sequence {pj} is defined uniquely if (yo, r, N) are given. Refs. 1 and 2 proposed the following simple rule to define the rows ofJ]j

fi+lj — \fij "fij+l I-

Fig. 2 illustrates the values {J^j} modulo 2 calculated by using the logical operator EQV, i.e.,

REFERENCES 1. A. Lakhtakia, A simple gasket derived from prime num­

bers. Comput. & Graphics 13, 57-58 (1989). 2. M. Szyszkowicz, A simple gasket derived from the logistic

parabola. Comput. & Graphics 14, 335-336 (1990).

Page 204: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V All rights reserved

Part IV. Mandelbrot, Julia and Other Complex Maps

1. Feedback

The earthworm burrowing through the soil encounters another earthworm and says "Oh, you're beautiful! Will you marry me?" and is answered: "Don't be silly! I'm your other end."

Robert Heinlein

Feedback is a term we often hear today in a variety of settings; for example, amplifier feedback during rock concerts, biofeedback in medicine and psychology, and chemical feedback in the field of biochemistry. Generally, feedback means that a portion of the output of a system or machine returns to the input. In electronic amplifiers, feedback can occur if the microphone is placed too close to the speaker. In the world of mathematics, feedback is often the result of an "iteration" or "recursion". By iteration, we mean the repetition of an operation or set of operations. In mathematics, composing a fimction with itself, such as in / ( / (x ) ) , can represent an iteration. The computational process of determining Xi+\ given x/ is called an iteration. Take for example the simple act of squaring a number. Let's presume we have a magic box that squares whatever numbers are fed to it - if we put in 2, out comes 4. Now let's take the output, 4, and feed it to the input. Out comes 16. This self-squaring process is an example of mathematical feedback, and it may be simply described by the following equation: z-^z^.

This particular squaring feedback seems rather uninteresting. The progress of the iteration is monotonic. Even if we add a constant c to the squaring process, the numbers still follow a rather uninteresting and ever-increasing progression: z^^z'^ + c.

Gaston Julia (1893-1978) was one of the first mathematicians to notice that, under certain conditions, this feedback loop produces startling results. These results arise when "complex" z values are used as input (complex numbers are of the form a+'ib where i = \ / ^ ) . However, the striking beauty and complexity of "maps" representing such iterative Julia calculations have only recently been explored in detail, due in part to advances in computer graphics. B. Mandelbrot, H. Peitgen, O. Richter, and others have extended the theory and graphic presentation of iterated fiinctions as a special class of fractals.

Since their simple graphical representations in the 1980s, the Julia and Mandelbrot sets have emerged as two of the most scintillating stars in the universe of popular mathematics and computer art. The sets often resemble spirals upon spirals, and they serves as an important example of how simple mathematical operations can produce astonishingly complex geometrical forms. The more you magnify a figure's border, the more detail you'll find.

This section is filled with Julia and Mandelbrot set maps. As background, let us review how to create a graphical representation of a Julia set. Researchers often start with an array of complex values (z) and have the computer follow the outcome of the squaring process defined by z-^z'^ + c, where c is constant. (Other mappings are also used.) Once the initial points are selected, each iteration represents a step along a path that hops from one complex number z to the next. The collection of all such points along a path constitutes an orbit. The basic goal is to understand the ultimate fate of all orbits for a given system. For example, for certain initial z values, the z^ equation produces larger and larger values; i.e., the function explodes

221

Page 205: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

222

or diverges. For other values, it does not explode (i.e., it is bounded). For color figures, the number of iterations needed for an initial point to grow beyond a certain threshold number is represented as different colors to indicate the rate of explosion.

In a computer program, you need not use complex numbers, because the equivalent mapping can be written as

Z„^i =Xl-Yl^a, Yn^i =2XnYn + b.

The variables X and Y usually are thought of as the real and imaginary parts of the complex number z. The filled-in Julia set then is the set of all initial conditions XQ and FQ whose solutions are bounded.

The computer is like a microscope opening a portal to a vast, unexplored and unpredictable universe. With many fractals, like the Mandelbrot and Julia sets, who would have thought that such beauty could be hidden within what was initially so lumpy looking? How could such a simple formula produce an inexhaustible reservoir of magnificent shapes and forms? The complexity exhibited by simple formulas correspond to behavior that even mathematicians could not fiilly appreciate before computers could display the results.

Arthur C. Clarke in The Ghost from the Grand Banks notes:

In principle the Mandelbrot Set could have been discovered as soon as men learned to count. But even if they never grew tired, and never made a mistake, all the human beings who have ever existed would not have sufficed to do the elementary arithmetic required to produce a Mandelbrot Set of quite modest magnification.

2. Beautiful Roots

Some of the graphics in this section are based on numerical root-finding methods, for example, Halley's and Newton's method. The use of computational techniques based on recurrence relationships can be traced back to the dawn of mathematics. The Babylonians used such techniques to compute the square root of a positive number, and the Greeks to approximate n. Today many important special function of mathematical physics may be computed by recurrence formulas. The choice of a particular algorithm influences not only the process of computing but also how we are to understand the results when they are obtained.

One goal of this section is to give a flavor of the subject of recurrence relations and chaos, and the computer graphics reveals the beauty that can be found in such relationships. Many papers in this section address the process of solving equations of the form/(x) = 0. The problem of finding the zeros of a continuous function by iterative methods occurs frequently in science and engineering. These approximation techniques start with a guess and successively improve upon it with a repetition of similar steps. Some of this section's figures give an indication of how well two of these iterative methods (Newton's method and Halley's method) work, and the papers show where the methods can be relied upon and where they behave strangely. Halley's method is of interest theoretically because it converges rapidly relative to many other methods. Each iteration is "supposed" to lead to a better guess, and the process is repeated. The variables in Newton's and Halley's method behave like comets torn between conflicting tugs of two nearby planets (metaphors for the roots). In some cases it might be difficult to determine which of the two nearby planets a comet will collide with even though we know the gravity equations. Of course, if we knew exactly how the comet is moving at any give time, then we could predict its fixture exactly. But we never do know anything exactly . . .

For Further Reading

(1) Clarke, A. (1989) Ghost from the Grand Banks New York: Bantam. (A female character goes insane after exploring the Mandelbrot set.)

Page 206: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

223

(2) Brooks, R. and Matelski, J. (1981) The dynamics of 2-generator subgroups of PSL(2,C). In Riemann Surfaces and Related Topics: Proceedings of the 1978 Stony Brook Conference. I. Kyra and B. Maskit, eds. Princeton University Press: Princeton, New Jersey. (Note: this 1978 paper contains computer graphics and mathematical descriptions of both Julia and Mandelbrot sets.)

(3) Devaney, R. (1986) Chaotic bursts in nonlinear dynamical systems. Science. 235: 342-345.

(4) Dewdney, A. K. (1985) Computer Recreations. Scientific American. 253: 16-24. (5) Douady, A., Hubbard, J. (1982) Iteration des polynomes quadratiques complexes. Comptes

Rendus (Paris) 2941: 123-126. (6) Julia, G. (1918) Memoire sur 1'iteration des fonctions rationnelles. Journal of Mathemat­

ics, Pure Applications 4: 47-245. (7) Mandelbrot, B. (1983) On the quadratic mapping z-^z^ - jji for complex ix and z: The

fractal structure of its M set, and scaling, Physica 17D: 224-239. (8) Peitgen, H., Richter, R (1986) The Beauty of Fractals. Springer: Beriin. (9) Pickover, C. (1990) Computers, Pattern, Chaos, and Beauty. St. Martin's Press: New York.

(Has a chapter devoted to Halley's method.) (10) Ushiki, S. (1988) Phoenix. IEEE Transactions on Circuits and Systems. July 35(7): 788-

789.

Page 207: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 225

Chaos and Graphics

A TUTORIAL ON EFFICIENT COMPUTER GRAPHIC REPRESENTATIONS OF THE MANDELBROT SET

RAUL ROJAS National Research Corporation for Mathematics and Computer Science, FIRST Laboratory at the

Technical University of Berlin, Hardenbergplatz 2, 1000 Berlin 12, West Germany

Abstract—In this paper we present a tutorial of some techniques that can be used in order to calculate the popular Mandelbrot set more efficiently. Emphasized is how to avoid floating-point calculations and how to suppress them completely (using a fixed-point representation). The divide and conquer method, which consists of recursively dividing the calculating region into subregions, is also described. Programming examples are given in a high level programming language, and black and white graphics are included.

1. INTRODUCTION

Even if a user does not know how the Mandelbrot set[3] is calculated, most have probably seen different views of it reproduced in computer magazines or pe­riodicals such as Scientific American[2]. Such images (obtained by magnifying the boundaries of the set) are exhilarating, providing astonishing examples of the complex patterns a very simple dynamical process can bring into being [ 1 ]. All around the world computer programmers try to find the most interesting re­gions [4]. The Mandelbrot set has captured the imag­ination of computer scientists and transformed an ap­parently abstruse mathematical function into what is probably the most expensive set in history. Many hours of CPU-time, perhaps worth several hundred thousand dollars, have already been used to chart the Mandelbrot set. Figure 1 shows the well known shape of the set on a grey background.

Why should the mathematically simple Mandelbrot set be so expensive? The most important reason is the way it is calculated: several floating-point operations must be repeated within a loop. The loop counter often runs from one to a number between 30 and 1000, and this calculation has to be repeated for each pixel in the screen. Thus, several million floating-point operations are required in order to have an aesthetic graphic. Even with a fast workstation using a floating-point co-pro­cessor, the entire process can take several hours if one is investigating a very small region of the set.

The main purpose of this article is to show some ways in which the necessary calculations to draw the Mandelbrot set can be accelerated. We show three main sources of inefficiency that one can find in many pro­grams published in computer magazines, and we pro­pose a method to organize the necessary calculations in a recursive way. We also show how to completely avoid floating-point calculations. With this method a significant speed up is achieved in all cases in which a significant portion of the border of the Mandelbrot set is to be drawn. We have tested this method in an IBM-PC/AT with no floating-point co-processor and the results are very encouraging. The laser printer graphics in this article were produced by a SUN-3 workstation using a slightly modified version of the same program.

2. THE MANDELBROT SET

In 1980, Benoit Mandelbrot described the set which now bears his name. He found that the very simple mapping z -^ z"^ -^ c could produce very interesting graphics. The Mandelbrot set is formally defined as the set of all complex c values for which the iterative process z„+, = z^ + c does not escape to infinity with the start point ZQ = (0, 0). So much for the formal definition. An example can clarify the way this cal­culation is done.

Each point in the plane has a pair of coordinates (x, y) that can also be interpreted as the complex number x -\- iy. Suppose that we want to know if the point c with coordinates (2, 0) in the plane belongs to the Mandelbrot set. First, we have to take the point ZQ = (0, 0) as starting point of the iteration. The next point is defined by the relation

Z, = Zo + C. (1)

These are operations with complex numbers (one complex multiplication and one complex addition) and they are performed according to the formulas:

(a + ib)(c + id) = {ac - bd) + i{bc + ad)

{a + ib) + (c + id) = (a + c) + i(b + d).

If we apply this formulas to relation (1) we get

z, = (0, 0)(0, 0) + (2, 0)

= (0,0)+ (2,0)

= (2,0).

In the next step we get

Z2= (2,0)(2,0) + (2,0)

= ( 4 , 0 ) + (2,0)

= (6,0).

We can repeat this procedure several times. Each time we will notice that the next point moves further

Reprinted from Comput. & Graphics Vol. 15, No. I, pag. 91-100, 1991

Page 208: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

226 RAUL ROJAS

Fig. 1. The Mandelbrot set.

away from the origin. We then say that the succession of points escapes to infinity. In this case c does not belong to the Mandelbrot set. The same procedure ap­plied to the point c = (0, 0) yields a stationary point succession (stationary at the origin). Because this succession does not escape to infinity, the point (0, 0) belongs to the Mandelbrot set. To test if a point succession escapes to infinity it is enough to see if it is already out of a circle big enough around the origin. We can take for example the circle of radius R = 25. We declare a point succession as one going to infinity if the distance of one of its points from the origin is greater than the radius of this circle. If the point has coordinates (x, y) we have to test only if the square root of x^ + y^ is bigger than R.

In practice we cannot calculate an infinite succession of points. We have to set a limit of say 100 iterations. If in 100 iterations the succession has not surpassed the boundaries of the circle of radius R, we accept c as a member of the Mandelbrot set and we paint this point in the screen with the appropriate color. If the point succession exceeds the circle before the iteration limit is reached, then the point does not belong to the set and its escape time is the number of iterations in which the succession escaped the circle. The points with odd escape times can be painted using one color and the points with even escape time using another. Figure 2 shows the Mandelbrot set as well as the points with even escape time in black.

3. HOW BIG A CIRCLE?

From this short explanation it is already obvious that in order to decide whether or not a point belongs to the Mandelbrot set, many calculations must be done. In each iteration several floating-point additions and multiplications have to be performed and the distance from the origin has to be compared to the radius R of the escape circle. Here is where we find one of the first

sources of ineflftciency when dealing with the calcula­tions. It is clear that the greater the radius of the escape circle, the greater the number of iterations that are needed in order to verify that a point succession has trespassed the circle borders. Some programs use very big values for /?, in the hope that this will yield a better result. A well known book on the subject recommends R = \0. Actually it is enough to use a radius of 2 for the calculations. If only the interesting region of the plane is being investigated (the rectangle with x-boundaries -2.25 and 0.75 and y-boundaries -1.5 and 1.5) then any point succession which skips out of this circle will never return again and will move farther away in each iteration. On the other hand, it is not possible to use a smaller radius because points to the right of the point ( -2, 0) and arbitrarily near to it belong to the Mandelbrot set.

4. HOW MANY ITERATIONS?

The second most common source of inefficiency when calculating the Mandelbrot set, is the limit for the number of iterations used before deciding that a point belongs in the set. There are programs which use 1000 iterations to draw the main island of the set using a low resolution [6]. It is not surprising that the authors warn about the six or seven hours needed to run the program. There is a kind of superstitious feeling that the graphics will look better with more iterations.

Actually it is not necessary for the programs to per­form so many iterations to obtain attractive pictures. It is possible to draw the main island of the Mandelbrot set with good resolution using no more than 30 iter­ations. More iterations bring only negligible variations to the graphic and my experience is that the rougher calculation looks even better than the finer. Even with the resolution of a laser printer, 30 iterations seem suf­ficient to get a good image (we used actually only 25

Fig. 2. The Mandelbrot set and contours of the different divergence regions.

Page 209: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Efficient computer graphics of the Mandelbrot set 227

iterations in Fig. 1). This problem deserves more at­tention.

Points which belong to the Mandelbrot set have an infinite escape time, that is they do not escape to infinity at all. Points outside the Mandelbrot set have different escape times, but the nearer the point is to a region of the Mandelbrot set, the greater is the escape time. When the regions of the plane are colored according to the escape time, we get a set of bands around the Man­delbrot set that look much like the known potential lines of an electric field. It is possible to see empirically that the width of these bands decreases as they approach the Mandelbrot set.

If we are drawing the main body of the Mandelbrot set and are interested in the escape regions around it, we typically inspect the frame with bounds —2.5 < x < 0.75 and -1.5 < y < 1.5. The side length of this region is equal to 3 units. If the resolution of our screen-window is 256 by 256, that means we can still look at details that are at least 3/256 units wide. Because of the exponential fall of the cross sections of the escape regions, it is impossible to get a very detailed picture of the nearest bands to the Mandelbrot set. As a matter of fact it is very difficult to notice a change when the number of iterations goes from 25 to 30. According to our experience, 25 iterations are good enough for most purposes when drawing the 256 by 256 resolution re­gion.

The above considerations have another important consequence. If we want to make a close up of an in­teresting region, we have to reduce the length of the sides of the frame we are investigating. If we inspect the frame with bounds 0.375 < x < 0.385 and 0.125 < y < 0.135, we are then dealing with a frame of side-length 0.01. This is a magnification of the original pic­ture by a factor 300. Even when this region is drawn using 1500 by 1500 pixels we do not have to increase the number of iterations from 25 (for the frame with side 3) to 300 times 25. It is enough with 120 iterations, less than 5 times more iterations than before.

This observation has to be taken with a grain of salt. Different regions of the plane require more iterations in order to show the richness of detail that is hidden in them. Figure 4 is an example of a frame of side 0.01

pixel's center

• •

Fig. 3. A very thin branch could miss the center of all pixels in a small region. In this case it would not be graphed.

Fig. 4. A region of side-length 0.01 calculated with 190 iterations.

that required 190 iterations in order to display the sea horses shown there with an acceptable resolution.

However, one should not think that more iterations always imply a better picture. It depends on the kind of picture in which one is interested. If one is only interested in the Mandelbrot set proper (and not in the escape regions around it), then some detail can be lost in very chaotic regions of the plane.

In the so called "sea horse" region of the plane, for example, one loses many points of the fine filigree that defines the sea horses if the number of iterations is increased excessively. It is clear why: as the number of iterations is increased, the fine strokes that constitute the body of the sea horses become thinner and thinner. It is very difficult for the center of each pixel to lie exactly in one of these thin lines. It is more probable that the center falls to one or the other side of the lines, and in this case the pixel will not be colored (you have to remember that for each pixel its center is taken as a representative and that the calculations have a meaning only for this point).

Figures 4 and 5 are a comparison of the results achieved in black and white when the resolution passed from 190 to 300 iterations. Some parts of the Fig. 5 become cleaner and more detailed, but some others lose their contours. In Figure 6 we merged both graph­ics (one in white, the other in black) against a grey background.

How much to iterate is then a very subjective ques­tion. It all depends in which region of a figure one is interested in and which resolution is being used. Nonetheless our practical experience has shown us, that the number of iterations required grows approx­imately proportional to the logarithm of the magnifi­cation factor. If the set is being drawn in color, one can almost always iterate deeper. If the escape regions are colored with different tones, we can still get a very

Page 210: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

228 RAUL ROJAS

Fig. 5. The same region as in Fig. 4 calculated with 300 iterations.

The routine shown does the job, but too many cal­culations are wasted. Some simple improvements are the following: (a) The square root is not necessary. The comparison

can be made against the square ofR (that is against 4 and not 2). One call to the SQRT function is saved in each iteration.

(b) It is possible to start with the point (x, y) instead of the point (0,0), because the first iteration takes us always to this point.

(c) The squares of x7 and yl can be calculated one time, but they can be used twice: first for the cal­culation ofx2 and then for the calculation of r.

(d) The squares ofxl and yl could be calculated with a special routine, such as that used in Pascal. The square of a floating-point number can be calcu­lated easier than a floating-point multiplication.

Program 2 shows how the first program could be modified in order to make it more efficient.

Program 2

good drawing of the shape of different, very chaotic parts of the Mandelbrot set.

If one is also drawing the escape regions (with a monochrome screen), using black for the even regions and white for the odd ones, one can iterate deeper, because the turbulence of the stripes that result pays for the lost detail around the thinnest arms of the Mandelbrot set.

5. THE ORDER OF CALCULATIONS

The third source of inefficiency found in many pro­grams is the ordering of the calculations needed to de­cide if a chosen point belongs to the Mandelbrot set. Program 1 is an example of an ad hoc routine used to plot a given pixel. The routine uses as arguments the coordinates of the point and decides if it should be plotted or not.

Program I

PROCEDURE plot(x,>;:REAL);

CONST kmax= 100; R=2.0;

VAR A::INTEGER; xI,x2,yI,r:REAU

BEGIN xl:=0;yl:=0] k:=0; r—SQRT(xl*xI -\-yl*y]); WHILE ({r<R) AND {k<kmax)) DO

BEGIN x2: = xl*xl-yl*yl + x; yl:=2*xl*yl -{-y; xl\ = x2\ r:=SQRTixl*xl +y]*y]); k:=k+l;

END; IF ik=kmax) THEN draw(x,>;);

END;

PROCEDURE plot(x,y:REAL);

CONST kmax= 100; R=4.0;

VAR A::INTEGER; xl,yl,r,b2,b3:REAU

BEGIN xl:=x; yl: = y; k:=U b2:=SQRixl); b3:=SQRiyl); r:=b2-\-b3; WHILE {{r<R) AND {k<kmax)) DO

BEGIN yI:=2*xl*yJ -^ y; xl:=b2-b3 + x; b2:=SQR(x]); b3:=SQR{yl);

Fig. 6. Fig. 4 (in white) and Fig, 5 (in black) merged against a grey background.

Page 211: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Efficient computer graphics of the Mandelbrot set 229

k:=k-\-U END;

IF (k=kmax) THEN draw(x,y); END;

With the second program many unnecessary operations are eliminated.

6. AVOIDING FLOATING-POINT OPERATIONS

It is possible to go one step further and suppress at least two floating-point operations, replacing them with integer calculations. If we examine the code of Program 2 more closely, we will find one trivial operation for a binary computer. The calculation 2*x\*y\ could be simplified if we note how the floating-point result is stored in the computer.

In Turbo Pascal 3.0 real variables are stored in six bytes. The first byte contains the binary exponent and the remaining 5 bytes contain the fractional part of the number. It is possible to multiply a floating-point number by two simply by increasing its exponent by 1. All one has to know is where the real number is stored. Turbo Pascal provides the function ADDR that could be used for this purpose.

The following piece of code multiplies a floating­point number by two:

VAR mfBYTE; xiREAL;

m:=ADDR(x);

This same method could be used with any other Pascal version that uses a similar representation for the float­ing-point numbers.

Another floating-point operation that could be sim­plified is the comparison r < R. Remember that R is equal to 4.0. This real is represented in Turbo Pascal as the number with fractional part 1 and exponent 131 (Turbo Pascal adds 128 to the exponent). If n is a pointer to the binary exponent of r, it suffices to ask if the contents of the pointed address is greater than 131. The comparison in the "WHILE" above could be re­written:

VAR«:^BYTE;

«:=ADDR(r); WHILE ((^'^ < 131)AND(/:<A:m^x))DO

Program 3 shows the full rewritten version of the subroutine "plot."

Program 3

VAR m,«:'^BYTE; r,Z77:real;

PROCEDURE plot(x,};:REAL); CONST kmax= \00; VAR A::INTEGER; xl,yl,b2,b3:^^^U BEGIN

xl:=x; yl:=y', b2:=SQR{x); b3:=SQR{y)-r:=b2-\-b3',k:=l;

WHILE ((«^<131) AND (k<kmax)) DO BEGIN

k:=^k+U bl:-xl*yl; m":=m^+l; xl:=b2-b3 + x; yh=bl + y\ b2—SQR{xI); b3:=SQR(yl); r:=b2-\-b3;

END; IF {k=kmax) then draw(x,y);

END;

m:=ADDR(Z?l); n:=ADDR(r);

We do not claim that the new routine is easier to read and debug, but it is certainly faster. Notice that the variables m, «, r, and bl have to be declared as global variables. Otherwise it is very difficult to find out their addresses at run time. The address calculation should be made in the main body of the program. Using this technique you should save about 20% of CPU-time, if you do not dispose of a floating-point co-pro­cessor.

7. AVOIDING ALL FLOATING-POINT OPERATIONS

We can now raise the stakes again and aim for even higher speeds. There is actually a way to suppress more floating-point operations, but it requires eventually a little more programming, especially if a 16 bit machine is being used. The speed up obtained by suppressing all floating-point operations varies according to the computer. In a Macintosh Plus, the difference between all-floating-point and all-integer can be dramatic. Floating-point operations in the Macintosh take a long time to perform, even longer than in an IBM-PC with no 8087. If one already has a floating-point co-pro­cessor, one can nonetheless gain a significant speed up.

The main idea is the following: we do not actually need all the power of unlimited floating-point calcu­lations because the numbers we are using always re­main in a small region of the complex plane. The x and y coordinates are never bigger in absolute value than 2 (if they are, we have already left the escape circle of radius 2). For the same reason, the squares of X and y cannot be greater than four. The product of X and y cannot exceed four in absolute value either. If we dispose of integers of 16 bits and adopt the con­vention that the 13 leftmost bits represent the binary digits to the left of the point, then we need only two more bits to the right to represent the integer part of the numbers we will be using (from 0 to 3). That means that we only need a total of 15 bits. The 16th bit could

Page 212: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

230 RAUL ROJAS

be used for the sign of the number (in a normal two's-complement representation). Using this convention the integer 1 represents the smallest floating point that can be represented with our convention, in this case 1 /2 *\ That is enough for the first zooms (without too much magnification) of the Mandelbrot set.

The first difficulty is how to multiply two numbers using this convention. In Pascal or C we get an integer overflow each time we multiply any number greater than zero in our representation (that means, with more than 13 significant bits). It is most probable that one will have to program the "plot" routine in assembler to take advantage of extended accumulators. With an 8086 processor, two signed integers of 16 bits can be multiplied and the result is stored in two registers (DX and AX). With a 68020 two 32 bit, signed integers can be multiplied and the result is stored in 64 bits that can be manipulated later. With the appropriate shift, one can always normalize the result to bring it back to the desired representation (with 13 or more fractional bits).

The routine in Program 4 was programmed in a computer with 32 bit integers. It was assumed that the 13 leftmost bits encoded the fractional part of the numbers used. In this representation four is equal to the binary number 100 followed by 13 zeroes. In order to multiply two fixed-point numbers, one has to make an integer multiplication and shift the result to the right by 13 places (using the function arithmetic shift right [ASR]). We controlled this routine simply by limiting the value of r to 4, but this test could have been made after each multiplication in order to stop the iteration process earlier and avoid an overflow.

Program 4

PROCEDURE plot(x,>^:REAL);

CONSTA:w«x=100;

VAR Jc7,y7,r,^2,Z7i,A::INTEGER;

BEGIN xl:=x\ yl'.=y\

^2:=ASR(SQR(x7),13); b3—ASR(SQR(yl),l3); r-b2^b3\ WHILE ((r<R) AND (k<kmax)) DO

BEGIN yh^ASK{xl''yU\2)-]-y\ xl:=b2-b3-hx; ^2:=ASR(SQR(x7),13); Z?i:=ASR(SQR(>;7),13); r:=b2-\-b3', k'=k+U

END; IF ik=kmax) THEN drawix.y);

END;

7?:=ASL(1,15);

As can be seen in the listing, R was initialized to 4 shifting 1 fifteen places to the left (with ASL). The product of xJ and yl was multiplied by two simply by shifting it only 12 places to the right (and not 13). The rest of the routine is as simple as before. We used only 13 fractional bits in order to avoid any overflow condition. If one is interested in going very deep into the Mandelbrot set, then 13 bits for the fractional part are not enough. With a 32 bit processor, up to 29 bits can be used for the fractional part without too much programming pain. If more precision is desired, the fixed-point representation should be extended to 64 bits using two long words. In each case it should be done in assembler to get the best results.

8. THE DIVIDE AND CONQUER TECHNIQUE

All the refinements mentioned previously do not essentially change the calculation procedure. We still have to go row by row, pixel by pixel, calculating the escape time. However, it is possible to get an additional speed up by using a rather different strategy to calculate the points in the graphic.

The main idea is very simple. The Mandelbrot set is a connected set. That means that each point of it is not isolated. There is always a path of points in the Mandelbrot set communicating two other arbitrary points in the set. The complement of the Mandelbrot set is also connected. Then we can do the following: instead of drawing the Mandelbrot set row by row in a window of the screen, we could draw first of all the sides of the window. If we use black for points in the Mandelbrot set and white for points outside of it, we have only to look at the color of the sides. If the sides contain only black points, then we can be sure that the whole window is black, because it contains only points in the Mandelbrot set. This happens because if a white point were to be located somewhere in the window, there should be a path of white points going out of it (to the rest of the complement of the Mandelbrot set) and at least one of the sides should contain white points (see Fig. 7).

The reverse is also true: if the sides of the window are found to be white, then the whole window can be colored white. No black points could be inside, because that would imply that a path of black points should traverse the window. The only exception is when we are using a window that totally contains the Mandelbrot set. In this case we have to check only if the origin is located in the window. We can adopt the following recursive strategy:

(a) Define the coordinates of a window in the real plane and its size in pixels.

(b) Look at how many pixels the window has: If the window has 2 by 2 pixels, draw the four points one by one and stop.

(c) If the window has more than 2 by 2 pixels, draw the four sides of the window.

(d) Look at the sides of the window: (d. 1) If the four sides have the same color, paint

the whole window with this color.

Page 213: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Efficient computer graphics of the Mandelbrot set 231

Fig. 7. If the sides of the reference frame are black, the whole frame is black.

(d.2) If there are different colors in the sides of the window, divide it into two smaller win­dows (drawing a line in the middle) and repeat the whole procedure for each one starting with step (b).

With the above method one should simply take care to divide the original window in such a way that the "cut" is done through the middle and perpendicular to the two largest sides. In this way, the resulting sub-windows are as regular as possible. The method can also be used to paint the escape regions of the Man­delbrot set with different colors. That means that not only calculations within the regions with infinite escape time are saved, but in other regions of the plane as well.

To anticipate criticism of this method, let me point out the following. The Mandelbrot set possesses ex­tremely fine branches that connect one part of the set to another. If the number of iterations is big enough, it could well be the case that one of these branches goes to the inside of a window with white sides un­noticed. The reason is that we make a discrete calcu­lation each time taking the center of each pixel as a representative for the whole pixel. If the branch is fine enough to go between the centers of two neighbor pixels without touching them, then this branch will not be detected and we could lose parts of the set. Although this criticism is correct, our practical experience is that this case does not occur very frequently if one is using a well combined pair of values for the resolution (pixels per side) and the iteration count. In many graphics that we made using the normal method and this vari­ant, only a few points got lost and the differences were for the most part unnoticeable. If one is unwilling to sacrifice any single point of the graphic, this method can still be used to explore the Mandelbrot set looking for an interesting region. Then one can shift to a row by row scanning of the whole window. But believe it or not, in most cases the difference is hard to notice.

We conducted experiments using a program that scanned the whole screen and a program using the method described. The second program was consis­

tently faster than the first when the size of the screen region was bigger than 32 by 32 pixels. We also made some graphics using a laser printer and a resolution of about 1500 by 1500 pixels. The results confirmed that the alternative method grows even faster in comparison to the whole scanning method when the resolution used increases. Using a floating-point co-processor in a workstation, our method consumed a third of the time of the normal method (using 256 by 256 pixels and 25 iterations) when the main island of the Mandelbrot set was drawn. For a window size of 1024 by 1024 pixels and 25 iterations, our method consumed about a sixth of the time consumed by the normal program. Figure 8 shows the borders of the windows used in the calculation of the main island of the Mandelbrot set. All the points inside the windows were not calculated, but rather deduced from the color of the window sides. It is easy to see that many calculations were saved.

It should be evident why the improved method grows relatively faster each time the resolution is increased. If one starts with a window size of say 256 by 256 and one increases this to 512 by 512, then there are four times as many points as before. With the traditional method, four times more calculations are made, so that the CPU time grows linearly with the number of pixels used. With the other method, one does not cal­culate all points on the screen. Our experience is that the CPU time grows by a factor of about three for each increase in the number of pixels by a factor of four. Figure 9 is a graph that shows how the CPU time in­creases with each resolution increase using the two methods. The first line (at 45 degrees) shows how the CPU-time increases by four each time the number of pixels is quadrupled, when using the all-scan method. The second line shows that the CPU-time increases by a factor of about 3 for each quadrupling of the pixel count, when only the Mandelbrot set is plotted. We gathered these statistics using the main island of the

.'.\ -.

P * ' ^^"^^^^^^^

:i*l|E ;JfSir' trfrt

Fig. 8. Borders of the frames used to calculate the Mandelbrot set.

Page 214: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

232 RAUL ROJAS

1000,0

relative elapsed

time

64 128 256 512 1024 2048

Pixels per side

Fig. 9. Calculation time in function of the pixels per side (rel­ative to the "all-scan" method, 64 X 64 resolution).

Mandelbrot set. Other regions of the plane produced similar results.

It is very important to mention that Fig. 9 was ob­tained using only 25 iterations. If you are using many more iterations, the difference between one method and the other could be much more drastic. Instead of a speed up of about 10 with 2048 by 2048 pixels, you could get speed up of as much as 100 if you are using 300 iterations or more.

We also tested how big the overhead is associated with our method, when compared to the complete scanning one. In an IBM-PC/AT without floating­point co-processor, the overhead was less than 1%, when using 25 iterations. That means that we pay al­most nothing for avoiding unnecessary calculations. If the number of iterations increases even more, then the overhead becomes negligible.

In very chaotic regions of the plane, the savings of this method are much more limited, but one can still avoid some calculations. In very chaotic regions, it is possible that the iteration count is already very large so each saved calculation must be welcomed.

L >

! [RLuirrTH

P S T

"A.

F*-

%k ^

jj ^ ^ ^

^^^

^M^

w - v '

apF^u^ '"'*'t*k^S^'''^'n©

Fig. 11. Borders of the frames used to calculate Fig. 10.

Figures 10 and 11 show the same region of the plane. Both were calculated using 90 iterations. The second shows how many calculations were saved using the dividing method.

Figures 12 and 13 show a blow up of a part of the previous graphics. You can see that due to the chaotic behavior of the set in this region not too many cal­culations were saved using our method. In cases like this the performance of both methods converge.

9. POSSIBLE REFINEMENTS

There are many other refinements that could be in­troduced. In order to speed up the floating-point cal­culations one could program special floating-point routines as described in Section 6. One public domain program for the Macintosh (Mandelzot 2.0) imple­ments the techniques discussed here and some others.

Fig. 10. A detail of the Mandelbrot set calculated with 90 iterations. Fig. 12. A magnification of a detail of Fig. 10.

Page 215: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Efficient computer graphics of the Mandelbrot set

partial sums

233

«fj?l«L^

- 1 | ? v . ••;

Fig. 13. Borders of the frames used to calculate Fig. 12.

A more promising field of research would be to in­vestigate if previous results for neighboring points could be used for other points. Another technique is discussed in [ 5 ] .

If one is working in a distributed computing envi­ronment, parts of the whole calculation can be sent to other computers and the results collected through files in the server. Naturally the ultimate in speed would be obtained using a hardware device to do the calcu­lations at the fastest possible pace.

REFERENCES 1. M. Bamsley, Fractals Everywhere, Academic Press (1988). 2. A. K. Dewdney, Computer Recreations, Sci. Am. August

(1985). 3. B. Mandelbrot, The Fractal Geometry of Nature, Freeman,

San Francisco (1982). 4. H. O. Peitgen and O. H. Richter, The Beauty of Fractals.

Images of Complex Dynamical Systems, Springer Verlag, New York (1986).

5. H. O. Peitgen and D. Saupe, The Science of Fractal Images, Springer Verlag, New York (1988).

6. Peter B. Schroeder, Plotting the Mandelbrot Set, Byte 11(13), December (1986).

APPENDIX A: HOW TO DETECT FRAMES OF EQUAL COLOR

The only open question in the text is how to test if the sides of the drawing frame are all the same color when using the divide and conquer technique. There is a way to do this test without recalculating the colors of all the points in the frame and without too much overhead. The main idea is the fol­lowing.

We can define a table of color numbers, so that for example black is 0, white 1, red 2, green 3, etc. If we draw the first side of our frame in the screen, then we know the color of each pixel on this line. We can then go from left to right (in the case of a horizontal line) and add the color of each pixel to the color of his right neighbor. We can store these partial sums in the stack and the last element in the stack is then the total sum of all colors in this line. I call this sum the "color length" of the line. It is very simple then to test if the whole line has pixels of a single color: all we have to do is to look

1 2 3 4 5 5 5 5 5 5

L cx)lor length=5 color length=0

I color length=5

Fig. Al. Line of length 10 with color length 5.

at the color of the first pixel and see if the color-length of the line is equal to its length in pixels multiplied by the number of the first pixel's color.

If we have a line of length 10, for example, and all pixels are black, then all partial sums are equal to 0 (black's number is 0). If we look at the last partial sum and it is equal to 0, then we know that the whole line contains only black points. Take the case shown in the Fig. Al.

If the first five points are white (color number 1) and the last five are black, then the first five partial sums are: 1,2,3, 4, 5. The last five partial sums are: 5,5,5,5,5. The total sum is 5 and it is not equal to the pixel length (10) multiplied by the color of the first pixel (in this case 1).

That is not all. One can divide the line in two parts. The first part contains the five leftmost pixels and the second the five rightmost ones. If we look at the partial sum that corresponds to the fifth pixel (5), then we know that the first part contains only white pixels, because this partial sum equals the pixel-length (5) multiplied by the color of the first pixel (1).

With the second part we can do the same, but we have to subtract the last partial sum of the first part (in this case 5) from the partial sum that corresponds to the tenth pixel (5 too). In this case we get zero and we know immediately that the second part of the line contains only black points.

It is very simple with this technique to test if the sides of a frame contain all pixels of the same color or not. All we have to do is calculate the partial sums for the four sides. If the color length of each side equals its pixel length multiplied by the color number of any pixel on the frame, then the whole frame is made up of a single color. If not, then we have to divide the frame drawing a horizontal or vertical line through its middle. With the two new frames we can repeat this process.

Note that the partial sums can be calculated simultaneously with the calculation of the pixel's color in a line. The overhead is just one integer addition per pixel. If these partial sums are stored in a stack, then we do not have to recalculate the partial sums each time we need to know what color the pixels in a line are. Once we do not need these partial sums any more (for example, if the whole frame is already completely drawn) we can pop them off the stack. In this way we do not need to store one integer per each pixel of the graphic in the stack. If the divide and conquer technique is programmed in a recursive way, a stack is needed which is not greater than 8 times the size of the side length of the picture. If we are using 1024 by 1024 points, then we need no more than 8192 integers to store the partial sums.

APPENDIX B It is possible to save floating-point calculations even when

a Pascal version does not feature the built in procedure ADDR. All one needs to do is to overiap a real with an integer variable. The real variable can be manipulated then using integer arith-

Page 216: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

234 RAOL ROJAS

metic. The following type definition achieves this in most Pascal versions:

TYPE overlap:RECORD boolean of true: (rel:real); false: (int:integer);

END;

The following program fragment allows one to investigate how the floating-point numbers are stored in the computer (supposing each real and integer variable occupies the same space, for example 32 bits):

VAR numbenoverlap;

number.rel:=4.0 writeln(number.int);

VAR numbenoverlap;

number.rel:=4.0; number.int:=number.int+16*256*256;

After this calculation number.rel is equal to 8. The number 16*256 *256 could be defined as a constant in order to avoid recalculating it each time. By adding this constant we increase the exponent of the real number by one.

It is possible also to ask if a real variable is bigger than four, only by looking at the exponent. In a SUN-3 computer the following code fragment does the trick:

VAR numbenoverlap;

number.rel:=5.0;

if(number.int>( 64*256*256*256 -h 16*256*256)) then writeln('it is bigger than four');

In a SUN-3 workstation the following code fragment permits us to multiply a real variable by two:

Before using this technique one should be completely sure of the internal representation for real variables used by the computer.

Page 217: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 235

Chaos and Graphics

JULIA SETS IN THE QUATERNIONS

ALAN NORTON IBM T. J. Watson Research Center, Yorktown Heights, NY 10598

Abstract—Recent mathematical work on the dynamics of complex analytic functions has given rise to a new subject matter for computer graphics. The combination of mathematical theory and computer graphics has resulted in new insight into the nature of some of the simplest of mathematical objects, second-degree polynomials. Most of that work has focused on the possibilities within the two-dimensional complex plane. This article shows how these investigations may be extended to higher dimensions, resulting in fractals that naturally reside in the 4-dimensional quaternions. Particular attention is paid to the formula ax^ + . A method is given for obtaining various interconnection patterns for the Julia sets in 4-space, and the results are displayed in 3-D computer graphics.

INTRODUCTION

Quadratic polynomials are usually presented early in elementary algebra courses, and illustrated using a pa­rabola. One learns how to calculate roots, to locate the focus and directrix. Since all parabolas look about the same, the subject is easily treated in one or two lectures, followed by generalizations to higher degree polyno­mials. This subject, at least, is one which apt students can understand completely, and use as a simple model for the relationship between algebra and geometry. Or so it seems.

But now look at the pictures illustrating this article. These pictures are directly derived from quadratic polynomials; in fact can be regarded as pictures of qua-dratic polynomials. These shapes of endless detail are in many respects more naturally associated with the polynomials than are parabolas. One needs more than a pen and graph paper to generate such drawings. The quadratic mapping reveals its inexhaustible content only when examined by the computer.

Several studies have appeared in recent years dem­onstrating the dramatic visual effects obtainable from applying two-dimensional computer graphics to com­plex polynomials. Fascinating as such pictures are, they are only slim fragments compared to the three- or four-dimensional physical reality. Quadratics do in fact re­side in higher dimensions, and we present one such extension in this study.

We shall show how the 4-dimensional quaternion algebra can be used to define structures possessing complex patterns of infinitely repeating geometric structure. We do not have complete control over the structure, comparable to the way a sculptor can pre­scribe the topology and texture of the object being cre­ated. We can, however, to a limited extent define the interconnection patterns of these shapes, and will show how such controls can be exploited.

An underlying theme in this study is the presence of endlessly repeating geometric patterns. The geo­metric objects revealed through these techniques are called fractals, and satisfy Mandelbrot's definition [ 5 ]. Mandelbrot asserted that fractals are the Geometry of Nature. In the illustrations of Julia sets in this article we see that the universe of mathematical shapes does not differ in that respect from the real world: Typical

Julia sets are fractals; only rarely do we encounter the smooth objects of Euclidean geometry.

DYNAMICS IN THE COMPLEX PLANE

Points in a plane can be represented with two real coordinates. But about three centuries ago it was dis­covered that much simplicity and conceptual under­standing is gained by recognizing the pair of real num­bers as a kind of number in its own right, a "complex number.'' Instead of the pair (x, y) representing a point in the plane, the single entity x -I- >'V —I is used. This required introduction of a new "imaginary" number.

Unlike real numbers, the number / does not represent distance along a straight line. Instead, / may be treated as a displacement in a direction perpendic­ular to the real number line. Using this new kind of number, all points in a plane are then regarded as "complex" numbers. The point with coordinates (x, y) is regarded as the complex number x 4- iy.

Like real numbers, complex numbers can be added and subtracted, multiplied and divided (except that we still are not allowed to divide by zero.) The complex numbers contain the real numbers as one line (the "real axis") in the complex plane. The rules of complex arithmetic are easily expressed in terms of the arith­metic of real numbers:

The sum of x + iy and v + iw is (x + u) + i{y + w). Their product is (xy - vw) -f i(xw + yv).

By thinking of points in the plane as complex num­bers, we can manipulate geometry with formulas. Consider for example a quadratic polynomial

/7(x) = x ^ - 1.

This formula determines a value, p(x), associated with a number x. It works equally well whether x is a com­plex or real number. We can regard it as a geometric rule that, for each point z in the plane associates a point piz), also in the complex plane.

Complex derivatives Many of the operations one performs with formulas

make sense whether the formula is applied to real or complex numbers. One example we shall use later is

Reprinted from Comput. & Graphics Vol 13, No. 2, pag. 267-278, 1989

Page 218: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

236 ALAN NORTON

the notion of a complex derivative of a polynomial. Derivatives are usually defined (in calculus class) as the slope of a line tangent to a graph. When we express that definition as a limit

lim A—0

pix -\-h)- p(x)

we see that the limit can make sense even if x and h are complex numbers and ifp(x) takes complex values. This derivative of a complex polynomial is then an­other complex polynomial, and can be computed by the power rule:

d —r- = anx" dx

The mathematical theory of complex analytic func­tions was developed during the 19th century. These functions have complex derivatives (as in the above limit) where they are defined. They include, for ex­ample, polynomials and the exponential function, but not the conjugation function/(x 4- / » = (x - iy).

Geometrically, what makes analytic functions so special is the fact that they are "conformal mappings." To explain this, we need to think of formulas as map­pings, in the sense that a formula/(A:) not only tells what / does to a point x, it also gives a way of taking points near x and associating them with points near f(x). Geometrically, we can think of / as stretching or otherwise distorting a piece of a plane near x as it pastes it onto the plane of/( jc). (This is illustrated in Fig. 1.)

In this context, conformality means that the map­ping has a particularly nice property: It preserves angles. If two lines, crossing at x, form an angle d, then the mapping / may distort the lines so that they are curves instead of straight lines, but the resulting curves still

meet at the same angle 6. Complex analytic functions (and polynomials in particular) have the property of being conformal everywhere they are defined, except at the places where the complex derivative/'(x) van­ishes.

What is dynamics? The subject of dynamics is concerned with what

happens to a physical or geometric system over time, when it is subjected to a force, or undergoes some kind of manipulation. For example the motion of planets about the sun can be modelled as a dynamical system in which the planets move according to Newton's laws. These laws provide a set of rules that one can use to compute the position and velocity of the planets to­morrow, if one is given their position and velocity to­day. With enough effort we could derive a formula that would approximate what the passage of a fixed time (i.e., one day) does to the solar system. Similarly, a complex polynomial p(x) can be regarded as a rule for moving points in the complex plane. If an object is positioned at z© at time / = 0, then Zx - p{zo) will be its position at time ^ = 1, p{p(zo)) - pizi) will be its position at / = 2, etc. Here of course the rule is completely nonphysical, having nothing to do with Newton's laws.

Dynamics is concerned more with the long-term be­havior of a dynamical system than the explicit rule defining the change from one time to the next. We would prefer to know whether the earth will eventually fall into the sun than where the earth will be tomorrow. Similarly, with a polynomial p(x), one would like to understand the limiting effect of "iterating" or com­posing the polynomial with itself To establish some notation, \etp"\x) denote the result of applying (or composing) the function/(x) n times to the starting value x:

r"\x)-fiA'"{Ax))'-)).

/(B)

/

/(A)

/(C)

Fig. I. Conformal mapping. A complex analytic function may be regarded as a rule that moves a portion of the complex plane to another portion. This motion may cause some distortion, but angles are preserved.

Page 219: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Julia sets in the quaternions 237

What sort of thing can happen top"\zo) as n be­comes large? We give some examples, to motivate some definitions. If/(z) = z^ and we start with Zo = 2, it is easy to compute that/ ^H^o) becomes arbitrarily large, or converges to infinity. Similariy, taking Zo = i, suc­cessive iterates rapidly approach zero. In general, if z© is within a circle of radius 1 of the origin, ihenp"\zo) converges to zero, and it converges to infinity whenever Zo is outside that circle. This illustrates the phenomenon of "attraction:" Zero is "attractive" in the sense that points nearby zero are moved closer when the formula is applied. Infinity is also said to be attractive in this context, since complex numbers far from the origin are moved further by the mapping.

There is also a converse notion of "repulsion." Con­sider how the transformation / (x) = x^ acts on the two numbers 1 and 1.01. Successive iterations of 1 do not change its position; however, iterating 1.01, we obtain successively 1.0201, 1.0406 • • • , 1.08 • • •. In fact, every point nearby to 1, other than 1 itself, moves away from 1 when the formula is applied. We say that 1 is "repulsive" or a "repeller" for the func­tion/.

Another concept worth defining occurs in the above example. Note that repeated applications of the for­mula / do not move the points 0 or 1. These points are called "fixed points" of/. More generally, it can occur that after several iterations a point returns to its starting position. To be precise, suppose that/^^^Zo) = ZQ. Then the/:points Zo, Zi =/(zo), Z2 = / (z i ) , • • • Z/t-i =/(Zfc_2) are said to form a "cycle of length /:," or "/c-cycle." A fixed point is then a cycle of length 1.

Cycles, like fixed points, can be attractive or repul­sive, depending on whether iterations of the formula bring nearby points closer to the cycle, or push them further away. For an example of a repulsive cycle, con--A .u . ~^ + 'V3 , - l - - / V 3 _ ^

sider the values ——r and . (These val-2 2

ues are cube roots of 1.) It is easy to check, by iterating nearby points, that this pair forms a repulsive 2-cycle for the formula x^. The formula/(x) = x^ — I has an attractive 2-cycle, consisting of the points 0 and —I.

There is a simple rule for determining whether a k-cycle is attractive or repulsive, based on the value of the complex derivative. We compute the absolute value of the complex derivative of the iterate/^*\ and eval­uate it any point of the cycle. If the result is less than 1, the cycle is attractive. If it is greater than I, the cycle is repulsive. If the result is exactly 1, the cycle is neither attractive nor repulsive, and will be called "indifferent."

If a formula has an attractive cycle, we can ask what points in the plane are attracted by the cycle. In other words, what points eventually get arbitrarily close to points in the cycle under repeated iterations of the for­mula. The set of these points, is called the "basin of attraction" of the cycle, and can be likened to the drainage basin associated with a depression in the earth's surface.

It is easy to use a computer to find basins of attrac­tion. Fig. 2 illustrates the basin of attraction associated with the cycle {0, - 1 } for the formula x^ — 1. This

picture displays a portion of the complex plane centered at the origin, of diameter 4. The red and yellow portions of the picture comprise the basin of attraction to the cycle. Red corresponds to points that approach 0 on even iterations, yellow points approach 0 after an odd number of iterations. The remaining (black) portion of the picture consists of points that are attracted to infinity.

Invariance Another concept of some importance in describing

long-term behavior of a dynamical system is that of "invariance." We say that a set 5 of complex numbers is "invariant under / " if/(S) = S, For example, a cycle or a fixed point is an invariant set. If an invariant set also satisfies/"* (S) = 5, then we say that 5" is "dou­bly invariant." For example, the point 0 is doubly in­variant for the function x^, but the point I is not. The circle of radius 1, its interior, and its exterior are also doubly invariant sets for x^.

What is a Julia set? What is perhaps most interesting about Fig. 2 is not

the basin of attraction, or yellow and red portion of the figure but rather the boundary between that basin and the black region. This boundary is known as the Julia set (or Julia-Fatou set) of the formula x^ — 1. Julia sets are named after the mathematician Gaston Julia, who in the early 20th century elaborated many of their properties. The Julia set is a geometric object in the complex plane associated with a formula; in this sense, a picture of the formula. Any polynomial has a Julia set, and many other formulas have them, too. Like the picture in Fig. 2, most Julia sets are fractals [ 5 ] , displaying an endless cascade of repeated detail.

There are several equally useful definitions of the Julia set of a polynomial, two of which we shall present here because they can be directly translated into com­puter algorithms. For a complete discussion, see [ 1 ] .

1. The Julia set is the closure of the set of repulsive cycles of the polynomial.

2. The Julia set is the boundary between the set of points that are attracted to infinity, and the set of points that are not attracted to infinity.

How are Julia sets computed? Using the above two definitions we provide two easy

algorithms for making computer graphics pictures of the Julia set. An algorithm based on the first definition can be found in [ 6 ]:

Start with a polynomial p{x) and a starting point ZQ in the complex plane, determine a sequence of complex numbers as follows:

1. Given z„, find the inverse of p{x) applied to z„; i.e., find the solutions x of the equation p(x) - z„. There will be no more solutions than the degree of the polynomial; and finding the solutions is partic­ularly easy if p is quadratic, requiring a complex square root.

2. Choose z„+i randomly from the set of solutions.

Page 220: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

238 ALAN N O R T O N

The above algorithm produces a sequence of points {r„} in the complex plane which converges to the Julia set. If many (thousands) of the points after the first 20 or so are plotted as separate dots on a screen, they will be seen to trace out a fractal. Fig. 5 was computed using this algorithm.

A second algorithm, based on the second definition, will more clearly delineate the Julia set for some poly­nomials. The object is to identify the Julia set as the boundary between points that are attracted to infinity, and points that do not converge to infinity. For ex­ample, if the polynomial has an attractive cycle, then the points that are attracted to the cycle can be rapidly determined as not converging to infinity. Different colors can be used to distinguish the two cases, thereby representing the Julia set as the boundary between two colors in a picture. To present this algorithm, assume the polynomial p(z) has an attractive cycle consisting of A: points, Xi, ^2, • • • x„. We shall also need to choose a "large" number N and a "smalP' number e. Large means, in this case, large enough that for \z\ > N, \p{z)\ > Iz|. In other words, Nis large enough that numbers as large as iVare all attracted to infinity. Sim­ilarly € must be small enough that if z is within e dis­tance of .Vi, then z will eventually converge to the cycle. Choosing numbers N and e is not difficult, but may occasionally involve some trial and error.

The algorithm consists of evaluating each point on a square grid of the same resolution as the desired dis­play device. If a point iterates to infinity, the corre­sponding pixel is given one color; if the point ends up in the cycle the pixel is given another color. The map­ping between display device and screen coordinates must be chosen so that the desired portion of the com­plex plane is mapped to the screen.

For each pixel on the display device:

1. Compute the complex number z = Zo that maps to the center of the pixel.

2. Iterate the function (say 50 or more times) as follows

• compute the next iterate, z„ = /7(z„_i). • Check if z„ has absolute value greater than N. If

so, terminate the iteration, and color the pixel appropriately.

• Check if z„ is within distance e of .Vi. If so, ter­minate the iteration and assign the "othef color to the pixel.

3. If all 50+ iterations complete without exceeding N, color the pixel as a point that does not get attracted to infinity.

There are many variations on this algorithm which can reduce the computation, or make the resulting pictures more informative. For example, in Fig. 2 the points that do not go to infinity are recognized by the fact that they become close to elements of the cycle. If a point ends up in the cycle, the number of iterations modulo the length of the cycle can be used to color-code the various components of the basin of attraction. This is used to obtain the pattern of four colors in Fig. 3. Much of the striking use of colors in [ 7] results from

color-coding the number of iterations required to get close to an attractive cycle.

Why are Julia sets fractals? First, we provide an informal definition of fractal [ 5 ],

sufficient for our purposes: A fractal is a geometric shape that possesses detail at all scales of magnification. In other words, one can magnify a fractal repeatedly, and more detail will appear with each magnification. Most but not all Julia sets are fractals; for example x^ and x^ - 2 have respectively a circle and straight line segment as Julia sets.

The repetitive structure of Julia sets can be explained by considering their invariance properties. If x is in the Julia set of a function/, then so is/( x); conversely, if/(,v) is in the Julia set of/, so is .v. (This follows from either of the above definitions of Julia set, and we leave it as an exercise for the reader.)

Now, given that the Julia set is invariant, suppose there is some feature For shape that occurs in the Julia set. The double invariance of the Julia set implies that / ( F ) , the image of F under/ also lies in the Julia set. Furthermore, the conformality of the mapping / im­plies that/( F) will appear very similar to F.

Repeatedly applying the function/ we see that any feature that occurs in the Julia set will occur again and again, distorted and rotated but of similar appearance. Not only will an infinite number of copies of such fea­tures reappear on the Julia set, but they will reappear in arbitrarily small size, everywhere along the Julia set, because the function / is expanding along the Julia set.

Many (but not all) fractals are self-similar, so that the fractal contains repeated scaled-down copies of it­self The fractals that occur as Julia sets are only ap­proximately self-similar, in the sense that repeated structures will be distorted rather than precise mag­nifications of the original. This approximate self-sim­ilarity was proved by Sullivan. (A proof can be found in[l].)

Classification of Julia sets using the Mandelbrot set Because different quadratic polynomials give rise to

very different Julia sets, it is useful to have a classifi­cation of the different possible shapes that can arise. This classification is best described with the aid of an­other computer-generated illustration, shown in Fig. 4. This set, known as the Mandelbrot set {see [6], where it was first described) provides the mathematical equivalent of a road map for the space of quadratic polynomials. The Mandelbrot set should be regarded as a picture of the set of all quadratic polynomials, in the same sense that a Julia set is a picture of one par­ticular polynomial.

For each complex number c, let/(jc) denote the polynomial x^ + c. The Mandelbrot set is defined as the set of values c for which the successive iterates of 0 under/ do not converge to infinity. It is the set of complex numbers c such that

\m \Pc"\0)\ < X .

Page 221: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Julia sets in the quaternions 239

Fig. 2. This illustrates the Julia set of the formula x^ ~ \, which has an attractive two cycle. Points colored red are at­tracted to 0 on odd iterations of the formula, and points colored yellow are attracted to 0 on even iterations. The region at­

tracted to infinity is black.

One easy way to compute the Mandelbrot set is as follows:

• For each complex number c on a grid, compute the iterates/,(0),/e(/,(0)), • • •

• If the iterate becomes large in absolute value (say greater than 5) then the point c is outside the Man­delbrot set and is shown white. Otherwise, stop the iteration after a suitable number of tries, and display the corresponding pixel as black.

As with the Julia set, more information (and more artistic license) can be obtained by color-coding the number of iterations used to determine the fate of a given point.

How the Mandelbrot set works By looking at where a given complex number c oc­

curs relative to the Mandelbrot set, it is possible to determine the dynamics associated with the formula A: + c, as well as to predict general properties of the Julia set o f^ . The different types of dynamics that occur when fc is iterated are described as follows:

Fig. 3. This is the Julia set of the formula x^ + .2809 - .53/. There is an attractive four cycle, and the four colors are used to identify the components of the basin of attraction to the cycle. Compare figures 6, 7, 8, and 9 of the quaternion Julia

set of the same formula.

Fig. 4. This illustrates the Mandelbrot set associated with the formula x^ - c. The formula is iterated for various values of c, and the point c is colored black or white depending on whether or not the iteration remains finite. The values of c designated 2,3,4,5, and 6 determine formulas with attractive

cycles of the respective lengths.

• The white portion of the figure, consisting of c's for which 0 iterates to infinity, corresponds to Julia sets which are Cantor sets, totally disconnected fractals. All points in the complement of the Julia set are attracted to infinity. Fig. 5 shows an illustration of this.

• The interior of the black region consists of values of c for which X has an attractive cycle other than in­finity. The various components of the interior of the black region correspond to different cycle lengths. The central (cusped) component contains c's such that fc has an attractive fixed point. Different com-

\

JU;» . 'vV

'• V'. \

yr

X

Fig. 5. This illustrates a totally disconnected Cantor set that is the Julia set of a quadratic polynomial. All points in the complex plane, except dots colored black, iterate to infinity.

Page 222: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

240 ALAN NORTON

Figs. 6, 7, 8, and 9. These four illustrations show components of the Julia set ofx^ + .2809 - .53/ in a three-dimensional subspace of the quaternions. The planar fractal shows the Julia set in the complex plane. The different figures show how the

four colored regions extend into higher dimensions.

ponents correspond to different cyclic structures, both in the length of the cycle, and in how the com­ponents are arranged.

For example, the value c == 0, which lies in the middle of the central shape. The formula fc is just x , having as Julia set the circle of radius I.

Another example, c = - 1 , corresponds to the shape illustrated in Fig. 2. In this case the point lies in the center of the black circle, denoted 2, in the center. The resulting 2-cycle is indicated by the al­ternating colors in Fig. 2.

In general it is easy to find cycles of any length just by picking a value of c from the interior of one of these components. The cycle length is determined by the position of the component. Consider for ex­ample the sequence of shapes marked 2, 3, 4, 5, 6 in Fig. 4. They correspond to cycles of lengths 2, 3, 4, 5 and 6. Using a graphics display with crosshair, it is easy to discover values of c for which the formula x^ -\- c has a desired cycle structure. Then by com­puting the Julia set itself, one can distinguish between other, more subtle features of the quadratic func­tions.

• The boundary between the black and white portions of Fig. 4 is perhaps the most significant feature of the Mandelbrot set. Values of c along this boundary are associated with many different (and beautiful) dynamical systems. Not only are such Julia sets the most complex and intricate, but the mathematics of the underlying dynamics is itself not completely un­derstood. We shall not describe the possibilities here, but refer the reader to [7] and [I ]. The animation "Dynamics of '*" [9] illustrates the transition in structure of the Julia sets that occur along that boundary.

Why does the Mandelbrot set work? In order to understand the relevance of the Man­

delbrot set to the dynamics of quadratic polynomials, we reconsider its definition. The trajectory of the point 0 under repeated applications offc determines whether the point c lies inside or outside of the Mandelbrot set. The significance of the starting point 0 is that it is the "critical point" of^; that is, the derivative f'c{z) van­ishes at the point z = 0. The Mandelbrot set can be regarded as a diagram of the behavior of the critical point under the quadratic mapping.

Fatou and Julia were well aware of the significance of the critical point in classifying the dynamics of it­eration. A basic result of Fatou (see [1 ]) is that the basin of attraction of an attractive cycle always contains a critical point. Consequently, any attractive cycle for fc can be found by following the iteration that starts at 0. If that iteration goes to infinity, fc can have no at­tractive cycle other than infinity.

In general, the critical points of a mapping are im­portant in describing the dynamics. Changes in the behavior of the dynamical system defined by a formula are accompanied by changes in the behavior of critical points under iteration. This general principle can be applied to many transformations other than quadratic mapping, and we shall soon see its usefulness in de­scribing the geometric structures that occur in iteration of quaternion mappings.

Page 223: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Julia sets in the quaternions 241

Fig. 10. This picture is associated with the formula \,06ix{ 1 - x). The planar Julia set of this formula is identical with the Julia set of x + .2809 - .53/, illustrated in Fig. 3; except that it is rotated by 90 degrees. The four colors are used to illustrate all the components of the quaternion Julia set and how they connect to the planar fractal. The resulting quaternion Julia set is quite different topologically from the one illustrated in Figs. 6-10 because of different interconnections resulting from

the placement of the imaginary axis.

EXTENDING TO HIGHER DIMENSIONS

Given the complexity and beauty of Julia sets and the Mandelbrot set, it is natural to seek higher dimen­sional generalizations. This is not only an interesting mathematical question; such dynamical systems can provide useful models for other disciplines, like com­puter graphics and physics.

In the following we show how the dynamics of the quadratic mapping gives rise to interesting geometric structures in the 4-dimensional quaternion algebra. We present these results not to show a completed analysis, but to demonstrate the wide range of possibilities for computer graphics illustration of dynamical systems.

What is a quaternion? Quaternions were discovered in 1843 by the Irish

physicist and mathematician William R. Hamilton[2]. Attempting to define a 3-dimensional multiplication, he found it necessary instead to extend to four dimen-

Fig. 11. This shape is also associated with a rotation of the Julia set of Fig. 3, in this case a rotation of about 30 degrees. The formula is (2. + 1.06/)A:( { -X). Note that the intercon­nection pattern of loops differs from the pattern in Figs.

6-10.

Fig. 12. This illustrates the three-dimensional extension of the Julia set of Fig. 2, from the formula x^ - \. Note that this is just the three-dimensional figure swept out by rotating the

Julia set of Fig. 2 about the real axis.

sions. After this discovery, Hamilton and his contem­poraries devoted a considerable effort advocating the application of quaternions to physics and other disci-plines[4].

There are several reasons for elevating quaternions above the status of "a mathematical curiosity." For example, the real numbers, the complex numbers, and the quaternions are now known (by a theorem of Hur-witz) to be the only Euclidean spaces in which we can perform addition, subtraction, multiplication, and di­vision (by nonzero elements). The standard vector operators (dot and cross products) are naturally embedded in the multiplication of quaternions. The dynamics of motion in 3-space is thereby easily ex­pressible in terms of quaternion operation. This rela­tionship implies computational advantages in using quaternions to express 3-D spatial manipulation (see [10]).

We can describe quaternions as an extension of the complex plane, comparable to the previous discussion of complex numbers as an extension of the real number line. Complex numbers provide an extension of the notion of "number" to permit us to consider numbers as two-dimensional quantities. In other words, complex numbers are just a set of rules for multiplying and adding points in two dimensions. Similarly, quater­nions may be regarded as a way of extending the notion of "number" to four dimensions: The rules of quater­nion multiplication and addition provide a way of doing arithmetic on four-dimensional quantities.

To explicitly define quaternion multiplication, we represent points in four dimensions in the form:

Q = ao + aii -\- aij + a^k

where /, y, k are (like the imaginary number /) unit vectors in three orthogonal directions, perpendicular to the real jc-axis.

To add or multiply two quaternions, we treat them as polynomials in /,7, /c, but use the following rules to deal with products:

-1;

ij = -ji = k\ jk = -kj = /; ki = -ik = j .

Page 224: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

242 ALAN NORTON

Figs. 13, 14, and 15. These show the result when a 90 degree rotation is applied to the formula of Fig. 2, resulting in i(x^ + 1). No longer is the quaternion Julia set simply a rotation of the planar Julia set. Figs. 14 and 15 illustrate the extensions of the red and yellow components into three dimensions. Fig. 16 illustrates the combination of both red and yellow, showing

how the pair of shapes is linked together infinitely many times.

We note that, since for example ij - ~ji, the mul­tiplication rule for quaternions is noncommutative; the result of multiplying two quaternions depends on their order. This greatly complicates the rules for doing al­gebra with quaternions.

Analogous to the absolute value of a complex num­ber, we have the "norm," defined by:

\Q\^^al + a\-¥al^a\.

This equals the squared distance from Q to the origin in four-space.

Quaternion polynomials Note that if we identify the quaternion / with the

complex number /, then the complex plane can be

regarded as situated inside the quaternions. This makes it possible for us to consider any complex polynomial as a polynomial over the quaternions as well. Expres­sions like:

ax^ + bx -^ c

are then polynomials. However, the noncommutativity of the quaternions implies that many polynomials cannot be so simply described. For example, unless the coefficients a and b are real, the above polynomial is not equal to

x^a + Z?x + c,

x^a + xZ? + c.

xax -\- bx -\- c.

etc. For the purposes of this article, we shall consider

only a small class of such quadratic polynomials, those expressible in the form ax^ + b, where a and b are complex numbers. We shall see that even this class of polynomials introduces a wealth of structure not seen in the complex quadratic mapping.

What is a Julia set of a quaternion polynomial? We begin with the observation that a quaternion

polynomial can be used to define a dynamical system on the quaternions: Ifp(z) is a quaternion polynomial, then for any quaternion q, p(q) is another quaternion. With the aid of a computer, quaternion polynomials can be easily iterated, to evaluate the long-term be­havior. We can still speak of attractive and repulsive cycles, basins of attraction and the like, where the no­tion of complex number is replaced by quaternion.

We shall generalize the (second) definition of Julia sets for complex polynomials: The Julia set of a poly­nomial p(z) is the boundary of the set of quaternions q such that p^"\q) converges to infinity as n becomes large. There is another definition of more generality, which we shall provide in the appendix, but for the purposes of computing the shapes in this article, this one definition will suffice.

Do quaternion Julia sets extend beyond the complex plane?

Consider a complex polynomial p(z). It will have a Julia set / in the complex plane, and /will necessarily be contained in the quaternion Julia set of p(z). But /could in fact be the entire Julia set in the quaternions as well. In other words, extending to the quaternions could provide us with nothing new. Fortunately, some Julia sets can easily be seen to extend beyond the com­plex plane, forming truly 4-dimensional objects.

Page 225: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Julia sets in the quaternions 243

Fig. 16. This is associated with the formula (0.617 + 0.774/)x( { -x). The repeated pattern of holes in this shape results when the imaginary axis intersects the planar Julia set

multiple times.

Fig. 18. This quatemionic Julia set is associated with the cubic polynomial, x^ + (0.596 + 0.161/), showing a three-fold pat­

tern resulting from the singularity of the cubic mapping.

Consider the polynomial p(z) = ax^ + b, where a and b are complex numbers, and suppose furthermore that p{z) has an attractive cycle in the complex plane. That means there is an area in the complex plane of points z such that p^"\z) converges into the cycle. If we show that other points outside the complex plane are also attracted into the cycle, that will imply that the domain of attraction to the cycle, as well as the Julia set, extend beyond the complex plane.

This is in fact true, and a proof will be presented in the appendix. Generally the polynomials of the form

ax^ + bdo have Julia sets that extend, although other polynomials, like ax^ + bx, do not share this property.

How we compute and visualize a Julia set in the qua­ternions

Techniques for computing and viewing quaternion Julia sets were presented in [8]. We shall briefly review the methods used. The first problem is to model the Julia set in such a way as to be tractable for 3D com­puter graphics. The second problem is to construct a 3D image that conveys the fractal nature of the object.

How 4-dimensional quatemionic Julia sets can be computed in three dimensions

The quatemionic Julia set as defined is a subset of 4-space, and such sets can in general only be sampled, not fully exhibited in one 3D picture. However, in the particular case that the polynomial has complex coef-

Fig. 17. An illustration of (-0.6 + 1.04/)x( 1 - x), associated with a four-cycle. The long strands result from choosing the imaginary axis to cross multiple components of the planar

Julia set. Fig. 19. A three-dimensional slice of a Mandelbrot set of x

- c, in the quaternions.

Page 226: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

244 ALAN NORTON

ficients we can use certain symmetries to reduce the dimension of the problem. Consider a three dimen­sional subspace of the quaternions that we obtain by adjoining to the complex plane any quaternion g that lies in the plane ofj and k. The four dimensional Julia set intersects this three-dimensional space with a set Jg that depends on the q chosen. In fact, the sets 7 are congruent (i.e., of identical geometric shape) re­gardless of the choice of ^. This means that, in order to completely understand such 4-dimensional Julia sets, we need only compute their intersection in one 3-dimensional space containing the complex plane. For example, we can use the space spanned by 1, ij.

Computing the 3D Julia set In theory these could be computed by the same sim­

ple algorithm we presented above for complex Julia sets. The polynomial could be iterated, starting with each point on a 3D grid, determining for each such grid point whether the corresponding quaternion it­erates to infinity. In practice, that method is intractable, requiring evaluation of billions of grid points to obtain moderately high-resolution pictures.

To compute illustrations for this article, the amount of computation is substantially reduced by only com­puting boundary points, rather than evaluating every vertex on the grid. The algorithm follows the boundary of the basin of attraction for a cycle, wherever the boundary may lead, tracking it through a 3-dimen­sional grid. Points far from the boundary are never evaluated.

By selectively following various components of the basin of attraction, it is possible to determine how these components are connected, without determining the whole Julia set. Figs. 6-9 show different components of the basin of attraction to the four-cycle associated with p{x) = jc + (0.2809 - 0.53/). By computing and viewing them separately we determine how they are interconnected.

Making pictures of 3D fractals Once the Julia set has been computed, as a set of

vertices in a three-dimensional grid, a second com­putation is required to produce a two-dimensional im­age, suitable for raster display. Because of the fractal nature of the surface it is important to present the image in a manner that conveys information about surface texture. When we view real physical objects, we un­derstand the three-dimensional surface structure by noticing shadows and shading on the surfaces. Similar visual cues must be generated by the computer if we are to perceive the surface structure.

In the images presented here, we simulate the surface illumination by a "z-buffer" algorithm [ 8 ]: All surface elements (i.e., grid points) are projected into a depth buffer to determine the element closest to the light source. Only surfaces visible to the light source receive illumination. Only after the illumination is complete, and a brightness value is known for each surface ele­ment, is the actual image computed. This is done through another z-buffer projection to the viewer.

Interconnections and loops in Julia sets The images of quatemionic Julia sets, resulting from

the above computation, reveal a surprising wealth of detail, not obviously deducible from the Julia sets in the complex plane. Perhaps the most striking features of these shapes are the long strands or loops that in­terconnect different portions of the complex Julia set.

Consider for example the shape depicted in Fig. 6. This shows the complex Julia set as a planar slice through the quaternionic Julia set. Only one compo­nent of the basin of attraction to the four-cycle has been followed into the quaternions. We see how some of the planar components (colored yellow) become interconnected in three dimensions, and others do not.

We can alter the loop interconnection pattern (and therefore the quaternionic Julia set) without changing the complex planar Julia set. For any angle B, the for­mula e^\^ + 6 "'V defines a Julia set in the complex plane that is congruent to the Julia set of x^ 4- c. This just rotates the Julia set of x^ -I- c by the angle B about the origin in the complex plane. This change of the formula does more than just a rotation in the quater­nions, resulting in a change in the topological structure of the Julia set. See for example Figs. 10 and 11, illus­trating the quaternionic Julia sets that result when the

TT TT

angle B is, respectively, - and - radians. 2 6

We shall show how one can predict these intercon­nections, and provide a mechanism for obtaining a set with desired connections. To explain the interconnec­tion patterns it is necessary to discuss the squaring mapping p{x) = x^ in terms of how it acts on the 4-dimensional space of quaternions.

The squaring mapping and its critical set in the qua­ternions

Recall first how the squaring function acts on the complex plane. If we represent a complex number in polar coordinates, z = re'\ then its square is z^ = r'^e^'^. Squaring results in a doubling of the polar angle, so that the mapping wraps the plane twice around the origin. Squaring is a two-to-one mapping except at the single critical point, 0, which is mapped to itself

Similarly, in the quaternions, the squaring map is usually a two-to-one map: A quaternion and its neg­ative have the same square. However, there is a much larger critical set, where the mapping fails to be two-to-one. Recall from the definition of quaternion mul­tiplication that /^=7^ = A: = - 1 . This shows that - 1 , at least, has more than two square roots. In fact, there is an entire two-dimensional sphere of quaternions q such that q^ = - 1 ; namely q can be any norm-one quaternion with zero real part.

The critical set of the quaternion polynomial ax^ + bis precisely the set of quaternions of zero real part. The above examples illustrate the fact that the quater­nion squaring map fails to be two-to-one precisely on that set of quaternions of zero real part; the square of any such quaternion lies on the negative real axis.

Page 227: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Julia sets in the quaternions 245

We describe the squaring mapping as follows: Let L'be the set of quaternions with positive real part, and -U those with negative real part. Under a squaring operation, both C/and -C/are mapped onto the com­plement of the negative real axis. Every quaternion, except those on the negative real axis, has exactly two square roots, one in (/and one in —U. The boundary of U (the quaternions with zero real part) is folded onto the negative real axis, taking all points of the boundary of radius rto the negative real number —r^.

Collapsing of two-spheres Note that the inverse under the squaring map of any

negative real number is a two-dimensional sphere, so that the action of the mapping is to collapse such spheres to points. This "collapse of 2-spheres" has consequences in the geometry of shapes invariant under a squaring operation. Suppose a set 5 is invariant under the polynomial ax^ + b. If a point q of S lies in the set which is collapsed to a point under the squaring, then invariance of 5 implies that the entire collapsing 2-sphere containing q lies in S. Since the Julia set is an example of an invariant set, this implies the exis­tence of numerous 2-spheres in the Julia set, if the Julia set crosses the set of quaternions with zero real part.

The loops in the 3-dimensional shapes pictured here can be explained by this phenomenon. The 2-spheres in the Julia set correspond to 1-spheres (loops) in the 3-dimensional slices of the Julia set that we are dis­playing. The loops that are visible in the illustrations result from intersections between the Julia set in the complex plane and the imaginary axis: If such an in­tersection occurs at a point P in the complex plane, then there is a loop in the 3D shape, connecting P and -Pin a. circle. Once one such loop L exists, there will occur in the Julia set an infinite cascade of other loops, namely/-•(L) , / - ' ( / - ' (Z^)) , • • . , etc.

How can we determine the topology of a qiiaternionic Julia set?

The discussion above gives a recipe for constructing loops in the quatemionic Julia set. More generally, we can design Julia sets with various interconnection pat­terns.

Consider again the formula fc = x^-\- c, having complex planar Julia set Jc, and suppose thatX has an attractive cycle, so that Jc is the boundary between the points (in the basin of attraction) that are attracted to the cycle, and the points attracted to infinity. If two components of the planar basin of attraction are located diametrically opposite, we can modify the formula to cause those components to be interconnected by a loop in the quaternions.

This is done as follows: Choose a line through the origin that intersects both the opposite components. Let d be the angle of rotation (clockwise) between the positive X-axis and the line. The formula to be iterated in the quaternions is then e'^x^ + e~'^c. This formula then has the same complex planar Julia set as^, except that it is rotated by the angle d about the origin. In the

quaternions, however, the two components to be con­nected now lie on the imaginary axis, so there will be a loop (more precisely, a two-sphere in four-space) in the quaternion basin of attraction, intersecting and connecting them both.

In some instances, not only one loop, but an infinite cascade of interconnected loops are created by this process. Suppose for example that a component of the 2-D basin of attraction that intersects the loop contains a point of the attractive cycle (not just a preimage of the cyclic point). The connected 4-dimensional com­ponent of that cyclic point will then be an invariant set under the mapping/. The invariance of this com­ponent implies that it will contain an infinite number of loops, preimages of the starting loop.

One final example to illustrate this technique. We have seen already (in Fig. 2) the complex planar Julia set ofx^ — I. When computed in the quaternions Fig. 12 results, a surface of revolution about the x axis. The only interconnections are those introduced by the components on the imaginary axis, and all of the loops are simple rings about the x axis.

Instead, let us rotate the complex Julia set by 90 degrees, obtaining the formula i{x^ + 1 ) . The com­ponents of the basin of attraction, formerly situated along the real axis at - 1 and +1, are now along the imaginary axis at +/ and —/. This causes the compo­nent containing — / and its opposite, the component containing /, to become connected in the quaternions. By considering the preimages of this pair (these are necessarily connected as well), it is not difficult to show-that all of the quaternionic basin of attraction becomes divided into just two connected components, illustrated in Figs. 13 and 14. The red component consists of points attracted to 0 on odd iterations, and the yellow-points are attracted to 0 on even iterations. These two components fit together (and intertwine) without overlap, as illustrated in Fig. 15.

Other directions We have only presented some of the simplest geo­

metric manipulations that can be imposed on the qua­ternion Julia sets. Figs. 16-18 illustrate some of the further directions that one can explore. These depict the formulas (0.617 + 0.774/)A-( 1 - x), (-0.6 + 1.04/).Y(l - x), and x^ + (0.596 + 0.261/), re­spectively. Fig. 16 shows that, by careful placement of the critical set, it is possible to cause repeating patterns of holes in the Julia set (rather than repeating patterns of interconnectivity). Fig. 17 demonstrates how long strands in the quaternionic Julia set can be induced by appropriate manipulation of a '^stringy" Julia set in the complex plane. Fig. 18 shows the Julia set of a cubic polynomial, illustrating that the critical set of higher-degree polynomials can similarly be manipu­lated.

Mandelbrot sets in higher dimensions Implicit in the above discussion (but not proved

here) is a method for describing the structure of qua­temionic Julia sets for quadratics of the form ax^

Page 228: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

246 ALAN NORTON

+ b, with a and b complex numbers. That structure can be derived from a knowledge of the planar Julia set together with a parameter 6, determining how the imaginary axis (and therefore the critical set) intersects the planar Julia set. A three-dimensional space (the planar Mandelbrot set, together with 6) is required to parameterize these dynamical systems. There is a space that serves as Mandelbrot set for these functions, clas­sifying the dynamics that occurs in the quaternions. Unfortunately, that space can be embedded only in four dimensions, so we can only show three-dimen­sional slices as exhibited in Fig. 19. This Mandelbrot set can be identified with the boundary of the set of pairs of complex numbers (z , c) such that fc"\z) re­mains bounded as « - • oo. The slice of this shape in Fig. 19 is the subset defined by restricting c to values on the boundary of the central component of the Man­delbrot set.

Acknowledgment—Discussions with B. Mandelbrot in 1980-82 exposed me to the notion of complex planar Julia sets, and stimulated me to pursue the research of this article. Evelyn Melton was a major encouragement in the writing of this ar­ticle. She carefully read the manuscript, advising me about needed improvements, and provided many of the illustrations.

REFERENCES 1. P. Blanchard, Complex analytic dynamics on the Rie-

mann sphere. Bull. Amer. Math Soc. H( I), 85-141 (July 1984).

2. Sir W. R. Hamilton, Elements of Quaternions. Vols. 1 and II, Reprinted by Chelsea Publ. Co., New York (1969).

3. G. Julia, Memoire sur Piteration des fonctions rationnelles. J. Math Pure Appl. 4, 47-245 (1918). Reprinted in Oeuvres de Gaston Julia, Vol. I, Gautier-Villars, Paris (1968).

4. A. McAulay, Utility of Quaternions in Physics, MacMillan and Co., London (1893).

5. B. B. Mandelbrot, The Fractal Geometry of Nature, Free­man, San Francisco (1982).

6. B. B. Mandelbrot, Fractal aspects of the iteration of z - • Xz( I - z) for complex X and z. Ann. N. Y. Acad. Sci. 357,249-259(1980).

7. H.-O. Peitsgen and P. H. Richter, The Beauty of Fractals, Springer-Vedag, Beriin, Heidelberg (1986).

8. A. Norton, Generation and display of geometric fractals in 3-D. Comput. Graphics 16(3), 61-67 (July 1982).

9. A. Norton and E. Melton, Dynamics of e"x( \ - x). Vid­eotape, 1986 ACM Siggraph Electronic Theater.

10. R. H. Taylor, Planning and execution of straight line ma­nipulator trajectories. IBM J. Res. Devel. 23(4), 424-436 (July 1979).

APPENDIX In this section we provide a mathematical justification for

some of the statements in the paper. The mathematical level of this discussion assumes understanding of advanced calculus.

Formal definition of Julia sets The usual definition of Julia set is different than the ones

we have used in this article. We begin by recalling the notion

of equicontinuity: A set of functions {/} is said to be equi-continuous at a point x if for any constant 5 there is an € such that for every /

\f{x-^h)-f{x)\ <5

whenever \h\ < €. This condition is stronger than saying that all the functions

fi are continuous at x, because it requires the same € to work for all the functions. If all the derivatives of the functions/ are bounded by the same constant, then the set of functions is equicontinuous.

The Julia set of a complex function/( x) is the set of complex numbers z such that the set of all iterates of/, {/^'^}, is not equicontinuous at z. For quaternion functions we take the same definition, replacing absolute values in the above state­ment with the quaternion norm.

This definition does not necessarily coincide with the one we used above, unless some restrictions are placed on the functions/. I f / i s a complex polynomial then Montel's theo­rem can be used to show the equivalence (see [1 ]). If / is a quaternion polynomial the equivalence is not clear. It may occur that for some quaternion polynomials the boundary of the set of points attracted to infinity is a proper subset of the Julia set, although this has not been observed.

Derivatives of quaternion polynomials To reason about attraction and repulsion in the quaternions

it is useful to have a means of computing derivatives. Because quaternion polynomials are mappings on four-dimensional space, their derivatives cannot be represented simply as a nu­merical value. The derivative of such a function / (x) at a point X must be regarded instead as the Jacobian matrix, or the linear transformation that best approximates the poly­nomial near the point x. In other words, the derivative Tof / at X is a linear transformation such that fix -i- y) is ap­proximately equal to / (x) -I- T{y) for y near 0.

An easy way of representing this linear transformation is to specify what it does to a quaternion y. The derivative of a polynomial is the sum of the derivatives of the monomials in it, so it is enough to differentiate monomials. The derivative of a monomial, evaluated at y, is the sum of all the monomials that are each obtained by replacing one occurrence o( x by the value y. Some examples: The derivative of x^ at a qua­ternion X is the linear transformation that takes a quaternion y to the quaternion xy -^ yx. The derivative o(x^ is the trans­formation whose value at y is x^y + xyx + yx^.

Attractive cycles in the quaternions We can use the above formulation of the Jacobian derivative

to show that attractive cycles for complex polynomials of the form ax^ + b extend to be attractive in four dimensions, im­plying that the quaternion Julia sets of such polynomials are nontrivial extensions of their complex planar counterparts. It suffices to consider an attractive fixed point p; cycles admit a similar proof. l(p is an attractive fixed point, then we know the absolute value of the complex derivative satisfies \f'{p)\ < 1. To show that p is attractive in the quaternions, we need to know that Jacobian matrix of / at p, as a linear transfor­mation, has norm less than one. The Jacobian of ax^ -f 6, applied at p to a quaternion y has value a{py + yp). Using the multiplicativity of the quaternion norm, we see that the norm is at most 2\a\ \p\ \y\. Since 2\a\ \p\ is the absolute value of the complex derivative of / at p, we conclude that the Jacobian matrix does in fact have norm less than one.

Page 229: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 247

Chaos and Graphics

SELF-SIMILAR SEQUENCES AND CHAOS FROM GAUSS SUMS

AKHLESH LAKHTAKIA' and RUSSELL MESSIER'•-'Department of Engineering Science & Mechanics, Materials Research Laboratory,

The Pennsylvania State University, University Park, PA 16802

Abstract—It is shown that the quadratic Gauss sums form self-similar sequences with well-defined scales and similarity dimensions. It is also shown that Gauss sums can be modified to yield intricate chaotic patterns.

1. FRACTAL SEQUENCES

A self-similar (fractal) sequence {f[n]} can be defined by the power law

f[S'n]^sVlnl (1)

with n > 0 ranging over all positive integers, while f[n] may be real or complex. The positive integer s > 1 is called the scale of the sequence, whereas a> 0 is a real number which serves as the similarity (fractal) dimension of the sequence. Provided f[n] ^ 0, it should be noted that

a = \og{f[s'n]/f[n])/\o${S'n/n). (2)

which serves to validate the fractal nature[l] of the sequence by explicitly revealing the respective statuses of a and s.

The sequence { / [«]} is completely determined by the specification of only a subset of its members. These members, countably infinite in number, are:

( i ) / [ l ] or/[5] , ( i i ) / [m]; m = 2, 3, 4 , . . . , 5 - 2, j ~ 1, and (iii) f[m]; m> s, (m, s) = 1.

From Eq. (1) it is readily seen that/[I] and/[5] are linked by the relation

/ [^] = ^Y[i ] ; (3)

hence, the specification of either one of them is suffi­cient to determine the other. Furthermore, if m < 5, then m(mod s) = m, ox mis relatively prime to 5; therefore, the specifications (ii) cannot be built up from Eq. (1) and must be independently given. Lastly, the specifications (iii) must also be made, since Eq. (1) cannot be used to generate them if the greatest common divisor of m and s is unity. But for any n> s, which has 5 as one of its divisors, f[n] can be ascertained through Eq. (I). In fractal parlance, the specifications (i)-(iii) collectively are the initiators of the sequence, while the power law (1) serves as its generator[2].

A very simple example of such a sequence is the following one.

which has a scale 5 = 2 and a similarity dimension a = log(3)/log(2). This sequence is replete with zeros, but can be easily augmented to yield a more substantial example,

1, 3, 5, 9, 11, 15, 19, 27, 29, 33, 37, 45, 49, 57,

65, 81, 83, 87, 91, 99, 103, 111,119, 135, 139,

147, 155, 171, 179, 195,211,243,. . . (4b)

which too has a scale 5 = 2 and a similarity dimension a = log(3)/log(2). Yet another example is furnished by the sequence

1, 3, 6, 8, 12, 18, 21, 27, 36, 38, 42, 48, 52,

60, 72, 78, 90, 108, 111, 117, 126, 132,

144, 162, 171, 189,216,. . . (5)

which has a scale 5 = 3 and a similarity dimension a = log(6)/log(3).

2. FRACTAL SEQUENCES FROM GAUSS SUMS

The bi-indexed numbers defined as the quadratic Gauss sum

<p{p. Q) = 2,.oj.2 ^,exp[2x/(;7/^)r2], (6)

where p and q are positive integers, provide interesting examples of the fractal sequences defined above; / = V( —1) as usual. These numbers have been much investigated in recent years, especially the celebrated Gauss sums ( 1, ) which have a long history [ 3 ] dating back to the great Gauss himself. It has been shown by Nagell[4] that

ip(p, q) = 2(p(p, q/4), (7)

provided /? ^ 1 is odd, and q^ 16 is a power of 2. This relation forms the basis of a family of fractal sequences {fp[Q]}^Q =^ 1, 2, 3 , . . . , the parameterp identifying relation lorms me oasis 01 a ramiiy or iractai sequences {fp[Q]}^Q =^ 1, 2, 3 , . . . , the parameterp identifying the genus of the sequence within the family. The members of the p-th sequence thus derived are given by

/.[I] = ( !+/") 1, 3, 0, 9, 0, 0, 0, 27, 0, 0, 0, 0, 0, 0, 0, 81, 0, 0, 0,

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 243, . . . (4a) f^[2] = V(2/'^')-(l + /)

Reprinted from Comput. & Graphics Vol 13, No. 1, pag. 59-62, 1989

Page 230: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

248 AKHLESH LAKHTAKIA and RUSSELL MESSIER

/ p [ 4 l = <^(/7,4^); ^'= 1 ,2 ,3 , . . .

/p[4'^'^'] = < (/7, 4^"'/^); ;t = 1, 2, 3, . . .

with fp[q] = 0 otherwise. Note that (pip, 1) = 1, and (fip, 2) = 0 for odd p; it would have been nice to be able todefine^[l] and7p[2] intermsofthesums(6) , but even so. The scale s for these sequences can be immediately seen to be equal to 4, while the dimension a = 0.5. Furthermore, 17^[^] I is seen to be independent of (odd)/?.

Similar fractal sequences {/v(^]} can also be con­structed by utilizing another identity given in [4 ] ,

<p(U2'N)--{\ +/)V(2*'iV), (8)

which holds for all integer N > 0 and q ^ 2, Such sequences would have a scale 5 = 2, while their simi­larity dimension would still be a = 0.5: verification of this statement is given by the ratio

log(v?(l, 2W)/<^(1, 2''-*7V))/log(2^iV/2^-'iV)

= log(V2)/log(2) = 0.5. (9)

3. EXTENSION TO THE COMPLEX PLANE The fractal sequences given in Section 2 are com­

prised of either zeros or complex numbers, but p and q are positive integers. Thus, complex patterns cannot be obtained from them, unlike the case of the Collatz sequence (3n + l ) [ 5 - 7 ] . Recently, Berry and Gold-berg[8] have studied the quadratic sum

SL(T)-= 2 , . , .2 ^expf/TTTr^],

which can specialize to

5,(2/(7) = ^(1 ,^) .

(10a)

(10b)

The parameter r is always real in their study, and they have worked out a renormalization transform to ex­plore SL(T) in the complex domain.

An extension of the quadratic Gauss sums can, however, be fruitfully utilized to yield complicated patterns provided p can be made complex. Accordingly, we can define the function

F{z; q,c)^ c-^- 2 , . o . 1.2 g-l exp[2x/z<7 V^], (11)

where z and c are complex. In general, the Julia sets of the mapping z => F{z; q, c) yield very intricate patterns. For q = \, F(z\ q, c) - c + 1, which is not very interesting. When ^ = 2, then F{z\q, c) = c -{• 1 + exp[2x/z] . The Julia set for the resulting process can be equivalently expressed as z ==» exp[27r/(c + l)]exp[27r/z], which is a take-off on the mapping z ==» X exp [ z ] due to Misiurewicz [ 9 ] and Devaney [10]. When viewed on a monochrome monitor using the program given here, the most distinguishing feature of such sets is a multitude of swirling speckled bands of

varying sizes. For higher q, the detail is even more spectacular, chiefly consisting of gouged-out bulbs of different sizes. Color pictures are highly intricate; as examples, see Figs. 1 and 2 for F(z ; 2, 0) and F(z; 3, 0 ) , respectively.

The function F(z; q, c) can be made even more interesting by using higher order Gauss sums, or even negative order sums, e.g., consider the function

F(z; ^, w, c) = c + 2,.o.i.: ,-,exp[27r/z(7-'r''],

(12)

in which the integer n can be zero, negative or positive. Yet another generalization, reminiscent of the Comu spirals[6], is the function

F(z; a,n,c)--c-h \ dr exp[27r/z(a + O'V"], Jo

(13)

where a > 0 is positive real. Despite Gauss* assertion that "the theory of numbers

is the Queen of mathematics" because queens do not dirty their hands with grime, this branch of mathe­matics is increasingly being applied. Thus, the qua­dratic Gauss sums <p(\y q) have been utilized in what may be termed quadratic-residue phase gratings, the ultimate in that application being the frosted glass and the sound difiusors in concert halls [ 11 ] . And here, these same sums have been linked to the eminently utilitar­ian concepts of fractals and chaos.

Acknowledgement—^Q thank Dr. C. A. Pickover of IBM Watson Research Center for generously creating Figs. 1 and 2 for this communication.

REFERENCES 1. B. B. Mandelbrot, The Fractal Geometry of Nature, Free­

man, New York (1983). 2. A. Lakhtakia, R. Messier, V. V. Varadan and V. K. Var-

adan, Spatial convolution and the generation of clusters and generalized Cantor bars. Phys. Lett. A 118, 54-58 (1986).

3. B. C. Bemdt and R. J. Evans, The determination of Gauss sums. Bull. Amer. Math. Soc. 5, 107-129 (1981). (Note: An extensive bibliography on ^(1, q) and other w-adic Gauss sums has been given here.)

4. T. Nagell, Introduction to Number Theory, Wiley, New York (1951), Sec. 53.

5. S. Wagon, The Collatz problem. Math. Intelligencer 7, 72-76(1985).

6. C. A. Pickover, Computers, Pattern, Chaos and Beauty, Springer-Verlag, New York (in press).

7. B. C. Wiggin, Wondrous numbers—Conjectures about the 3A2 + 1 family. / Recreational Math. 20, 52-56 (1988).

8. M. V. Berry and J. Goldberg, Renormalisation of curli­cues. Nonlinearity 1, 1-26 (1988).

9. M. Misiurewicz, On iterates of *. Ergod. Theory Dvnam. Sys. 1, 103-106(1981).

10. R. L. Devaney, Julia sets and bifurcation diagrams for exponential maps. Bull. Amer. Math. Soc. 11, 167-171 (1984).

11. M. R. Schroeder, Number Theory in Science and Com­munication, Springer-Verlag, New York (1986).

Page 231: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Self-similar sequences 249

Fig. 1. Julia set of the function F(z; 2, 0) of Eq. (11) produced on an IBM 5080 color display. The screen resolution is 1024 X 1024, and the z-domain is -1.940 ^ x <. -0.716, -0.621 ^y ^ 0.559.

Fig. 2. Same as Fig. 1, but for F{z\ 3, 0) with the z-domain 0.550 ^x:^ 1.420, 0.013 ^ y :^ 0.842.

Page 232: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

250 AKHLESH LAKHTAKIA and RUSSELL MESSIER

COMPUTER PROGRAM

c C TO CREATE JULIA SETS FOR THE MAPPING GIVEN BY EQUATION (11) C WITH PARAMETER C « 0. C PROGRAM IS IMPLEMENTED ON MACINTOSH II COMPUTER. IT UTILIZES A C ABSOFT MACFORTRAN/020 V2.3 COMPILER, AND GIVES A C BLACK-AND-WHITE OUTPUT. C

PROGRAM GAUSS INCLUDE TOOLBX.PAR INTEGER*4 P,NA,NB,KMAX,NX,NY,KOLOR,K,Q,WHITE, BLACK COMPLEX Z,ZO,PHI DATA WHITE/30/, BLACK /33/

Q****•••**••** INPUT DATA ************* WRITEO,*) 'GIVE XMIN, XMAX, YMIN & YMAX. ' ACCEPT XMIN, XMAX, YMIN, YMAX WRITE(9,*) 'GIVE NA & NB IN THE RATIO 4:3.' ACCEPT NA, NB WRITE(9,*)' GIVE THE INTEGER Q' ACCEPT Q

Q************* SET VALUES ************* DELX « (XMAX - XMIN)/FLOAT(NA - 1) DELY « (YMAX - YMIN)/FLOAT(NB - 1) KMAX « 63 RMAX « l.OE+02

C************* COMMENCE ITERATIONS ************* DO 1000 NX » 0, NA-1 DO 1000 NY =« 0, NB-1 ZO « CMPLX(XMIN + NX*DELX, YMIN + NY*DELY) K = 0

25 K = K+1 Z = PHI(ZO,Q) R « ABS(Z)**2 IF (R.GT.RMAX) KOLOR « K IF (R.GT.RMAX) GO TO 50 IF (K.EQ.KMAX) KOLOR = 0 IF (K.EQ.KMAX) GO TO 50 ZO - Z GO TO 25

50 CONTINUE Q************* PLOT *************

IF(MOD(KOLOR,2).EQ.O)CALL TOOLBX(FORECOLOR,BLACK) IF (MOD (KOLOR, 2) .EQ.DCALL TOOLBX (FORECOLOR, WHITE) CALL TOOLBX(MOVETO, NX, NY) CALL TOOLBX(LINETO,NX,NY)

1000 CONTINUE C************* END OF ITERATIONS *************

STOP END

C************* FUNCTION SUBPROGRAM PHI ************* FUNCTION PHI(Z,Q) COMPLEX PHI,Z,CI INTEGER Q,R CI=CMPLX(0.0,8.0)*ATAN(1.0)*Z/FLOAT(Q) PHI=CMPLX(1.0,0.0) DO 10 R = 1,Q-1

10 PHI=PHI+EXP(CI*R*R) RETURN END

Page 233: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 251

Chaos and Graphics

COLOR MAPS GENERATED BY "TRIGONOMETRIC ITERATION LOOPS"

MICHAEL MICHELITSCH Emilienstr. 38, D-7000 Stuttgart 80, FRG

Abstract—Interesting color maps are being generated by using "trigonometric iteration loops." They yield vortices and fern-like structures, amongst others.

1. INTRODUCTION

The famous Mandelbrot set[l, 2] is being generated in the parameter space by iterating z„+i = zj - c. The real and imaginary parts of this equation are:

^n+l ~ ^n Vn ^x ' '

yn+l ~ ^' X„* y„ — Cy

(1)

(2)

During each iteration loop the previous x„ has to be replaced by a new x„+i-value:

X„ -^ Xn+\ * ' • (3)

SO that the complete iteration cycle runs from (1) ^' ( 2 ) - ^ ( 3 ) - ^ (I) and so forth.

2. RESULTS AND DISCUSSION

Exciting graphics are being obtained by changing (3) either into

Xn -^ COS( 1.193-X^+i)

x„-> tan(0.75-x„+,)

(3a)

(3b)

Iteration cycles from (1), (2), through (3a) yield Fig. I and those of (3b) yield Figs. 2a, b, c, d. The factors

1.193 and 0.75 are empirical ones and preserve the "head" of the Mandelbrot-like set and that of the "tri-corn-like" structure on the Cx-axis, as well.

The "cosine structures" (Fig. l)show:

• Mandelbrot-like sets, if the sign of the cosine is pos­itive, and tricorn-like structures [3, 4] , if the sign of it is negative [right-hand part of Eq. (2)]. These two structures are repeatedly found with a period of 27r on the C;c-axis.

• vortices between both kinds of structures which re­minds one of "high and low pressure" areas above an "ocean with islands."

• self-similar small sets of above structures being dis­tributed over the entire parameter plane.

The "tangent structures" (Figs. 2a, b, c, d) show:

• "fern leaves" surrounding the Mandelbrot-like set. This feature is refound at any scale. Again, a peri­odicity of 27r of the "columns" containing a set can be seen. Within one "column" infinitely many "subperiods" appear in the Cx- and c^-directions, re­spectively.

• "fern leaves" enveloping the Mandelbrot-like sets at any scale (Figs. 2b, c).

• that the fractality of the boundaries disappears, some kind of "dust" is surrounding these structures. This dust seems to consist of helical arrangements of el-

Fig. I. Computer scan of x„+, = xl- yl- Cx\ y«+i = 2 • x„ • y„ - Cy\ Xn -^ cos(1.193* x„+i); "Hurricans above an Ocean with Islands," initial value Xo = yo = 0; axis -0.5 <Cx< 5.5; -1.6 < c < 1.6; maximal iteration number 250; explosion

threshold value ci + cl = 250.

Fig. 2a. Computer scan of x„+i =xl~ yl- Cx\ y„+i = 2 • x„ • n - Cy\ x„ -»• tan(0.75 • A:„+I ) showing "fern leaves"; initial value 0 = yo = 0; axis -6 < C;c < 6; -4.5 < Cy < 4.5; maximal

iteration number 80; explosion threshold value cl -f- cj = 80.

Reprinted from Comput. & Graphics Vol 14, No. 1, pag. 125-126, 1990

Page 234: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

252 MICHAEL MICHELITSCH

Fig. 2b. Computer scan, all equations and parameters as in Fig. 2a, except -0.7 <Cx< -0.5; l.O<Cy< 1.2.

Fig. 2d. Three-dimensional "Lake Mandelbrot" (blue—for one period out of Fig. 2a, surrounded by "Fern Leaves Moun­

tains"—brown); maximal iteration number 50.

Fig. 2c. Computer scan, with "fern leaves" accompanying a helical arrangement of ellipses, all equations and parameters as in Fig. 2a, except -0.41132 < c^ < -0.41078; 0.0150 < Cy < 0.01588; maximal iteration number 250; explosion thresh­

old value 250.

lipses near the boundary of the Mandelbrot-like sets (Fig. 2c).

Finally I should mention that other nice graphics can be obtained, if trigonometric functions are applied to other terms of Eqns. (1) and/or (2) .

Acknowledgments—I thank Prof. O. E. Rossler and M. Klein very much for stimulating discussions and A. Murle for kindly sharing with me his computer programs.

REFERENCES 1. B. B. Mandelbrot, Fractal aspects of the iteration of z -^

Xzi 1 - z) for complex A, z. Ann. N. Y. Acad. Sci. 357, 249(1980).

2. H.-O. Peitgen and P. H. Richter (Eds.), The Beauty of Fractals, Springer-Verlag, Berlin (1986).

3. R. L. Devaney, private communication (Mandelbrot set for the complex iteration Zi = (Zcoiy) + c\ Milnor's "Tri-com").

4. M. Szyszkowicz, Computer graphics generated by nu­merical iteration. Comp. & Graphics 13(1), 121-126 (Example G)( 1989).

Page 235: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 253

Chaos and Graphics

A NOTE ON HALLEY'S METHOD

R A Y REEVES Department of Computer Science, University of Lowell, Graphics Research Laboratory,

1 University Avenue, Lowell, Massachusetts 01854

Abstract—Scrutiny of Pickover's representation of Halley's method applied to solving the polynomial equation z**7 = 1 elicits several remarkable features. The nodules are seen to be bilinear conformal mappings of the whole plane which explains the coloration by targets. There are distinguished director nodules that direct the forward orbits out of the chaotic separators to their target basins. There are points of essential complexity where all targets are represented. At sufficiently high root density, separators will web over to form more complex separators.

INTRODUCTION

In 1988 Pickover [1] published some engaging illustra­tions showing the rate of convergence of Halley's it­erative method for the solution of z**7 = 1. While reproducing these results as part of a graphics capability demonstration, we noticed several interesting features of the separators and orbits.

Following Pickover, we use Halley's method of it­eration which is just a second order form of Newton's iteration derived from the Taylor series. For each point in a selected window on the complex plane, the number of steps required by Halley's method to converge to a root of the polynomial were recorded. The stopping criterion was by the absolute value of the polynomial. The points were then colored according to the number of steps required (distance coloration), as in Pickover's map, or according to the root that is reached from it (target coloration). In either case, the intermediate points in the convergence sequence are valid starting points for the process and are also plotted. This accel­erates the display if the scan is arranged to start from the outside so that intermediate points do not on the whole fall within areas already scanned. The resulting adumbration of the final display captures the viewer's attention immediately. Fig. la shows a distance col­oration, and Fig. lb a target coloration. While there are basins of attraction around each root where the convergence trajectory is simple, both of these maps illustrate the chaotic structure near the radial spokes that separate the basins. We refer to these regions as separators. Each spoke is characterised by a principal sequence of nodules extending apparently to infinity and getting closer together and smaller towards the origin. Between them, there are sequences of smaller nodules. Inside each nodule, the coloring according to Fig. 2 shows that the iteration will not, in general, lead to either of the adjacent roots but to one of the other five more distant ones.

Figure 2a is a detail of one of the nodules on the unit circle, at the point - 1 , 0 in the complex plane, with distance coloration, and Fig. 2b is the same nodule with target coloration.

The striking feature is that the nodule is constructed of circular arcs, and it contains two seven-fold equi­

angular hubs, like the pattern at origin of the complex plane. This suggests that the whole plane is reflected here by a bilinear conformal transformation of general form z' =^ Az + B/Cz -\- D, which transforms circles to circles.

The adjacent septants have mapped into the upper and lower half planes, and the other five septants map to the five interior regions of the nodule, which explains the target coloration there. The nodules that were orig­inally seen along the radial spokes are reproduced along the spokes of each nodule, and it can be seen that these nested nodules, too, have the same form. This is the characteristic fractal self-similarity typically encoun­tered.

A question remains: what is the form of the forward orbit starting from a point within a nodule? In this example, only the nodules on the unit circle seem to have the distinguished property of allowing the trajec­tory to escape to the final basin. We call them director nodules. Starting from another nodule in the principal sequence will result in stepping along the nodules until the director nodule on that spoke is reached, where the trajectory will be directed to a basin. Starting points further out than unit circle will move inwards, and those within unit circle will move outward. Thus, col­oring nodules according to the distance criterion will produce, in adjacent principal nodules, adjacent colors on the count spectrum, in corresponding areas.

Starting at a secondary nodule will also orbit along a path towards the director nodule, but will exhibit an overshoot before arriving. Starting at a nodule within a nodule will step to corresponding inner nodules on the way to the director.

The node in Fig. 2 is on the unit circle, as are its directors. Since the nodules in this sequence are di­minishing in size, it follows that there is a sequence of nodules converging to points on the unit circle (and elsewhere) where all the roots and indeed, every point in the plane, is represented in an arbitrarily small neighbourhood. We refer to this limit of a sequence of nodules as an essential complexity, and these points collectively constitute the Julia set for this function. By plotting the spectrum of target colors on a locus along the unit circle one can see the fluctuations in the

Reprinted from Comput. & Graphics Vol. 15, No. 1, pag. 89-90, 1991

Page 236: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

254 RAY REEVES

Fig. la. z**7-1 Distance coloration. Fig. 2a. z**7-1 Distance detail at -1,0.

Fig. lb. z**7-1 Target coloration. Fig. 2b. z«*7-l Target detail at -1,0.

colors at these points as the locus is perturbed by a very small amount.

GENERALIZATION

Looking at maps of different roots of unity merely supports the observations made so far, but adding an­other root at the origin prevents all the separators from meeting there, and produces a different kind of map. A map of

z ( z * * 3 - 1)

shows a parabolic separator around each root on the unit circle, and these do not meet. There are now two director nodes on each parabola, symmetrically dis­posed about the apex. There is sufficient space between

the roots to allow the basin belonging to the root at the origin to extend continuously to infinity.

However, a similar map of:

z(z**4 — 1)

show that this origin basin is getting pinched. And when there are five or more roots on the unit circle webbing sets in between the separators, so that the number of chaotic spokes appears to be halved; but each contains a sequence of disjoint basins that belong to the root at the origin. Such a map is more easily understood in the light of the simpler cases.

REFERENCE 1. Clifford A. Pickover, A Note on Chaos and Halley's

Method, Comm. y4CM 31 (11), November (1988).

Page 237: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 255

Chaos and Graphics

A NOTE ON SOME INTERNAL STRUCTURES OF THE MANDELBROT SET

KENNETH J. HOOPER Southern California Edison Co., P.O. Box 128, San Clemente, CA 92084

Abstract—This article presents two simple methods for creating images which reveal some of the "interior" patterns of the Mandelbrot Set. The "epsilon cross" and "star trails" methods described here monitor the trajectory of a point, as calculated by the Mandelbrot Set algorithm, on a complex plane. A portion of this algorithm is presented along with a discussion of the changes required to create the images in the accompanying figures.

The traditional algorithm [1-3] for generating graphic representations of the Mandelbrot Set reveals the richness of the exterior region while the interior is often shown in black and largely ignored. By modifying the existing Mandelbrot Set algorithm, it is simple to create new displays that are unlike those seen in the traditional images. This study is a tutorial on artistic methods revealing "interior" Mandelbrot Set struc­tures.

The two methods to be described are based on ex­amining the results of each iteration of the inner loop of the Mandelbrot Set algorithm. The inner loop pro­duces the variables x and y which correspond to the X and y coordinates of a point on a complex plane. The behavior of this point as it moves about the plane on successive iterations of the inner loop can be analyzed in various ways to create new images. Only the algo­rithm for the inner loop is presented here. Readers may refer to refs. 1, 2 and 3 for further information on the Mandelbrot Set.

Simplified code for the Mandelbrot Set inner loop is shown below.

jc = 0, >; = 0 for j = 1 to 100

xx^ x^ — y^ -^ a yy = 2*x*y + b ii xx^ + yy^ > 4, exit loop X = XX

y = yy end loop color = colortable(j) setpixel (column,row)

Note: The variables 'a' and 'f are the starting points. They range from —2 to 2 and are incremented over this range by the outer loops. The pixel position as defined by column and row is also supplied by the outer loops.

Figs. 1 and 2 are examples of Pickover's "epsilon cross" technique [4, 5 ]. Both images were made on an IBM-AT clone using VGA 640 X 480, 16-color mode. Fig. 1 is a typical "bud" located near a = 0.308 and b = 0.544. The blue regions represent the interior of the Mandelbrot Set and the black regions the outside. The green and yellow patterns are based on the location of the point (x,y) calculated by the inner loop. The pic­tures show that the resulting patterns are not confined to the interior (blue region) of the Mandelbrot Set. Note that the green patterns are not quite symmetrical but that the yellow patterns are. Also, notice how the

yellow and green arcs interweave in Fig. 2 giving the illusion of a 3D object. Fig. 2 is located near a bud at a = 0A5, b = 0.65. The patterns are present in buds at different scales, as Fig. 1 shows, and exhibit increased branching as the boundary is approached.

The epsilon cross method adds a test at the end of the inner loop to check the position of the point (jc, y) after each pass through the inner loop. If the point falls close to the X axis, we exit the inner loop, and the pixel for the current row and column is colored green. Likewise, if the point falls close to the y axis, the pixel is colored yellow. Epsilon is the name of the variable that defines a tolerance band on either side of the X and Faxes within which the point must fall to be con­sidered close to an axis. Typical values of 0.01 to 0.005 are used depending on the magnification of the display.

The inner loop is modified as shown below for the epsilon cross.

ifxx^ + yy^ > 4 then color = black and exit loop

if XX > -.01 and xx < .01 then color = green and exit loop

else if yy > -.01 and yy < .01 then color = yellow and exit loop X ^ XX y = yy

end loop if 7 > 99 then color = blue setpixel (column, row)

Another technique, which I will call "star trails," is based on the patterns formed by plotting points cal­culated from several iterations of the inner loop on an X - y plane. Some locations inside (and outside) the Mandelbrot Set yield clusters of points occurring alone or in groups. In the case of multiple clusters, each it­eration of the inner loop adds a point to each cluster by jumping from one to another within the group in a continuous orbit. When a starting point inside the Mandelbrot Set is used, the orbit is stable around an attractor with cluster sites forming along the orbital path. The number of clusters in a group varies accord-

Reprintedfrom Comput & Graphics Vol. 15, No. 2, pag. 295-297, 1991

Page 238: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

256 KENNETH J. HOOPER

Fig. 1. Three levels of "buds" using the epsilon cross method. Fig. 3. Star trails crossing the boundary of the Mandelbrot Set.

Rib-like structures Fig. 4. Here, some stars are transformed into graceful forks.

ing to the starting point in the Mandelbrot Set.' Figs. 3 and 4 can be considered maps which define the cluster count in a given group and were made on the same VGA system. The coordinates for Figs. 3 and 4 are: a = - 0 . 2 , b = 0.8; and a = - 0 . 4 , b = 0.65, respectively. In each picture, self-similar patterns appear as the larger stars, that seem to be foreground objects, trail off into smaller stars. Notice how the tips of some stars break into streaks, mimicing the velocity lines cartoonists use to give the illusion of motion. Both figures cross the boundary between the interior and exterior of the Mandelbrot Set. However, do not misinterpret the points where the star tips streak off as the boundary. The stars themselves cross the boundary without ap­parent change. The points where the streaks occur seems to coincide more with the region surrounding buds that resemble flames in the more familiar Man­delbrot Set images.

In order to count the clusters, it is not necessary to repeat the inner loop very many times. I have chosen

' These clusters can be viewed by modifying the inner loop so that each point defined by x and y is plotted, i.e., use setpixel (jc, y) instead of setpixel (column, row). This requires that the programmer scale the viewing window to span approxi­mately -1.0 to 1.0, horizontally and vertically. Run the pro­gram with a starting point at A = - .5 and b = .55 to view a five-cluster site.

16 iterations because high resolution VGA mode pro­vides 15 colors (plus black as background), and the loop count is used to define color. Also, I assume that the clusters are not positioned around the origin (0, 0) symmetrically, and that two clusters do not share a common angle with respect to the origin. Therefore, each cluster has a unique tangent value which defines its position.^ Each x and y value is used to find the tangent of the angle of a vector between the points (0, 0) and (x,y). This value is stored in a table for sub­sequent use. After completing the inner loop, another loop is entered which compares the first tangent table entry with each of the remaining entries. If, for ex­ample, the comparison shows that entry number 4 dif­fers from the first by less than .05 we have returned to the first cluster, and can conclude that three clusters occurred within this group. The value of .05 can be reduced so that foreground stars do not obscure the

^ Of course, there are exceptions to these assumptions. For example, the starting point at A = -.42 and b = .25 actually has six clusters but three of them share approximately the same angle. This program only resolves four clusters in this case but the continuity of the patterns remains intact as it blends in quite well with genuine four cluster sites nearby. Perhaps clusters tend to align themselves along the same angle eventually blending together, thereby providing the transition between differing cluster counts.

Page 239: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Internal structures of the Mandelbrot Set 257

receding stars as much. The comparison loop is exited here and the loop count is used to define the color of the current pixel. If no cluster count is found, then color the pixel black.

This method gives relatively quick results since the usually time consuming inner loop is limited to 16 iterations. Instead of finding the tangent, the X and Y values could also be stored in a table and processed similarly, possibly giving a different image.

Here is the modified inner loop for star trails.

forj = 0to 15 xx = x^ - y^ + a yy = 2*x*y + b X = XX y = yy Tantable(j) = 3;/(x+.000001)

end loop Note: In case x = 0.0,

this prevents divide by zero,

color = 0 Note: Colors are defined by the

fork = 1 to 15 numbers 0-15. Diff = Tantable(O) - Tantable(k) Q = black 1

if Diff < .05 and Diff > -.05 then = 51^^ ^^^ color = k and exit loop

end loop setpixel (column, row)

These two examples show how to extract interesting images from inside the Mandelbrot Set (ref. 4 gives still another method). The reader interested in ex­ploring the interior region further might start by mak­ing simple modifications to either of the methods de­scribed.

REFERENCES 1. B. B. Mandelbrot, The Fractal Geometry of Nature,

W. H. Freeman, New York (1983). See also: H. Peitgen and P. Richter, The Beauty of Fractals, Springer, New York (1986).

2. A. K. Dewdney, Computer recreations. Scientific Amer­ican {SeptQmbQT, 1986).

3. R. T. Stevens, Fractal Programming in C, M&T Pub­lishing, Redwood, CA (1989).

4. C. A. Pickover, Computers, Pattern, Chaos and Beauty, St. Martin's Press, New York (1990).

5. C. A. Pickover, Inside the Mandelbrot Set. Algorithm: The personal computer newsletter. (Nov/Dec 1989). (P.O. Box 29237 Westmount Postal Outlet, 785 Won­derland Road South, London, Ontario, Canada N6K 1M6.)

Page 240: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 259

Chaos and Graphics

THE METHOD OF SECANTS

JOHN DEWEY JONES School of Engineering Science, Simon Eraser University, Burnaby, British Columbia, Canada, V5A 1S6

Abstract—The method of secants is defined. The convergence of the method is discussed and illustrated for some simple examples.

1. INTRODUCTION

The method of secants is an iterative method for finding the roots of an equation/(z) = 0. Two estimates of the root are used to construct a third, this being re­peated until successive estimates agree to within a specified tolerance. Exphcitly, the formula used is

^(k+\) ^ ^{k) . f(z''')

(k) _ ^(A:-l)

(1)

iz

where z ^ denotes the approximation to the root ob­tained on the (/c + 1 )th iteration, and z ° and z ^ are the two initial estimates.

A graphical interpretation of this method for a real-valued function is shown in Fig. 1. The underlying assumption is that the function whose roots are being sought is approximately linear in the region of interest. Where the method converges, it can be shown [ 1 ] that its order of convergence is the "golden ratio" 0 = 1.618- • •:

l im \ek+i\ X Ac-^oo

(2)

However, the method is by no means guaranteed to converge for all pairs of initial estimates; and, where it does converge, the number of iterations required can change significantly for small changes in the values of the initial estimates.

This behavior is illustrated in Fig. 2, which shows the use of the secant method to locate the root of JC — 1 = 0 for pairs of initial estimates in the range

{(a, b): -2.0 < ^ < 2.0, -2.5 < ^ < 2.5}

Each point on the figure represents a pair x^^\ x^'\ the horizontal coordinate corresponding to x^^\ the vertical coordinate to x^*\ The color assigned to each point denotes the number of iterations, /c, required to attain convergence to within 10~^; dark shades of red indicate rapid convergence, while lighter-colored points lead to slower convergence. The mauve-colored areas correspond to pairs of initial estimates for which con­vergence was not attained within 64 iterations.

Fig. 2 shares some characteristics with maps which have been created to illustrate the convergence of Newton's method in the real plane[2]. There are re­gions in the lower left quadrant, for example, where a very small change in the initial conditions can make a large change in the time required to attain conver­gence; this extreme sensitivity to initial conditions is one hallmark of chaotic behavior. In the lower right quadrant, we see the emergence of a curvilinear, neu­ron-like structure; the appearance of complex natu­ralistic forms from apparently simple mathematical operations is a second indicator of chaos. On the other hand, Fig. 2 does not display self-similarity, nor do any of the shapes or boundaries in the figure qualify as fractal curves.

2. EXTENSION TO THE COMPLEX PLANE

Showing the sensitivity of the secant method to the initial pair of guesses is straightforward when the pair is selected from IR , as [R maps naturally to the surface of a display device. The secant method can also be used to find the zeroes of complex-valued functions. Algebraically, the calculation procedes as for the real case, though the equivalent geometric construction is more difficult to visualize as it now occurs in a space of four dimensions. The two guesses z ^ and z ' re­quired to start the calculation have four independent components, so the graph representing the dependence of convergence time and root on those initial guesses must also be four-dimensional. Constructing a full graph with the same level of detail as the images above, that is, considering 1000 alternatives for each com­ponent of the initial guesses and iterating to a dwell limit of 64, would require about 64 trillion repetitions of the iterative step, and the results would be difficult to view on a conventional display device. Rather than go to these lengths, we take a series of two-dimensional slices through the four-dimensional object. This is analogous to dissecting a biological specimen: we must wield the scalpel in such a way as to expose the inner structure of the graph, then stain it with a color scheme that will reveal its significant details. Figs. 3, 5, and 6 are different sections through the four-dimensional object representing the application of the secant method to z^ - 1 = 0.

Reprinted from Comput. & Graphics Vol. 15, No. 3, pag. 451-454, 1991

Page 241: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

260 JOHN DEWEY JONES

Fig. 1. Graphical interpretation of the secant method apphed to a real-valued function. Numbered points correspond to

successive values of (A:^*\/(X^*^)).

In Fig. 3, we again apply the secant method to z 1 = 0, selecting our initial guess z ° from

the two methods should become identical as the series of iterates converges on a root. Inspection confirms that the correspondence between Fig. 3 and equivalent maps for Newton's method is most exact in the neigh­borhood of the roots.

Figs. 2 and 3 may be regarded as different cross-sections through a single four-dimensional map. The two cross-sections intersect along a single line, which appears in Fig. 2 as the line z^^^ = z ° + e, and in Fig. 3 as the real axis. The contrast between the cross-sec­tions is striking.

In Fig. 5 we have constrained z ^ to be zero and colored the points representing z ' according to the root they converge to: red (root = 1), blue (root = -1 / 2 + /V3/2) and green (root = - 1 /2 - /V3/2); as the time to convergence increases, red shades to yellow, blue shades to violet, and green shades to cyan. Black regions do not converge within the preset dwell limit of 80.

Fig. 6 shows values of z ° in the range

|R(z^o>)| < 7 , |T(z^°>)| < 7

the corresponding values of z ' are generated by the transformation

T(z ' ) = IR(z )), >) = T(z^^>)

|D(z^«>)| < 1.5, >)| < 2

mapping the real and imaginary parts of z ^ to the horizontal and vertical axes, respectively, and gener­ating z ' from z ' = z ^ + e, where e = 0.001 (1 + /). Each starting point is assigned a color depending on the root it ultimately leads to, and the parity of the number of iterations required to reach that root. When 64 iterations from a given starting point have not led to convergence, that point is colored black. The result resembles the maps obtained by applying Newton's method to complex-valued functions [ 3 ]; Fig. 4 shows the results of using Newton's method to solve the same problem over the same range of initial values. The two figures share the property that at every point where the striped zones corresponding to two distinct roots meet, the third zone also meets [ 3 ] . This resemblance is not altogether surprising, given the method we have se­lected for generating the second guess; as e - 0, we have for the denominator in the first iteration of the secant formula:

/ (z^' ) ) - / (z<^>-0 T ( » ) _ (Z^^>+6) ^fW)

Thus, on the first iterative step, this application of the secant method approximates to Newton's method. On subsequent iterations, one would expect the approxi­mation to become more or less good, depending on the distance between successive iterates; in particular.

This time we seem to have wielded the scalpel care­lessly. The structure revealed is distorted and uninfor-mative. Perhaps this is not a good plane to slice along?

But taking a similar slice—that is, interchanging the real and imaginary parts of z ° to obtain z ' —through a different object gives good results. Fig. 7 is just such a slice through the object sin(z) = 0; z ° lies in the range

|IR(z<°>)| ^ 110, |T(z<°^)| < 110

Different hues denote the roots (0, ±ir, ±27r, • • •), and the saturation of each hue varies with the number of iterations required for convergence. The white and black zones correspond to convergence to a fixed value which is not a legitimate root, and to nonconvergence, respectively.

Fig. 8 is an enlargement of the central region of Fig. 7 (the area lying within the values ±7 on each axis). We note that the basins of convergence are streaky and* soft-edged. Also, there are small stitch marks on the borders between the coloured zones. Fig. 9 shows a close-up of one of these stitch marks, which is seen to have a complex antisymmetric structure with black zones of nonconvergence, rather similar to the shape found at the center of Fig. 3.

3. SUGGESTIONS FOR FURTHER WORK

It would be of interest to apply the techniques used here to investigate the convergence of the false-position

Page 242: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fig. 2. The secant method applied to find the real root of x^ ^ , , _ J = Q Fig. 6. The secant method applied to find the three complex

roots of z - 1 = 0; z ' obtained by interchanging real and complex parts of z^^K

Fig. 3. The secant method applied to find the three complex roots of z - 1 = 0; z ' set to z< ^ + e.

Fig. 7. The secant method applied to find the complex roots of sin(z) = 0: z ' obtained by interchanging real and complex

parts of z^°\

Fig. 4. Newton's method appHed to find the three complex roots of z - 1 = 0 .

Fig. 8. Enlargement of central region of Fig. 7.

Fig. 5. The secant method applied to find the three complex roots of z - 1 = 0; z< ^ set to 0.

Page 243: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

262 JOHN DEWEY JONES

Fig. 9. Enlaragement of a "stitch" from Fig. 8.

method[4]. Where the secant method uses the two most recent values of z^^^ to generate the next, the false-position method uses the most recent z^^\ to­gether with the most recent earlier value for which/(z) is of opposite sign. It converges more reliably but more slowly than the secant method.

REFERENCES A. Ralston and P. Rabinowitz, A First Course in Nu­merical Analysis (2nd ed.), McGraw-Hill, New York (1978). H. O. Peitgen and P. H. Richter, The Beauty of Fractals, Springer-Verlag, Berlin, 103-108 (1986). H. O. Peitgen, D. Saupe, and F. v. Haeseler, Cayley's problem and Julia sets. The Mathematical Intelligencer 6(2), 11-20(1984). W. H. Press, B. P. Flannery, S. A. Teukolsky, and W. T. Vetterling, Numerical Recipes, Cambridge University Press, Cambridge, UK, 248-251 (1986).

APPENDIX

Computer details The calculations for Figs. 2, 3, and 4 were performed on a Cray X-MP 24, using an IBM 3084 as a front-end. The figures are displayed on the 1024 X 1280 screen of a Tektronix 4115, using the ADDSYS extension to the DI-3(X)0 graphics package marketed by Precision Visual, Inc., and photographed using a matrix camera.

Calculations for Figs. 5 through 9 were performed on a Sun SparcStation 1. The figures are displayed on the 1280 X 900 screen of the SparcStation, using the PIXRECT graphics pro­gram marketed by Sun.

Page 244: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 263

Chaos and Graphics

A GENERALIZED MANDELBROT SET AND THE ROLE OF CRITICAL POINTS

MICHAEL FRAME* and JAMES ROBERTSON** *Department of Mathematics and **Department of Computer Science,

Union College, Schenectady, NY 12308-2311

Abstract—We examine the Julia sets for certain cubic and quartic polynomials and observe the structure of the Julia set as determined by the orbits of the critical points. In examples where the orbits of some critical points diverge and others converge, or where orbits converge to different cycles, we note the local structure of the Julia set is dominated by the behavior of the nearest critical point. This information is encoded in a generalized Mandelbrot set reflecting the behavior of all the critical points.

1. INTRODUCTION

Since the appearance of high-resolution images of the Mandelbrot set and Julia sets [6], [9-11], a consid­erable amount of computer time has been devoted to exploring the detailed structure of these sets. The usual Mandelbrot and Julia sets are generated by iterating the function Fdz) = z^ + c, for the Mandelbrot set always starting the orbit at z = 0. Taking z = 0 for a starting point is the natural choice since work of Fatou and Julia shows the iteration sequences generated from the critical points (points at which the derivative of the function is zero) dominates the dynamical behav­ior, and for Fdz) the only critical point is z = 0.

In this paper we investigate the structure of Julia sets for two families of polynomials, each with more than one critical point, and consider a generalization of the Mandelbrot set to the case of several critical points.

2. THEOREMS OF FATOU AND JULIA, CRITICAL POINTS, AND A GENERALIZED MANDELBROT SET

General background references for this material are [1, 4, 5, 8]. Given a polynomial

p{z) = a„z" + a„-iz"~^ + • • • + fliz + ao,

and a complex number ZQ, a natural question is to ask what is the asymptotic behavior of the orbit { ZQ, /7(zo), p(p(zo)), • • •} of this point under iterated appUcation ofp{z). Will this orbit diverge to oo, converge to some fixed point, converge to a cycle of points, or wander chaotically? Work by Pierre Fatou and Gaston Julia in the 1910s-1920s shows these questions can be ap­proached by studying the orbits of the critical points of/7(z). In this section we estabUsh some preUminary notions, review the results of Fatou and Julia, and de­scribe the families of polynomials to be studied.

To begin, polynomials take large numbers to large numbers and so it will be convenient to "add the point at infinity" to the complex plane and extend our poly­nomials to this larger set by taking /?(oo) = oo. That is, the point at oo is a fixed point for any extended polynomial. Recall (e.g., [4], p. 78) that a (finite) fixed

point ZQ ofp(z) is attracting if \\p'(zo) || < 1. For every polynomial the point at oo is attracting:

PROPOSITION 2.1. The point z = oo is an attracting fixed point for any polynomial p(z).

Proof. A fixed point ZQ is attracting if ||/7'(zo)|| < 1. To take the derivative at z = oo, we change variables by z = //(w) = l/w. Then Q(W) = h~^ph(w) has the same dynamics for points w2Lsp(z) has for z = h(w). In particular, z = oo corresponds to w = 0 and so we test whether the fixed point n = 0 is attracting for g{w). Assuming « ^ 2 and a„ ¥= 0, a straightforward computation shows ^'(0) = 0. That is, w = 0 is an attracting fixed point for q{w) and so z = oo is an attracting fixed point for p{z). ///

Recall the basin of attraction of a fixed point ZQ is the set of all points w for which p°"(w)-^zo, where we have used the notation /7°"(z) for the «-fold com­position p{p{' • ' p{z)' • •))• The basin of attraction of Zo is denoted (zo), so Proposition 2.1 can be viewed as stating ^(oo) is nonempty.

For a polynomial p{z), the filled-in Julia set Kp consists of all points not converging to oo under iter­ation of/7(z). That is,

A-;, = {z: p°''(z)-7*^ 00 } = C - ^(oo).

One way a point can fail to be attracted to oo is to be attracted to some finite point or cycle of points. For example, p(z) ^ z^ - 1 has a cycle {0, -\}: p(0) = -1 , j7 ( - l ) = 0. Both 0 and - 1 are fixed points for p°^{z), and this 2-cycle for p(z) is attracting if its points are attracting as fixed points for /7°^(z). By the chain rule, either fixed point can be used to test attraction:

(/7°2y(0) = p'{p(0))'p'(0)=p'(-l)'p'(0)

= p'(0)'p'(-l)=p\p'{-l))'p\-l)

= (/?°')'(-l).

In fact, this is true in general. Say {zi, Z2, • • • , z„} is an n-cycle for p(z) if/?(zi) = Z2, p{z2) = Z3, • • • ,

Reprinted from Comput. & Graphics Vol 16, No. 1, pag. 35-40, 1992

Page 245: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

264 MICHAEL FRAME and JAMES ROBERTSON

p(z„-i) = z„, and p{z„) = Zi. The 2-cycle argument above can be rewritten directly to prove (e.g., [4], p. 78).

PROPOSITION 2.2. The n-cycle {zu Z2, - - - , z„} for p(z) is attracting if and only if

Upn'(z,)\\ \\p'iz„)'p\z„-i)' • P ' ( z i ) | | < l .

The product p'(z„)• p'{Zn-\) p'(zi) is called the multiplier of the «-cycle. The multipUer is a useful tool; for example, with it we can locate the centers of the discs and cardioids of the Mandelbrot set ([4], p. 86).

A surprising (and relatively difficult) theorem of Fa-tou and Julia is that for every polynomial, even those without attracting (finite) cycles, there are points not diverging to oo under iteration of p{z) that is, (e.g., [8], p. 60).

THEOREM 2.3. For every polynomial p{z), Kp is non­empty.

Fatou's and Julia's analysis of the structure of Kp is based on their showing that many aspects of the dy­namics of p(z) are determined by the orbits of the critical points of p{z)\

FATOU'S THEOREM. Every {finite) attracting cycle of p{z) has in its basin of attraction a critical point of /7(z).(e^., [4] ,p .79) .

Before discussing the complications arising from higher-order polynomials, we review a familiar ex­ample. The standard Mandelbrot set is constructed us­ing iterations of the quadratic polynomial Fdz) = z^ + c. Let Kc denote the fiUed-in Julia set for Fdz). For each c, Fdz) has only one critical point, 2 = 0, and so by Fatou's Theorem Fdz) can have at most one attracting cycle. The existence of an attracting cycle determines the structure on the Julia set Kc in this sense:

DICHOTOMY THEOREM (Fatou and Julia). The Julia set Kc is connected or is a Cantor set. Moreover, Kc is connected if and only if the orbit ofz = 0 is not attracted tooo.ie.g, [4], p. 80 and [5], pp. 313-314).

The Mandelbrot set is the set of those c for which Kc is connected. Since the Julia set of Fc(z) is either connected or a Cantor set, the Mandelbrot set is a nat­ural object to study. Of course, testing the connectivity of Kc for each c is not a reasonable way to draw a picture of the Mandelbrot set; instead we test the di­vergence of the orbit of z = 0 under iteration of Fdz).

For polynomials with more than one critical point, Julia sets admit a third kind of structure in addition to being connected or being Cantor sets. Again, the orbits of the critical points are the determining features, and Fatou and Julia proved ([ 2 ], p. 181).

TRICHOTOMY THEOREM. For any polynomial p(z)

(with n>:2), the Julia set Kp satisfies

1. Kp is connected if no critical point is attracted to oo, 2. Kp is a Cantor set if all critical points are attracted

to 00, and

3. Kp is disconnected, but not necessarily a Cantor set, if some critical points are attracted to oo and some are not.

There are several ways to extend the notion of Man­delbrot set to higher-order polynomials. We select one, not necessarily the most natural, but nevertheless al­lowing easy visualization. A more general extension is discussed in [ 3 ].

Let p{z) be a polynomial without constant term, i.e., p(0) = 0. We consider the family of polynomials Pd^) ^ p{z)-\- c. As we did with Fc{z), let Kc represent the fiUed-in Julia set for the polynomial pc{z), that is, Kc = {z: Pc"{z)-^ oo). Denoting by Zi, • • • , z„ the critical points of p{z), define the z,-Mandelbrot set of p(z) by

M ( z , ) = { c : / ? r ( ^ / ) ^ o o } .

By the Trichotomy Theorem, if c ^ M(zi) U • • • U M(z„) then under iteration of pdz) the orbit of no critical point stays bounded and so Kc is a Cantor set.

Fig. 1. The Mandelbrot sets M{0) (above) and M(-10/3) (below) for the cubic polynomial p{z). The points A = -2.3363 + 0.0475/, if = -0.4125 + 1.0687/, and C= 0.015 + 0.7837/ are the points at which the Julia sets of Figs. 3, 4,

and 5 are computed.

Page 246: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

A generalized Mandelbrot set 265

Fig. 4. The Julia set for -0.4125 -I- 1.0687 (6 in Fig. 1). The orbits of both critical points diverge to oo.

or where the orbits of different critical points converge to different cycles. We examine several examples of this behavior for the polynomials

1

Fig. 2. The Mandelbrot set M{p) (upper) and a magnification of its right central region (below).

p(z) = jz' + z\

and

9(z) = - z ' ' , . | , -

•r-(-l'>. On the other hand, if c E M(zi) D • • • fl M(z„) then the orbits of all critical points stay bounded and so Kc is connected. As our generalization of the (quadratic) Mandelbrot set we shall take the set of all c for which Kc is connected—that is, the Mandelbrot set for the family of polynomials/7c( 2) is

M(/7) = M(z i )n- • -OMCzJ.

Structures unlike any exhibited by Julia sets of z^ + c can be seen for polynomials where the orbits of some critical points remain bounded while others diverge.

and we use the location of c in the M(z,) to deduce a rough understanding of the symmetry features of the Julia set Kr.

3. A CUBIC EXAMPLE

The polynomial p(z) has derivative p'(z) = fz^ + 2z, hence critical points Zi = 0 and Z2 = —10/3. Figure 1 shows M(0) and M(-lO/3) , together with the three c-values at which Julia sets are shown in Figs. 3, 4, and 5. Figure 2 shows M(p) in black, along with a magnification of the right central region. The colors outside the set are assigned by the average escape rate

Fig. 3. The Julia set for -2.3363 + 0.0425/ (A in Fig. 1). The orbits of both critical points converge to a 4-cycle.

Fig. 5. The Julia set for 0.015 -K 0.7837/ (C in Fig. 1). The orbit of 0 converges to a 3-cycle, while the orbit of -10/3

diverges to oo.

Page 247: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

266 MICHAEL FRAME and JAMES ROBERTSON

for the two critical points. Notice how the color pattern is similar to the contours of M(0) and Af(-10/3).

Figure 3 shows the Julia set for c = -2.3363 + 0.0425/. The orbits of both critical points converge to a 4-cycle, as can be understood from Figure 1 by noting this value of c lies in 4-cycle components of both M(Q) and M(-10 /3 ) . In fact, both orbits con­verge to the same 4-cycle:

-1.97211 +0.0189657/, 0.0189961 +0.0119508/

-2.33608 + 0.0429563/, 0.57199 - 0.01756/

though with a phase difference of two {i.e., the 200-th term of the orbit of 0 is -1.97211 + 0.0189657/ while the 200-th term of the orbit of -10 /3 is 0.57199 - 0.01756/). This Julia set looks connected, and from case (1) of the Trichotomy Theorem we see this is the case.

Figure 4 shows the Julia set for c = -0.4125 + 1.0687/. Here the orbits of both critical points di­verge to 00, and the Julia set is a Cantor set. In Figure 1 we see this c is outside both M(0) and M(-10 /3 ) .

For Fig. 5 we take c = 0.015 + 0.7837/. Again re­ferring to Fig. 1 we see this c lies outside of M(-10/3) but in a 3-cycle component of M(0), so not surprisingly the orbit of 0 converges to a 3-cycle and the orbit of - 1 0 / 3 diverges to oo. This falls in case (3) of the Tri­chotomy Theorem, and indeed the Julia set is not a Cantor set but consists of infinitely many islands, each of which is similar in appearance to the well-known "Douady rabbit" Julia set of z^ - 0.122 + 0.745/. The 3-cycle to which the orbit of 0 converges is reflected in the three-fold branching symmetry of each island.

4. A QUARTIC EXAMPLE

The polynomial q(z) has derivative q'{z) •• (1 + (2/5)/)z2 + (1 + (2/5)/) = (z + l ) . ( z - l ) - (z - ( 1 + (2/5)/)), hence critical points Zj = - 1 , Z2 = 1, and Z3 = 1 + (2/5)/ . Figure 6 shows M ( - l ) , A/(l), and M{1 + (2/5)/) , together with the five c-values whose Julia sets are given in Figs. 8-12. Figure 7 shows the Mandelbrot set M(g). As with the cubic JuHa sets, any cyclic behavior to which the orbit of z, converges can be read from the component of Af(z/) to which the c-value belongs.

Figure 8 shows the Julia set for c = 1.1935 + 0.3565/. The orbits of all three critical points converge to the 3-cycle

1.48879 + 1.00252/ 0.965602 + 0.542445/

1.61555+0.636692/,

with the orbits of 1 and 1 + (2 / 5) / converging in phase, and the orbit of 1 lagging behind by one step. Notice that every branch point has three-fold symmetry. Since the orbits of all three critical points are bounded, this c belongs to Af(^). y

Figure 9 shows the Julia set for c = 0.465/. Here the orbit of - 1 converges to the fixed point.

Fig. 6. The Mandelbrot sets Af(-1) (top), A/( 1) (middle), and M{~\ + (2/5)/) (bottom) for the quartic polynomial q(z). The points A = -0.1395 + 0.527/, B = 0.465/, C = 0.1395 + 0.744/, D = 1.1935 + 0.3565/, and E = 1.2245 - 0.6355/ are the points at which the Julia sets of Figs. 12, 9,

11,8, and 10 are computed.

-0.994918 + 0.197039/

while the orbits of 1 and 1 + (2/5)/ converge to the 4-cycle

0.802156 + 0.42222/, 0.409652 + 0.768738/,

0.469522 + 1.05952/, 0.880189 + 1.12601/.

Observe that the largest features on only the right side of the Julia set exhibit four-fold branching. Again, this c belongs to A/(^).

Figure 10 shows the Julia set for c = 1.2245 - 0.6355/. The orbit of - 1 diverges to oo, while the orbits of 1 and 1 + (2/5)/ converge to a 3-cycle. As in Fig. 5, the JuHa set consists of infinitely many islands, each with a 3-fold branching structure.

Figure 11 shows the Julia set for c = 0.1395 + 0.7440/. As with the previous example, the orbit of - 1 diverges and the orbits of the other two critical points converge to a 3-cycle. Again the JuUa set consists

Page 248: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

A generalized Mandelbrot set 267

Fig. 7. The Mandelbrot set M{g).

Fig. 8. The Julia set for 1.1935 + 0.3565/ (D in Fig. 6). The orbits of all three critical points converge to a 3-cycle.

Fig. 9. The Julia set for 0.465/ (B in Fig. 6). The orbit of -1 converges to a fixed point, while the orbits of the other critical

points converge to a 4-cycle.

of infinitely many islands, each with a 3-fold branching structure. The most obvious difference between this and the previous example can be seen in the spiral patterns in Fig. 11.

Figure 12 shows the Julia set for c = -0.1395 + 0.527/. Here the orbits of 1 and 1 + (2/5)/ diverge, while the orbit — 1 converges to a fixed point.

Comparing Figs. 10-12 suggests some interesting behavior. In Figs. 10 and 11 the orbits of 1 and 1 + (2/ 5)/ converge to 3-cycles, while the orbit of - 1 does not. The largest features on the right side ofKc (near 1 and 1 + (2/5)/) exhibit a three-fold branching sym-

Fig. 10. The Julia set for 1.2245 - 0.6355/ (E in Fig. 6). The orbit of -1 diverges to oo, while the orbits of the other critical

points converge to a 3-cycle.

Fig. ll.TheJuliasetfor0.1395 +0.7440/(CinFig.6).The orbit of -1 diverges to oo, while the orbits of the other critical

points converge to a 3-cycle.

Fig. 12. The Julia set for-0.1395 -l-0.527/(AinFig.6).The orbit of-1 converges to a fixed point, while the orbits of the

other critical points diverge to oo.

metry, while the largest features on the left side of Ac (near - 1 ) are chains of islands. In Fig. 12 the largest features on the right are chains of islands, while the largest feature on the left is the major island of i :. In Figs. 10 and 11 the orbits of 1 and 1 +(2/5)/converge to 3-cycles, while the orbit of - 1 diverges to oo; in Fig. 12 the orbits of 1 and 1 + (2/5)/ diverge to oo while the orbit of - 1 converges to a fixed point. We are lead

Page 249: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

268 MICHAEL FRAME and JAMES ROBERTSON

to conjecture that for polynomials with more than one critical point, the structure of the Julia set near a critical point is dominated by the behavior of that critical point. Figure 9 provides additional support for this (admit­tedly vague) conjecture. A proper formulation will use the theory of polynomial-like maps [7] and is still evolving.

5. CONCLUSION For polynomials pdz) with more than one critical

point (and parameterized by a single additive constant (c) , the local structure of the Julia set Kc seems to be determined by the orbit of the critical point "nearest" to c. This can be visualized by plotting the Mandelbrot set for each critical point z, (the c' for which the orbit p°"(Zi) does not diverge to oo) and analyzing the structure of this set near c. If for a given c critical points exhibit different asymptotic behavior, then the branching symmetries and patterns of islands can be knitted together in complicated ways. In the case where the orbits of some critical points diverge and others converge, this knitting can be analyzed using kneading theory. For cubic polynomials this is treated in [ 2 ] ; in a later paper we shall investigate the case that different critical points have different kneading sequences.

REFERENCES 1. P. Blanchard, Complex analytic dynamics. Bull. Amer.

Math.Soc. 11,85-141 (1984). 2. P. Blanchard, Disconnected Julia sets. In Chaotic Dy­

namics and Fractals, M. F. Bamsley and S. G. Demko (Eds.), Academic Press, Orlando, FL, 181-201 (1986).

3. B. Branner, The parameter space for complex cubic poly­nomials. In Chaotic Dynamics and Fractals, M. F. Bamsley and S. G. Demko (Eds.), Academic Press, Or­lando, FL, 169-179(1986).

4. B. Branner, The Mandelbrot sets. In Chaos and Fractals: The Mathematics Behind the Computer Graphics, R. L. Devaney, L. Keen (Eds.), American Mathematical So­ciety, Providence, RI, 75-105 (1989).

5. R. L. Devaney, An Introduction to Chaotic Dynamical Systems, 2nd Ed., Addison Wesley, Menlo Park, CA (1989).

6. A. K. Dewdney, Computer recreations. Sci. Amer. 253, 16-21, 24 (August, 1985).

7. A. Douady and J. H. Hubbard, On the dynamics of poly­nomial-like mappings. Ann. Sclent. Ec. Norm. Sup. 18, 287-343(1985).

8. L. Keen, Julia sets. In Chaos and Fractals: the Mathe­matics Behind the Computer Graphics, R. L. Devaney, L. Keen (Eds.), American Mathematical Society, Prov­idence, RI, 57-74 (1989).

9. B. B. Mandelbrot, The Fractal Geometry of Nature, Free­man, New York (1982).

10. H-O Peitgen and P. R. Richter, The Beauty of Fractals, Springer-Verlag, New York (1986).

11. H-O Peitgen and D. Saupe (Eds.), The Science of Fractal Images, Springer-Verlag, New York (1989).

APPENDIX Multiple critical point pseudocode

This pseudocode describes our program for drawing the generalized Mandelbrot set for the polynomial/(z). For the cubic example/(z) = \z^ + z , we have Re{f{x + yi)) = x^

3xy^ / — and Im{f{x + yi)) -• 2xy +

3x^y Z3

The analogous formula must be derived for the quartic ex­

ample. Coordinates of the critical points are entered in the array cy. The drawing window is taken to occupy -2 < c <2,-2<d<2.

/i_screen_size is the horizontal extent (in pixels) of the draw­ing window

u_screen_size is the vertical extent (in pixels) of the drawing window

Mandelbrot pseudocode

type

cy = array [0..19,0..1] of real; (This is used to hold all critical points used for the given formula. The 0 part of this array holds the real part of the critical point, and the 1 part holds the imaginary part of the critical point.)

for /: = 1 to /z_screen_size do for 7: = 1 to u__screen_size do begin

c: = -2 + //round(/i_screen_size/4); d: = -2 +j/ round (i;_screen_size / 4); for critical: = 1 to number_of_critical_points do begin

x: = cy [ critical,0 ]; {real critical point} > = cy [ critical, 1 ]; {imaginary critical point} for count: = 1 to maxdwell do

if not test—distance (x, y) then begin; {This function tests to see if

(x*x + y*y)> escape_radius*escape_radius} newx: = Re(/(x + yi) + c\ newy: = Im(/(x + yi)) -I- d\ x". = newx, y. = newy; color: = count;

end; temp—color: = temp_color + color;

end; temp_color: = (round (temp_color/number

_of_critical_points)); {taking average of total color}

plot (/•, 7, temp—color); {Places a pixel in the (i,j) spot on the screen in color

of temp_color} temp_color: = 0;

end; end;

Julia pseudocode

for /: = 1 to /i_screen_size do for 7: = 1 to u_screen_size do begin

x: = -2 + //round (/z_screen_size/4); y: = -2 +7/round(t;_screen_size/4);

for count: = 1 to maxdwell do if not test—distance (jc, y) then begin; {This function

tests to see if (x*x + y*y)> escape_radius*escape_radius}

newjc: = Re{f{x + yi) + c; new y. = Im{f{x-\- yi)) + d; x: = newx; y. = newy; color: = count;

end; temp_color: = temp_color + color;

end; temp_color: = (round (temp_color/number

_of_critical_points)); {taking average of total color}

plot (/, 7, temp—color); {Places a pixel in the (ij) spot on the screen in color

often^p—color} temp_color := 0;

end; end;

Page 250: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 269

Chaos and Graphics

A NEW SCALING ALONG THE SPIKE OF THE MANDELBROT SET

MICHAEL FRAME,' A. G. DAVIS PHILIP^ and ADAM ROBUCCI^ 'Mathematics Department, Physics Department and Computer Science Department Union College,

Schenectady, NY 12308

Abstract—Using the zeros of a family of real polynomials, we locate a sequence of midgets along the spike of the Mandelbrot set. By this method we can readily find midgets (tiny copies of the Mandelbrot set) of high cycle number; we include a picture of a 200-cycle midget magnified by a factor of 5.68 X 10 *. The ratios of distances between the cardioid centers for successive midgets in this sequence exhibit an asymptotic scaling, as does the ratio of head-to-center distances. We present evidence supporting a pattern of scalings for some "generalized Mandelbrot sets."

1. INTRODUCTION

The Mandelbrot set, M, is the collection of complex numbers c for which the Julia set Jc of Fdz) = z^ + c is connected. From classical theorems of Fatou and Julia {e.g., Theorem 2, p. 80 of [1]) we know that Jc is either connected or a Cantor set, and that Jc is con­nected if and only if the sequence

0, F,(0), FciFciO)) = F°2(0), F!HO), (M)

remains bounded. (By the theorems of Fatou and Julia, the orbit of the critical point of Fc(z) determines the structure of Jc. For Fc(z) the critical point is z = 0, hence the sequence (M) starts with z = 0.) Being the set of c values for which the Julia sets exhibit one of their two possible kinds of connectivity structure, the Mandelbrot set is a natural object to study. Moreover, the boundary of M, denoted dM, can be thought of as the "bifurcation" set for the Jc—the set on which the structure of Jc changes—so we would expect it to be geometrically interesting. Presumably no one, not even Mandelbrot, expected dM to be as fascinating as it is. There appears to be a limitless variety of features re­vealed as we probe ever more closely to dM. Indeed, investigating dM has used thousands of hours of CPU time on the full spectrum of machines from the hum­blest of PCs to supercomputers. Looking more deeply into dM captures, in part, the spirit of the explorer, wondering what lies over the next hill. Some (but not all!) of the authors of this paper are in danger of being lost forever in these regions.

Part of the allure of this intricacy of dAf lies in Man­delbrot's discovery that a cloud of infinitely many tiny copies of M(commonly called midgets) surround dM. In fact, these midgets are dense in dM: Every neigh­borhood of every point of dM contains infinitely many midgets (see 9.2, p. 100 of [1]). The midgets are not exact shrunken copies of Af; all have patterns of dec­orations reflecting the location of the midget relative to the large features of M, and some midgets are sig­nificantly distorted. Nevertheless, these midgets man­ifest the self-similar nature of the Mandelbrot set. There are many sequences of midgets, related through scalings of size. In Section 2, we review some of the known

sequences; in Section 4 we report on a new scaling of midgets, discovered along the real axis, progressing to­ward c = - 2 .

Before discussing scalings, we review some of the main features and properties of the Mandelbrot set. (See [1] for more details). One way the sequence (M) can remain bounded is by converging to an «-cycle. For each n^ 1, the set of c-values for which (M) con­verges to an «-cycle is an open set, the connected com­ponents of which are called hyperbolic «-cycle com­ponents. These can be described analytically through the stability of the «-cycle, determined by the deriva­tive: If PFis a hyperbolic «-cycle component, then for each cGW

P ^ ^ ( c ) - ~ ( F r ) | z . = 2" Zn' Z„-r Zl'Zl

satisfies ||pW^(c)|| < 1, where the «-cycle is {zi, Z2, . . . , z„}. (The first equality results from an «-cycle's being a fixed point for the «-fold composition F?" of Fciz), the second from the chain rule.) Douady and Hubbard [ 5 ] show p w is SL conformal isomorphism, and so W contains a unique point c, the center of W, for which piv(c) - 0. Centers are also called superstable points; observe that c is superstable if and only if the critical point c = 0 belongs to the «-cycle. For the quadratic polynomial z^ + c, hyperbolic components are either cardioids or discs. Every «-cycle cardioid has infinitely many disc components tangent to it, one 2n-disc, two 3«-discs, two 4«-discs, four 5«-discs,... (de­tails in [1]). By the head of an «-cycle cardioid we mean the unique 2«-cycle disc tangent to the cardioid. Figure 1 illustrates the main cardioid and its head (the 2-cycle component), 3-cycle components, and several midgets.

2. REVIEW OF SOME SCALINGS

Recall the bifurcation sequence of the logistic func­tion Lr(x) = r • x • (1 — Jc) for A: in the interval [0, 1]. As long as 0 : r : 4, if JC E [0, 1] then Lr(x) E [0, 1] and so the logistic function can be used to generate a sequence of points in [0, 1]:

Reprinted from Comput. & Graphics Vol. 16, No. 2, pag. 223-234, 1992

Page 251: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

270 M. FRAME, A. G. D. PHILIP, and A. RoBUcri

r 7 / 4. \ /

* V/

2-cycledisc / 1 ^ 7 * ' -h»adofth»'^ ' ^ main cardioid

^

- ? JT

^ ^ n M l i n

3-cycl* " " d i s c

3-cycl* disc

Fig. 1. The Mandelbrot set, with the main cardioid, 2-cycle disc, and 3-cycle discs labeled, and with three midgets mag­nified. The magnifications along the spike do not illustrate

the sequence reported in this paper.

X2 = LriXi), Xi = Lr{X2), (L)

(The critical point for Lr(x) is {, which is why the sequence (L) starts with i ) . The character of this se­quence depends upon the value of r. For 0 r 3, (L) converges to a fixed point, while at r = 3 the fixed point disappears (actually, becomes unstable, hence numerically invisible) and a 2-cycle arises. The change from fixed point to 2-cycle is a period-doubling bifur­cation, so we say the first bifurcation value is ri = 3. The sequence (L) converges to a 2-cycle for ri < r < r2 = 3.449490, to a 4-cycle for r2<r<r^^ 3.544090, to an 8-cycle for r^ < r < r4 = 3.564407, to a 16-cycle for r4 < r < rs = 3.568759, . . . ; this sequence of r„ values accumulates at r^ = 3.5699456. In the late 1970s Feigenbaum[8] discovered that the ratios of the dis­tances between successive period-doubling bifurcations converges to

8 = lim„-H r„-i

fn+l ~ fn = 4.669201609 . . . ,

and produced arguments supporting his claim that this limit is universal over a large class of functions. A rig­orous proof of this conjecture was provided by Lan-ford[l 1]. For r> r^ the behavior of (L) is very com­plicated. There is a set of r-values of positive measure on which (L) is chaotic[10], while woven in among these chaotic regions are "windows" of periodicity, each with its own period-doubling cascade. The largest of these periodic windows corresponds to a 3-cycle arising at r = 3.828427. This is the only 3-cycle window; there is only one 4-cycle window, there are three 5-cycle windows, Milnor (pp. 230-231 of [14]) gives a method for determining the number of «-cycle win­dows for each « 3, and the ordering in which these periodic windows occur was analyzed by [13]. The dynamics of maps of the interval is a very active area of study, the modem efforts, perhaps beginning with the Ulam's and von Neumann's [20] use of L4 as a

random number generator, and including the work of Misiurewicz[16], Sarkovskii[19], Collet and Eck-mann [ 2 ] , and Milnor and Thurston [15].

These observations are relevant to our study of Mandelbrot midgets centered along the real axis be­cause the linear transformation JC = ( — l/r)«z + ( i ) conjugates Fdz) to Lrjx) with the correspondence of parameters r = 1 + Vl - 4c. It follows that the Fei-genbaum scaling is reflected in the features of the Mandelbrot set along the real axis, in particular, the sequence of period-doubling bifurcations at ri = 3, r2 = 3.449490,... mentioned above corresponds to the points of tangency of the 2-cycle disc to the main car­dioid, of the 4-cycle disc to the 2-cycle disc, and so on. Moreover, the periodic windows for Lr(x) correspond to the hyperbolic components of midgets centered along the real axis.

Each midget along the real axis exhibits its own se­quence of period-doublings, though here, the main cardioids of the midgets correspond to w-cycles rather than fixed points. Attached to the left of an «-cycle cardioid is a sequence of increasingly smaller disc components, first a 2«-cycle disc, then a 4/2-cycle disc, followed by an 8«-cycle disc, and so on. For example, the main cardioid for the largest midget is a 3-cycle component; attached to the left of this cardioid is a 6-cycle disc, attached to the left of that is a 12-cycle disc, etc. Computing the Feigenbaum constant 6 for any of these sequences of period-doublings yields 6 = 4.669201609. . . .

Using a construction of Douady and Hubbard[5], recently Milnor[14] has applied these ideas to other sequences of scalings along the real axis, and to scaling off the real axis. (Milnor's work extends [3], [6], [7], and [9].) For each superstable point c, Douady and Hubbard show there is a topological embedding of M into a subset of itself, taking 0 to c. Denote by WQ the main cardioid of Af, and say Wc is the hyperbolic com­ponent with center the superstable point c. Then the Douady-Hubbard function sending 0 to c sends WQ to Wc. The most obvious example of these functions is the map from Af to the 3-cycle midget, carrying 0 (the center of WQ) to -1.754878 (the center of the main cardioid of this midget). Another example carries 0 to - 1 , the center of the 2-cycle disc, and consequently carries WQ to the 2-cycle disc W-i. This function takes the 3-cycle discs attached (above and below) to WQ to the 6-cycle discs attached toW-i, the 4-cycle discs at­tached to Wo to the 8-cycle discs attached toW.i, and similarly for other correspondences. By sending the entire Mandelbrot set to its pieces, the Douady-Hub­bard functions act to express the self-similarity of the Mandelbrot set, though to be sure, the existence of distorted midgets guarantees these need not be linear self-similarities.

Milnor's generalization of the Feigenbaum sequence is illustrated by the following example. Let C\ = -.122561 -f .744862i denote the center of the upper 3-cycIe disc, Wd, attached to the main cardioid WQ, Let T denote the Douady-Hubbard function taking Wo to Wci. Being the image of a 3-cycle disc now at-

Page 252: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Scaling along the spike of the Mandelbrot set 271

tached to a 3-cycle disc, T(Wci)isa 9-cycle disc. Sim­ilarly, T^'^iWci) is a 27-cycle disc, T°\Wci) is an 81-cycle disc, and so on. Figure 2 illustrates this sequence. Let C2 denote the center of T{Wci), Ci the center of T^^{Wc\), . • . , and form the sequence of complex numbers (C2 - c,)/(C3 ~ C2), (C3 - C2)/(C4 - C3), ( Q " C3)/(C5 - C4), Milnor (and also [9] and [3]) argues that this sequence converges in the same way as the original Feigenbaum sequence (geometrically); in this example to the limit 4.6002246 + 8.98122591. This suggests that the Mandelbrot set exhibits many types of scaling.

More complicated sequences can be used. Let Wc and Wd denote a 3-cycle and a 7-cycle disc attached to the main cardioid, and let Tx and T^ denote the Douady-Hubbard functions taking the main cardioid to Wc and to Wa. Now consider the sequence of discs generated by alternately applying these functions. That is, again denoting by WQ the main cardioid, TX{WQ) is a 3-cycle disc (in fact, W^) attached to WQ, TX(T2{WQ)) is a 21-cycle disc attached to r,(H^o), TX{T2{TX{WQ))) is a 63-cycle disc attached to r i ( 72(^^0)), and so on. The centers of these hyperbolic components converge to another Feigenbaum-like limit, and Milnor conjec­tures that any infinite sequence of these functions, whether or not produced by iterating a finite string like T\T2, gives rise to a generalized Feigenbaum limit.

In this paper, the sequence of midgets we located is simply the left-most«-cycle midget along the real axis. That is, we found the left-most 3-cycle midget (there

is only one 3-cycle midget), the left-most 4-cycle midget, the left-most 5-cycle midget, the left-most 6-cycle midget, and so on. Plotting the log of the head-to-center distance against the cycle number of the midget cardioid yields a remarkably straight line over many, many orders, and so it appears this sequence of midgets represents another kind of scaling in the Man­delbrot set.

To see this is different from the Milnor scalings, let ^3, Q, C5, C6 , . . . , denote the centers of the main car-dioids of the sequence of midgets we generate. That is, Cn is the center of the main cardioid of the left-most «-cycle midget along the spike. Since the Milnor scheme of generalized Feigenbaum points is con­structed by successive applications of Douady-Hubbard functions, the second point corresponding to the se­quence C3, C4, C5, C6, . . . , would not be the center of the left-most 4-cycle cardioid along the spike, but rather the image of that point under the function taking the whole Mandelbrot set to the 3-cycle midget. In partic­ular, the second point would be a superstable 12-cycle, the third a superstable 60-cycle, and so on. For all of the Milnor sequences, the periods of the points are multiples of the periods of the previous periods; for our sequence, the periods go up by 1.

3. ELEMENTARY PROPERTIES OF SOME POLYNOMIALS

As we observed, the centers of the n-cycle hyperbolic components along the spike can be found by locating

1 ^ .-

II T(\U \-r\Kl

T * » ( W e ^ ^ _ _

H H J ^ H H I H H I H B s . i^HHEF^^

IP^HBpW^HKSi^'™ nWlWnlBl&iSn

[f!^T^yfH|BE8iM|lffl?t ^

^_^„*Kii iKg*^ ^^bjbt '*'

ri

^ B » ^

^ it

_ ^ i

* ' i*. 1

Yi^Jj»^ f 1

- j iL^^9H^EL* j^- jy

Wr I t jftl* '^^s^ip' 1

i / r cwc.) I X 1

Fig. 2. A hierarchy of hyperbolic components, under repeated application of the Douady-Hubbard map taking the main cardioid to the upper 3-cycle disc. The centers of the components are marked with crosses.

Page 253: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

272 M. FRAME, A. G. D. PHILIP, and A. ROBUCCI

the real solutions of 0 = F?"(0) = F?"-\c). In this section, we derive some elementary properties of a family of polynomials and use these properties to es­tablish the correctness of our Cycle Finder program for locating centers. In particular, we study polyno­mials, with which we can locate the left-most «-cycle midget for each « ^ 3 along the spike of the Mandelbrot set, and locate the center of the head of these midgets. To avoid a multitude of compositions, we introduce the following notation:

Definition J: Define fi(c) by/Kc) = c, and for « ^ 2 define/„(c) by/„(c) = (f^-dc))' + c.

That is, F?"{0) = f„(c). Recall for c and z real, the bifurcation diagram for the quadratic function Fc(z) is obtained by plotting for - 2 ^ c : | the eventual orbit { F r ( 0 ) , F r ^ ' ( O ) , . . . , Fr^'CO)} = {/„(c), f„+i{c),... ,f„+mic)} for large n and m. Even though it is the eventual orbit of the critical point that we plot, the initial orbit provides a sequence of "envelopes" delineating the major features of the bifurcation dia­gram. The top left of Fig. 3 shows a "weighted" bifur­cation diagram, only plotting a pixel after it has been visited some fixed number of times by orbit points. (This weighting emphasizes the main features of the diagram.) The bottom left superimposes the orbits {Fc°2(0), . . . , F,°'(0)}, while the right graphs/2(c) (top) through flic), at \ scale of the left. Since Fc"iO) = fn(c) we see the initial orbits are just the graphs of the corresponding polynomials, so the f„{c) give analytic expressions for the envelopes. For ex­ample, the main "band-merging" point, or 2 to 1 re­verse bifurcation, is a Misiurewicz (eventually periodic, but not periodic) point of the diagram, and is a point

Fig. 3. Top: a "weighted" bifurcation diagram for Fdz), c and z real, with c along the horizontal axis, -2 ^ c ^ - i, and z along the vertical axis, -2 ^ z ^ 2. A pixel is plotted only when at least a minimum number of orbit points land in the pixel. Bottom: superimposing on the bifurcation diagram the graphs of^(c) , . . . , /7(c), at the same scale as the top. Note: many arcs trace out features of the top picture. In top and bottom, the main "band merging" point is marked by a star. Right: individual graphs (reduced scale) offiic),...,

Mc).

of intersection of the f„(c). This point is marked with a star in the top and bottom diagrams.

This sequence of functions/,(c), each mapping the parameter plane to itself, provides a simple tool for locating the centers of the hyperbolic components. Now we restrict our attention to locating for each « ^ 3 the left-most «-cycle midget along the real axis.

Definition 2: For each n^3 denote by c„ the left-most zero along the real axis off„(c). That is, f„(c„) = 0 and for any real number c,f„(c) = 0 implies c„ <. c.

We begin with some elementary observations about the behavior of the functions/, (c) for c real. With these results we establish the correctness of our method for locating midgets along the spike. Part of the motivation for providing the details of these arguments is peda­gogic, illustrating that students can be shown rigorous yet elementary derivations of some properties of the Mandelbrot set.

Proposition 1: For each « ^ 3 we have

(1) - 2 < c „ , (2) c„+, < c„, (3) forc<c„,/J(c)>0,and (4) forc^c„, / ; (c )<0.

Proof: For the first, a simple inductive argument on n shows/,(c) ^ I c\ when c ^ - 2 , since c + c 2t \c\ for c ^ -2, Consequently, no zero off„(c) can occur 2Xc^ - 2 .

For the second, observe that c = 0 is the right-most zero of each/«(c), so c , < 0. Then/„+,(c„) = (f„(c„))'^ •\- c„ = c„ < 0, and since we know for c sufficiently negative/,+1(c) is positive (for « ^ 3,/,(c) ^ | c| if c ^ -2),f„+i(c) must have at least one zero between - 2 and c„. It follows that c„+i lies between - 2 and c„.

The third and fourth also follow by induction. To begin, observe that for c < Ci,fy(c) > 0, /3 (c ) < 0, and /3 (c ) > 0. k\so,f„(c) > 0 for c < c« since c„ is the left-most zero of f„(c). For the third, suppose /J (c ) > 0 for c < c„. Then for c < c„+i < c„, we see

+ cY 2'{fn(c)y fUi(c) = ((/„(c))2 2 - / „ ( c ) . / ; ( c ) > 0 .

For the fourth, suppose for induction that c < Cn implies f'„(c) < 0. Then (f^ic^Y = 2 . /„(c) . / ; (c) , which is negative for c < c„. Now f'„+\(c) = 2« / . ( c ) - / ; ( c ) + 1 =(/„(c)2)'+ l , and( / , ( c )Y = 2-(fn(c))^ + 2'f„{c)'f'„(€), which is positive for c < c„, and so{f„{cY)'is monotone increasing for c<c„. Consequently, there is at most one c < c„ for which {fnic)^Y = - 1 • That is,^+i (c) has at most one critical point less than c„, and this critical point certainly is a local minimum. It follows that f'„+i(c)<0 for c less than this critical point, hence for c < c„+i. D

Proposition 2: Starting with initial guesses - 2 - c and —2, e a small positive number, the secant method ap­plied to f„(c) produces a sequence of points converging toc„.

Proof: The concavity condition (3) guarantees that the tangent lines at the guesses (-2 - e,f„(-2 - e)) and

Page 254: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Scaling along the spike of the Mandelbrot set 273

(-2, / , ( - 2 ) ) intersect the c-axis at points di and d2 to the left of c„. In addition, by concavity we know the secant line through the two guesses intersects the c-axis at a point ei between di and d2. This point d is the first in the sequence converging to c„.

In the secant method, this procedure is repeated us­ing (-2,/ ,(~2)) and (ei ,f„(ei)) as guesses. (Our Cycle Finder program obtains/,(^i) by iterating /v(z) n times, using c = ei and starting with z = 0.) As before, the new point 2 lies between Ci and c„, and since /«(C/i) < 0, we see the sequence { 1, ^2, • • •} converges to c„. D

Our Cycle Finder program uses the secant method and initial guesses - 2 - c and - 2 , so Proposition 2 assures us the Cycle Finder will produce a sequence of ever more refined guesses, converging to c„. In practice, the iteration stops when the difference between the old and new guesses is less than the user-defined accuracy bound e. The final value output by the program is an approximation of a root of the equation/,(c) = 0 and corresponds to the left-most superstable «-cycle along the spike of the Mandelbrot set.

In addition to locating the centers of the cardioids of our sequence of midgets, we want the centers of their heads. The next proposition allows us to modify our scheme for finding centers of cardioids to also find centers of heads.

Proposition 3:

(1) iff„{c) = 0, then fk„(c) = 0 for any positive integer k.

(2) if/,(co) = 0, then ~ / . ( c ) | Co = ~/2„(c)| Co.

Proof: Observe (1) follows by writing

F?^"(0) = F?"(F?"(... F!"(F?"(0)) • • • ) ) ,

A: copies of F®".

For (2), first note

^ / 2 n ( c ) k o = ~ ( ( / 2 „ - , ( c ) ) 2 + c ) k o

= 2/2„-, (Co).(^( /2.- , (c)) |Co)+ 1 = . . .

= 2/2„-.(Co)-(2/2„-2(Co).(...-(2/„^,(Co)-(2/„(Co)

x ( £ ( / „ ( c ) ) | c o ) + l ) + l ) . . . + l ) + l

Since f„(co) = 0, the middle factor 2/,+,(co)

'(2Mco)4£ (f„(c))\co) + l ) + l reduces to

2f„+i(Co) + 1 and so -j-finic) I Co becomes ac

2/2„-,(Co)-(2/2.-2(Co)

X( . . . . (2 /„+ , (Co)+ l ) . . .+ l ) + l .

Now/„(co) = 0 implies/„+, (Co) = (/„(co))^ + cb = Co = yi(co). Similarly,/„+2(co) ^fiico),... Jin-iico) = fn-i(co) from which we see

d Y^f2n(c)\Co = 2/„_,(Co)-(2/„_2(Co)

X ( . . . . ( 2 / , ( c o ) + l ) . . . + l ) + l . (1)

Now compute — f„(c)\ Co, obtaining ac

2/,-,(Co)-(2/„_2(Co)-(...-(2/,(co)

x(£( / , (c ) )ko)+ l )+ l ) . . .+ l ) + l (2)

Since T fi(c) = 1 (recall/i(c) = c), (2) reduces to dc

2f„.dCo)'(2f„.2{co)

X ( . . . - ( 2 y ; ( c o ) + l ) + l ) . . . + l ) + l .

Comparing this with (1) we see

j/2n(c)\Co = £Mc)\Co. D

The left side of the top of Fig. 4 shows the graph of f3{c), the right side, the graph off(,(c). The zero at c = 0 corresponds to the center of the main cardioid, both graphs cross the axis there because, of course, a fixed point is also a 3-cycle and a 6-cycle. The other zero of the (c) graph is the center of the 3-cycle car­dioid. The zeros of the fe(c) graph correspond to the centers of the main cardioid, 3-cycle and 6-cycle car­dioids, and to the 6-cycle period-doubled disc off the 3-cycle cardioid. The right side of the bottom of Fig. 4 superimposes these two graphs, and the left side magnifies the picture around the 3-cycle cardioid center and its period-doubled 6-cycle disc. The shapes revealed in this magnification provide the key for our approach. From this, to find the period-doubling 2n-cycle center simply decrease c (with a step-size chosen using the standardization described in Section 5) until ^;,(c) changes sign from positive to negative. We resort to this approach for finding the center of our «-cycle midget head since in general there will be many real solutions of^(c) = 0 to the left of the w-cyde midget's cardioid center.

4. NEW SCALINGS

Since f„(c) = 0 is a polynomial equation of degree 2''"\ we must be careful when searching for centers of even modest cycle number, n. To approach this problem of accuracy, our Cycle Finder program, writ­ten in Turbo C, manipulates numbers as strings. This gives us effectively unlimited precision; typically com­putations were carried to many more places than we report here, and we verified many of the centers by generating pictures at these locations and observing midgets there. Unlike the scaling sequences reviewed

Page 255: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

274 M. FRAME, A. G. D. PHILIP, and A. ROBUCCI

Fig. 4. Top: the graph offiic) on the left; the graph off(,(c) on the right. Bottom: the right side superimposes the two graphs of Fig. 3; the left side magnifies the this picture around the 3-cycle cardioid center and its

period-doubled 6-cycle disc.

in Section two, we investigated a sequence that was not a manifestation of the self-similarity of the Man­delbrot set, but rather identifies "geographically simi­lar" features, here the left-most «-cycle midget along the spike, for each « ^ 3.

In this section, we present some new scaling data which appeared during our investigation of this se­quence of midgets. Recalling from Definition 2 that c„ denotes the center of the left-most«-cycle midget car­dioid, Table 1 presents the values of the ratio

c„ - c„+i

Cn + \ - Cn^l

for « = 3, . . . , 101. The limit of the ratio appears to be 4, and in Section 6 we present an argument sup­porting this.

The top of Fig. 5 shows the graph of ln(c„+i - c„) as a function of «. Linear regression gives the relation

ln(c„+i - Cn) = -1.386 • n + 2.412 (3)

with correlation coefficient 1.000, hardly a surprise considering the straightness of the graph.

Letting hn denote the location of the center of the head of the «-cycle midget head. Table 2 gives the ratio of head-to-center distances

for « = 3, . . . , 101, and the bottom of Fig. 5 shows the graph of ln(c„ - /2„) as a function of «.

5. TINY MIDGETS

Figures 6 and 7 show the 85- and 200-cycle midgets in this series. (These pictures were printed on an HP LaserJet using the program Pizzaz Plus by Applications Technologies, Inc.) The first picture of the 175-cycle midget appeared in [17], so the 200-cycle now su­persedes this as the smallest midget pictured along the spike, as far as we know. Throughout this project, we have generated pictures of midgets 3 through 86, 95 through 125 by 5s, 150, 175, and 200. The images are standardized by using for the picture height five times the head-to-center distance of the midget, noting each successive head-to-center distance is ^ of the previous (the second scaling mentioned in the last section). In this way, all the midgets in our series appear to be the same size, so features and decorations are presented in the same level of detail. More thorough description of the procedures used here, and many more pictures, can be found in [ 18 ] . By the magnification of a picture, we mean 2.5/(height), where height is the difference in the imaginary coordinates of points of the top and the bottom of the picture. The scaling described in this paper was discovered while generating the pictures of

Page 256: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

the midgets in this sequence. The original motivation was simply to produce pictures of a coherent collection of very tiny midgets. While trying to standardize the size of the pictures, the head-to-center scaling appeared.

Scaling along the spike of the Mandelbrot set

we obtain results supporting the claims

275

m lim„_.oo^m(«)

6. EXTENSIONS TO SOME GENERALIZED MANDELBROT SETS

A "generalized Mandelbrot set," M(m), can be constructed by following the orbit of z = 0 under it­eration of z'" + c for fixed m > 2. (Note that for each of these polynomials, z = 0 is the unique critical point.) For even m, M{m) has a spike along the negative real axis and so our Cycle Finder could easily be adapted to find the center of the left-most«-cycle midget along this spike. For each even m, the family of polynomials defined by

gi(c) = c and for n > 2,g„(c) = (g„-i(c)r + c (4)

qualitatively exhibits much of the same behavior as the family X(^) of Section 3. To find a good initial guess for the secant method with the f„(c), we used the observation that^( - 2 ) = 2 for « > 2. For even m > 2, c = —2 is a very bad initial guess. To find a better initial guess, use

Proposition 4: For even m, let Coo = -2'^^'""'^ Then for«> 2,g„{Coo) = -Coc.

Proof: For fixed m even, induct on n. For « = 2, note g2(c) = c'" + c, sog2ic^) = (-I'^^'^-'^r - 2 / '"-' = 2i/('"->).(2 - 1) = I'^^'^-'K Assume ^„-,(Coo) = -Coo, and observe gnic^o) = (g"~\c^)r + c^o _ /2^/('"~'))'" — 2^^^"^~^^ = 2^^^"^~^^*(2 — 1) = 2i/(w-i)^ j - |

Note that for each even m, Coc = - 2 ' '"" Ms a Mis-iurewicz point for g„(c) with the given value of m: gniCoo) = -Coo 2indg„ig„{Coo)) = gn(-Coo) = "Coo- That is, Coo is eventually fixed, but is not fixed. (In general, recall such a point is eventually periodic, but is not periodic.) Misiurewicz points are powerful tools for understanding dM, but we shall not pursue this further here.

Since the centers of the hyperbolic components are dense in dM(m) (the argument given on page 101 of [1] extends directly to M(m)), and since the graphs Q^gn{c) have zeros approaching c^ as n increases and have no zeros less than Coo, we see that CQC is the left­most point of M(m) along the real axis.

For each even m, using Coo and Coo - c as initial guesses, the secant method applied to ^„(c) converges to the center of the left-most «-cycle cardioid com­ponent along the negative real axis. Repeating the cal­culation of the limit for large n of the ratio

10

12

12

16

20

24

To illustrate the uniformity of the convergence, we present the difference ofRn,(40) from the claimed limit:

| i?2(40) -4 | < 10-2'

| i?4(40) -8 | < 10- 2

\Re(40)- 121 < 10-^'

\Rs(40)- 161 < 10"^

| i?io(40)-20| < 10' ^

| /? ,2(40)-24 | < 10""

i?m(«) = -C„+2

Fig. 5. Top: the log of the distance between the centers of successive w-cycle midgets in our series, as a function of the cycle number n,3 ^ n 101. Bottom: the log of the head-to-center distance of successive «-cycle midgets in our series,

as a function of the cycle number «, 3 « ^ 101.

Page 257: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

2 7 6 M. FRAME, A. G. D. PHILIP, and A. RoBucri

Table 1. Cycle number versus the ratio of distances between centers of successive midgets in our series.

^ Cn - Cn+1 Cn+1 - Cn+2

3 4.16637414605908662208496455654839111377920160972260972260354 4 4.07459062274231735159872047478088055695713550822857469822557 5 4.02710240282901100185576866924130444467989408991256485727581 6 4.00896145399839807438351789583510757789206905695806750914514 7 4.00279737020555418877607870167518113275671966025453046005272 8 4.00083979224262016238306903536659879312871447469506726371456 9 4.00024517934233964400834854096899560219758409417089377370461 10 4.00007011346947268604441935445897870877419505642951991048702 11 4.00001973395248636269474770773131172432979721769628461560051 12 4.00000548496041719596635305681848766516348688043312852899005 13 4.00000150911421351233416983822142941109388727464014583290479 14 4.00000041174754750354060161134376777114411930757412052662773 15 4.00000011155417077780054836089339684144202559220741679612024 16 4.00000003004286630462413131008633668373963446705923881158999 17 4.00000000804929767225869647538780671141504228956751437866251 18 4.00000000214696970508878925854772371226865818738297428307093 19 4.00000000057040375014435997223335468317845104367457196263031 20 4.00000000015101626851953529433021629056983224685242576916949 21 4.00000000003985789976446295084695921763677430746956084488204 22 4.00000000001049043311938054289697531184468438351487206318541 23 4.00000000000275409782443605834183826009929569225117701075806 24 4.00000000000072139684225845777744272378692858709212242616572 25 4.00000000000018856730710209327881315809436431153971247802389 26 4.00000000000004919635090990112683171621201009654984064735376 27 4.00000000000001281271876107028681967591528956519905441238843 28 4.00000000000000333158744866636064592263708822339640222221017 29 4.00000000000000086499880176628997376054102053109799957119195 30 4.00000000000000022427518534149746454013573957615773096013330 31 4.00000000000000005807516756035581694248314990257490858270184 32 4.00000000000000001502038469633424713050425587400643598046215 33 4.00000000000000000388049437565084338365270649189938510756026 34 4.00000000000000000100147314427180282663159623930366237300917 35 4.00000000000000000025820567369677466139102603627653680330808 36 4.00000000000000000006651076531763883981033834237978619610126 37 4.00000000000000000001711752805425865916238117310636739666795 38 4.00000000000000000000440184119477690209311325917845420182901 39 4.00000000000000000000113107509399728484891236447207677886078 40 4.00000000000000000000029042247232508604363690495402606935065 41 4.00000000000000000000007451904278771271876144959821830965622 42 4.00000000000000000000001910811687353848165341955148168635444 43 4.00000000000000000000000489661826253719590411926222864384583 44 4.00000000000000000000000125405182667244284872091482587763006 45 4.00000000000000000000000032098727192764668035300389656328035 46 4.00000000000000000000000008211539679679566213144479582280809 47 4.00000000000000000000000002099599390291991354365965730507100 48 4.00000000000000000000000000536578465166022788861452198401138 49 4.00000000000000000000000000137064270689761934782854129186472 50 4.00000000000000000000000000034995981272004543087585982715063 51 4.00000000000000000000000000008931473717892150619864643204065 52 4.00000000000000000000000000002278488029445791366958197682504 53 4.00000000000000000000000000000581026907354636269737558641106 54 4.00000000000000000000000000000148107951836956174433891965452 55 4.00000000000000000000000000000037739794208813320358348567379 56 4.00000000000000000000000000000009613150114596899277056034533 57 4.00000000000000000000000000000002447837919247617116131216160 58 4.00000000000000000000000000000000623097077461502353249631874

Page 258: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Scaling along the spike of the Mandelbrot set 277

Table 1. (Cont'd.)

^ 4.00000000000000000000000000000000158558668777775106866604971 60 4.00000000000000000000000000000000040335767047543656355201610 61 4.00000000000000000000000000000000010257966725160883998437994 62 4.00000000000000000000000000000000002607997922108963477018896 63 4.00000000000000000000000000000000000662876040731926488607073 64 4.00000000000000000000000000000000000168438150234153026989855 65 4.00000000000000000000000000000000000042789322571331107956985 66 4.00000000000000000000000000000000000010867276896030989791626 67 4.00000000000000000000000000000000000002759305787307300648501 68 4.00000000000000000000000000000000000000700448087651713462274 69 4.00000000000000000000000000000000000000177767432119150440605 70 4.00000000000000000000000000000000000000045105710581343128910 71 4.00000000000000000000000000000000000000011442390783224661917 72 4.00000000000000000000000000000000000000002902088480278385401 73 4.00000000000000000000000000000000000000000735894816187651331 74 4.00000000000000000000000000000000000000000186566878076426577 75 4.00000000000000000000000000000000000000000047290013026485080 76 4.00000000000000000000000000000000000000000011984576633465879 77 4.00000000000000000000000000000000000000000003036662502577622 78 4.00000000000000000000000000000000000000000000769295211697193 79 4.00000000000000000000000000000000000000000000194856199437495 80 4.00000000000000000000000000000000000000000000049347148987673 81 4.00000000000000000000000000000000000000000000012495062028993 82 4.00000000000000000000000000000000000000000000003163334202766 83 4.00000000000000000000000000000000000000000000000800725724571 84 4.00000000000000000000000000000000000000000000000202654474612 85 4.00000000000000000000000000000000000000000000000051281879520 86 4.00000000000000000000000000000000000000000000000012975035097 87 4.00000000000000000000000000000000000000000000000003282400078 88 4.00000000000000000000000000000000000000000000000000830260345 89 4.00000000000000000000000000000000000000000000000000209980167 90 4.00000000000000000000000000000000000000000000000000053098812 91 4.00000000000000000000000000000000000000000000000000013425645 92 4.00000000000000000000000000000000000000000000000000003394147 93 4.00000000000000000000000000000000000000000000000000000857970 94 4.00000000000000000000000000000000000000000000000000000216851 95 4.00000000000000000000000000000000000000000000000000000054802 96 4.00000000000000000000000000000000000000000000000000000013848 97 4.00000000000000000000000000000000000000000000000000000003498 98 4.00000000000000000000000000000000000000000000000000000000883 99 4.00000000000000000000000000000000000000000000000000000000223 100 4.00000000000000000000000000000000000000000000000000000000056 101 4.00000000000000000000000000000000000000000000000000000000014

Motivated by these suggestive results, we give an With the multinomial expansion we establish the re-ai gument supporting this observation: for each even cursion relation a„+i = a„- nt-i-c^)"'' + 1. Now m, lim^,^ Rm{n) = 2m. writing c„ = c^ + e„, we have 0 = g„(c„) = g„{c,^ +

Using the notation of Proposition 4, write points e„)!==i-c^ + a„ •£„, whence e„t=>Coo/a„ = e„. It follows near c^asc^^ + s, and expand g„(c^ + e) = -c^ + that a,fi + p„(e), where p„(e)is simply all the higher-order terms of g„(c^ + e). For example,

ft(Ca, + e) = (C.. +«)"• +(Co. + £) 1 - - ^

= -Coo + a2*C + P2(c) (5) Cn+2

Page 259: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

2 7 8 M. FRAME, A. G. D. PHILIP, and A. ROBUCCI

Table 2. Cycle number versus the ratio of successive head-to-center distances for the midgets in our sequence.

n 'n - "n Cn+1 - hn+1

3 18.3401551994738078932293364270477004897785651570168500752764 4 16.9161183378306161702891764725654156643446147792235057394940 5 16.3085803740513327005257203105555287743134320449526969582979 6 16.0978321921328113285899928603600429128825482691063137539968 7 16.0297704370594686295146318159185441569131503544733273560405 8 16.0087874423429305973593640970435509561252722245350994806777 9 16.0025347635074281843881918406858425056673654910371699614997 10 16.0007183225733905134024956364052860491842074579038390280277 11 16.0002007520316907404888446214546727496170948444828839394015 12 16.0000554819652667942813475626919991804253118466696285494226 13 16.0000151940691096469587282777717463601460537372365258032764 14 16.0000041294185874686103949264713484271893166522228129959041 15 16.0000011150804954166347568476884785217414081172023977429657 16 16.0000002994516248697882485964200301170907943279976569103495 17 16.0000000800332844320451599356735908558664204136049505306140 18 16.0000000213009183023437288982263750885678201123057289530762 19 16.0000000056484229525721835591242374636811579891077268598887 20 16.0000000014928337032418059687293769574708956441984829448625 21 16.0000000003934171913107017701898556874707084164002808234904 22 16.0000000001034034963382996876636889847766229992526222249331 23 16.0000000000271131737125980748796832226074433941310049146265 24 16.0000000000070938683351807493790564906693819166998015290823 25 16.0000000000018523608105547634787376943709278194873666851535 26 16.0000000000004828136343287401844607767604061854160531723825 27 16.0000000000001256342665072699371036302017294626013444377153 28 16.0000000000000326412811109556568337534673224741868084741582 29 16.0000000000000084684993763806587856528094589475056406989989 30 16.0000000000000021941719182935193477140650342670851609427130 31 16.0000000000000005678004832128563027938017789791674207747931 32 16.0000000000000001467661680832563870739638702954127058537484 33 16.0000000000000000378953647558028740223109014921345458822604 34 16.0000000000000002372810458549583308209820628681165837127022 35 15.9999999999999997750126891568508622559412499651631196728737 36 16.0000000000000000006485442650120188546072574861921814672882 37 16.0000000000000000001668384988115546260638736594985423754484 38 16.0000000000000000000428852328425261346200479239420440674917 39 16.0000000000000000000110152102455409031813621972058072093856 40 16.0000000000000000000028272780701125681849765452206305325123 41 16.0000000000000000000007251883947099776575418174011007967127 42 16.0000000000000000000001858893179729543571832640451505460481 43 16.0000000000000000000000476203843171341732841206030129637264 44 16.0000000000000000000000121921097850997452137593007705871334 45 16.0000000000000000000000031197808817605708436550712294161828 46 16.0000000000000000000000007978837273833521267276081665817865 47 16.0000000000000000000000002039572731718008808520195594240952 48 16.0000000000000000000000000521132687620016530483053665531324 49 16.0000000000000000000000000133025888469821186534635608250748 50 16.0000000000000000000000000033970195370666077403133215729370 51 16.0000000000000000000000000008667728306136001353431323212752 52 16.0000000000000000000000000002210729451897706216968282579268 53 16.0000000000000000000000000000563653194299708283250403194453 54 16.0000000000000000000000000000144263348914140737153994248636 55 16.0000000000000000000000000000036876785047875028668950009118 56 16.0000000000000000000000000000174823277264000135912059302490 57 16.0000000000000000000000000002680623584714668750651575971558 58 15.9999999999999999999999999997155924255655618707462523681616

Page 260: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Scaling along the spike of the Mandelbrot set 279

Table 2. (Cont'd.)

59 16.0000000000000000000000000000000153643222290414029913551954 60 16.0000000000000000000000000000000039079061431579391931396341 61 16.0000000000000000000000000000000009936829322638819096101173 62 16.0000000000000000000000000000000002525973321845697552338315 63 16.0000000000000000000000000000000000641934828257922582662834 64 16.0000000000000000000000000000000000163094081513605194310272 65 16.0000000000000000000000000000000000041426113990682435738710 66 16.0000000000000000000000000000000000010519676900740893224965 67 16.0000000000000000000000000000000000002670706325952794379190 68 16.0000000000000000000000000000000000000677873356680091362054 69 16.0000000000000000000000000000000000000172017532967996063034 70 16.0000000000000000000000000000000000000043641681691492276317 71 16.0000000000000000000000000000000000000011069745035246401051 72 16.0000000000000000000000000000000000000002807267411904931388 73 16.0000000000000000000000000000000000000000711774641249565628 74 16.0000000000000000000000000000000000000000180433107380724608 75 16.0000000000000000000000000000000000000000045730638612264526 76 16.0000000000000000000000000000000000000000011588250094837307 77 16.0000000000000000000000000000000000000000002935960134168339 78 16.0000000000000000000000000000000000000000000743714436660766 79 16.0000000000000000000000000000000000000000000188359713877967 80 16.0000000000000000000000000000000000000000000047697796781486 81 16.0000000000000000000000000000000000000000000012078562400568 82 16.0000000000000000000000000000000000000000000003101130220790 83 16.0000000000000000000000000000000000000000000001276501434379 84 16.0000000000000000000000000000000000000000000007942675591695 85 16.0000000000000000000000000000000000000000000054464061200197 86 16.0000000000000000000000000000000000000000001646024960717090 87 15.9999999999999999999999999999999999999999998291280292468739 88 16.0000000000000000000000000000000000000000000000000830371180 89 16.0000000000000000000000000000000000000000000000001031147495 90 16.0000000000000000000000000000000000000000000000010152836877 91 16.0000000000000000000000000000000000000000000000182751063798 92 16.0000000000000000000000000000000000000000000002111790070561 93 16.0000000000000000000000000000000000000000000064978156017275 94 16.0000000000000000000000000000000000000000000582204277914789 95 16.0000000000000000000000000000000000000000008649892129019734 96 15.9999999999999999999999999999999999999999990700619955097304 97 16.0000000000000000000000000000000000000000000000000000003377 98 16.0000000000000000000000000000000000000000000000000000000853 99 16.0000000000000000000000000000000000000000000000000000000215 100 16.0000000000000000000000000000000000000000000000000000000054 101 16.0000000000000000000000000000000000000000000000000000000013

n^^ CO. Because of the steepness of the polynomials a„ an+2 ° CLn near Coo, this fesult r emains elusive.

Un+i Cln + \ \m-\ i ^ 1 l H - m * ( - C o o ) H 7. CONCLUSION

T h e Mande lb ro t set exhibits m a n y scalings. Mi lnor xirri'i — c ) ' " " 'H — I -^ ^^^ others have generalized the Feigenbaum sequence;

\ n+1 / we present another approach, not based directly on the m*(-c )'"~^ = m-l (1) self-similarity of the Mandelbrot set, but rather looking

for relative sizes and positions of the features associated where the limit is evaluated using the recursion relation in other natural ways. Presumably, many more se-and the observation lim„-*oo l/a„ = 0. quences of this type are to be found in the quadratic

To see this linearization argument is sufficient, we and in the generalized Mandelbrot sets. While our se-

would have to show that '-^^^^ becomes small as ^^^^^^ '' ^ manifestation of a much more elementary e„ feature t han are the Fe igenbaum a n d Mi lnor scalings.

Page 261: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

280 M. FRAME, A. G. D. PHILIP, and A. ROBUCCI

Fig. 6. The 85-cycle midget in our series, at a resolution of 400 X 300. The magnification is 1.89 X 10 •^, the dwell is 2000, and the center is on the real axis at -1.99999999999 9999999999999999999999999999999999999990107826 1203241533145505932256565548427495965286099483

24978.

Fig. 7. The 200-cycle midget in our series, at a resolution of 100 X 76. The magnification is 5.68 X 10"^ the dwell is 10000, and the center is on the real axis at -1.9999999999 9999999999999999999999999999999999999999999999 9999999999999999999999999999999999999999999999 9999999999999999426685746903701524868873414969 9219827953939104649515643786208826673859032991 1741950434088623707585559846010582920065846534

438813818139373097636.

we believe this and similar sequences are useful tools for navigating at high magnifications around the Man­delbrot sets.

Acknowledgements—Throughout this project, the authors have benefitted from extremely helpful conversations with K. W. Philip of the Institute for Arctic Biology of the Uni­versity of Alaska at Fairbanks. Indeed, his picture of a midget at a magnification of 2 X 10^', first mentioned in [4], was the catalyst that began our work.

Some aspects of the mathematical analysis were clarified significantly through discussions with Susan Niefield of the

Mathematics Department of Union College, and with David Peak of the Physics Department of Union College. Consid­erable support for the computations of this project was pro­vided by Lance Spallholz of the Computer Science Department of Union College.

REFERENCES 1. B. Branner, The Mandelbrot set. In Chaos and Fractals:

The Mathematics Behind the Computer Graphics R. De-vaney and L. Keen (Eds.), American Mathematical So­ciety, Providence, 75-105, (1989).

2. P. Collet and J. Eckmann. Iterated Maps of the Interval as Dynamical Systems, Birkhauser, Boston (1980).

3. P. Cvitanovic and J. Myrheim, Universality for period «-tuplings in complex mappings. Physics Letters A 94, 329-333(1983).

4. A. Dewdney, Computer recreations. Scientific American 260, 12-15 (June, 1989).

5. A. Douady and J. Hubbard, On the dynamics of poly­nomial-like mappings. Ann. Sci. Ecole Norm. Sup. Paris 18,287-343(1985).

6. J. Eckmann and H. Epstein, Scaling of Mandelbrot sets generated by critical point preperiodicity. Commun. Math. Phys. 101,283-289(1985).

7. J. Eckmann, H. Epstein and P. Wittwer, Fixed points of Feigenbaum's type for the equation/''(Xx) = \f{x). Commun. Math. Phys. 93, 495-516 (1984).

8. M. Feigenbaum, Universal behavior in nonlinear systems. Los Alamos Science 1, 4-27 (1980).

9. A. Gorberg, Ya. Sinai and K. Khanin, Universal prop­erties for sequences of bifurcations of period three. Russian Math. Surveys 38, 187-188 (1983).

10. M. Jakobson, Absolutely continuous invariant measures for one-parameter families of one-dimensional maps. Commun. Math. Phys. 81, 39-88 (1981).

11. O. Lanford, A computer-assisted proof of the Feigenbaum conjectures. Bull. Amer. Math. Soc. 6, 427-434 (1982).

12. B. Mandelbrot. The Fractal Geometry of Nature, Freeman, New York (1983).

13. M. Metropolis, M. Stein and P. Stein, On finite limit sets for transformations ofthe unit interval. / Combinatorial Theory (A) 15, 25-44 (1973).

14. J. Milnor, Self-similarity and hairiness in the Mandelbrot set. In Computers in Geometry and Topology, M. Tangora (ed.). Marcel Dekker, New York, 211-257 (1989).

15. J. Milnor, W. Thurston, Iterated maps ofthe interval. In Dynamical Systems, Lecture Notes in Mathematics (vol. 1342), J. Alexander (ed.). Springer-Verlag, New York (1988).

16. M. Misiurewicz, Horseshoes for mappings ofthe unit in­terval. Bull. Acad. Polon. Sci. Ser. Sci. Math. 27, 167-168(1979).

17. A. G. D. Philip, An introduction to the Mandelbrot set. In CCDs in Astronomy II, A. G. D. Philip, D. Hayes, S. Adelman (eds.), L. Davis Press, Schenectady, NY, 275-286(1990).

18. A. G. D. Philip, A. Robucci, M. Frame, K. Philip. Mm., L. Davis Press, Schenectady, NY (1991).

19. S. Sarkovskii, Coexistence of cycles of a continuous map­ping ofthe line onto itself Ukrain. Mat. Z. 16, 61-71 (1964).

20. S. Ulam, J. von Neumann, On combinations of stochastic and deterministic processes. Bull. Amer. Math. Soc. 53, 1120(1947).

Page 262: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 281

Chaos and Graphics

FURTHER INSIGHTS INTO HALLEY'S METHOD

RAY REEVES Graphics Research Laboratory, Department of Computer Science, University of Massachusetts at Lowell,

1 University Avenue, Lowell, MA 01854

Abstract—Algebraic analysis of Halley transforms reveals the nature of the so-called director nodules that characterise iteration maps.

1. INTRODUCTION

An earlier note [1] on features of Halley's method when applied to simple polynomials is here elaborated by analysis.

The salient features noted were:

• The fractal nodules in a map of z" — 1 all have the form of a bilinear (Mobius) transformation of the entire map.

• There are distinguished "director" nodules through which the forward orbits escape to their target basin.

• A map of z(z" - 1) exhibits parabolic separators and twice as many director nodules.

2. THE MOBIUS TRANSFORM

Scrutiny of the nodules situated on unit circle in the map of z^ — 1 reveal that their own principal nodules are also on unit circle (see Fig. 1). It follows that the biUnear (Mobius) transforms that generate them are of a particularly simple form:

(z-a) ia*z - 1) (1)

which preserves unit circle. The modulus of a appears to be about 1.04, and in the case of the nodule at — 1 it is real. Such a transform is self-inverse, and will transform radial lines from the origin into coaxial cir­cles, exactly as seen at the nodules. Since the map con­tains both radial spokes and their images, it is self-conjugate with respect to a Mobius transformation and does not appear altered by it, but the interior points of each nodule are mapped into it's exterior.

3. HALLEY TRANSFORM OF z" - 1

The Halley transform is defined as:

H(z):z- f(z)

f\z)- r{z)fiz) 2f\z)

(2)

The general formula for the primitive «th roots of unity is:

z" - 1 = 0

and substituting this in the Halley transform we get:

ziz''^ a) H{z):

a(z"-\- l/a) (3)

where: a = in+ 1) in-\)'

This factors to:

-!n \aV «,io^+i/(i«r/"62-^/")

(4)

So, the Halley transform for this class of polynomial is precisely the product of n Mobius transforms (to­gether with a zero at the origin), each of the anticipated form. In the case of « = 7, o: has the value:

which is about 1.042. The pole and zero in these factors are close together and each pair locally dominates the behaviour of the transform. The pole is just inside unit circle, and the zero just outside.

These factors account for the whole set of director nodules, and explain the crucial orbit step directing the forward orbit out of the nodule and into the target basin. The remaining (infinite) set of nodules are found by composing the Halley transform with itself to find where the images of the director nodules fall. Unlike its factors, the Halley transform is not self-inverse and the orbit does not loop. These images form a sequence to infinity and to zero, with a spacing that appears to be asymptotic to the ratio a. As well as the principal sequence of nodules along the separators, it must be remembered that each nodule is an image of the whole scene, and contains all the other nodules in it, which accounts for the myriad smaller nodules seen between those of the principal sequence.

For any root-finding iterator, we require the fixed points of the transform to be just at the roots for which we are searching. It can be seen from eq. (3) that z = 0 is an unwanted fixed point where the orbit and all its images will be trapped. Apart from that, it can be ascertained that equating expression (3) to z does, in fact, have solutions at just the roots of z" - 1.

Reprinted from Comput & Graphics Vol 16, No. 2, pag. 235-236, 1992

Page 263: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

282 R A Y REE^^P'=^

4. HALLEY TRANSFORM OF ziz" - 1 )

The earlier note also discussed the class of polyno­mials:

z ( z " - l ) (5)

which, by introducing a root at the origin will clearly make a profound change from the radial spoke pattern. Substituting this in eq. (2) we get:

(z" + (^^^)

^ + 2_,„., (^-4) (6)

(« + 2) z" + ( « + l)(« + 2)

This does not factor into Mobius transforms, because the denominator is quadratic in z", giving two poles for each zero not at the origin. For values of n up to 4, the map is characterized by parabolic separators around each root on unit circle, isolating it from the root at the origin; and by two director nodules on each separator, not one. Since the separators do not meet at the origin, the zeros of the transform are not conspic­uous as "stars" on the nodule as the poles are. How­ever, they are seen as isolated spots distance one step from the root at the origin, and colored accordingly. Figure 2 is a general view of z(z^ — 1) and the zeroes are marked there with crosses. They are positioned just inside unit circle. The two adjacent director nodules are seen as stars on the separators, produced by the poles of Halley, consisting of a loop around the image of each root that is not adjacent to that separator.

For values ofn greater than four, the separators web over and join up, and the basin about the origin breaks up into a sequence of basins to infinity. The first of these contains a zero of the Halley transform, showing that it is one step away from the origin in Halley dis­tance. For values of n above seven, the adjacent pole pairs are no longer separated on a circle centered at the origin, but are then separated on a constant radius through the origin. In this sense, the separators are no longer a composite of parabolic separators, but are in­tegrated into radial strips of more complex patterns.

Fig. 2. z(z^- 1).

Of particular interest are the fixed points of this transformation.

n I (n+l)l

n + 2 , 2 . ^ ( « - 4 ) = z (1)

z" + (« + 2) ( « + l)(« + 2)

which reduces to:

, . . _ ( Z L ± 2 ) , „ ^ . 1 (AT+ 1) ( « + 1 )

(8)

Fig. l . z^ - 1 Detail at-1,0.

It can be seen that, as well as the fixed points on unit circle, as desired, there is another set at the apex of the parabolas (also seen as black spots in Fig. 2), where the orbits will be trapped. Although these anomolous points are not attractive, and have no basin, they will trap the orbit by virtue of a finite epsilon of change used as a stopping criterion in a practical method. No­tice they are situated just where the basins seem to touch.

5. CONCLUSION

The so-called director nodules form a basis for the whole picture. They correspond directly to the poles and zeros of the Halley transform, and get their status as directors by mapping their interiors to their exteriors, i.e., to the target basin. The other nodules that look identical except for scale, are images of the directors due to repeated Halley transforms, which direct the forward orbit to the directors, where they escape.

When the Halley poles and zeros are paired up close to each other, as in z" - 1, they dominate the local behaviour and behave as simple Mobius transforms, as was originally perceived.

Analysis reveals unwanted fixed points in the Halley transform that can trap an orbit and give false results as a root-finder.

REFERENCE 1. R. Reeves. A note on Halley's method, Computers &

Graphics 15, 89-90(1991).

Page 264: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 283

Chaos and Graphics

VISUALIZING THE DYNAMICS OF THE RAYLEIGH QUOTIENT ITERATION

CLIFFORD A. REITER Department of Mathematics, Lafayette College, Easton, PA, 18042

Abstract—The chaotic behavior of the Rayleigh Quotient Iteration over the complex numbers is explored. The global behavior is seen to be related to the behavior at a point. The contrast between the behavior on non-Hermitian and Hermitian matrices is studied visually.

1. INTRODUCTION

Much recent work has taken advantage of computer generated images to study the behavior of numerical iteration. General references include [1-5] and some examples using specific numerical algorithms are in [6-8]. This note utilizes computer generated images for insight into the behavior of the Rayleigh Quotient Iteration in the complex plane. The Rayleigh Quotient Iteration is a numerical technique for estimating ei­genvalues. It typically converges to an eigenvalue qua-dratically but the convergence is cubic when the matrix is Hermitian. While there is a sense of unpredictability in the convergence, distinct basins of attraction often have smooth boundaries.

2. THE RAYLEIGH QUOTIENT ITERATION

An elementary introduction to the Rayleigh Quo­tient Iteration can be found in [9]. An advanced in­troduction is in [10]. The dynamics of a real variable version of the algorithm are studied in [11]. The Ray­leigh Quotient Iteration begins with a fixed square, complex, matrix A, an initial estimated eigenvalue IXQ, and an initial estimated eigenvector XQ, then the al­gorithm iterates the following steps:

(a) Solve the system {A - n„I)Y = X„ for Y, (b) let X7+1 be the unit vector in the direction of Y, (c) and let n„+i = X^+iAX„+i. (The Rayleigh Quo­

tient)

The matrix /designates a square identity matrix of the appropriate size and the superscript "H" designates a Hermitian conjugate. The iteration halts when the sys­tem to be solved is singular, up to numerical tolerance, or the maximum number of iterations is reached. The system is singular exactly when /u„ is an eigenvalue, so this halting condition is appropriate.

The program used to generate the figures uses float­ing point computations carrying about 19 significant figures. The system solver uses maximal column pi­voting. Experiments with Gauss-Jordan elimination as an alternate system solver resulted in a few changed pels, but did not change the essential features observed. The system was considered to be singular when a pivot of magnitude 10~"* or smaller would have been re­quired. The maximum iteration of 50 was never achieved in these images. Each image uses a fixed vector as the initial vector while the initial estimate for the

eigenvalue corresponds to change in position in the complex plane.

2.1. Examples Five basins of attraction are visible in Fig. 1 with

the basins colored green, blue, red, magenta, or cyan. Within each basin the iteration count modulo three determines whether black, or a dark shade, or light shade of the appropriate color are used. The appearance of black makes the basin ambiguous, but highlights symmetries. Since three colors are used per basin, the orientation of the basins can be determined in the sense that moving across contours within a basin from black to the dark shade and then to the light shade is moving in the direction of increasing iteration count.

Figure 1 results from the algorithm run on the com­panion matrix of x^ — 1 which is given in matrix (/), see Table 1. The eigenvalues are the fifth roots of unity. All the figures use 1 1 1 1 1 (truncated to the appro­priate dimension) as the initial estimate for the eigen­vector except for Fig. 1. Matrix (/) has that vector as an eigenvector associated with 1; thus an alternate vec­tor, 1 0 0 0 0, is used as the initial estimate for the eigenvector in that case. The image in Fig. 1 show five basins of attraction dividing the plane into five sectors with no turbulence on the boundary. The Rayleigh Quotient Iteration behaves in the manner that is hoped for; namely, the nearest eigenvalue value to the initial estimate is eventually located.

Figure 2 gives the first visual example the author recorded of intertwining basins. The figure arises from the algorithm applied to matrix (//). The real eigen­value dominates the global behavior while the basins of attraction of the complex conjugate pair intertwine within a disk. Notice the symmetry about the real axis and the near perpendicular crossovers of the boundaries of the basins of attraction along the real axis. Figure 3 results from matrix (///). That matrix has one entry changed an imaginary unit from matrix (//). Figures 2 and 3 are very similar even though the eigenvalues for matrix 3 are all nonreal and the intertwining pair of basins do not result from complex conjugate eigen­values.

Figure 4 was generated using matrix (IV). This is a symmetric matrix with one of the middle eigenvalues dominating globally. Figure 5 indicates that Hermitian matrices can have basins with more than one com-

Reprintedfrom Comput. & Graphics Vol 16, No. 3, pag. 341-344, 1992

Page 265: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

284 CLIFFORD A. REITER

Fig. 1. The Rayleigh Quotient Iteration on matrix (/) with - 4 < Re (fio) <4 and - 3 ^ Imino) ^3.

Fig. 2. The Rayleigh Quotient Iteration on matrix (//) with -14 ^ Re ifio) ^ 10 and -9 ^ Im(Mo) ^ 9.

ponent. Note the magenta crescent-shaped side com­ponent. Figure 6 arises from the symmetric matrix (VI) and shows basins with many components.

Which basin(s) dominate globally is perhaps not immediately apparent, but, heuristically, the global

behavior is the same as the behavior in the neighbor­hood of the Rayleigh Quotient X ^AXQ where XQ is assumed to be unit length. This is because for very large magnitude /JLQ the matrix A - IIQI is dominated by -/Lio/, thus the y found at the first step is very close

Table 1. Matrices used to construct the figures.

0 0 0 0 1

(//)

(III)

(IV) - 6

7 1

- 5 (V)

2 - 9 + 6i - 3 + i - 3 - i

(VI) 1 2 3 4

(VH) -14

21 -15

10 (VIII)

12 7

-10 -18

1 0 0 0 0

1 9 5

1 9 + i

5

7 10 3

- 4

- 9 - 6 i - 4

- 9 - 2 i - 6 - 6 i

2 5 6 7

-10 12

- 9 7

-14 - 6 12 22

Matrix

0 1 0 0 0

1 8 6

1 8 6

1 3 8

- 7

- 3 - i - 9 + 2i

2 3i

3 6 8 9

0 - 4

3 -1

0 - 2 - 2 - 3

0 0 1 0 0

1 4 2

1 4 2

- 5 - 4 - 7

8

- 3 + i - 6 + 6i

-3i 2

4 7 9

10

0 0 1

-1

4 4

- 2 - 4

0 0 0 1 0

Approximate Eigenvalues

1 0.31 +0.95i 0.31 - 0.95i

-0.81 +0.59i -0.81 - 0.59i

-0.53 + 0.62i -0.53 - 0.62i

12.05

-0.73 +0.6 li -0.32 -0.71i

12.05 +0.1i

-9.43 1.32 7.87

20.23

-19.45 -0.09

7.32 14.22

-0.81 0.18 0.56

24.06

1 + i 1 - i

- 1 + i -1 - i

1 + i 1 - i

- 1 + i - 1 - i

Page 266: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Visualizing the dynamics of the Rayleigh quotient iteration 285

Fig. 3. The Rayleigh Quotient Iteration on matrix (///) with Fig. 6. The Rayleigh Quotient Iteration on matrix (VI) with -14 ^ Re(Mo) : 10 and - 9 <. Im(/io) < 9. -18 ^ Re(Mo) < 14 and -12 ^ Im(/io) ^ 12.

Fig. 4. The Rayleigh Quotient Iteration on matrix (IV) with Fig. 7. The Rayleigh Quotient Iteration on matrix (VII) with -30 < Re(Mo) ^ 70 and -37.5 ^ Im(/xo) ^ 37.5. -.0006 < Re(Mo) ^ .0006 and -.00045 ^ Im(Mo) ^ -00045.

Fig. 5. The Rayleigh Quotient Iteration on matrix (F) with -20 ^ Re(/io) ^ 60 and -30 : Im(Ato) ^ 30.

Fig. 8. The Rayleigh Quotient Iteration on matrix (VII) with - 4 < Re(/io) ^ 4 and - 3 < Im(Mo) < 3.

to a complex multiple of XQ. If XQ is unit length, then the next estimate for the eigenvalue is very close to the Rayleigh Quotient X^AXQ and the eigenvector is in nearly the original direction. In particular, consider Fig. 4. Let Xo = ( H H ) a n d ^ be matrix ( /K) , then X^AXQ = 2.5 and that lies within the basin of attrac­tion of the second eigenvalue from the left (near 1.32), hence that basin dominates globally.

Figures 7-9 give examples where features recogniz­

able at a global level can also be viewed at a zoom around the value of the Rayleigh Quotient. These im­ages are generated by a real matrix whose eigenvalues are ±1 ± /; these fall symmetrically in the four quad­rants around zero. Moreover, the Rayleigh Quotient with the initial eigenvector is zero. So the global be­havior should be the same as the behavior centered between the eigenvalues at zero. Figure 7 is a zoom into the origin. Notice the red and magenta ring of

Page 267: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

286 CLIFFORD A. REITER

Fig. 9. The Rayleigh Quotient Iteration on matrix (VII) with -4000000 ^ Re(Mo) ^ 4000000 and -3000000 : Im(Mo) ^

3000000.

Fig. 11. The Rayleigh Quotient Iteration on matrix {VIII) with -80 : Re(Mo) ^ 80 and -60 ^ Im(Mo) ^ 60.

Fig. 10. The Rayleigh Quotient Iteration on matrix (VIII) with - 4 <, Re(Mo)(Mo) ^ 4 and - 3 : Im(/io) ^ 3.

Fig. 12. The Rayleigh Quotient Iteration on matrix (VIII) with -8000 ^ Re(/iio) ^ 8000 and -6000 : Im(Mo) ^ 6000.

basins on the left and green and blue six way crossover between the heads of the red and magenta pinchers on the right. Fig. 9 is a high scale antizoom. The six way crossover is visible inside the pinchers and the red and magenta ring is visible. Figure 8 shows the behavior on a scale where the eigenvalues are visible. The four basins nearly form quadrants with a bit of turbulence on the boundary.

Figures 10-12 are generated by matrix (VIII), which has the same eigenvalues and Rayleigh Quotient as matrix (VII). Figure 10 is an image on a scale where the eigenvalues are visible and the four basins nearly form four quadrants with some turbulence. Figure 11, "A Butterfly in a Lightning Storm," is an antizoom, showing much turbulence, and the green and blue ba­sins for — 1 ± / appearing to dominate. While Fig. 11 shows considerable complexity, the iteration counts appearing are not very large. The mode of the frequency table for iteration counts for this image is 12 iterations and the maximum number of iterations is 33. Figure 12 is a large scale antizoom where turbulence is still visible, but the red and magenta basins associated with 1 ± / are seen to dominate.

Acknowledgement—The author appreciates the efforts of a summer student research assistant, Kenwyn Pilgrim, who was supported by Lafayette College. Kenwyn Pilgrim programmed

an eariier version of the code used to generate images of the Rayleigh Quotient Iteration.

REFERENCES 1. M. Bamsley, Fractals Everywhere, Academic Press, New

York (1988). 2. R. L. Devaney, Chaos, Fractals, and Dynamics, Addison-

Wesley, Reading, MA (1990). 3. B. Mandelbrot, The Fractal Geometry of Nature, Freeman,

New York (1982). 4. H.-O. Peitgen, P. H. Richter, The Beauty of Fractals, Im­

ages of Complex Dynamical Systems, Springer-Verlag, Berlin (1986).

5. C. A. Pickover, Computers, Pattern, Chaos and Beauty, St. Martin's Press, New York (1990).

6. M. A. Motyka and C. A. Reiter, Chaos and Newton's Method on Systems, Computers and Graphics, 14, 131-134(1990).

7. H.-O. Peitgen, D. Saupe, and F. V. Haeseler, Cayley's Problem and Julia Sets, Mathematical Intelligencer, 6, 11-20(1984).

8. C. A. Pickover, A Note on Chaos and Halley's Method, Communications of the ACM, 31, 1326-1329 (1988).

9. C. A. Reiter, Easy Algorithms for Finding Eigenvalues, Mathematics Magazine, 63(3), 173-178 (1990).

10. B. Pariett, The Rayleigh Quotient Iteration and some Generalizations for Nonnormal Matrices, Mathematics of Computation, 28, 679-693 (1974).

U . S . Batterson and J. Smillie, The Dynamics of Rayleigh Quotient Iteration, SIAM Journal on Numerical Analysis, 26,624-636(1989).

Page 268: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 287

Chaos and Graphics

THE "BURNING SHIP" AND ITS QUASI-JULIA SETS

MICHAEL MICHELITSCH and OTTO E. ROSSLER Institute for Physical and Theoretical Chemistry, University of Tubingen, D-7400 Tubingen, Germany

Abstract—By manipulating the imaginary part of the complex-analytic quadratic equation, we obtain, by iteration, a set that we call the "burning ship" because of its appearance. It is an analogue to the Mandelbrot set (M-set). Its nonanalytic "quasi"-Julia sets yield surprizing graphical shapes.

1. INTRODUCTION

The real and imaginary components of the complex quadratic equation are

2 •yl- Cx and

yn + \=2Xnyn- Cy. ( 1 )

Iterating Eq. (1) in the c-plane (parameter space) yields for Xo = 0 and 30 = 0 under the usual manipulations [ 1, 2 ], the Mandelbrot set (M-set).

We arbitrarily replace some elements of the right-hand side of Eq. (1) by their absolute values. Thereby, the analyticity of this equation breaks down. A first such case was considered in [ 3 ]. Here we present results for the following equation:

•^«4 yl- and

yn+x = 2\xnyn\ ' Cy (2)

Its quasi-Julia sets (QJS's) apply in the x, y plane (state space). The word "quasi" is used because the present maps are not analytic, that is, they do not obey the Cauchy-Riemann conditions

^fx{x,y)ldx=df2{x,y)lby

dfi^x,y)ldy=-df2{x,y)/dx

2. STRUCTURE AND PROPERTIES OF THE "BURNING SHIP"

Figure 1 shows an analogue to the M-set in param­eter space. We arbitrarily put Xo = yo = 0. The main body in this figure is called the burning ship.

1. The length of the main body in the c^-direction is the same as for the M-set. Along the G-axis (antenna region of the M-set), at identical positions, occupied by the small M-sets, "mini-ships" are located.

2. The main body can be divided into five regions that each exhibit different properties (Fig. 1):

Region 1 of Fig. 1 is below the "water fine" of the ship, Cy < 0. The range - .5 < Cx < -.25 we call the "bump." Its boundary is slightly irregular; in its front range, - .43 <Cx< -.39 and - .2 <Cy<-.\l, the boundary is actually dust-like.

Region 2 also lies below the water line to the right of Region 1, extending up to c = 1.8. These "keels,"

Reprinted from Comput. & Graphics Vol. 16, No. 4, pag. 435-438, 1992

both of the main ship and those of the mini ships, are mostly smooth. Some intervals (in the main keel at .5 <Cx< .65, 1.15 <Cx< 1.25, and 1.35 < Cx< 1.4), and corresponding regions of the mini-ships, show beard-like structures (Fig. 2).

Region 3 lies above the water line for Cx > 1.46. It also includes all upper parts of the mini-ships. There are Eiffel Tower-like superstructures at low iteration number limits of about 50 (Fig. 3a, b, c).

Region 4 lies to the left of Region 3, comprizing the upper—"burning"—part of the ship. Its boundary is "dusty" in contrast to the correspond­ing parts of the mini-ships. Within the dust dumb­bell-like voids of all sizes are randomly distributed (Fig. 4).

Region 5 is the "bow" of the burning ship, lying at - .8 < Cx< - .5 and 0 > Cy> 1.1. Its boundary is smooth (Fig. 1, left hand edge).

3. CORRESPONDING QUASI-JULIA SETS (QJS's)

When iterating Eq. (2), with fixed px and py values replacing the previously variable Cx and Cy values, we obtain QJS's in \\\t x, y plane. Bearing close to the border of ships' bodies, tantalizing pictures can be ob­tained.

• All QJS's along the x-axis, i.e. with diflrering/?^-values but Py = 0, are identical with the Julia sets of the M-set. This is because the second variable of Eq. (2) is squared immediately at each iteration step, within the first part of Eq. (2).

• All pairs of ;?-values that correspond to smooth boundary points of the burning ship in Fig. 1 yield smooth QJS's. They explode when the borders of the ship are crossed from the inside, similarly as this is known from the Julia sets of the M-set. (A differ­ence is that the coincidence is not perfect this time because different Xo, yo pairs yield slightly different canonical boundaries for the ship.) QJS's that cor­respond to the beard-Uke intervals of Region 2 exhibit highly esthetical, self-similar fractal ornaments (Figs. 5,6,7).

• Eiffel Tower-like superstructures above the Region-3 ships gives rise to corresponding features in the QJS's (Fig. 8a, b, c). Its ordered Eiffel-Tower su­perstructures are similar to structures reported in[4] for the simplest nonanalytic Julia-like set.

• Corresponding to the randomly distributed dumbbell void structures of Region 4, we find QJS's that have

Page 269: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

288 MICHAEL MICHELITSCH and OTTO E. ROSSLER

Fig. 1. Computer scan of the "burning ship". Eq. (2) with Xo = yo = 0; maximum iteration number = 250; explosion threshold x^ + y^ = 200; coordinates: -1.25 < c^ < 2.25;

- .75<Cv< 1.75.

Fig. 3b. The largest of the mini ships, antenna region. Note the Eiffel Tower superstructures. Maximum iteration number = 50; explosion threshold = 50; 1.7 < C; < 1.8; -.01 < c < .1.

Fig. 2. "Beard-like" structures (arrows) in the keels in Region Fig. 3c. Detail of Fig. 3b, main left hand Eiffel Tower; 1.74 3. Vertical blow-up; .3 < C; < 1.8; -.01 < c < .1. < c, < 1.75; -.043 <Cy< .05.

Fig. 3a. Eiffel Tower-like superstructures above the "water line" near the rear end of the ship (main body) and the mini ships of the antenna region (Region 3). 1.4 < c < 1.75; -.01

<Cy< . 1 .

• . . ^

Fig. 4. "Dusty" area of Region 4, showing dumbbell-like voids and randomly distributed mini-ships. Maximum iteration number = 250; explosion threshold = 250; .6 < C;c < 1.01; .6

<Cy< 1.01.

Page 270: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

The "burning ship" and its quasi-Julia sets 289

fr^:''^ «l>"€|

'•m,^^""^ •4P*

eij^^^i^kiS Fig 5 Exploding quaa-Julia set (QJS) of Region 2. Note the „ ^ „ , . ^ ^ ^ ^ g . , T- J J ^ ^ ^ dust-like self-similar rhomb-shaped ornamental structures: P^ .6.«. v u „ . _ „ _ . . „ „ _ ^ ^ ^ ^ ^ ^ ^ = 02. Maximum it^tion

«i^c;/« *K oei,«M - onn. A ^ V - ^ A . A ^ ., ^ A number = 120; explosion threshold = 8 -.33 < x < .33 plosion threshold = 200; ~.b < x < .o; —A < y < A. _ o^ ^ ^ o^ -.25 <y< .25.

Fig. 6. Detail from an exploding QJS in region 2. P^ = .3, Py - - .13. Maximum iteration number = 150; explosion

threshold = 8; -.18 < x < .18; .57 < y < .89.

Fig. 8b. Blow-up from Fig. 8a. "Head" of the gorilla, -.06 < x<.06; .059<3;<.150.

Fig. 7. Detail from an other exploding QJS from Region 2. Px = .5, Py = -.07. Maximum iteration number ^ 150; ex- Fig. 8c. Detail from Fig. 8b. "Hole" in the center of the gorilla's plosion threshold = 8; -.115 < x < .115; .675 <y< .860. chest. -.0052 < x < -.005; .0610 <y< .0750.

Page 271: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

290 MICHAEL MICHELITSCH and OTTO E. ROSSLER

Fig. 9a. "Alzheimer Brain." QJS from Region 4. p^ = .75, Py = .9. Maximum iteration number = 120; explosion threshold

= 120; - 3 < jc < 3; -2.2 <y< 2.2.

Fig. 9b. Detail from Fig. 9a; maximum iteration number = 400; explosion threshold = 200; -1.15 < x < - .55; -.31 <

>^< .31. Compare text.

corresponding dumbbell structures too. However, they appear completely symmetric now (Fig. 9a, b ) . Note that even the outer circumference of these QJS's reproduces the (inverse) shape of these void struc­tures (Fig. 9a) . Those dumbbell voids are, thus, self-similar.

• The smooth structures of the Region 5 ("bow") yield smooth QJS's at corresponding p-values. An example is Fig. 10a. A QJS from the transient zone between Regions 4 and 5 is shown in Fig. 10b.

4. CONCLUDING REMARKS

Nonanalytic, noninvertible maps of two variables exhibit an unexpected esthetical and mathematical richness. There is some hope that they form a link to realistic, both invertible and continuous, systems; for example, in physics, chemistry, and technology.

Acknowledgement—^t thank Albert Murle for kindly sharing with us his computer programs, and Professor J. Encamagao for his help at a crucial stage.

REFERENCES 1. B. B. Mandelbrot, Fractal Aspects of the Iteration of z ^

Xz(X - z) for Complex 2, z. Ann. NY Acad. Sci. 357, 249(1980).

Fig. 10a. Smooth QJS from Region 5, a "Frog". Px = -.45; py = .70. Maximum iteration number = 150; explosion

threshold = 8 ; - 1 . 2 < A : < \.2;-\.3<y< 1.3.

Fig. 10b. Clutch of selfsimilar "Frogs." QJS from upper part of Region 5, close to region 4. p^ = -.7387; py = 1.1. Maxi­mum iteration number = 500; explosion threshold = 500;

-\ <x< U-2.2<y<2.2.

H.-O. Peitgen and P. Richter(Eds.), The Beauty of Frac­tals, Springer-Verlag, Berlin (1986). M. Michelitsch and O. E. Rossler, Spiral structures in Julia sets and related sets. In: Spiral Symmetry, I. Hargittai and C. A. Pickover (Eds.), World Scientific, Singapore 123-134(1992). O. E. Rossler, C. Kahlert, J. Parisi, J. Peinke, and B. Rohricht, Hyperchaos and Julia sets, Z Naturforsch. 41a, 819-822(1986).

Page 272: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 291

Chaos and Graphics

FIELD LINES IN THE MANDELBROT SET

KENELM W. PHILIP Institute of Arctic Biology, University of Alaska, Fairbanks, AK 99775

Abstract—A technique for displaying color images of field lines surrounding the Mandelbrot Set using angle-slicing decomposition and a "contrast color lookup table," is described. A modification of this method, which compensates for the spatial-frequency doubling inherent in angle-slicing decomposition, can produce black and white images that even more accurately portray the field lines.

Plotting the Mandelbrot set using the level set method[l] involves iterating the following equation:

>Z'^C, (1)

where Z and C are complex numbers, and testing whether Z is farther from the origin than a previously assigned escape radius. It is well known that if the es­cape radius is large compared to the size of the set, the iteration-number contours map out equipotential lines in the electric field that would be present if the M-set carried an electric charge[2]. The usual escape radius of 2, on the other hand, gives a very different set of

contours. Figure 1 shows two views of the M-set with different escape radii—2 in Fig. 1(a), and 100 in Fig. 1(b). Figure 2 shows an enlarged view of these contours for the spike of the M-set, and it is clear that the con­tours in Fig. 2(b) are appropriately shaped for equi­potential lines.

It would be interesting to have a simple way to dis­play the "field lines" of this hypothetical electric field, for the Mandelbrot set or for other images involving the level set method. A first approximation to these field lines may be obtained through binary decompo-sition[3]. Figure 3(a) shows an image of the M-set, using an escape radius of 10, where each pixel outside the set has been set to either black or white, depending on whether the value of the imaginary part of Z was pos­itive or negative when Z passed beyond the escape ra­dius. The transitions from black to white that run or­thogonal to the iteration-number contours are short sections of field lines, but the broken-up nature of the plot, and the wide separation between adjacent tran­sitions, tend to overshadow the rendition of the electric

Fig. 1. Mandelbrot set showing iteration number contours, (a) escape radius=2; (b) escape radius= 100.

Fig. 2. Spike of Mandelbrot set showing iteration-number contours, (a) escape radius=2; (b) escape radius=100.

Reprinted from Comput. & Graphics Vol 16, No. 4, pag. 443-447, 1992

Page 273: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

292 KENELM W. PHILIP

(b)|

Fig. 3. Mandelbrot set with binary decomposition, (a) escape radius= 10; (b) escape radius= 100.

field. Figure 3b shows another M-set image where the escape radius was set to 100, and binary decomposition produces somewhat narrower blocks that give a slightly better rendition of the field lines.

Recently, I received a block of True BASIC source code that used a different kind of decomposition: angle-

Fig. 4. Mandelbrot set using angle-slicing decomposition.

slicing decomposition[4]. Rather than testing for the sign of the imaginary part of Z, this method computes the arc tangent of zi/zr, and then assigns black or white to the pixel according to the value of the angle as the escape radius is passed. Along any given iteration-number band, the number of black/white alternations is a function of the fineness or coarseness of the angle-slicing, which may be set by the programmer—and a fine slicing can produce blocks that are (locally) a series of parallel lines orthogonal to the iteration-number bands. Note, however, that the spatial frequency of the resulting pattern doubles each time you move one it­eration band closer to the set. Angle-slicing decom­position is admirably suited to displaying the field lines, as Fig. 4 indicates, and can be set to yield blocks of any desired width at any given iteration-number band, for any choice of the escape radius.

To this point we are on well-trodden ground, al­though I have not seen M-set images that utilize angle-slicing decomposition specifically to suggest field lines. Two experiments that I carried out resulted in an im-

Fig. 5. Mandelbrot set: Field lines.

Page 274: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

293

Fig. 6. "Sea Horse" in Mandelbrot set: Field lines.

Fig. 7, Tail of "Sea Horse": Field lines.

Fig. 8. Midget at Re=-1.99638 on spike: Field lines.

Page 275: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

294 KENELM W. PHILIP

Fig. 9. Mandelbrot Set. Fig. 12. Midget at Re=-1.99638 on spike.

Fig. 10. 'Sea Horse' in Mandelbrot set.

Fig. 11. Tail of'Sea Horse'.

proved ability to map M-set field lines, as described below.

I incorporated the angle-slicing routine in my own True BASIC color Mandelbrot program, and linked it to the "contrast color lookup table (GLUT)" coloring scheme I was using. In an RGB color system, one can make a simple contrast coloring scheme by taking the six simple colors (red, yellow, green cyan, blue, ma­genta) and cycling each one in turn through a preset

number of intensity levels. If M-set iteration numbers are then keyed to this so-called contrast GLUT, you get a coloring system that tends to accentuate structures that lie some distance from the M-set boundary.

Experimentation with this program yielded some rather striking color images in which the field lines can easily be traced. The distinct changes of intensity within each hue allow the field lines to be followed even within a block of a single hue, and the lai ge change of intensity between hues highlights the field line at the boundary. When the spatial-fi^uency doubling at higher iteration numbers makes the hue blocks too narrow for the in­tensity changes to show, the hue blocks themselves map the field lines. If the angle-slicing is set to a sufl5ciently small value, the electric field around the M-set is well mapped until one gets so close to the set that aliasing obscures the lines. Figures 9-12 show the field lines around the M-set and various features within the set according to this method.

Even angle-slicing decomposition shows a doubling of the number of "field lines" each time you move one iteration number closer to the set. It would be inter­esting to have a means of showing the field lines which, over at least a limited range of iteration numbers, would display a constant number of lines over a given angle independent of distance from the set. For the simpler case of black and white imaging, I was able to arrive at such a scheme by multiplying the color number within a given iteration band by an appropriate power of two to counteract the spatial-frequency doubling. The effect of this correction is shown in Figs. 5-8, which cover the same regions as Figs. 9-12. The decision not to follow the frequency-doubling correction down into the valleys in these figures was deliberate—the weak­ening of the field in the valleys would have led to the entire valley being colored black or white, with no in­dication of its interior field structure.

The Appendix discusses the code that produced these images.

REFERENCES 1. H.-O. Peitgen and D. Saupe, The Science of Fractal Im­

ages, Springer-Verlag, New York, 187-188 (1988). 2. H.-O. Peitgen and P. H. Richter, The Beauty of Fractals,

Springer-Verlag, New York, p. 163 (1986).

Page 276: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Field lines in the Mandelbrot set 295

3. H.-O. Peitgen and P. H. Richter, The Beauty of Fractals, Springer-Verlag, New York, 40-44, 64-76 (1986).

4. J. Corbit, personal communication, after J. D. Jones, I>e-composition: They went thataway—Another way of viewing the object. MFGD^L^, 13,2-3 (October, 1988).

APPENDIX Code for angle-slicing decomposition

Below is the iteration subroutine used to produce the color images. The plotting area used is 500 pixels wide by 4(X) pixels high, on a 640 X 480-pixel screen (Macintosh II). Another subroutine set up 240 colors to a sequence of 10 intensity steps each of red, yellow, green, cyan, blue, and magenta— making 60 different colors that repeat 4 times to occupy 240 successive color numbers. The language being used (True BA­SIC 2.01) allowed assignation of over 240 RGB colors to color numbers, which could be accessed by the ' ' SET COLOR colornumber' ' statement.

Variables are:

realcent: real value of the center of the plotting rectangle.

imagcent: imaginary value of the center of the plotting rectangle

mag: magnification in relation to a standard view of the region from —2.0 to +0.5 along the real axis, defined as having mag=l.

dwell: maximum iteration number ersqr; square of the escape radius

SUB Iterate 2r=0 zi=0 FORx=lTO 500 r=-l. 5/mag+realcent+x* (. 00625/mag) PORy=lTO400 i = -1,25/mag+imagcent+y* (.00625/mag) FOR n=l TO dwell zsqr=zr*zr—zi*zi zi=2*zr*zi+l zr=zsqr+r sizesqr=zr*zr+zi*zi IF sizesqr>ersqr THEN nn=n n=dwell

1 compute angle phi=atn(zi/zr) for Z

IF zr>0 THEN IF zi>0 THEN theta = phi ELSE theta=360+phi 1 set quadrant

ELSE theta=180-l-phi

END IF colr=int((theta*240)/360) Imap 240 color # s on to 360 degrees

SET COLOR colr/div+1 1 complete angle -slicing with parm 'div*

END IF NEXTn PLOTx+10,y+10 SET COLOR ' 'black* • zr=0 zi=0

NEXTy END IF

NEXTx END SUB

To produce the black and white field line images (Figs. 4-7), the line

SET COLOR c o l r / d i v + 1

was replaced with two lines:

IF nn<fl_dwell THEN co l r f l=co l r*2 (fl_dwell-nn) ELSE c o l r f l = c o l r

SET COLOR c o l r f 1 / d i v + l

where f l_dwell is set by trial and error so that the desired portion of the image is occupied by field lines without spatial-frequency doubling. The colors were set by having successive blocks of color numbers assigned alternately to black and white, and div was set to 1. The block size was set by trial and error for a reasonable width for the field lines.

The black and white binary decomposition images were made by replacing the entire angle-slicing section with a simple test for the sign of z i , coloring black or white according to sign. The black and white angle-slicing image (Fig. 3) was made by setting the 240 colors to alternate black and white in blocks of 60 (30 white and 30 black), using a d iv of 1.

Page 277: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 297

Chaos and Graphics

A TUTORIAL ON THE VISUALIZATION OF FORWARD ORBITS ASSOCIATED WITH SIEGEL DISKS

IN THE QUADRATIC JULIA SETS

G. T O D D MILLER^ Hartford Graduate Center, Hartford, CT 06120

Abstract—This article presents the use of computer graphics to gain a better understanding of the dynamics occurring in the Siegel disk Julia Sets. Traditional images of the Julia Sets usually display only the final behavior of the forward orbits of each point in the discretized complex plane. For each pixel in the image, a forward orbit must be computed—usually the information contained in the orbit is thrown away. This approach examines the orbit as well as its final behavior.

1. INTRODUCTION

The quadratic Julia sets arising from the familiar dy­namical system z„+i = f(z„) = zl + c where z, c are complex, have one of five basic morphologies: (a) a Jordan curve, homeomorphic to the unit circle; (b) a periodic basin of attraction; (c) a parabolic basin of attraction in which the Julia set reaches inward to the fixed point, (d) a dendrite where there is but one basin of attraction, and (e) the Siegel disk[l]. This paper will show how computer graphics can be used to gain a better understanding of the dynamics associated with the Siegel disk morphology.

2. VISUALIZATION OF A SIEGEL DISK

Figure 1 shows a representation of the Julia set Jc for the parameter c = -0.39054 - 0.58679i[l]. This Jc is one of many possible that have a Siegel disk. The space represented in the figure is a set of complex co­ordinates z E: 6' where ^ denotes the complex plane. Each pixel on the computer screen is mapped to a unique z. The algorithm[l, 2] iterates each z in turn by applying/(z) and in doing so produces a sequence of complex numbers. (See the Appendix for algorithm pseudo-code.) This sequence is called the forward orbit of z and is denoted as Or^{z) = {z, / ( z ) , / ( / ( z ) ) , . . . } . In Fig. 1, if the orbit remains bounded (that is | /"(z) | < 2 where/"(z) denotes the nth iterate off) then the pixel mapped to that z coordinate is colored black. If the orbit tends toward infinity ( l/"(^) I > 2) then the corresponding pixel is colored white. The complex plane (P has been partitioned into 2 disjoint sets called basins of attraction. The boundary between the 2 sets is the Julia set Jc. The set of black points is called the fiUed-in Julia set and is denoted as Kc= {ze(P|Or+(z)+^ 00 }. The complement of i c is the basin of attraction for the point at infinity denoted as ^(oo). Note that Jc is the boundary of ^(oo), de­noted as d^(oo) as well as the boundary of Kc such that dAioo) ^ Jc = dKc. Therefore, Fig. 1 is a visual­ization of the final behavior of the forward orbits. It says nothing about the orbit itself What path in (P does the orbit follow? Is it a random path or does it have structure? In the case of the Siegel disk the answer to this question is especially interesting.

^ Presently at Bolt Beranek and Newman Inc., Union Sta­tion, New London, CT 06320.

It turns out that the path of Or^(z) in a Siegel disk is very structured. This type of dynamical behavior was named after the German mathematician C. L. Sie­gel who discovered the case in 1942[ 1 ]. His discovery lead to the Kolmogorov-Arnold-Moser theory that at­tempts to explain the stability of the solar system. Fig­ure 2 show seven of the many orbits associated with the Siegel disk as rings of dots. Basically orbits from smaller peripheral buds make their way to larger and larger buds and finally to one of the many rings that make up the Siegel disk. Once the orbit makes it to the disk, it is trapped and simply revolves about the disk forever, never making it to the center of the disk where the fixed point is located. Jc in Fig. 2.0 is the same as the previous figure except Kc is colored white and ^ ( 00) is rendered as a collection of black and white contours called level sets. Some of the buds on Kc are labeled with capital letters. Kc is symmetric about the origin (z = 0 + 0/ in the center of image) and the labeling of the buds reflects that symmetry. It turns out that the ring associated with Or^{z) where z orig­inates in a peripheral bud is also associated with the symmetric image of that bud. For example, the forward orbit of z from the center of the bud labeled C becomes trapped in the same ring (the inner-most, smallest ring) as the forward orbit of z from the center of bud C. The association between peripheral buds and displayed rings is as follows (listing in order of increasing ring diameter): {C, C'}, {B, B'}, {F, F ' } , {G,G'},{A, A'}, { D, D'} and finally {E, E '} . Therefore the inner­most (smallest) ring is the Or^(z) where z E C or C and the largest ring is the Or^(z) where z G E or E'. Figure 2 was created by first plotting an image of Kc like in Fig. 1, then interactively prompting the user for a particular value of z for which the forward orbit was superimposed on the image.

Figure 3 shows a single forward orbit for z E D'. In this case, however, the topology ofOr^ is demonstrated by connecting the forward iterates. This presentation of the same data demonstrates not only do the iterates settle down to a particular ring in the disk, but the way that the iterates make up the ring. For example, one could imagine the first point of the ring being foUowed by the next iterate and so on around the rings perimeter, z,, Z/+1, Z/+2, . . . . This is clearly not the case, the trajectory seems to resemble that of a triangle, whose

Reprinted from Comput. & Graphics Vol. 17, No. 3, pag. 321-324, 1993

Page 278: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

298 G. T. MILLER

Fig. 1. Filled-in Julia set K_o.39054-o.58679i •

vertices are consecutive iterates, that is being rotated about its centroid. The resulting path of the vertices make up the points in the ring.

3. SIEGEL DISKS IN THE TRANSCENDENTAL JULIA SETS

The quadratic Julia sets are not the only ones ex­hibiting the Siegel disk dynamics. The Julia sets of the

transcendental function such as e^, sin z, cos z are other candidates. In fact the dynamical system defined by/(z) = X sin z where z,\^G has been investigated by R. L. Devaney [ 3 ] and associates. They have found a Siegel disk in the sine family at X = 0.6 -f- 0.8/ and have produced a video (available from the American Mathematical Society) showing the explosion of the Siegel disk as the critical points for /escape to infinity.

Fig. 2. Siegel disk visualization.

Page 279: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

A tutorial on the visualization of forward orbits 299

Fig. 3. Path from the forward orbit of D'.

4. CONCLUSION The time invested in creating fractal images such as

these is primarily dedicated to the computation of the forward orbit of each and every pixel in the image. After all the computations, only the final behavior of the orbit (convergence or divergence) is shown in most representations. By visualizing the orbit, a better ap­preciation for the underlying dynamics is achieved. Also the manner in which the orbit is visualized can give different information. For example, in Fig. 2 it was apparent that an orbit made its way to one of the rings and then was trapped on the ring, never pro­ceeding further to the fixed point in the center. Figure

2, however, did not show how the iterates made up the ring. This was displayed in Fig. 3, when the iterates were connected by lines. Figure 4 shows a larger col­lection of orbits in the region of the Siegel disk. Watch­ing the image unfold on the computer screen is es­pecially interesting as the rings seem to oscillate in and out from the center of the disk as some of the trajec­tories near the edge of the disk flare out away from the disk and then return. Although computer experimen­tation can never replace the rigor of the mathematics, visualization can enhance one's understanding of the phenomena being studied.

REFERENCES 1. H. O. Peitgen, P. H. Richter, The Beauty of Fractals,

Springer-Verlag, New York, (1986). 2. H. O. Peitgen, Fantastic deterministic fractals. In The

Science of Fractal Images, H. O. Peitgen and D. Saupe (Eds.), Springer-Verlag, New York, 189-190 (1988).

3. R. L. Devaney, An Introduction to Chaotic Dynamical Systems (2nd ed.), Addison-Wesley Reading, MA (1989).

APPENDIX The C-style pseudo-code for the generation of Fig. 1 is as

follows. For the Julia set with the Siegel disk p = -0.39054 and q = -0.58679, The value a is the screen resolution in pixels.

Fig. 4. Orbits in the region of the Siegel disk.

1

2 3 4 5 6 7 8 9

10

Let xmin = ymin = -1.5, xmax = ymax = 1.5, M = 100

dx = (xmax - xmin) / (a- l ) dy = (ymax - ymin) / (a- l ) for(nx=0 - • nx=a){

for(ny=0 -^ ny=a){ X = xmin+nx*dx; y = ymin+ny*dy; count = 0; while (x*x*+y*y<M and count < maxcount){

tempx = x*x — y*y + p; y = 2*x*y + q; X = tempx; count-f-+;

Page 280: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

300 G. T. MILLER

11 } 12 if(count= =maxcount) then 13 Plot—the point (nx,ny) 14 } end of ny loop 15 } end of nx loop

To draw something like Figure 2, insert a line after line 9 that will store the orbit as it is being computed.

9.1 xor[count] = x; yor[count] = y;

and then replace lines 12-13 with:

12 if(count==maxcount) 12.1 siegel (xor, yor, dx, dy); 12.2 else if (count%2==0) 12.3 Plot—the point(nx,ny)

Notice the subroutine siegel ( ) that does the plotting of the ring is only called for bounded orbits. The unbounded orbits will be plotted as the level sets in lines 12.2 and 12.3.

The subroutine siegel ( ) will expect the arrays xor, yor

and the floating point numbers dx and dy computed in the main program. This is a listing of the subroutine.

16 siegel (xor, yor, dx, dy) 17 float xor [ ], yor [ ], dx, dy; 18 { 19 int i, sx, sy; 20 for(i=0 to i<maxcount){ 21 screen—x = (int)((xor[i]-xmin)/dx); 22 screen y = (int)((yor[i]—ymin)/dy); 23 Plot—the—point (screen—x, screen—y); 24 } end of i loop 25 } end of subroutine

Notice that this code will plot all the forward orbits for the z Ei Kc along with the level sets of the points z ^ Kc. The picture will very quickly become too congested and one may want to do variations on the code to plot just a few of the rings. Perhaps the subroutine siegel could prompt the user for a particular z value, and then it could calculate the forward orbit as in the main program and plot the points associated with the orbit. Notice that lines 21,22 map the z-coordinates of the orbit from the C plane to the screen coordinates where as line 6 maps the screen coordinate (nx, ny) into the z-value of the C plane.

Page 281: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 301

Chaos and Graphics

IMAGE GENERATION BY BLASCHKE PRODUCTS IN THE UNIT DISK

HOI SUB KIM,^ HONG OH KIM^ and SUNG YONG SHIN* ^Department of Mathematics and *Department of Computer Science, Korea Advanced Institute of

Science and Technology, 373-1 Ku Song Dong Yusung Gu Taejon 305-701, Korea

Abstract—After the computer graphical representation of the mysterious Mandelbrot set in the late 1970s, computer graphics are contributing greatly to the representations of natural phenomena and structures of dynamical systems. In particular, the visual representation of the dynamics of a simple complex analytic map becomes a field of computer art. In this paper, the convergence patterns of sequences of partial products of infinite Blaschke products are visualized and are exploited to generate color graphics images.

1. INTRODUCTION

After the emergence of the fantastic computer-gener­ated images of the Mandelbrot set by B. Mandelbrot and the equally enticing mathematical work of Douady, Hubbard, and Sullivan in the late 1970s, re­newed attention was once again drawn to the rich structure of dynamical systems in the complex plane [4-6]. Computer graphics are contributing greatly to the generation of aesthestic art and the visual repre­sentations of mathematical functions and physical phenomena [7, 8].

A (finite or infinite) Blaschke product / is an in­teresting function in itself and plays a very important role in the analytic function theory. For example, any bounded analytic function / on the unit disc of the complex plane can be factored as a product of the Blaschke product B carrying all the zeros of /and an­other bounded analytic function^ without zeros having the same superimum norm as/. In this paper, the con­vergence patterns of sequences of partial products of infinite Blaschke products are visualized by color graphics images and are exploited to generate aesthetic graphics.

2. BLASCHKE PRODUCTS

Let D be the open unit disc in the complex plane and let {a„] be a sequence in D. Let

bniz) \an\ an- z a„ 1 - dnZ

and let

Bj,iz) = U^^ib„iz), N=U2,

We use the convention that \an\ an

1 when an = 0. If

the sequence {un} satisfies the Blaschke condition 2( 1 - |<2„|) < CO, then it is well known that 5iv(z) con­verges to a nonconstant analytic function B(z) in D whose only zeros are {a„} (counting multiplicities) [1-3]. This Umit function B(z) is called an infinite Blaschke product. But if {an} does not satisfy the Blaschke condition, we know that BN(Z) converges to

the zero function on the unit disc [2,3]. Here is a short and direct proof: If we note that x < e^~^ and

1 - \b„(z)\' = , _ ( 1 - \a„\^)(l - \z\')

11 - a„z\

then

\BAz)\ = n iwz)i

^expj,{\b„(z)\ - 1 )

: e x p - 2 ( I M z ) l ' - 1)

= e x p ( - i

^ e x p ^ - - -

1 ^ ( 1 - | a „ P ) ( l - \z\')

|1 -a„z\

• • - i ^ ' s d - K i ^ ) + \z\

< exp 1 1 - Ul 2 1 + |z | 2 ( 1 - I «J)j.

Since S r ( l - |«„|) = oo, \Bjs;{z)\ -^ 0 asTV^ oo. For more on Blaschke products, see [1-3].

3. THE METHOD OF IMAGE GENERATION

For a given sequence {an} inD, whether it satisfies the Blaschke condition or not, the partial product Bi^(z) always converges for each point z in D SLS N ^^ oo. Therefore, if we fix z in D, then the successive difference B]^(z) — Bis!+i{z) tends to zero as TV grows. For fixed small positive e, we associate the smallest natural number N^iz) to each point z in D so that | Bj^(z) — BN+I(Z)\ < e. If we assign a color corresponding to each number N^z), we get a graphics image that shows the pattern of convergence of the sequence of partial products ^iv(z).

In practice, we represent Z> as a finite set of grid points of mesh size h and use a finite number K of colors that can be displayed on the graphics terminal

Reprinted from Comput. & Graphics Vol. 17, No. 4, pag. 489-494, 1993

Page 282: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

302 H. S. KiM, H. O. KIM and S Y. SHIN

Fig. 1. a„ = 11 - ^^^j|^)exp(/v;rrT)

Fig. 2.a„ = (l- —!-j^jexp(/V^TT).

Fig. 4. a„ = (1 - ^^-^)exp( , \ /^TT)

Fig. 5. a„ = (1 - ^^^py^)exp(,V^TT)

Fig. 3.a„ = (l- ' jexp((V/;+ 1). Fig. 6. a„ = (1 - („+'i)0.i)exp(/V^TT)

Page 283: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Image generation by Blaschke products 303

of a computer. Choose a large number M. If N^z) > M for the grid point z, we set N^z) = M. We now assign a color corresponding to the number L = N,{z) (mod K) to the grid point z.

4. EXPERIMENTS AND OBSERVATIONS For a given tolerence € and a point z in D, N^z)

depends on the sequence {a„] of complex numbers. First, we consider an = Tne'^" with

rn= 1 1

(«+ 1) ( « + l ) ^ « = 1,2,

The parameters p and ^ measure the growth of r„ and ^„, respectively.

The "eyes" in Figs. 1-6 appear at the points a„. The point a„ appears as a zero in Bi^(z) only for N > n (provided Umi^ a„for m < n, as in our case), and so the eyes given by these zeros can have different colors. It is for this reason that eyes appear in figures with a„ not satisfying the Blaschke condition even though the limit function is identically zero. We emphasize that eyes appear at z = ^„ because the product BN(Z) con­verges (to zero) at a finite value of A' . The following argument may support that the eyes are asymptotically circular: We note that

\Bj,Mz)-Bj,{z)\

^N+l ~ Z

1 - a^+iz \Br,-Az)\

QN

| ^ iV- l (« iv ) |

11 - ivz

1 ^AT+i^AT 1 \aN\'

X \aN- z\ = yN+i\ciN- z\

for z near ajs/. Therefore, in a small neighborhood of UN, the points on the concentric circle around attend to have the same color in the graphics images. In Figs. 1 through 6, we can see the effects of the rate of r„ tending to 1 for a fixed sequence 6„ = ]l(n + 1. In Figs. 1 and 2, the sequences {a„} of zeros satisfy the Blaschke condition, and the images are generated with small number of eyes because the moduli go fast to one.

Figures 3, 7, and 8 are for g = 0.5, 0.7, and 1, re­spectively, for fixedp = \. The spiral patterns in these figures reflect the growth of the argument of a„ for different ^'s. As n becomes larger, the absolute value r„ approaches one, and thus the shape near the unit circle is complex because many eyes appear there. For a fixed p, we can observe the more detailed pattern changes by varying q gradually. Similar results can be obtained for different p's and ^'s.

We now choose a„ so that they are not dense in the unit circle. For example.

" (•- H )

Fig. 7. a„ = (1 - ^^j-^)exp(i(n + 1)»').

Fig. 8. fl„ = (1 - ' jexp(i(» + D).

Fig. 9. a„ = (1 - jexp(2Tm).

Page 284: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

304 H. S. KIM, H. O. KIM and S, Y. SHIN

Fig. 10. a„ = (1 - ^ j-j-jyj jexp(«>,).

Fig.ll.a„ = ( l - ^ ^ ) e x p ( ^ )

Fig. 13. a„ = (1 - ^^-^i^JexpdV^TT).

Fig. 14. a- = ( j - ' )exp(/(w + D).

Fig..2..„ = ( l - ^ ) e x p ( f ) . Fig. 15. Q„ = (-l)"^'(l - ' )exp(i(w + 1)).

Page 285: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Image generation by Blaschke products 305

ar,= <

Fig. 16.

(exp(0.07r/)- jexpf/——-J, « = 0(mod5)

|exp(0.47r/) - ^;^77yi)e^p(^";^ ' « 1 (mod 5)

^exp(0 .87rO-^^; -^jexp | /^ «-2(mod5)

| e x p ( 1 . 2 7 r / ) - ^ ^ ^ ^ j e x p | / ^ j , «-3(mod5)

( e x p ( 1 . 6 . / ) - ^ ^ ) e x p ( / ^ ) , « ^ 4 ( m o d 5 ) .

1 - jexpl ( « + l )

x^¥A T^¥A

Fig. 17.

O.OTT II, n = 0(mod5

0.47r I I, « = 1 (mod 5

«+ \)l

O.STT II, « = 2 (mod5) «+ 1//

1.2ir ^ j ] , « = 3(mod5)

II, «^4(mod5) 1 . 6 7 r -

for fixed A o- The zeros a„ head out to the unit circle in a periodical pattern of period Ao • This pattern is reflected in the following figures.

In Fig. 9, the zeros appear as eyes on its right. The concentric circles around the point at - 1 reflect the following fact:

the images in Figs. 16 and 17. Figure 18 is a simple black-and-white rendition of Fig. 2 using the rule L = NJ^z) (mod 2) for assigning black and white to each point.

For the graphics in this paper, we choose € = 10"^, h = 0.002, M = 5000 and K = 256 except for Fig. 13,

^ B^(-\)

1 + QN+I

(1 -^iv+i) ( l + z ) 1 - a^+iz

1 - ciN+i

1 + aN+ - | l + z | ,

1 + z |

for z near — 1. The points z on a small concentric circle around the point at - 1 tend to have the same number N^z) and hence the same color. This pattern is also reflected in Fig. 11. In Figs. 10 and 12, we can observe that these effects are interfered by respective zeros on the opposite rays. Finally, we make some variations in choosing zero sequences and in color assignments.

Figures 13 and 14 have the images like a "jewel" and a "shellfish," respectively. A minor modification of{a„} in Fig. 8 generates a completely different image in Fig. 15. Similar experiments are performed to obtain Fig. 18.a„ = | l - ^ ^ ^ ^ jexp(/V^TT)

Page 286: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

306 H. S. KIM, H. O. KIM and S. Y. SHIN

for which K= 44. They are generated on HP9000 with the screen resolution of 1280 X 1024.

5. CONCLUSION The computer graphical representation of conver­

gence patterns of sequences of partial products of in­finite Blaschke products gives a method of generating various color images, illustrating the convergence pat­terns, and producing beautiful graphics images. The flexibility of this method is the arbitrariness of the choice of zero sequences. The graphics can be trans­formed in principle to any simply connected region that is not the whole plane by a conformal mapping. We can also apply this method to other infinite prod­ucts for generating images.

Acknowledgement—We wish to gratefully acknowledge the helpful comments of referees on this paper, which greatly im­proved its quality and to express our gratitude to the CAD

Department, Samsung Electron Devices, Ltd. for allowing us to use their facilities. The second author was partly supported byTGRC(KOSEF).

REFERENCES 1. P. Colv^eW, Blaschke Products, The University of Michigan

Press, Ann Arbor (1985). 2. P. L. Duren, Theory ofH'' Spaces, Academic Press, New

York/London (1970). 3. W. Rudin, Real and Complex Analysis (3rd ed.) McGraw-

Hill, New York (1986). 4. M. Barnsley, Fractals Everywhere, Academic Press, New

York (1988). 5. R. L. Devaney, An Introduction to Chaotic Dynamical

Systems, Addison-Wesley, Reading, MA (1989). 6. H.-O. Peitgen and P. H. Richter, The Beauty of Fractals,

Springer Verlag, New York (1986). 7. C. A. Pickover, Mathematics and beauty: Time-discrete

phase planes associated with the cyclic system. Comp. & Graph. 11,217-226(1987).

8. C. A. Pickover, Mathematics and beauty: Turbulent complex curls. Comput. & Graph. 11, 499-508 (1987).

APPENDIX. THE PSEUDO-CODE FOR DRAWING FIGS. 1 THROUGH 8

C C C C c c c c c

A(I) TOL P Q GRIDSIZE IN

COLOR-TABLE COLOR

THE ZEROES OF A BLASCHKE PRODUCT. THE TOLERANCE. THE POWER FOR RADIUS. THE POWER FOR ARGUMENT. THE MESH SIZE. THE MINIMUM NUMBER SATISFYING THE TOLERANCE TO WHICH WE ASSIGN A COLOR. THE RESERVED COLOR AT HP9000. THE COLOR ASSIGNED TO THE PIXEL.

COMPLEX*8 A(5000),CC,BP,Z,OLDBP

READ*,P,Q READ*,GRIDSIZE CC=(0.,1.) TOL=l.E-5 GENERATE THE ZEROES OF A BLASCHKE PRODUCT.

l./FLOAT(I+l)**P)*CEXP(CC*FLOAT(I+l)**Q) DO 1=1,5000

A(I) = (1. ENDDO

COMPUTE THE MINIMUM NUMBER AND ASSIGN COLOR. DO X = -l.,l.,GRIDSIZE

DO Y=-l.,l.,GRIDSIZE IF((X*X+Y*Y).LE. l.)THEN

Z=X+CC*Y BP=(1.,0.) OLDBP=(1.,0.) IN=5000

DO 1=1,5000 BP=BP*CABS(A(I))/A(I)*(A(I)-Z)/(I.0-CONJG(A(I))*Z) IF(CABS(BP-OLDBP) .LT. TOL) THEN

IN=I BREAK

ELSE OLDBP=BP

ENDIF ENDDO

ENDIF COLOR=COLOR_TABLE(MOD(IN,256)) WRITE THE PIXEL AT (X,Y) WITH COLOR

ENDDO ENDEX) END

Page 287: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 307

Chaos and Graphics

AN INVESTIGATION OF FRACTALS GENERATED BY z ^ X/z^n + c

KEN W . SHIRRIFF 571 Evans Hall, University of California, Berkeley, CA 94720

Abstract—This paper explores methods of generating fractals from the mapping z^>^ z~" -\- c and discusses the structure of the resulting images. Lyapunov exponents and cycle periodicity show details of these fractals that are obscured by prior escape-time techniques. The resulting fractals are shown to have a hypocycloid shape. The associated Julia sets can be classified into a variety of types.

1. INTRODUCTION

Several programs and papers have used escape-time methods to produce images of fractals based on the complex mapping Eq. (1), where exponent «is a pos­itive integer.

z-"" + c (1)

However, these methods do not clearly show the fun­damental structure of the fractals. This paper explores alternative methods of generating these fractals that reveal new structures. These methods are Lyapunov exponent computation and cycle periodicity checking.

2. GENERATING THE FRACTALS

Fractals have been generated from Eq. (1) using es­cape-time techniques, for example by Gujar and Bhavsar[l] and Glynn[2]. Figure 1 shows a c-plane escape-time fractal generated by starting with an initial z value, iterating the mapping (Eq. 1) with exponent « = 2 and c depending on the pixel, and stopping if the magnitude of z exceeds a fixed bound. Note that the initial value ZQ should be infinity, since infinity is the critical point of Eq. (1). However instead of starting with ZQ = infinity, it is simpler to start with Zi = c, which yields the same result. (A critical point of z ^• F(z) + cis a point where F'(z) = Q. The role of critical points is explained in [ 3 ].)

The escape-time technique is not as satisfactory for Eq. (1) as it is for fractals such as the Mandelbrot set, due to the difference in dynamics between the two mappings. For the Mandelbrot mapping, z^^ z^ •\- c, infinity is an attracting value; sufficiently large z values will diverge to infinity. However, the mapping in Eq. (1) doesn't diverge to infinity since large z values get mapped back near c. As a result, looping until z is large is not a rigorous stopping condition for mapping Eq. (1); the structure of the fractal strongly depends on the stopping radius, as Glynn found in [2]. This is illustrated by Fig. 2, which shows a fractal generated by the same method as Fig. 1, but with a stopping radius of 10 instead of 3. This suggests that much of the structure of the fractals in Figs. 1 and 2 is an artifact of the stopping criterion. The remainder of this paper examines methods of generating fractals from Eq. (1) that avoid these artifacts.

One method of displaying the fractals is to compute

the Lyapunov exponents of the mapping in Eq. (1). Figure 3 shows the results of this process for « = 2; black points are those with a positive Lyapunov ex­ponent, corresponding to chaotic behavior. According to [4], the Lyapunov exponent X for the mapping z„+i = F{Zn) -\- c can be computed from:

X= lim - Z ln\F'{z„)\ (2)

A positive Lyapunov exponent indicates chaotic be­havior, and a negative Lyapunov exponent indicates stable behavior. For Fig. 3, the Lyapunov exponent was approximated at each point by performing 250 iterations of the mapping in order for the values to settle, and then summing Eq. (2) over the next 250 iterations. (See [4] for more details on computing Lyapunov exponents.)

The Lyapunov method reveals several new features of the fractal, as can be seen by comparing Fig. 3 with Fig. 2. The main difference is that the large dark circular regions of Fig. 2 have disappeared; they are artifacts of the escape-time techniques. These regions corre­spond to areas that are mapped near infinity by Eq. (1), causing them to exceed the escape-time bound. Figure 3 is much less dense than Fig. 2; it has a lace­like structure and numerous voids. Figure 3 probably shows the fundamental structure of the fractal; its shape does not depend on arbitrary values such as the escape bound.

Figure 4 shows a detail of a very small part of Fig. 3; this detail reveals several interesting things. First, there are numerous stable triangular structures resem­bling the quartic Mandelbrot set generated by z - • z"* + c. Presumably these arise because iterating z~^ twice results in z"*. Second, Fig. 4 is roughly self-similar; zooming in on Fig. 4 to any level of detail results in an image resembling Fig. 4. Finally, all the unstable parts of Fig. 3 appear to have small details resembling Fig. 4. Thus, there doesn't seem to be any uniformly chaotic part of the fractal; there are tiny stable regions everywhere. This probably accounts for the lace-like structure of Fig. 3.

A second technique for generating a fractal from Eq. (1) is to color points according to the periodicity of the resulting sequences. For each c value, we can

Reprinted from Comput. & Graphics Vol. 17, No. 5, pag. 603-607, 1993

Page 288: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

308 K. W. SHIRRIFF

-**^i

Fig. 1. Escape-time fractal generated from z -^ z~ + c. The initial z value is c; the escape condition is \z\ > 3. Dark

points diverge quickly; white points are stable.

iterate the mapping and test if the resulting sequence of z values approaches a cycle. Points leading to cycles can be colored according to the length of the cycle, and points that never enter a cycle but wander cha^ otically can be left black. (An algorithm for finding cycles is given in [5].) Figure 5 shows the results of this process. There is an outer white area in which z converges to a fixed point, a central red region that converges to a 2-cycle, other regions that converge to

Fig. 3. Lyapunov exponent fractal generated from z-*- z~^ + c. Stable points (/>., those with negative exponents) are white;

unstable points are black.

longer cycles, and black points that apparently don't converge to cycles.

If we color periodic points white and nonperiodic points black, we obtain an image nearly identical to Fig. 3. This is not surprising since stable cycles have negative Lyapunov exponents. (Mandelbrot [6] and Peitgen and Richter [7] applied a similar coloring technique to z -^ X(z - 1/z). Interestingly, the re­sulting image contains quadratic Mandelbrot set "is­land molecules" analogous to the quartic Mandelbrot sets that appear in Fig. 4.)

2.1. Structure of the fractal By examining fixed points, we can mathematically

determine the basic shape of the fractal. Consider the

Fig. 2. Escape-time fractal generated from z -^ z ^ + c. The escape condition is \z\ > 10.

Fig. 4. A very small detail of Fig. 4. The coordinates are 0.546 <x< 0.547, 0.620 <y< 0.621. The stable points are white.

Page 289: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Investigation of fractals 309

Fig. 5. Fractal generated from z ^^ z" + c, colored according to periodicity of the mapping. Short cycles are colored ac­cording to length: 1 = white, 2 = red, 3 = orange, 4 = yellow, 5 = green, 6 = blue. Points that did not converge to a cycle

are colored black.

c values that result in convergence to a fixed point of Eq. (1). A fixed point of Eq. (1) will satisfy

second term corresponds to a fixed point; cancelling this term and dividing by zc yields z~' + zc = c~K Now, for stability | dldz{(z-^ + c)"^ + c)| < 1. This simplifies to | (z~' + zc)'^ \ < 2~^'^. Finally, combining the two equations yields \c\ <2~^'^, proving the 2-periodic region is a circle.

For n = 3, the 2-periodic region is given by c = ± V(2 + a^ where \a\ <?>~^'^. This follows from the sta­bility condition | d/dz{{z~^ + c)~^ + c)| < 1, which yields Kz'^ + zc)"M < 3~ ' /^ Defining a = (z'^ + zcy^ and algebraically manipulating the 2-cycle con­dition (z~^ -\- cy^ -\- c = z yields the equation specifying the region. A similar derivation shows that for « = 2, the 3-periodic regions are given by c^ = —(\ -\- a -\-a^), where \a\ < 1/2; these are the three orange car-dioid-like regions in Fig. 5.

The fractals generated from Eq. (1) have rotation and reflection symmetries. As conjectured by Gujar and Bhavsar in [ 1], the fractal generated with exponent « is (« + 1 )-way rotationally symmetric. This can be seen since if/(z) = z"" + c, g(z) = z'" + ^2.'/(«+i)^^ and h(z) = ^27r//(«+i) ^ ^y^^^ ^^y ^^^ ^ ^^ /and g are topologically conjugate by homeomorphism h. There­fore the parameter values c and ^2ir//(«+i)^ result in the same dynamic behavior and the fractal is (« + 1 )-way rotationally symmetric. (In other words, rotating c by 2,r/7(«+i) sinf piy rotates terms in the resulting z se­

quence by the same amount.) Similarly, if/(z) = z~" + c, g(z) = z~" + c, and h{z) = z, then / and g are topologically conjugate. Thus, c and c yield the same dynamic behavior, so the fractal is symmetrical by re­flection in the real axis.

c = z — z

For a stable cycle, the derivative of Eq. (1) must have magnitude less than 1; that is, \-nz~

\z\>n'^^"^'^ (4)

(3) 2.2. Julia sets A z-plane Julia set can be generated from Eq. (1)

by fixing c and varying the starting z value in the plane. < 1 so Gujar, Bhavsar and Vangala have used escape-time

techniques[8] to create z-plane fractals from Eq. (1).

Thus, the fixed point region in the c-plane (the white region in Fig. 5) is given by Eq. (3), where z satisfies Eq. (4). (A similar analysis is applied to the Mandelbrot set by Branner in [ 3 ].)

Geometrical analysis of Eqs. (3) and (4) shows that the boundary of the fixed point region forms a « + 1 cusped hypocycloid. (A hypocycloid is the curve formed by rolling a smaller circle inside a larger circle and tracing a fixed point on the circumference of the smaller circle.) The radius of the outer fixed circle for the hypocycloid can be computed as \z\ + \z~"\, where z satisfies Eq. (4), resulting in a radius of (« + J )„-«/(«+!) Yhe radius of the inner moving circle is |z""|, yielding n~"^^"'^^\ Figure 6 shows the fractal generated from z ->• z"" + c using the Lyapunov ex­ponent method; note the hypocycloid shape of the outer boundary.

For n = 2, the 2-periodic region is a circle with radius 2~^^^; this is the red region in Fig. 5. To see this, note that a point with period 2 must satisfy (z"^ + c)"^ + c = z, and thus {c- z-\- c^z^)( 1 + cz^ - z^) = 0. The

Fig. 6. Lyapunov exponent fractal generated from z -*• z-^ + c.

Page 290: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

310 K. W. SHIRRIFF

A different way to generate Julia sets that avoids escape-time problems and results in new images is to iterate each z value and examine its cyclical behavior. For example, pick a c value such that if iteration is started with zo = c, the result is convergence to an attractive cycle of length 2. Call the two values in the cycle a and /?. If we now iterate the mapping consisting of Eq. (1) composed with itself, which we will denote as/^(z), the cycle of length 2 becomes a fixed point, either a or h. Finally, for any z value in the plane, we can iterate /^(z), see if it converges to ^ or to Z), and color the associated pixel one of two colors.

Figure 7 shows the result of the fixed-point coloring process applied to c = 0.106 + 0.619/. (This c value is near the edge of the central red circle in Fig. 3.) The Julia set is the boundary between the black and white regions in Fig. 7, and consists of z values that don't converge to the cycle. (Note: the exponent in Eq. (1) is « = 2 for all images in this section. Julia sets with other exponents can be generated similarly.)

The Julia sets corresponding to longer cycles can be computed in a similar way. Fig. 8 shows the fiUed-in Julia set generated from c = 0.48 + 0.9/. The c value is in the large upper-right orange circle of Fig. 5 cor­responding to a cycle of length 3. Thus, most z values converge to a stable 3-cycle, and there are three fixed points of/^(z), resulting in the three colors of regions in Fig. 8. Figure 9 shows the filled-in Julia set for c = 0.72 + 1.05/; the corresponding cycle is of length 7, resulting in 7 regions. Note that the regions never meet along an edge, but only at single points where all 7 regions meet. (This follows from a theorem[9] that the Julia set of a rational function is the frontier of the stable set associated with any fixed point. Thus, any boundary point must be on the border of every region.)

Based on experimental image generation, it appears that the Julia sets can be roughly categorized. A c value

Fig. 8. Filled-in Julia set generated ft-om z ^^^ z~^ + c with c = 0.48 + 0.9/. This c value is in the upper right large orange region of Fig. 5 and generates a cycle of length 3. Points are

colored according to the fixed point of/^(z).

that results in convergence to a fixed point {i.e., a c value in the white region of Fig. 5) yields a Julia set that is a Cantor set. A c value that converges to a cycle of length 2 (i.e., the red region in Fig. 5) results in a Julia set that is a simple closed fractal curve between two regions, as in Fig. 7. As the c values approaches the boundary of the red region, the Julia sets becomes more jagged. For c values in one of the large rounded regions centrally located in an arm, touching two white regions in Fig. 5, the Julia sets are resemble Fig. 8. These Julia sets are reminiscent of fractals generated by finding basins of attractions of Newton's method [ 7 ]. For c values in one of the buds off the white region in Fig. 5, the Julia sets resemble Fig. 9, with large regions with complex boundaries that pinch together at various points. Other c values corresponding to stable values result in a Julia set that is somewhat

Fig. 7. Filled-in Julia set generated from z ->- z" + c with c = 0.106 -I- 0.61^/. This c value is near the edge of the central red regiori of Fig. 5 and generates a cycle of length 2. Points are colored according to the corresponding fixed point of

fHz).

Fig. 9. Filled-in Julia set generated from z -^ z~^ -\- c with c = 0.72 + 1.05/. This point is in a small bud off the right-hand white region of Fig. 5 and generates a cycle of length 7. Points

are colored according to the fixed point of/^(z).

Page 291: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Investigation of fractals 311

foam-like, with many rounded regions of various sizes packed together. For c values corresponding to unstable values, we were unable to generate Julia sets by the cycle-finding method, as the iteration was not cyclical. The Julia set classifications appear to generalize to ex­ponents other than « = 2.

The Julia sets generated from Eq. (1) are «-way ro-tationally symmetric, as conjectured by Gujar, Bhavsar, and Vangala[8]. Since (^^"/"zo)"'' + 0 = 20" + ^, the rotation of ZQ drops out in the first iteration. In general, the Julia sets are not symmetrical by reflection unless c is real.

3. CONCLUSIONS Interesting fractals can be generated from z ^*' z~"

+ c by computing Lyapunov exponents and by deter­mining the periodicity of cycles. These fractals have a detailed structure that is obscured by the escape-time method of computation. The corresponding Julia sets yield a variety of structures.

There are several avenues for future research. Equa­tion (1) can be analyzed for noninteger or even com­plex exponents by the use of the Lyapunov and cycle techniques, extending the analysis of Gujar et al The techniques of this paper can also be used with other formulas besides Eq. (1); the techniques may be es­pecially useful for formulas such as z ^^ (z)~" + c or z -^ cosh(z) + c [10] that do not diverge to infinity.

Acknowledgments—This research was supported by an IBM Graduate Fellowship. The Pbmplus package of image tools by Jef Poskanzer was of great assistance in generating the figures. Photography was courtesy of Steven Lucco.

REFERENCES 1. U. G. Gujar and V. C. Bhavsar, Fractals from z -^r- z" +

c in the complex c-plane. Comp. & Graph. 15, 441-449 (1991).

2. E. F. Glynn, The evolution of the gingerbread man, Comp. & Graph. 15,579-582(1991).

3. B. Branner, The Mandelbrot set, Proceedings of Symposia in Applied Mathematics, 39. Published as Chaos and Fractals: The Mathematics Behind the Computer Graph­ics, ed. R. L. Devaney, L. Keen, 75-105 (1989).

4. M. Markus and B. Hess, Lyapunov exponents of the lo­gistic map with periodic forcing, Comp. & Graph. 13, 553-558(1989).

5. S. T. Welstead and T. L. Cromer, Coloring periodicities of two-dimensional mappings, Comp. & Graph. 13, 539-543(1989).

6. B. B. Mandelbrot, The Fractal Geometry of Nature, W. H. Freeman, New York (1983).

7. H.-O. Peitgen and P. H. Richter, The Beauty of Fractals, Springer-Verlag, Beriin (1986).

8. U. G. Gujar, V. C. Bhavsar, and N. Vangala, Fractals from z <- z" + c in the complex z-plane, Comp. & Graph. 16,45-49(1992).

9. P. Blanchard, Complex analytic dynamics on the Rie-mann sphere. Bull. Am. Math. Soc. 11, 85-141 (1984).

10. C. Pickover, Computers, Pattern, Chaos, and Beauty, St. Martin's Press, New York (1990).

Page 292: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 313

Chaos and G raph i c s

INFINITE-CORNER-POINT FRACTAL IMAGE GENERATION BY NEWTON'S METHOD FOR SOLVING

exp (-f^) - 1 0

Y O U N G BONG K I M , ^ H O I SUB K I M , * H O N G O H K I M , * and S U N G Y O N G SHIN^ ^Department of Computer Science and *Department of Mathematics, Korea Advanced Institute of

Science and Technology, 373-1 Ku Song Dong Yusong Gu, Taejon 305-701, Korea

Abstract—Newton's method is sensitive to an initial guess. It exhibits chaotic behavior that generates interesting fractal images. Most of them have either a finite number of attractors (attractive fixed points) or unbounded

Julia sets. In this paper, we show that Newton's method for a family of equations exp I -a 1 - 1 = 0

(for « > 0 and | f | = 1) has infinitely many attractors and a bounded Julia set. The dynamics of Newton's method for finding their roots are also visualized.

1. INTRODUCTION

Consider the complex polynomial p{z) = z^ — 1. Newton's method is often employed to numerically find a root of the equation p(z) = 0 [1 -3 ] . A root of p(z) = 0 is the limit of a sequence {zk} of complex numbers generated by this method with a proper initial guess ZQ. Therefore, each of its roots plays the role of an attractor (attractive fixed point) when Newton's method is applied to solve the equation p{z) = 0. In other words, the three roots are competing with each other to attract ZQ. The set of starting points whose generated sequences converge to a root forms a basin of attraction for Newton's method. It is well-known that the boundary of each basin of attraction is the Julia set of Newton's method. As illustrated in Fig. 1, this Julia set consists of three-comer-points with respect to the basins of attraction of the roots ofp{z) = 0 [ 2 ] . That is, three basins of attraction meet at every point in the set. By the same token, the Julia set of Newton's method for z" — 1 = 0 consists of «-corner-points with respect to the basins of attraction of the n roots of unity.

It is natural to expect that more interesting graphical images can be obtained if an equation has infinitely many roots. A suitable limit ofz"— 1 = O a s « ^ ' oo is ^^ — 1 = 0 whose roots z = Ikiri, where k is an integer, are unbounded and form attractors of New­ton's method for e^ - 1 = 0. Its unbounded Julia set consists of infinite-comer-points, and its inversion with respect to a circle appears in [4, 5 ] . By allowing an equation with singularities, a bounded Julia set of in­finite-corner-points can be obtained without a deco­rative touch such as a circle inversion.

In this paper, we consider a family of functions

Mf,«(z) = exp hn (1)

where « > 0 and | f | = 1 [6, 7 ] . It has a singularity at z = f. The equation

This research is supported by TGRC and KOSEF.

Ma^) - 1 = 0 (2)

turns out to have all its infinite number of roots on the unit circle. The minor defect is the singularity at f, which can easily be avoided in image generation.

The behavior of Newton's method for Eq. (2) is analyzed to present a number of fractal images that are rather complicated and aesthetic. In Section 2, we show that Eq. (2) has infinitely many roots on the unit circle, and Newlon's method for solving this equation also gives an extra attractor at infinity. Section 3 pre­sents color graphical images to visualize its behavior. Concluding remarks are given in Section 4.

2. ATTRACTORS OF NEWTON'S METHOD

Newton's method for the equa t ion / (z ) = 0 has the form Zk+i = N(Zk), where A^(z) = z - / ( z ) / / ' ( z ) . The simple roots o f / ( z ) = 0 are fixed points of A/^(z), and they act as attractors of Newton's method since the derivative N'{z) = f(z)f"{z)/(f (z))'^ vanishes there. That is, a Newton sequence {zk} converges to a root o f / ( z ) = 0 if an initial value ZQ is properly chosen. For a simple root z^, the set of initial values where Newton sequences converge to z* is called the basin of attraction of z* [ 1, 2, 8, 9 ] .

The attractors of Newton's method for Eq. (2) are the roots of the equation. For a > 0, the roots f satisfy

a -—^ = Ikiri, k integer.

If we set f = ^"^, then the roots have the form ^k = e'^'' where

a cot

dk = (l)-\- 2 cof

( ^ ) 2^71

•m A: integer. (3)

Reprinted from Comput. & Graphics Vol 17, No. 6, pag. 705-711, 1993

Page 293: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

314 Y. B. KIM, H. S. KIM, H. O. KIM and S. Y. SHIN

Fig. 1. Three basins of attraction of the Newton's method for z - 1 = 0.

Fig. 2. Roots of M,,,o( ) - 1 = 0

Therefore, Eq. (2) has infinitely many roots ^^ = ' * on the unit circle. These roots are symmetrically located about the singular point f. That is, for an integer m, f and J_w are symmetric about the ray of angle 0. Most of the roots cluster near f. We can observe that as a decreases the corresponding roots ^^ = "' get closer to the singular point f.

The explicit form of Newton's method for Eq. (2)

N^(z) = z + 2af

1 - exp m)] (4)

For the function T^{z) = 1 /N^{ 1 /z) , we observe that TfCO) = 0 and T\{0) = 0. That is, z = 0 is an attracting fixed point for T^{z), whence z = oo is an attracting fixed point for N^(z). In particular, we show that if

\z\ > 2 + 4a

-a/2 • (5)

then A f(z) -> oo as /c -^ oo. First, we note that the right hand side of Eq. (5) is bigger than 3 and hence

exp exp a Re

exp

< exp —a (|z| + 1 W

; exp (6)

From expression (4) and estimate (6), we have

|A^,(z)| > - ! - | z - f | 2a 1 - exp m) |z|

S 7 - ( U I - 1)'(1 -e""')- \z\ la

= ui \ la

1 - e-i^

>\A[—Z \z\-\ 2a

> \z\.

•/2 I _ p-«n - \ 2 \

' ^ )

1 - e- + a\

Table 1. Color mapping scheme for basins.

Basin of attraction

Singular point Point at infinity P* farthest zero 2""* farthest zeros 3'* farthest zeros 4*" farthest zeros 5 '' farthest zeros 6*'' farthest zeros 7* farthest zeros 8'*' farthest zeros 9 '' farthest zeros lO"' farthest zeros 11*** farthest zeros 12''' farthest zeros 13*'' farthest zeros 14*'' farthest zeros 15*'' farthest zeros Remaining zeros

Assigned color

black medium orchid royal blue red dark orange gold light goldenrod yellow green green pale green light sea green cyan cornflower blue steel blue dark violet magenta medium violet red yellow

The value of r, g, b (0-255)

0:0:0 186:85:211 65:105:225 255:0:0 255:140:0 255:215:0 255:221:130 173:255:47 0:255:0 152:251:152 32:178:170 0:255:255 100:149:237 70:130:180 148:0:211 255:0:255 199:21:133 255:255:0

Page 294: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Infinite-corner-point fractal image generation

Table 2. Color mapping scheme for convergence behavior.

315

No. of Iteration

1 2 3 4 5 6 7 8 9

10 11 12 13 14 15 16 17 18 19 20

Assigned color

lime green DodgerBlue3 pink4 RoyalBlue3 gold3 indian red green4 yellow! bluel magental turquoise MediumPurplel chocolate 1 RosyBrown 1 snow3 ivory4 Sky Bluel 01iveDrab2 marmoon2 Misty Rose2

The value of r, g, b (0-255)

50:205:50 24:116:205 139:99:108 58:95:205 205:173:0 205:92:92 0:139:0 105:205:0 0:0:205 255:0:255 0:245:255 171:130:255 255:127:36 255:193:193 205:201:201 139:139:131 135:206:255 179:238:58 238:48:168 238:213:210 Fig. 4. A magnification of the rectangle in Fig. 3; window:

-7.0 < Re z < 7.0, -7.0 < Im z < 7.0.

provided

I - e-

la

or

\A

\z\ > 2 +

+ a > 1,

Therefore, we have |iVf(z)| > | z | for z in the region satisfying inequality (5) . This means that Newton se-

Fig. 3. Basins of attraction of the Newton's method for Mi,io(^) - 1 = 0 ; window: -35.0 < Re z < 15.0, -25.0 < Im z <

25.0.

quence {z^} generated by an initial value ZQ in the region satisfying inequality (5) always diverges to in­finity. That is, the region satisfying inequality (5) is contained in the basin of attraction of the attractor at infinity. Therefore, the basins of attraction of the roots of Eq. (2) are contained in a finite region

Ul ^2 + -4a

and so is the Julia set of Newton's method. This fact will be used to determine the threshold value L for testing the divergence of an orbit in image generation in Section 3.

On the other hand, each root of the Eq. (2) attracts orbits starting from its neighboring points. For a root

^k of Eq. (2 ) , if we note expl -a- ^ I

^_ 2ai{z-^,)

1 and set

(f-^)(r-6) for computational simplicity, we

have

A^f(z)-^, = z - f , + (f-^r 2af

X e x p l - . ^ j

( f - z ) ^

1 - exp ( " ^ )

= 2 - f * + • 2af

X 2-kk

b (r-z)(z-^.)

)1

Page 295: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

316 Y. B. KiM, H. S. KIM, H. O. KIM and S. Y. SHIN

<l\z-ik\.

, 9 i r - a i + 10

exp 2a

9 | f - f . |

Fig. 5. The flower when a = 10; window: -7.0 < Re z 7.0, -7.0 < Im z < 7.0.

1 1 2

(z - «*) -('-F^) 1 + - ^ + - ^ ^ +

( z - f * )

( z - 6 ) -

If-aj ^ ^ ^ ^ 3 i ^ ^

^ - ^ ^ -

f-^* 1 1 ,

oc^

( f - Z ) ( f - ? , )

2 2 ,

Suppose that |z - JJ < If - ?;tl/10. Then \z - f| 2a

> 9 | f - J , | / 1 0 a n d s o M | < 9 | ^ _ ^ | • ^ow, we

can estimate \N^(z) - ik\ as follows:

\N,{z)-ik\ ^ \ z - h I

I f - ? .

+ • l f - 2 | | f - f ; t l

1 l^-?. l '

lOa

9 | f - ? . |

f - f . l

• j e x p d ^ j )

yexpCMI)

e x p ( M | ) |

exp(MI)

l 9 | f - f , | + 10a^''^\ 9

2a \1 f - fJ / j (7)

then \N^{z) ~ ^k\ < \z - ^k\' Therefore, it follows that Nfiz) ^^ {;t as m -^ 00. That is, the points in the region satisfying inequality (7) are contained in the basin of attraction of the root ^k- This fact will be used in determining the threshold value e for testing the convergence of an orbit to an attractor ^k in image generation in Section 3. For a = 10 and 0 = 0, some of the roots of Eq. (2) with regions satisfying inequality (7) (indicated by small circles) are shown in Fig. 2.

We show explicitly that if two points ZQ^^ and ZQ^^ are symmetric about the ray of angle 0, then the orbit of two points behaves symmetrically about the ray. For f = I where </> = 0, we note that

N,(z) = z + i\-zy la

1 - exp ( . 1 + z

\ 1

A^.(^). (8)

Fig. 6. The flower when a = 5; window: -4.0 < Re z < 4.0, -4.0 < Im z < 4.0.

Page 296: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Infinite-corner-point fractal image generation 317

Fig. 7. The flower when a = 1; window: 0.4 < Re z :S 1.6, -0.6 < Im z < 0.6.

The relation (8) shows that if the orbit of a starting point ZQ tends to a root JAC, the conjugate point ZQ gen­erates the sequence converging to the root ^-k. There­fore, the Julia set for f = 1 is symmetric about the real axis. When f = ^" , we can easily see that

7Vf( e''^z) = e^'^z + (^/0 _ ei<t>^)2

lae''

1 — expla e"^ + e"^z

\ e'' e'^z

e'^^N.iz). (9)

The relation (9) indicates that the dynamics of N^(z) are conjugate to that of iVi (z) by the multiplication of e''"'. From the relations (8) and (9), we can explain that as (t> increases, the corresponding Julia set rotates counterclockwise about the origin.

3. GRAPHICS IMAGE GENERATION AND OBSERVATIONS

In this section, the behaviors of Newton's method for solving Eq. (2) such as the basins of attraction and its convergency are graphically presented. As analyzed in the previous section, Eq. (2) has infinitely many roots lying on the unit circle. Therefore, it is not pos­sible to identify all of them. As shown in Fig. 2, most of the roots cluster near the singular point f. In fact, experiments show that the basins of these clustered attractors are too small to appear in a computer-gen­erated image. They also provide the fact that the basin of an attractor tends to be smaller if the attractor is nearer to f. Hence, we first choose, as attractors, the point at infinity and 29 roots farther from f than the others to generate graphical images. The remaining in­finitely many roots near f are considered to be the artificial attractor.

It is hard to determine how many iterations are re­quired for Newton's method to reach an attractor from an initial point ZQ. If ZQ lies on the JuHa set, its Nev^on sequence does not even approach to any attractor. Furthermore, M^^„{z) is not well-defined at the singular point f, which makes it unable to evaluate M^^J^z) there. We empirically choose the maximum number A of iterations to be 100.

Let {zk}hQ the sequence of complex numbers gen­erated by Newton's method with an initial value ZQ. Suppose that {Zk} has a value z, near a root ^rn such that i < N and I z, - J^ | < e where e is set to be the value of the right hand side of inequality (7). Such a root ^n,, first encountered by Newton's method, is taken as the attractor of ZQ. If Nev^on's method does not hit such ^rn within N iterations, the attractor of ZQ is as­sumed to be either the artificial attractor or the point at infinity unless {z^} has a point sufficiently close to f. The attractor of ZQ is the point at infinity if | z, | > L for some / < A where the number L depends on the value of a as described in inequality (5). Otherwise, its attractor is assumed to be the artificial attractor. Suppose that {Zk} has a point z, close to f such that U/ - f I < 6, where b is chosen to be a small positive number. If Newton's method does not stop with an attractor until its /' ' iteration, {z/t} is considered to contain f. In this case, ZQ is thought not to have any attractor. Fortunately, the effect of the singular point f appears to be negligible in fractal images shown later in this section. We choose 6 = 10~^ in our image gen­eration.

Let Z) be a rectangle in the complex plane containing the unit disk. Then, D contains all roots of Eq. (2). In order to observe its Julia set that is the boundary of the basins of attraction, the size of Z) is required to be sufficiently large. However, it is also restricted by the physical characteristics of a graphics terminal. In prac­tice, D consists of finite grid points of mesh size h,

Fig. 8. The convergency in the basin of attractor at —1; win­dow: -35.0 < Re z < 15.0, -25.0 < Im z < 25.0.

Page 297: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

318 Y. B. KIM, H. S. KIM, H. O. KIM and S. Y. SHIN

which is dependent on the resolution of a display de­vice. The value in the complex plane corresponding to each grid point is sampled as a starting point ZQ for Newton's method. The color at each grid point is de­termined either by its attractor (Figs. 3-7 and 10) or by the number of iterations before reaching at a point within € of its attractor (Figs. 8 and 9). In either case, we do not assign any color to a grid point with no attractor, which is induced by the singular point f.

The RGB color system is adopted to present graph­ical images. The basins of the thirty attractors including the point at infinity are painted with seventeen colors as shown in Table 1. The i'^ farthest roots from the singular point f always appear in pair for / = 2, 3 , . . . , 15, since M^^^(z) is symmetric about the ray of argu­ment 0 = arg( f). Therefore, their two basins are given the same color. The remaining three colors are assigned to the basins of the farthest root, the point at infinity, and the artificial attractor, respectively. In order to maintain the consistency, this color mapping scheme is applied to all figures (Figs. 3-7 and 10) in which the basins of attraction are focused. For visualizing the convergency of Newton's method, the number of its iterations for each starting point ZQ is mapped into a color (Figs. 8 and 9). Table 2 shows the color assign­ment for the first 20 iterations.

Now, we are ready to present computer-generated images illustrating the dynamics of Newton's method when it is applied to Eq. (2). By varying a. Figs. 3 through 7 are obtained. Figures 3 and 4 give a typical shape of the Julia set of Newton's method for Mf,«(z) - 1 = 0 when f = 1 and a = 10, i.e., M^oiz) - 1 = 0. Figures 5, 6, and 7 show how the shape of the Julia set is changed if a is varied. On the other hand. Figs. 8 and 9 visualize the convergency of Newton's method. Finally, the Julia set of Newton's method for Mij(z) - 5 = 0 is given in Fig. 10 as a variation of Eq. (2).

We begin with observing Fig. 3 in which the basins of attraction of Newton's method for A/i,,o(z) - 1 = 0 are graphically represented as a prototype image for Mf,«(z) — 1 = 0 . We can observe that this image is

Fig. 9. The convergency in the basin of attractor at oo; window: -45.0 < Re z < 25.0, -35.0 < Im z < 35.0.

Fig. 10. The basins of attraction of the Newton's method for Ml ,(z) - 5 = 0; window: -1.0 ^ Re z < 7.0, -4.0 : Im z

^ 4.0.

symmetric about the real axis. The image globally con­sists of three structural components; the region colored medium orchid, the region colored royal blue, and "flowers" lying between the two regions. As indicated in Table 1, the first two regions are the basins of at­traction induced by the point at infinity and the farthest root at the point - 1 , respectively. The basin of the point at infinity covers the most of the complex plane except the "deformed disk" containing the remaining two components and thus is unbounded. The deformed disk is mostly occupied by the basin of the farthest root, excluding the flowers of various sizes. The most interesting one is the flowers in the deformed disk. A "petal" of a flower looks like a "helmet" with showy "ornaments," and the color of its main body indicates its attractor. The Julia set of Newton's method for J^]Ao{z)- 1 = 0 is the union of boundaries of colored regions. It appears not only on the boundary of the deformed disc but also on the boundaries of flowers in its interior. We can observe, as expected, that the fractal structure with the infinite number of attractors within a bounded region gives rather remarkable fig­ures.

Figure 4 is a magnification of a small squared region containing a big flower near the singular point fin Fig. 3. The helmet-shaped petals of the flower are enlarged to show an interesting structure. Each ornament on a helmet is itself a flower. This confirms the self-similarity of a fractal image. Let R be an arbitrarily small disc centered at a point on the Julia set. Even though R does not contain any flower in the image, if R is suf­ficiently magnified, new flowers will come out from this "magic disc" R as many as we want. As a petal lies more deeply in the flower, its size is smaller. The outmost one is the largest that is colored red. According to Table 1, it is the basins of the second farthest pair of attractors from f. Similarly, the medium violet red spots represent the basins of the attraction nearest to f among the selected 29 attractors on the unit circle.

Page 298: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Infinite-corner-point fractal image generation 319

The small yellow-colored region in the center of the flower indicates the basin of the artificial attractor. Its small size justifies the artificial attractor. Black colored spots apparently do not occur in the image. This means that the effect of f is negligible.

Figures 5, 6, and 7 show how the shape of a flower is changed when a is changed. The value of a gets 10, 5, and 1 in Figs. 5,6, and 7, respectively. As a decreases, the roots of Eq. (2) except the farthest one from f tend to move closer to f along the unit circle. Accordingly, the flower in Fig. 4 is getting smaller, and its petals are moving outward. We make use of this phenomenon to show a blooming flower. In order to exaggerate the flower, the small isolated regions near the flower, which is colored medium orchid, are painted with royal blue. The sizes of the flowers are adjusted so that each flower in Figs. 5, 6, and 7 has a similar size. The flower looks blooming when the three flowers in the figures are in­terpolated in the order of decreasing a.

The convergence behavior of Newton's method is visualized according to Table 2 in Figs. 8 and 9. In Fig. 8, the convergency for a starting point ZQ in the basin of the farthest root is given. Figure 9 illustrates the convergence for ZQ in the basin of the point at in­finity.

Finally, we graphically show, in Fig. 10, the basins of attraction of Newton's method for

M.A^)- (10)

By varying c, an interesting phenomenon can be ob­served. Suppose that c moves along the real axis. As observed in Fig. 3, the flowers lie in the deformed disc when c = 1. Notice that they now are outside this disc for c = 5 as shown in Fig. 10. In fact, this conversion occurs when c = e. For c = ^, we show that Eq. (10) has solutions only on the vertical line Re z = 1: If z = X + iy satisfies Eq. (10) with c = e, comparing moduli of both sides of Eq. (10) , we see

( -exp - R e

1 + (jc + iy)

1 - (x + iy)

I \-x'-y'\

Therefore,

\-x^-y^ J 1 - 2 x + x^ + /

and hence x = \. Thus, all the roots of Eq. (10) occur on Re z = 1. This implies that the roots of Eq. (10) lie in the half plane Re z < 1 for c < ^ and in Re z > 1 for c > e. That is, if c < e, then the flowers lie in the deformed disc. They lie outside this disc when c> e. For general a in MxJ,z) = c,a similar argument gives that the conversion occurs at c = e".

4. CONCLUDING REMARKS

Equation (2) , which is M^^„{z) — 1 = 0 for |f| = 1 and a > 0, has infinitely many roots on the unit circle. The Julia set of Newton's method for Eq. (2) is bounded since the point at infinity is an attractor. The dynamics of Newton's method for Eq. (2) result in a number of interesting fractal images with infinite-cor­ner-points. Their deformations are observed by varying f and a.

As an analogue of Eq. (2), the dynamics of Newton's method for M^^J^z) — z" = 0 also give equally re­markable fractal images. For A2 = 1, they show the cha­otic behavior of Newton's method for finding a fixed point ofMf,«(z) [ 4 ] .

REFERENCES 1. H.-O. Peitgen and D. Saupe (Eds.), The Science of Fractal

Images, Springer Verlag, New York/Berlin (1988). 2. H.-O. Peitgen and P. H. Richter, The Beauty of Fractals,

Springer Verlag, New York/Berlin (1986). 3. E. R. Vrscay, Julia set and Mandelbrot-like sets associated

with higher order Schroder rational iteration functions. Math. Comp. 46, 151-169 (1986).

4. H. S. Kim, Dynamical Behaviors of Point-mass Singular Inner Functions. Doctoral Thesis, KAIST, South Korea (August 1992).

5. M. A. Motyka and C. A. Reiter, Chaos and Newton's method on systems. Comp. & Graph. 14, 131-134 (1990).

6. R. L. Duren, Theory ofH^ Spaces, Academic Press, New York/London(l970J.

7. H. O. Kim and H. S. Kim, Iterations, Denjoy-Wolff points and ergodic properties of point-mass singular inner func­tions. J. of Math. Anal. Appl. 175, 105-117 (1993).

8. M. Barnsley, Fractals Everywhere, Academic Press, New York (1988).

9. R. L. Devaney, An Introduction to Chaotic Dynamical Systems, Addison-Wesley, Reading, MA (1989).

10. B. B. Mandelbrot, The Fractal Geometry of Nature, W. H. Freeman, New York (1982).

Page 299: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 321

Chaos and Graphics

CHAOS AND ELLIPTIC CURVES SANDY D . BALKIN,^ ELIZABETH L. GOLEBIEWSKI,* and CLIFFORD A. REITER^

^ 10 Dorothy Avenue, Livingston, NJ 07039 *335 Wastena Terrace, Ridgewood, NJ 07450

^Department of Mathematics, Lafayette College, Easton, PA 18042

Abstract—The .escape time behavior of a function associated with elliptic curves is studied via Julia sets and composite Mandelbrot sets. The Mandelbrot sets are composite in the sense that two critical points are followed.

1. INTRODUCTION

After an appropriate affine transformation, elliptic curves can be thought of as solutions to the equation: y^ = x^ -^ a2X^ + aix + «o. We can solve this for y, choosing the positive branch of the square root and viewing the result as a function of a complex variable. Thus, we will consider the escape time behavior of the iterated function:/(z) = Vz + a2Z^ + aiz + UQ. No­tice that this function is derived from the positive branch of elliptic curves but it is not the "addition" defined on rational points of elliptic curves that plays an important role in number theory [9].

Escape time for iterating the quadratic function z^ + c has been extensively studied. Introductions in­clude [ 1,2, 5,6, 7 ]. The generalization to z" + c where a need not be integer is considered in [3, 8] and is available in the most recent version of Fractint[10]. The function considered here includes several terms, including a third power term, and a fractional power on the outside. Computing Julia sets from the elliptic curve function/(z) is straight forward although sur­prises do occur. Computing the Mandelbrot set is challenging since we follow two critical points.

2. COMPOSITE MANDELBROT SETS

In order to compute a composite Mandelbrot set, we let one of the constants in our function/(z) cor­respond to screen position while the others are fixed. For example,/(z) = Vz + cz^ + 1, where c is a com­plex number corresponding to screen position, gen­erates the image shown in Fig. 1. This is a "composite" Mandelbrot set in the sense that it follows two critical points z = 0 and z = -2c /3 . For these images the maximum iteration was taken to be 1005 and points were considered "escaped to infinity" if the square of their magnitude exceeded 1000 before maximum it­eration was reached. Notice this lacks the point toward the left found in the usual Mandelbrot set. Indeed, the tips of the side bulbs look more like the classical Man­delbrot set than the entire composite Mandelbrot set itself.

In order to track the behavior of the two critical points an appropriate coloring scheme is used. Let ki be the iteration count of the first critical point and let k2 be the iteration count of the second critical point. When ki and k2 are both less than the maximum it­eration, then ki modulo 15 determines the amount of

Fig. 1. Composite Mandelbrot set with -3 < Re(c) < 1, -1.5 < Im(c) < 1.5.

Reprinted from Comput, & Graphics Vol. 18, No. 1, pag. 113-117, 1994

Page 300: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

322 S. D. BALKIN, E. L. GOLEBIEWSKI and C. A. REITER

Fig. 2. Composite Mandelbrot set with -1.867 < Re(c) < -1.155, -0.267 < Im(c) < 0.267.

blue while k2 modulo 15 determines the amount of green. For example, if /ci = 0 and /c2 = 0 then black is used, if/ci = 14 and k2 = 0 then blue is used, if/ci = 0 and /:2 = 14 then green is used, and if /ci = 14 and /c2 = 14 then cyan is used. Shades of magenta are used when kx is the maximum iteration but ki is not; the shade is determined by ki modulo 15. Shades of yellow are used when k2 is the maximum iteration but kx is not; the shade is determined by kx modulo 15. When both critical points reach the maximum iteration, white is displayed.

In Fig. 1, notice the green shadows of some of the blue features. Also notice the yellow towers where 0

goes to infinity but the other critical point stays finite. Figure 2 shows the composite Mandelbrot set generated by/(z) = Vz + cz^ + 0.001. This has notable yellow and magenta regions where each one, but not both critical points stay finite. Notice the turbulence along the right edge persisting into the magenta region and the green-blue swirls preceding the other magenta edge.

Figure 3 shows the composite Mandelbrot set gen­erated by/(z) = Vz + iz^ + c. This looks consider­ably different than the classical Mandelbrot set. Notice the rough teeth on the upper right and the smooth boundaries on the left. The smooth boundaries are presumably an artifact of the branch cut of the square

Fig. 3. Composite Mandelbrot set with -2 < Re(c) < 2, -1.5 < Im(c) < 1.5.

Page 301: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and elliptic curves 323

Fig. 4. Julia set with a^ = 0.008 - 0.186z, a^ = 0, «2 = /, for -2 < Re(z) < 2, -1.65 < Im(z) < 1.35.

root used. However, if one tries to highlight the pixels that have orbits that come close to the branch cut {Re(z) < 0, Im{z) < tolerance), no pels are high­lighted; the branch cut lies in a repelling region. If one rotates the branch cut clockwise, the image deforms. However, the smooth boundaries rotate with the branch cut. Even though the features of this composite Mandelbrot set are much different than the classical one, the teeth seem to be associated with attractive cycles. The large tooth below the largest external white spot is associated with 4-cycles. Our experiments show both the critical point 0 and -2 / / 3 converging to the same 4-cycle except in the yellow part of the region

where 0 diverges to infinity. The next major tooth (clockwise) is associated with 5-cycles, the next with 6-cycles and the next with 7-cycles. Our first Julia set picture. Fig. 4, is taken from the region with one critical point attracted to a 7-cycle and the other goes to in­finity.

3. JULIA SETS

For these Julia sets, the iteration count modulo 240 determines the hue displayed. Thus, low iteration counts are shown in red, and as the iteration count increases, the colors run through yellow, green, cyan, blue, magenta and then recycling beginning with red

Fig. 5. Julia set with ao = 0, a, = 0.4 + 0.1/, 2 = 0, for -2 < Re(z) < 2, -1.5 < Im(z) < 1.5.

Page 302: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

324 S. D. BALKIN, E. L. GOLEBIEWSKI and C. A. REITER

Fig. 6. Julia set with OQ = 0.5 + 0.5/, A, = 0, AJ = -1.644 - 0.833/, for -1 ^ Re(z) ^ 3, -1.5 ^ lm(z)^ 1.5.

again. Figure 4 shows a Julia set with fern-like tips and spirals with seven arms. The seven arms correspond to the fact that the critical point -2 i /3 approaches the seven cycle: 0.14766583 - 0.66348345i, 0.4290094 -0.41460049i, 0.55683479 - 0.29766265i, 0.6273122 - 0.17140472i, 0.6440807 - 0.014887148i, 0.57238196 + 0.18352628i, 0.33081357 + 0.42643194i. The crit­ical point 0 goes to infinity. The threefold outer sym­metry arises from the third power inside the square root. Notice the fine detail as well as the smooth boundaries similar to the images in [4].

Lastly, we consider three pictures that give a glimpse at the great diversity found in these Julia sets. Figure 5 gives another Julia set where self-similar bubbles ap­pear suddenly. Notice the fact that there are two distinct components, but again a sort of three-fold symmetry of spiralling tips. In Fig. 6 we have an escape time picture. Here there are sequences of spirals descending out toward three tips. Figure 7 gives a Julia set that appears to have infinitely many components. Unlike quadratic Julia sets, the components have regions ap­pearing to contain fractal dust.

Fig. 7. Julia set with OQ = 0.001/, a^ = 0, «2 = -1.376 - 0.07/, for -1 < Re(z) < 3, -1.5 < Im(z) < 1.5.

Page 303: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and elliptic curves 325

Acknowledgments—This work was supported in part by the National Science Foundation REU grant DMS-9200329 and by Lafayette College.

REFERENCES 1. M. Barnsley, Fractals everywhere, Academic Press, San

Diego (1988). 2. R. Devaney, Chaos, fractals, and dynamics: Computer

experiments in mathematics. Addison-Wesley, Menlo Park, CA( 1990).

3. U. Gujar and V. Bhavsar, Fractals from z <- z" + c in the complex c-plane. Comp. & Graph. 15, 441-449 (1991).

4. A. Lakhtakia and R. Messier, Self-similar sequences and

chaos from Gauss Sums. Comp. & Graph. 13, 59-62 (1989).

5. B. Mandelbrot, The fractal geometry of nature, W. H. Freeman and Company, New York (1983).

6. H.-O. Peitgen and P. H. Richter, The beauty of fractals, images of complex dynamical systems. Springer-Verlag, New York (1986).

7. C. Pickover, Computers, pattern, chaos and beauty, St. Martin's Press, New York (1990).

8. C. Pickover and E. Khorasani, Computer graphics gen­erated from the iteration of algebraic transformations in the complex plane. Comp. & Graph. 9, 147-151 (1985).

9. J. Silverman, The arithmetic of elliptic curves, Springer-Verlag, New York (1986).

10. T. Wegner and M. Peterson, Fractal creations, Waite Group Press, Mill Valley, CA (1991).

Page 304: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 327

Chaos and Graphics

NEWTON'S METHOD FOR MULTIPLE ROOTS

WILLIAM J. GILBERT University of Waterloo, Waterloo, Ontario N2L 3G1, Canada

Abstract—We investigate the basins of attraction in the complex plane of Newton's method for finding multiple roots and illustrate what happens as two simple roots coalesce to form a double root.

1. INTRODUCTION

Newton's method for finding a real or complex root of a function is very efficient near a simple root because the algorithm converges quadratically in the neigh­borhood of such a root. However, at a multiple root, that is, a root of order greater than one, Newton's method only converges linearly. Various modifications of Newton's method have been proposed that converge quadratically at multiple roots. One standard method that we discuss here will find the roots of the function g{z) by applying Newton's method to the function S(z)/g'(z)' Newton's method applied to this quotient will always converge quadratically near all the roots of g{z). This method introduces extraneous fixed points into Newton's method, but they are always repelling. We plot the basins of attraction for the roots in the complex plane and illustrate what happens to these basins as two simple roots coalesce to form a multiple root. We then compare this method with other Newton methods.

2. NEWTON'S METHOD FOR MULTIPLE ROOTS

The standard Newton's Method for finding the real or complex roots of a function g{z) consists of iterating the function

N{z) = z-g(z) g'{z)

by starting with some initial approximation ZQ and de­fining the (« + 1 )st approximation by z„+i = N(z„). See [ 11 and [ 2 ] for the connection between the global study of Newton's method for finding complex roots and dynamics in the complex plane.

Any root of the function g{z) is a fixed point of N(z). If w is a root of a polynomial g{z) of order k, then the multiplier (or eigenvalue) of the fixed point w is N'{w) = (k — l)/k; this multiplier gives infor­mation about the behavior of the dynamics of the it­eration near the fixed point [ 3, §6.1 ]. At a simple root, k = 1 and the multiplier is zero, which means that w is a super-attracting fixed point and Newton's method converges quadratically in some neighborhood of the fixed point. At a multiple root, k > 1 and the multiplier lies between 0 and 1, which means that the fixed point w is attracting, but that the convergence will only be linear. Hence Newton's method will not be very sat­isfactory near a multiple root. The point at infinity is

a repelling fixed point with multiplier d/(d— 1), where d is the degree of the polynomial g{z). This means that large values of z„ will tend to be pushed away from infinity.

If ^(z) has a root of order k at the point w, then g(z)/g'{z) has a simple root at w. If we apply the stan­dard Newton's method to ^(z)/^'(z) we obtain

M(z) g{z)g'iz)

lg'{z)V - g(z)g''(z)

This is called Newton's method for multiple roots [4, Eqs. 8.6-24]. It is quadratically convergent at every root of ^(z), but could be more complicated to com­pute than the standard Newton's method because it involves second derivatives. Furthermore, there may be fixed points of M(z) that are not roots of (z). The critical points of ^(z), that are not also roots of ^(z), are extraneous fixed points for this Newton's method for multiple roots. However, if w is such an extraneous fixed point then the multiplier is M'{w) = 2, which means that w is a repelling fixed point and so will not affect Newton's method. If ^(z) is a polynomial, then infinity is never a fixed point for M(z).

Figure 1 shows the basins of attraction of the roots when this method is applied to the polynomial g(z) = z^(z^ — 1), that has one double root and three simple roots. If the initial value ZQ lies in the white region then Newton's method for multiple roots will converge to within 0.001 of the origin in 10 iterations. Initial values lying in the colored regions will converge to one of the cube roots of unity, while those lying in the black re­gions have not converged to within 0.001 of any root in 10 iterations.

In practice, because of experimental errors or trun­cation of coefficients, the polynomial may not have a multiple root, but two or more roots that are very close together. This causes no problem to this Newton's method for multiple roots. For example, if the double root in the polynomial of Fig. I was split into two close roots to obtain g(z) = z{z -\- 0.01 )(z^ — 1), then the rate of convergence of Newton's method for multiple roots is unchanged. Notice that the basins of attraction of the three cube roots in Figs. 1 and 2, which are the red, blue, and green areas, are basically the same. The white region in Fig. 1, which is the basin of attraction of the double root at the origin, is the union of the

Reprinted from Comput. & Graphics Vol 18, No. 2, pag. 227-229, 1994

Page 305: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Fig. 1. Newton's Method for multiple roots applied to g{z) = z^{z^ - 1). After 10 iterations points in the white and

colored regions come to within 0.001 of a root.

Fig. 3. The standard Newton's Method applied to^(z) = z^{z^ - 1). After 10 iterations points in the white and colored regions come to within 0,001 of a root while points in the black region

have not come close to any root.

white and yellow regions of Fig. 2, which are the basins of attraction of the two close roots, 0 and —0.01.

3. OTHER METHODS FOR A MULTIPLE ROOT

Let us compare the above method with other New­ton methods for multiple roots. It is possible to use the standard Newton's method. Figure 3 illustrates the ba­sins of attraction of the roots of ^ (z ) = z^{z^ - 1) after 10 iterations. If this figure is compared to Fig. 1, we see that there is a large black area in the basin of attraction of the double root 0, where points have not come close to the root after 10 iterations, because the method only converges linearly at the double root. Even if we look at the standard Newton's method ap­

plied to the modified polynomial g(z) = z(z +0.01 )(z^ - 1), that has no double roots, we see in Fig. 4 that the two close roots cause problems with Newton's method. This is because the range in which quadratic convergence occurs is extremely small near these close roots.

Another technique for dealing with multiple roots is the relaxed Newton's method. If w is a root of ^(z) of order k then

Ndz)-kgjz)

g'iz)

2\,

1 ,#. •.~ • ,

-214 .mi^tt----^' iii- iiS ^

• • • - • . » • i ' "

-2 -1 1

Fig. 2. Newton's Method for multiple roots applied to giz) = z(z + 0.01 )(z^ - 1). After 20 iterations points in the white

and colored regions come to within 0.001 of a root.

Fig. 4. The standard Newton's Method applied to g{z) ^ z{z + 0.01 )(z^ - 1). After 10 iterations points in the white and colored regions come to within 0.001 of a root while points

in the black region have not come close to any root.

Page 306: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Newton's method for multiple roots 329

will converge quadratically at the root w [4, Eqs. 8.6-13]. However, this method is hopeless if the root is not of order exactly k. The white region in Fig. 5 is the basin of attraction of the double root at the origin, under the relaxed Newton's method with k = 2. The cube roots of unity are fixed points under this method but Njfw) = - 1 , for any cube root w. Since this mul­tiplier has modulus 1, a simple root of^(z) is a neutral (or indifferent) fixed point for the method N2(z). Newton's method will behave very badly near these roots. Any neighborhood of such a neutral fixed point contains some points that are in the basin of attraction of the neutral point and some points that are not. The black regions in Fig. 5 are the basins of attraction of the cube roots, but it would require thousands of it­erations for points in these regions to come close to the roots [ 5 ] .

If some roots of ^ (z ) are only approximately mul­tiple, then the convergence of the relaxed Newton's method at these roots changes drastically. Figure 6 il­lustrates the relaxed Newton's method N2(z) applied to g{z) = z(z + 0.01 )(z^ - 1) after 3000 iterations. Compare Fig. 5 and Fig. 6. The large white area in Fig. 5, which is the basin of attraction of the double root, now contains large areas of black in Fig. 6 that have not converged to a root after 3000 iterations! However this is not a good representation of the actual basins of attractions of the two close roots. This diagram is very sensitive to how close we require the method to come to a root; changing the tolerance 0.004 to another value would substantially alter the diagram. In contrast, Newton's method for a multiple root is insensitive to the tolerance parameter; changing the tolerance from

Fig. 5. The relaxed Newton's Method for a double root applied to (z) = z^(z^ - 1). After 100 iterations points in the white region come to within 0.001 of the double root at the origin while points in the black regions have not come close to any

root.

Fig. 6. The relaxed Newton's Method for a double root applied to ^(z) = z(z + 0.01 )(z^ - 1). After 3000 iterations points in the white and colored regions come to within 0.004 of a

root.

0.001 in Figs. 1 or 2 would not change the figures sig­nificantly. Notice also that the values in the black re­gions of Fig. 5 are now colored in Fig. 6, indicating that they have converged to the cube roots of unity. This would have also occurred in Fig. 5, if we had iterated the method 3000 times.

Figures 1, 3, and 5 show three different Newton methods applied to the same polynomial with a double root. All the roots in the three figures are the same, but the basins of attractions are quite different, and the rate of convergence to the roots also varies tre­mendously. Likewise, Figs. 2, 4, and 6 show the three different Newton methods applied to another poly­nomial that has two almost equal roots. These figures show how sensitive the methods are to a double root dividing into two simple roots.

These last two figures show that the relaxed Newton's method is very sensitive to the two roots being exactly equal, and so it will never be a good method in practice, even if the initial approximation is quite close to the (nearly) equal roots. Newton's method for a multiple root is much safer.

REFERENCES 1. F. V. Haeseler and H.-O. Peitgen, Newton's method and

complex dynamical systems. Acta Appl Math. 13, 3-58 (1988); also in Newton's Method and Dynamical Systems, H.-O. Peitgen (Ed.), Kluwer, Dordrecht (1989).

2. H.-O. Peitgen, D. Saupe, and F. v. Haeseler, Cayley's Problem and Julia Sets. Math. Intell. 6, 11-20 (1984).

3. A. F. Beardon, Iterations of Rational Functions, Springer-Verlag, New York (1991).

4. A. Ralston and P. Rabinowitz, A First Course in Nu­merical Analysis, McGraw-Hill, New York (1978).

5. W. J. Gilbert, The complex dynamics of Newton's method for a double root. Comp. Math. Appl. 22, 115-119 (1991).

Page 307: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 331

Chaos and Graphics

WARPED MIDGETS IN THE MANDELBROT SET

A. G. DAVIS PHILIP Union College and Van Vleck Observatory, 1125 Oxford Place, Schenectady, NY 12308, USA

and

MICHAEL FRAME and A D A M ROBUCCI Union College, Schenectady, NY 12308, USA

Abstract—Warped midgets in the Mandelbrot set have been measured, using an algorithm that allows the positions of the head, and cardioid atoms (north and south) of any midget to be found, once one has placed the cursor on the computer terminal somewhere inside any midget. We describe two distortions of midgets: linear distortions and angular distortions. When the north and south angles are plotted in the north/south angle plane, families of points are formed. The angle and distance measures of warped midgets from the Sea Horse Valley of the Mandelbrot set and from other sea horse valleys of midgets, whether on the Spike or on tendrils above atoms, all fall closely together in one part of the north/south plane. Measures of warped midgets from tendrils above the major atoms on the surface of the Cardioid fall closely together in another part of the north/south plane. This different way of looking at the Mandelbrot set offers an interesting way of studying the distortions of midgets.

1. INTRODUCTION

The Mandelbrot set (M-set) is a fascinating mathe­matical construction discovered by Benoit Mandelbrot in the early 1980's. The set represents the intricate be­havior of the mapping z ^- z^ + c for complex values of z and c. A picture of the M-set is shown in Fig. 1 with various parts named. The structural features have been given many fanciful names, such as "midget," "spike," "atom," "radical," and "Sea Horse Valley," in both the popular and mathematical literature. We are following the nomenclature proposed by Mandel­brot in naming the round appendages attached to the set as "atoms" and the whole structure of the append­ages, "radicals." Some investigators name these two parts of a radical a "bud" plus "tendrils." The name "midget" refers to the infinite number of close (but not exact) copies of the M-set that occur on the Spike and along tendrils of the M-set. Tendrils can be seen in Figs. 1 and 2. When we are discussing the major parts of the M-set we capitalize the name (Spike, Head, Cardioid, Atom, etc.) but when we discuss the parts of a midget then the name is in lower case (spike, head, cardioid, atom, etc.). This convention will help the reader in understanding which parts of the M-set are being described in any section of this paper.

In [ 1, pp. 24-25 ], dealing with midgets on the Spike of the M-set, two figures were presented that described the geometrical distortions exhibited by midgets. On casual inspection the midgets seem to be exact copies of the M-set, but if one studies them carefully, distor­tions in angles and in distances can be discerned. Figure 2c of [ 2 ] is perhaps the first image of a warped midget. The figures on page 24-25 of [1] describe these dis­tortions (linear distortions for midgets on the Spike and angular and linear distortions for midgets off the Spike). If the numbers are calculated to sufficient pre­cision, we speculate that no midget will have the same

distortion measures as found in the M-set itself, thus we conjecture all midgets are distorted relative to the M-set, and further, no two midgets have the same dis­tortion measures.

First we must define the angles and distances that we use in our measures of the distortions. Here we use a naming scheme for the atoms on the boundary of the cardioid and heads of the M-set, presented in [3]. The basic idea of this scheme is that we name the atom according to its cycle number, the number of elements in the cycle to which the orbit of Z = 0 converges under iteration of Z ^ -^ Z ^ + C for C taken in the atom. (We show the M-set with the main features named in Fig. 1.) The number of spiral arms in the radical is a visible manifestation of the cycle number. In addition the iteration track (the orbit of Z = 0) displays n similar patterns for C in an «-cycle atom. These features were identified using a program[4] to calculate the position of the center of the cardioid, center of the head and centers of the north and south atoms of a given midget.

We number the tendrils by calling the connection from the atom head to the center of the radical struc­ture, tendril 0. Then (for atoms on the north side of the M-set) we number them 1, 2, 3, etc. in a clockwise direction. For the major atoms attached to the Car­dioid, (Atom 3, 4, 5 etc.) the largest warped midget is always found in tendril 1, to the magnifications that we have investigated. The "deepest" midget measured in this study is the Cycle 1149 midget at a magnification of 2.5 X 10^. The midget in tendril 1 is always the most warped midget to be found in the tendrils asso­ciated with that atom. To illustrate this naming con­vention. Fig. 2 shows Atom 7 with the tendrils num­bered 0-6. The major warped midget can be seen in tendril 1. There is a similar warped midget in each tendril, but its size rapidly decreases with higher tendril

Reprinted from Comput. & Graphics Vol. 18, No. 2, pag. 239-248, 1994

Page 308: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

332 A. G. D. PHILIP, M. FRAME and A. ROBUCCI

Atom 3

Spike East Valley

Fig. 1. The Mandelbrot set with features labeled. Three of the major atoms are marked on the Cardioid. SHV indicates Sea

Horse Valley, C3 the Cycle 3 midget on the Spike. Fig. 3. A color picture of the Cycle 57 warped midget.

numbers. In each tendril there are many other series of midgets, but again their sizes are much smaller than the major warped midget in tendril 1.

The Cycle 57 warped midget is shown in the color picture. Fig. 3. Referring back to Fig. 2, the largest warped midget for Atom 7 can be seen in tendril 1. In Fig. 3 tendril 1 of Atom 57 is shown with its warped midget pointing to the right. Its north atom (on the bottom in this figure) is much smaller than the south atom. The head of the warped midget is not opposite the east valley but is well to the right of a position opposite it. The spike of the warped midget is not straight but bent to the left. On the top of Fig. 3 one can see the series of "elephant trunks" against the rear of the "elephant" in front. An uncountable number of these patterns exist in Fig. 3; a pattern that is com­mon for all the major atoms that lie on the surface of the Cardioid, leading into East (or Elephant) Valley.

The position-finding program has been utilized to locate the center of the cardioid, head, north, and south atoms of warped midgets. The distances head-to-center, north-to-center and south-to-center, and the angles H-C-N (north angle) and H-C-S (south angle) are cal­culated. On the left side of Fig. 4a there is a picture of the Mandelbrot set, with members of the set shown in white instead of the usual black so that the lines and angles can be seen. On the right side of Fig. 4a the lines shown inside the figure on the left are reproduced and labeled. The lower case letters "«" and "5" indicate the north and south angles, respectively. In Fig. 4b the

Atom 7

same diagrams are shown for the major warped midget in tendril 1 of Atom 72. This midget is facing east, looking out of East Valley. The north atom (on the bottom in this picture) is much smaller than the south atom and the north angle is smaller than the south angle. Note that in both Fig. 4a and 4b the main body appears to have the shape of a cardioid. What is dif­ferent in Fig. 4b is that the atoms on the surface of the cardioid have been shifted in position and are different sizes, compared to the atoms in Fig. 4a. The measures for this midget are presented in Table 1. As a result of the position and size shifts of the atoms in Fig. 4b note that the N-t-C and S-t-C distances are different and the north and south angles are different from those measured in Fig. 4a. The measures obtained for the distances and angles in the M-set are shown in Ta­ble 2.

For measures of midgets made off the Spike, there is no longer symmetry across the real axis. The figure on page 25 of [1] compares the large warped midget in the first tendril off Atom 3 (the North Atom) with a similar midget off Atom 18. We can also see the distortions in warped midgets in Fig. 4b.

In Section 2 we give some background material on the set. Then in Section 3 we describe a numerical method for locating the centers of the cardioids, head, north, and south atoms of midgets. An illustrative ex­ample is given in Section 4. In Section 5 we describe the results of applying these techniques to the mea­surement to warped midgets in several regions of the M-set and some interesting relations that have been found. We also show plots of the distortion measures and describe their behavior in different places in the M-set.

2. BACKGROUND ON THE MANDELBROT SET

The M-set consists of all complex numbers c for which the sequence

0, FAO), F,(F,(0)) = Ff(0), Ff(0), (1)

Fig. 2. The seven tendrils surrounding the head of Atom 7. does not diverge to infinity, where Fdz) = z^ -\- c. This sequence is called the orbit of 0. One way (though not

Page 309: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Warped midgets in the Mandelbrot set

N

333

H

Fig. 4. The definition of the north and south angles. The north angle is the angle formed between the head-center line and the north-center line.

the only way) a sequence can fail to diverge is by con­verging to some cycle. We say the complex numbers Zi, Z2, Z 3 , . . . , z„ form an /i-cycle (or a cycle of order /i)ifFe(zi) = Z2,Fc{z2) = Z3 , . . . ,F^(z„_i) = z„,and Fc{Zn) = Zi. Equivalently, each of Zi, Z2, . . . , z„ is a solution of Fc"(z) = z. Since this is a polynomial equation, for each c there are «-cycles for all «, but most of these are numerically invisible. That is, most are unstable—under repeated application of F^ nearby points wander away, hence the slightest error is mag­nified. By a theorem of Fatou, if an «-cycle is stable the sequence (1) will converge to it. More precisely, Fatou's theorem [5, p. 79] states that every stable cycle

must attract the orbit of a critical point, and we note for Fc(z) = z^ + c the only critical point is z = 0.

The disk and cardioid features of the M-set are sets of c-values for which Eq. (1) converges to cycles of particular orders. For example, for c in the main car­dioid, Eq. (1) converges to a 1-cycle (= fixed point); for c in the head Eq. (1) converges to a 2-cycle; for c in the north and south radicals, and for c in the cardioid of the largest midget along the spike of M, Eq. (1) converges to a 3-cycle. Call these features 1-cycle, 2-cycle and 3-cycle components. To calculate the extent of an «-cycle component W, in principle we simply find all the «-cycles (as functions of c) and determine

Table 1. Distortion measures for warped midget off atom 72. Table 2. Distortion measures for the mandelbrot set.

Place

Center Head North Atom South Atom Head-to-Center

Distance North-to-Center

Distance South-to-Center

Distance North Angle South Angle NC/HC SC/HC NC/SC n/s

Cycle #

73 146 219 219

Position

0.251909027+ 0.000131946i 0.251910675 + 0.000132214i 0.251909482 + 0.000130965i 0.251908826 + 0.000133436i

1.669209681

1.081364809

1.503563993

74.356761 deg. 88.465358 deg. 0.6478304202 0.9900764002 0.7192010546 0.8405184

Place

Center Head North Atom South Atom Head-to-Center

Distance North-to-Center

Distance South-to-Center

Distance North Angle South Angle NC/HC SC/HC NC/SC n/s

Cycle #

1 2 3 3

Position

0.000000 + O.OOOOOOi -1.000000+ 0.000000i -0.122561 H-0.744862i -0.122561 -0.744862i

1.000000

0.754878

0.754878

80.656154 deg. 80.656154 deg.

1.342531 1.342531 1.000000 1.000000

Page 310: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

334 A. G. D. PHILIP, M. FRAME and A. ROBUCCI

if one of them is stable. An «-cycle Zi(c), Z2(c), z„(c) is stable if its multiplier

p(c) = 2"z,(c)z2{c) . - . z„(c) (2)

is less than 1 in modulus [ 5, p. 79 ]. Most importantly, the multiplier provides a 1 to 1 function from the n-cycle component W onto the unit disk D in the com­plex plane:

c^ p(c),

and by a theorem of Douady and Hubbard [ 5, p. 83 ], [6], this function preserves angles locally. Note that for each component W there is a unique c for which p(c) = 0. This c is called the center of W. The centers are just the roots of certain polynomials:

flic) = (fdc))'+ c

Mc) = (flic))' + c

MC) = (fn-dc))' ^ C.

From the form of p{c) given in Eq. (2), it follows that if c is the center of W, then one of the Zi(c) must be 0. That is, F^CO) = 0, or since F^(0) = c, the centers of the «-cycle components are the solutions of 0 = FT~\c) = fnic). With suitable initial guesses, Newton's method can be used to locate the centers of the «-cycle components.

The center of the 1-cycle component is the solution of/i (c) = 0, the centers of the 2-cycle components are the solutions ofy^(c) = 0, and so on. The only point about which we must be careful is to note that if m divides n, then an m-cycle is also a cycle-« and so the roots offmic) are also roots off„(c). To find the bi­cycle centers that are not also «-cycle centers, find the roots of the quotient/,(c)/yw(c). For example, y^(c) = c^ + c and/i(c) = c, so the 2-cycle center that is not also a 1-cycle center is the root of {c^ + c)/c = c + 1, that is, c= - 1 .

The theorem of Douady and Hubbard guarantees the multiplier extends to take the boundary of W to the boundary of D, thus allowing the assignment of "internal angles" to the boundary of W. If c is on the boundary of W, p{c) is on the boundary of D—the unit circle—and so its position on the circle determines an angle. This same angle is the internal angle asso­ciated with c, though typically in W'\X is measured in fractions of turns. That is, 180° on the unit circle cor­responds to an internal angle of { on the boundary of W, 120° and 240° correspond to \ and f, and so on.

For the main cardioid (the 1-cycle component), a 2-cycle component (the head) is attached at internal angle 5, 3-cycle components (the north and south at­oms) at 5 and §, 4-cycle components at \ and | (note \ = 2 has already been used), 5-cycle components at

, §, f, and f, 6-cycle components at g and |, and so on. In general, for a fraction p/q in lowest terms (and 0 < P/Q < 1)» a ^-cycle component is attached to the cardioid at internal angle p/q.

Part of the fractal nature of the M-set lies in how components are attached to components in a repeating pattern. So if J^is an «-cycle component, attached to W diX internal angle p/q is a qn-cycle component. In particular, at 5, 5, and § are attached a 2«-cycle and two 3/7-cycle components. For our measure of devia­tion, we need to find the centers of these three com­ponents.

3. DESCRIPTION OF A METHOD FOR LOCATING CENTERS

Let Wbe an «-cycle component with center c . For each c in W, there is a stable cycle-« zi, Z2, . . . , z„ and the multiplier is 2zi2z2 * • • 2z„ = p(c). That this «-cycle is stable is just the condition that \p{c)\ < 1.

Now initially, we don't necessarily know anything about the orientation of H (except in special cases, like components along the spike), so we take another point C| in W, The idea is to use the vector Ci ~ Co and a perpendicular vector to navigate toward the desired point s (with internal angle p/q) on the boundary of W. To do this, we translate the problem to the unit disk, use the familiar geometry there to find a point closer to the point of angle lirp/q on the circle, and translate the correction back to W.

Let do denote the center of the unit disk, and dx = p{c\). The vector from do to d\ makes an angle d with the real axis:

19 = Arctan(Im(^,))/Re(t/,)) if Re(fl^)>=0, and

6* = Arctan(Im(fif,))/Re(^,)) + 7r if Re(^,)<0.

(3) Denote by f the difference lirp/q - 6, the difference between the angle we want and the one we have so far. If r is the ''goal" point on the unit circle—the point with angle l-Kp/q—then the segment from d\ to r has length

L = (l + \dx-do\'-2\dx-do\cos(^)y (4)

and the angle (/> from the ray dx - do to r is given by

</) = Arctan((sin(f))/^) if A > 0, and

0 = Arctan((sin(f))/^) +TT if ^ < 0, (5)

where A = cos(f) - \dx — do\. In IV v/e mimic the process of moving halfway between di and r, using 0 and L, with L suitably scaled for comparing the size of W to the size of Z). As a scaling factor we use | Cx - Co\/\dx- do\. In W, the next point C2 in our sequence approaching internal angle p/q is

C2 = Cx-\- {M/2){{(cx - Co)/\cx - cj)cos(0)

+ ((-Im(cj - Co) + Re(c, - 0 / ) / | c, - c j ) )

sin(0)) (6)

Page 311: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Warped midgets in the Mandelbrot set 335

where M = L\ci — Co\l\di - do\. Now find the n-cycle for C2, compute the multiplier J2 = p(c2), and repeat the previous steps.

After this method converges to a point near the boundary of W and near the internal angle piq, we use the vector c„+i — c to cross over the boundary into the 2«-cycle or 3«-cycle cycle component. Taking this point as initial guess, Newton's method applied to f2r,{c) = 0 or fi„(c) = 0 converges to the center of the cycle component (the head or the north or south atom) off W. Knowing the center of W, the center of Ws head, and the center of Ws north and south atoms, we compute the deviation by taking the ratio (north-to-center / head-to-center, south-to-center / head-to-center and the angle ratio north angle/south angle.

C2 = c, + (0.5)(0.008675)

X ((c, - Co/0.0010002)cos(0.5039)

+ ((-Im(c, -Co)

+ Re(c, - cj)/0.0010002)sin(0.5039)*/)

= -1.7571 +0.004756/

Now repeat this process with C2 taking the place of Ci. That is, begin by iterating Fd starting from z = 0. This gives the 3-cycle

1.3311 - 0.009783/, 0.01455 - 0.02129/,

-1.7573 + 0.004137/.

4. AN EXAMPLE CALCULATION

To illustrate this procedure, we locate the center of the main midget and the centers of its north atom, south atom, and head. The cardioid of the main midget is a 3-cycle component, so its center is a solution of 0 = /3(c) = c"" -^ 2c^ -\- c^ + c = c(c^ -\- 2c^ -^ c + 1). The point c = 0 is the center of the main cardioid, a 1-cycle component, and we have seen it is no surprise that the 3-cycle center equation would detect this. Al­though the equation c + 2c^ + c + 1 can be solved exactly, to provide a model for the general case we use Newton's method with initial guess c = — 1.75, obtained visually. Newton's method converges to the solution Co = —1.75488, the center of the main midget cardioid. The north radical of the main midget is a 9-cycle com­ponent, but unhappily if we use Newton's method to so\wQfg{c) = 0 with initial guess c = c , we obtain Co again. A moment's reflection shows there is no surprise here: a 3-cycle is also a 9-cycle. As described in the previous section our method is to produce a sequence of points approximating the point of internal angle 5 on the cardioid boundary. This is the point of tangency of the north atom, so from the last point of this sequence we hop into that atom, take an initial guess there, and then use Newton's method to solve /9(c) = 0.

Here are the steps to approximate the point of in­ternal angle 5. We have Co = -1.75488. Take Ci = -1.7549 + 0.001/, another point of the cardioid. It­erating Fci starting from z = 0, we converge to the 3-cycle

1.3249 - 0.00249/, 0.0004083 - 0.005608/,

-1.7549 +0.009954/.

The multiplier is di = -0.007338 + 0.1043/, with magnitude 0.1046 and angle 0.2612. The angle between di and the point 5 around the unit circle is 0.5039 (ra­dians), the distance between di and this point is 0.9071. Scaling this distance back to the midget's cardioid, we obtain a distance 0.008675. The next point in the se­quence is

Compute the multiplier, find the new angle </> and dis­tance, . . . , eventually obtaining C3 = -1.7579 + 0.007446/. After only eight iterations we obtain Cg = -1.7579 + 0.01185/ corresponding to internal angle 0.3359 and magnitude 0.9790. Extrapolating the A -rule (the radius of an «-cycle atom is approximately 1/A^^[7] to the case of disks attached to the midget cardioid, we "hop" into the north atom by Co + (1 + (1 /81 ))(C9 - Co). From this guess, Newton's method to solve/9(c) = 0 gives -1.7678 + 0.01380/, the center of the north atom.

Starting from the same Co and seeking the boundary point with internal angle |, after eight iterations we obtain -1.7579 - 0.01380/ with corresponding internal angle 0.6632 and magnitude 0.9976. Hopping into the south atom by the same process as before, Newton's method for/9(c) = 0 converges to -1.7578 - 0.01380/, the center of the south atom.

To find the center of the head, we start from Co and after eight iterations obtain the point —1.7682 + 0.00002783/ with corresponding internal angle 0.4996 and magnitude 0.9716. Hopping into the head and applying Newton's method for^(c) = 0, we obtain -1.7729, the center of the head.

5. THE DISTORTION MEASURES

Our first investigation was to compute and display the largest warped midget in tendril 1 for each atom from Atom 3 to Atom 100 on the Cardioid of the M-set and to measure the linear and angular distortions of these warped midgets. Some additional warped midgets were measured between Atoms 100 and 1148. As the cycle number increases the average dwell in­creases and for cycles much larger than 1149 the dwell limit of 32,000 in FRACTINT (see description in [ 8 ]) was exceeded.

5.1. Angle and distance measures In Figs. 5a-i we show plots that summarize the mea­

sures made in the M-set. Figure 5a shows the positions, in the complex plane, of the warped midgets in the first tendrils leading away from the head of the major atoms on the Cardioid of the M-set. In Figs. 5b and 5c the Cycle number of each warped midget is plotted

Page 312: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

336 A. G. D. PHILIP, M. FRAME and A. ROBUCCI

ixm

1"" 1 0.400

0.200

aooo

Position in Complex Plane WupedMidgeU

»

> «

^ _ . _ • ^ ' ' ' ' '

Cycle vs Real Position WupedMidtett

Cycle vs Imaginary Position

I"

soao looao 1200.0

Cycle vs North Angle

89X)

tija

1 ^^ SZ.0

81.0

800

T9ja

Cycle

. x

vs South Angle WupedMidieti

«

Cycle vs South Angle WirpcdKOdfMi

1200i> 1400X> 800.0 1000.0 1200.0 1400.0

-SJOOO

C -10.000

5 -15.000

-20000

~2SJXXi

Cycle vs Ln(H to C) Wir|wdMid(M

,

I \

" » •

"""

« liomt L

Cycle vs Angle Ratio WuiMdMi l%M

400.000 8000)0 1200.000 ) <0O000 lOOOOOO 1'

Cydc Number

F Cycle vs Distance Ratio

WupadMld(eti

i 1.2S0 f

' I.IJO |>

800000 600000 I

Cyck Number

8 h i

Fig. 5. Plots of the parameters measured in this study. See text for explanation of each diagram.

versus its real and imaginary position. As the Cycle number increases, the real position approaches 0.25, the location of the end of East Valley. The imaginary position approaches 0 as the cycle number increases. Figure 5d plots the Cycle number v . the north angle (as defined in Fig. 4). Starting at an angle of 76.8° the north angle rapidly decreases to a value near 74.3° and then decreases much more slowly. The south angle (Figs. 5e and 5f) rises to a maximum at Cycle number 57 (near 88.47°) and then falls. Figure 5f shows a magnified vertical scale near the maximum south angle value to show its non-monoicity. The north angle plot appears to be monotone. Figure 5g plots the log (head-to-center distance) vs. Cycle number.

The angle ratio is defined as (north angle/south an­gle) and is displayed in Fig. 5h. The distance ratio is defined as (north distance/south distance) and is shown in Fig. 51. Neither of these plots exhibit a turn­over such as that shown in Fig. 5f.

In Fig. 6 we plot the south angle vs. the north angle and the center-south distance v . the center-north dis­tance. Figures 6a and 6c plot the angles and distances for the whole data set. In Figs. 6b and 6d the scale is magnified to show the turnover in each function. The angle and the distance measures show approximately the same features in Figs. 5 and 6. We have chosen the angle ratio as the best feature to illustrate the be­

havior of midget distortion with higher cycle numbers. The separation of families of points seems to be clearer in the angle plots. We will use this ratio in Section 5.1.2 as the best descriptor of warped midgets.

5.1.1. Linear ratios. In Fig. 7 the CN ratio (ratio of the center distance to the north distance) is plotted vs. the CS ratio (ratio of the center distance to the south distance) for the series of warped midgets above the major atoms on the Cardioid, warped midgets in Sea Horse Valley and SHV of other midgets, warped midgets under atoms and warped midgets in tendrils. (In Figs. 6c, d only the points calculated from warped midgets above the major atoms on the Cardioid were shown). The points representing the measures in the sea horse valleys now are in the upper left of the dia­gram and the measures of the major atoms are on the lower right. In Fig. 8 the distance ratios are compared to the angle ratios. The distribution of the points is very tight, but not quite a linear relation, from the upper left of the diagram to the lower right so the angle ratios and the distance ratios are giving similar infor­mation about the M-set.

For warped midgets in the first tendril of major at­oms, the relation in Fig. 8 implies that as higher cycle numbers are obtained the N/S angle ratio reaches val­ues smaller than 1 as the S/N distance ratio gets larger. Thus, more distorted midgets on tendrils have more

Page 313: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Warped midgets in the Mandelbrot set 337

North/South Angle Ratio Warped Midgets

North/South Angle Ratio Warped Midgets

88.420 1 74.000 74.500 75.000 75.500 76.000 76.500 77.000 77.500 74.100 74.200 74.300 74.400 74.500 74.600

North Angle North Angle

1.240

1.220

1 1.200

2 1.180

^ 1.160

1 1.140

1.120

1.100

1.080

Distance Ratios Warped Midgets

. X

X

X X

X X

X

\

1.140

S •^ 1.130

1 1.120

8 1.110

1.100

Distance Ratios Warped Midgets

-

X

X

> »

1.250 1.300 1.350 1.400 1.450 1.500 1.550 1.600 1.530 Center-North Distance

1.535 1.540 1.545 Center-North Distance

Fig. 6. The Angle and Distance Measures. Sections b and d are enlargements of the regions of crowded points in sections a and c.

extreme angle ratios and more extreme distance ratios. Remember that for cycle numbers greater than 57 the south angle turns over (reaching a maximum value of near 88.467) and starts decreasing, but, the N/S angle ratio continues to decrease. For warped midgets of at­oms going into a sea horse valley, with higher cycle numbers the N/S angle ratio gets larger than 1 but the distance ratio approaches 1.

5.1.2. Angle measures. Figure 9 summarizes the re­gions of the M-set investigated and presents the loca­tions of each region in the north/south angle plot. Fig­ures 9a, b presents the major warped midgets on the

Cardioid of the M-set and on the Cycle 3, 4, 5 midgets on the Spike (See Fig. I). In the north/south angle plot, all these positions fall very closely together and on the scale shown in Fig. 8b the individual positions cannot be separated. The north angle starts out at a value of 76.72°, decreases fairly rapidly to 74.5° and then continues to decrease but more slowly to a value near 74.3°. At a cycle number of 600 the north angle is slightly below 74.3°, by a cycle number of 1149 it is 74.29539°. The midgets were calculated with the program FRACTINT and when midgets deep in East Valley were attempted, with cycle numbers much

1.6-

1.4-

1.2-

1.0

0KUit^^^

^ . *

" • N .

1.2 1.4 Center Distance/North Distance

0.9 1.1 Angle Ratio

Fig. 7. The CN (center to north distance) ratio vs. the CS Fig. 8. The Distance Ratio (south-center distance/north-center (center to south distance) ratio. distance) vs. the angle ratio (south angle/north angle).

Page 314: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

338 A. G. D. PHILIP, M. FRAME and A. ROBUCCI

h4

So.

I 0..

8 o.t

|^-0.2j

I -

Complex Plane Major Atoms, Spike Midgets

* ^

Complex Plane Sea Horse VaOeys

/

Complex Plane Atom 10 ond under Atom 3

1 ^ * .*

10

North Angle vs South Angle Major Atoms, Spike Midgets

North Angle vs South Angle Sea Horse VoRcys

North Angle vs South Angle Atom 10 and under Atom 3

Complex Plane Atom 6 - Atom 1 1

j >

-1.5 -0.9 0.3 0.9

North Angle vs South Angle Atom 6 to Atom 11

^^r^""

I ,0 0.1

Complex Plane Details, Atoms 4 and 5

%

90.0

8S.0

80.0

75.0

70.0-

North Angle vs South Angle Details, Atoms 4 ond 5

^** J- * ***

*^

Fig. 9. On the left the positions measured in the M-set are plotted. On the right the north and south angles produced from these positions are plotted. The warped midgets in Figs. 9h and 9j were measured by Joseph

Marocco, a student at Union College.

higher than 1149, FRACTINT's dwell Hmit of 32 K was exceeded so we left cycle 1149 as the deepest one investigated at this time.

In Fig. 10a (upper part) the positions of all the warped midgets measured are shown in the complex plane. In Fig. 10b (lower part) the distribution of the

north/south angles for these warped midgets is shown. A series of calculations was made for the warped midg­ets above the atoms on the cardioid of the Cycle 3, 4, and 5 midgets on the Spike. A midget between the Cycle 3 and Cycle 4 midgets was also calculated. These angles fell very close to those for the corresponding

Page 315: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Warped midgets in the Mandelbrot set 339

1.0

0.7 (U

I 0.4

o O.H

b -0 .2 H

c

1 -0 .5 -0.8

-1.1

Complex Plane All Calculated Points

i

-2.1 —I—I—r

-1.5 -0.9 -0.3 Red Coordinate

— I — I — I

0.3 0.9

North Angle vs South Angle All Calculated Points

90.0

85.0

80.0 H

75.0 i

70.0

j * 1?- * +++

J Hit- + ^

1 ^ + ^HHd^fn:!}?*^^ " " J h

-T 1 1 1 \ 1 1 1 1 1 1 1 1 1 1 r-

d

— 1 1 1 1

70.0 75.0 80.0 North Angle

85.0 90.0

Fig. 10. On the top, all the positions in the M-set that were investigated in this study are plotted. On the bottom, all the north and south angles for the warped midgets measured at those positions, are plotted. Interesting families of curves result. The various families can be identified by referencing the sections of

Fig. 8.

sequence of warped midgets around the main Cardioid of the M-set (Fig. 4a) . The points were not identical, differing in the third or fourth places. But, on the scale of this plot, they fell nearly on top of one another. The

angle ratios determined from the warped midget above Atom 3 all fell extremely close together, then there is a space in the graph and the points from the warped midgets above Atom 4 fell together and so on. For the

Table 3. N/S angle measures for atom 3 warped midgets.

ID

C3 C4 C5 C3b MS R3 RIO

Feature

Cycle 3 Midget Cycle 4 Midget Cycle 5 Midget A spike midget Atom 3 on MS Atom 3 WM R3 Atom 3 WM RIO

N Angle

76.642 76.714 76.719 76.718 76.727 76.745 76.892

S Angle

80.612 80.595 80.591 80.591 80.590 80.681 80.769

Real pos.

-1.754 -1.941 -1.985 -1.861 -1.565 -0.153 +0.340

Imag. pos.

0.019 0.010 0.000 0.008 1.032 1.040 0.050

Page 316: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

340 A. G. D. PHILIP, M . FRAME and A. ROBUCCI

90

c < O

CO

80

70

RIO

R3

C3 MsC3bC4«^

70 80

Fig. 11. An enlargement of a portion of Fig. 9b. On the left the family of points from Cycle 4 (bottom), Cycle 5, Cycle 6 warped midgets are shown. Dotted lines connect these three sets of points to enlarged representations. On the far right the points in the patterns are identified by the position in the M-set from which they come (for the middle group of points). C3 stands for warped midgets of the major radicals on the Cycle 3 midget on the spike, R3 represents warped midgets above the radicals on radical 3, RIO is the similar case for radical 10, MS represents the warped midgets above the major radicals on the cardioid of

the M-set, C3b, C4 and C5 represent midgets on the Spike.

higher cycle numbers the points all merge together to fall on a smooth curve. But again, if the values are investigated closely, they differ in the third or fourth place. In [1] there is a chapter about the supposition that midgets are like snowflakes, i.e., no two midgets have the same distortion measure. This statement has not been proved but Figs. 10 and 11 show one example of the idea. Here is a family of warped midgets, all of which have different angle measures. Measures taken from similar objects (atoms of midgets on the spike) have an extremely close relationship to this plot, but each single value is different from all the others, pro­vided that the numbers are carried to sufficient pre­cision. In Fig. 11 an enlargement of the "Z?" family is shown on a scale that allows one to detect the individual positions derived from measures of warped midgets in the first tendrils of major atoms.

Table 3 lists the features measured (shown in Fig. 9) : the N / S angle measures and the position of Atom 3 in the warped midget measured.

6. CONCLUSIONS

We have begun our search of relationships in the north angle, south angle plane, taking measurements from several families of warped midgets. The fact that series of measures of angle ratios of warped midgets in the M-set give distortion measures that form families in the N / S plane is an interesting new feature of the M-set. Once one knows to which family of curves a set of measures belongs, then one can use this set of

relations to predict how the warped midgets in that series will be distorted, as a function of cycle number. At present we have found no angles greater than 90° nor smaller than 75°. Further investigations will place tighter limits on the angles to be found in the N / S angle plane. We are interested in finding a more com­plete distribution of points in the N / S plane when a much greater number of warped midgets have been measured in the M-set.

REFERENCES 1. A. G. D. Philip, A. Robucci, M. Frame, and K. W. Philip,

Series on Fractals, Midgets on the Spike {\o\. 1), L. Davis Press, Schenectady, NY (1991).

2. B. B. Mandelbrot, On the quadratic mapping Z-* Z^ -n for complex ii and z: The fractal structure of its M set, and scaling. Physica D7, 224-239 (1983).

3. A. G. D. Philip and K. W. Philip, The taming of the shrew. Amygdala 19, 1 (1990).

4. A. Robucci, unpublished (1993). 5. B. Branner, The Mandelbrot set. In Chaos and Fractals,

The Mathematics Behind the Complex Graphics, R. De-vaney and L. Keen (Eds.), American Mathematical So­ciety, 75-105 Providence, RI (1989).

6. A. Duoady and J. Hubbard, Iteration des polynomes quadratiques complexes. Comptes Rendu Acad. Sci. Paris 294, 123-126(1982).

7. B. B. Mandelbrot, On the dynamics of iterized maps III. The individual molecules of the M-set, self similarity properties, the empirical n^ rule, and the n^ conjecture. In Chaos, Fractals, and Dynamics, P. Fischer and W. Smith (Eds.), Marcel Dekker, New York (1985).

8. T. Wegner and M. Peterson, Fractal Creations, Waite Group Press, Mill Valley, CA (1991).

Page 317: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 341

Chaos and Graphics

AUTOMATIC GENERATION OF GENERAL QUADRATIC MAP BASINS

JULIEN C. SPROTT Department of Physics, University of Wisconsin, Madison, WI 53706, USA,

e-mail: [email protected]

and

CLIFFORD A. PICKOVER IBM Watson Research Center, Yorktown Heights, New York 10598, USA,

e-mail: [email protected]

Abstract—In this informal article, we describe simple approaches whereby a computer can automatically select parameters and generate a large collection of diverse, aesthetically appealing fractal patterns based on general quadratic map basins. Computational recipes are included to encourage reader involvement. In essence, we describe methods for teaching a computer to be both an artist and a critic of its own art.

1. INTRODUCTION

An infinite number of monkeys with an infinite num­ber of typewriters (word processors, nowadays) will eventually reproduce every work of Shakespeare. The problem is that someone has to sort through all the gibberish to find the occasional gem. On the other hand, the criteria for visual art are much less con­strained than for literary composition. A monkey with a paintbrush has a reasonable chance of producing a pattern that someone would consider artistic.

We have been experimenting with replacing the monkey by a computer and having it generate a collec­tion of visually interesting patterns. Unlike the mon­key, the computer can be trained to select those images that are likely to appeal to humans. The procedure is to take some simple equations with adjustable coef­ficients chosen at random, solve the equations with the computer, and display those which meet criteria that we have found to be strong indicators of artistic quality.

One approach is to use equations with chaotic solu­tions. Such solutions are unpredictable over the long term yet exhibit interesting structures as they move about on a strange attractor, a fractal object with non-integer dimension. Our books show many examples of computer art produced by these and related meth­ods [1-3] . Here we propose another simple method for producing fractal art.

2. GENERAL TWO-DIMENSIONAL QUADRATIC ITERATED MAPS

Traditionally when physicists or mathematicians saw complicated results, they often looked for compli­cated causes. In contrast, many of the shapes which follow describe the fantastically complicated behavior of the simplest of formulas. The results should be of interest to artists and nonmathematicians, and anyone with imagination and a little computer programming skill.

One lesson of chaos theory is that simple, nonlinear equations can have complicated solutions. The solu­tions are most interesting if they involve at least two variables, x and y, which can be used to represent horizontal and vertical positions, and if the variables are advanced step-by-step in an iterative process. The simplest nonlinearities are quadratic (x^ or xy). The most general two dimensional quadratic iterated map is:

Xnew = a + bx + cx^ + dxy + ey + fy^

yn w = g + hx^ ix^ + jxy -^ ky + ly^

where a through / are constants chosen at random but held the same throughout the calculation. Think of this as a mathematical feedback loop where new values for X and y are used again in the next round of iteration by setting x = x„ew and y = ynew The constants can be considered as settings of a combination lock, each revealing a different pattern for you to admire. They open doorways to an infinite reservoir of magnificent shapes and forms.

There are many ways to display the solution to our general maps. One way is to plot successive values of X and y as dots on the screen. Many of the solutions will move toward a point and remain there. Others will settle into a periodic orbit, or will move off toward infinity. The interesting cases are the chaotic ones which remain confined to a limited region but whose orbits produce a strange attractor with intricate fractal structure. You can choose the starting values of x and y arbitrarily within the basin of attraction, but you should discard the first few iterates since they probably lie off the attractor.

Another way you can display the solution is to solve the equations with many different starting values and count the number of iterations required for the solution to wander outside some region in the xy plane. You

Reprinted from Comput & Graphics Vol. 19, No. 2, pag. 309-313, 1995

Page 318: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

342 J. C. SPROTT and C. A. PICKOVER

can use the final number of iterations to determine the color for that point in the plane of initial xy values. Plots produced in this way are called escape-time frac­tals because the color contours indicate the time re­quired for the orbit to escape from the region. Some initial values may have orbits that never escape, and so you need to have a *'bailout condition" beyond which your program stops iterating and moves on to test the next initial condition.

Some of the most artistic examples of escape-time fractals explored in the past have been Julia sets of the map Zne^ = z^ -\- c, where z and c are complex numbers [4,5]. In terms of jc and y this map is

Xnew = x^ - y^ -\- a

ynew = 2xy -¥ b

and the test escape region is normally taken as a circle of radius of 2 centered on the origin. These traditional Julia sets are a special case of the more general maps we propose in this article.

3. COMPUTER ART CRITIC

Visually interesting escape-time fractals are those for which the orbits escape slowly. We have found that escape times between about a hundred and a thousand produce the most fascinating maps. We start by choos­ing the twelve coefficients randomly over the range — 1.2 to 1.2 in increments of 0.1, and then we iterate the equations for our generalized quadratic map with initial conditions of x = y = 0. If we find a group of coefficients that result in the initial point escaping beyond a circle of radius 1000 centered at the origin within 100 to 1000 iterations, then we save the param-

'Array of coef f ic ients 'Reseed random numbers 'Assume VGA graphics

DIM a(12) RANDOMIZE TIMER SCREEN 12 n% = 0 WHILE INKEY$ = "" 'Loop un t i l a key is pressed

IF n% = 0 THEN CALL setparams(x, y) CALL advancexy(x, y , n%) CALL testso ln(x , y , n%) IF n% = 1000 THEN CALL display: n% = 0

WEND END

SUB advancexy (x , y , n%) 'Advance (x , y) at step n% SHARED a( ) xnew = a(l) + x * (a(2) + a(3) * x + a(4) * y) + y * (a(5) + a(6) * y) y = a(7) + X * (a(8) + a(9) * x + a(10) * y) + y * (a(ll) + a(12) * y) X = xnew n% = n% + 1 END SUB

'Plot escape-time contours SUB display () FOR i% = 0 TO 639

FOR j % = 0 TO 479 X = -5 + i% / 64 y = 5 - j % / 48 n% = 0 WHILE n% < 128 AND X * X + y * y < 1000000

CALL advancexy(x, y , n%) WEND PSET ( i % , j % ) , n% MOD 16

NEXT j % NEXT i% END SUB

SUB setparams (x , y) 'Set a ( ) and i n i t i a l i z e (x ,y ) SHARED a( ) X = 0: y = 0 FOR i% = 1 TO 12: a(i%) = (INT(25 * RND) - 12) / 10: NEXT i% END SUB

SUB testsoln (x , y , n%) 'Test the solution IF n% = 1000 THEN n% = 0 'Solution is bounded I F x * x + y * y > 1000000 THEN 'Solution escaped

IF n% > 100 THEN n% = lOOO ELSE n% = 0 END IF END SUB

Fig. 1. ESCAPE.BAS: A BASIC program for automatically producing an unlimited number of escape-time fractals similar to those shown.

Page 319: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Generation of general quadratic map basins 343

Fig. 2. Escape-time fractal for parameters EHPLWTDJRCAP.

eter set and compute an escape-time fractal for a par­ticular region of the x-y plane. The choice of 1.2 for the coefficient range is about optimal for speeding the search, and it allows the coefficients to be compactly represented as letters of the alphabet (A = -1.2, B = - 1 . 1 , through Y = 1.2) for easy reference and replication.

The fisting ESCAPE.BAS (Fig. 1) shows a BASIC program for producing an endless succession of es­cape-time fractals by this method. It should run with­out modification under QBASIC, QuickBASIC, Visu-alBASIC for MS-DOS, or PowerBASIC on the IBM PC. It assumes VGA graphics (640 X 480 pixels X 16 colors). When run on a 486DX33 under PowerBA­SIC 3.0, the program takes on average about ten sec­onds to find each interesting case and about a minute

to plot it. In the process of searching for what we call "beautiful parameters," it discards about 300 sets for every one it saves for plotting. This still leaves about 200 trillion cases, nearly all of which are different. If you view them at the rate of one per second, it would take over six million years to see them all, and thus it is very unlikely that any of the patterns you produce will ever have been seen before. We often run the program overnight and capture the screens to graphics files, which can be rapidly examined the next morning.

4. SAMPLE ARTWORK

Although the programs and methods we have de­scribed work well with personal computers and pro­duce good-quality patterns within VGA screen limits, we became curious as to how our approach could be

Fig. 3. Mount Fractalia, a three-dimensional representation of Fig. 1.

Page 320: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

344 J. C. SPROTT and C. A. PICKOVER

extended to higher resolutions (Figs. 2-8) . Naturally, high-resolution, high-iteration computations would take longer to perform. To overcome these problems and push our method to the limit, we made use of IBM's Power Visualization System, a graphics super­computer which can compute our general quadratic iterated map in parallel using up to 32 Intel i860XP processors. This means that the computer can simulta­neously work on different portions of the artwork and therefore greatly reduce the time needed to explore a large number of images to find interesting structures. With our software and special hardware we can com­pute and view images at VGA resolution in under a second. The images in this article were computed at a resolution of 1600 X 2400 pixels using 1000 itera­tions for each pixel. Computation and display required less than a minute for each high-resolution image. The final step in aesthetic presentation involves the mapping of escape times to colors. Although beautiful images result from simple color mappings, such as the one used in the BASIC code, we used custom software which permits the algorithmic or mouse selection of colors from a palate of 2^^ colors in a convenient fashion. It is also possible for us to render the maps in three dimensions, representing escape time as height. The Power Visualization System enables us to fly-by the 3D maps in real-time, permitting us to make video-tape animations characterizing the intricate be­havior of these functions.

Fig. 5. Escape-time fractal for parameters MWRQ-FVMKUVFK.

. 4. The Fractal Curtain, an escape-time fractal for parameters WBMLNRQMNRAA.

Fig. 6. Escape-time fractal for parameters KUONOVSV-FLAR.

Page 321: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Generation of general quadratic map basins 345

Fig. 7. Escape-time fractal for parameters EMXI XPQMMTWRJ.

Fig. 8. Escape-time fractal for parameters JLLG-JTKDCRWY.

In the future, high-end methods such as these will be accessible to everyone as PC power increases, cost decreases, and Internet collaborations such as ours be­come commonplace[2]. In our own collaboration, in­put parameters were generated on a personal computer in Wisconsin, electronically sent over the Internet to New York, at which point they were read by the Power Visualization System and rendered.

To artists and computer graphics programmers, the automated generation of our generalized quadratic-map representations has great appeal because the speed allows the human analyst the freedom to experi­ment with many parameters. Students and teachers will enjoy such an approach as they explore and dem­onstrate the complexity and chaos associated with sim­ple formulas. Mathematicians may find the approach useful because the sheer number of different structures they can generate has the potential for making com­plex behaviors apparent which might have been over­looked using traditional approaches.

5. FURTHER SUGGESTIONS The method we have described is simple and effec­

tive, but we do not claim it is the final word on auto­

mated computer art. You can explore other criteria for selecting the patterns and other ways to display them. We chose a generalized two dimensional quadratic map to emphasize the complexity and variety that arises from simple equations. You can easily extend the technique to other mathematical functions and to higher dimensions. The same ideas can be used for automatic generation and evaluation of computer mu­sic. We would like to hear of any interesting results obtained by readers using our approach.

REFERENCES J. C. Sprott, Strange Attractors: Creating Patterns in Chaos, M&T Books, New York (1993). C. A. Pickover, Mazes for the Mind: Computers and the Unexpected, St. Martin's Press, New York (1992). C. A. Pickover, Chaos in Wonderland: Visual Adventures in a Fractal World, St. Martin's Press, New York (1994). H. O. Peitgen and P. H. Richter, The Beauty of Fractals: Images of Complex Dynamical Systems, Springer-Verlag, New York (1986). B. Mandelbrot, The Fractal Geometry of Nature, Free­man, New York (1993).

Page 322: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V All rights reserved

Part V. Iterated Function Systems

Within fractal geometry, iterated function systems (IPS), popularized by mathematics Professor Michael Barnsley, provide a method for both generating and characterizing fractal images. IPS can be thought of as a set of rotations, translations, scalings, and reflections (affine transformations) that provide a practical tool for image compression and understanding neural netw^orks, and for producing images of clouds, smoke, seascapes, flames, horizons, plant branchings. IPS can also be thought of as a collection of functions w^hose domain and range are in the same space; the functions can be applied successively, in any order. If the functions satisfy some minor conditions (in particular, they are all contraction mappings), iteration will result in convergence to the fractal attractor that is the union of all the limit points of all possible compositions of functions. Authors often investigate tw o methods of generating IPS: deterministic, in vv hich all the transformations are applied simultaneously, and random, in w^hich the transformations are applied one at a time in random order.

In the standard IPS formalism, there are no implied relations betvv een the transformations. Por example, in the random IPS implementation, the probability, /?(/), of applying transformation T{i) is independent of w^hich transformation w as previously applied. On the other hand, RIPS (recurrent iterated function systems) include a transition matrix, a table of probabilities/?(//) for applying T{i) given that T{j) has just been applied. (In the standard IPS, p{ij) =p{i) for ally.) By setting some of the /?(//) equal to 0, w e obtain a very rich collection of attractors having simple descriptions. (Por details, see Chapter 10 of Barnsley (1993), Chapter 2 of Pisher (1995), and Chapter 2 of Massopust (1994). Similar ideas are presented for the notion of "language restricted iterated function systems" (Prusinkiewicz, 1992).)

Local iterated function systems (LIPS) generalize IPS in another w ay. Instead of requiring that the transformations are defined on the entire space, LIPS consist of contractions defined on subsets of the space. This approach permits more compact descriptions of shapes made up of several distinct fractals. See Barnsley and Hurd (1993) for a clear example. Perhaps more surprisingly, LIPS permit the automization of the "inverse problem", finding the transformations to produce a given image (Barnsley and Hurd, 1993; Fisher, 1995).

Other researchers have "driven" IPS vv ith a symbol string, obtained by binning the output of a mathematical dynamical system or an experimental time series, and using the resulting pattern to analyze the driving string (Jeffrey, 1994; Stew^art, 1992). Por example, in Jeffrey's approach, four letters corresponding to bases in a DNA sequence drive the IPS pattern. Nonuniformity in the resultant graphics are caused by departures from randomness in the DNA string.

In 1995, Sonya Bahar introduced an IPS w ith time-varying coefficients (Bahar, 1995). By driving the choice of transformations, the full attractor reveals delicate subfamilies of imbedded orbits. Also, by partitioning the attractor space, the sequences of points generate a symbol string that can be used to drive the IPS. (See also Bahar, 1997; Mauldin, 1995; and Mauldin 1996).

Yuval Pisher's 1995 book Fractal Image Compression: Theory and Application features a collection of articles by twelve experts in the field of fractal image compression and iterated function systems, and contains details of hovj to encode and decode images, offering w^orking codes usable in practical applications. The following are several recent patents in the field of fractal image compression:

349

Page 323: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

350

(1) (4,941,193) Methods and apparatus for image compression by iterated function system (Bamsley; Michael E (Atlanta, GA); Sloan; Alan D. (Atlanta, GA)), Jul. 10, 1990.

(2) (5,065,447) Method and apparatus for processing digital data. (Bamsley; Michael E (Atlanta, GA); Sloan; Alan D. (Atlanta, GA)), Nov. 12, 1991.

(3) (5,384,867) Eractal transform compression board (Barnsley; Michael E (Atlanta, GA); Sloan; Alan D. (Atlanta, GA); Elton; John H. (Atlanta, GA); Moreman; Charles S. (Lawrenceville, GA); Primiano; Guy A. (Gumming, GA)), Jan. 24, 1995.

(4) (5,416,856) Method of encoding a digital image using iterated image transformations to form an eventually contractive map (Jacobs; Everett W. (San Diego, CA); Boss; Roger D. (San Diego, CA); Fisher; Yuval (La Jolla, CA), May 16, 1995.

(5) (5,430,812) Fractal transform compression board (Bamsley; Michael E (Atlanta, GA); Sloan; Alan D. (Atlanta, GA); Elton; John H. (Atlanta, GA); Moreman; Charles S. (Lawrenceville, GA); Primiano; Guy A. (Gumming, GA)), Jul. 4, 1995.

For recent information on iterated function systems, see the web sites http.7/inls.ucsd.edu/y/Fractals/ and http://www.iterated.com/.

For Further Reading

(1) Bahar, S. (1995) Chaotic orbits and bifurcation from a fixed point generated by an iterated function system. Chaos, Solitons and Fractals 5: 1001-1006.

(2) Bahar, S. (1997) Symbolic dynamics for IFS attractors. Fractals. 5: 237-246. (3) Bamsley M., and Hurd, L. (1993) Fractal Image Compression. A. K. Peters: New York. (4) Bamsley, M. (1993) Fractals Everywhere, 2nd Edition. Academic Press: New York. (5) Bamsley, M. and Demko, S. (1985) Iterated function systems and the global construction

of fractals. Proceedings of the Royal Society London A 399: 243-275. (6) Fisher, Y (1995) Fractal Image Compression. Springer-Verlag: New York. (7) Fisher, Y, (1996) Fractal Image Encoding and Analysis: A NATO ASI Series Book

Springer-Verlag: New York. (8) Hart, J. (1996) Fractal image compression and recurrent iterated function systems. IEEE

Computer Graphics and Applications. 16(4): 20-30. (9) Jeffrey, H. (1994) Fractal and genetics in the future. In Visions of the Future, C. Pickover,

ed., pp 127-135. St. Martin's Press: New York. (10) Lu, N. (1997) Fractal Imaging. Academic Press: New York. (11) Massopust, P. Fractal Functions, Fractal Surfaces, and Wavelets, Academic Press: New

York. (12) Mauldin, R. (1995) Infinite iterated function systems: theory and applications. Progress

in Probability 37: 91-110. (13) Mauldin, R. and Urbanski, M. (1996) Dimens ions and measures in infinite iterated

function systems. Proceedings of the London Mathematics Society. 73: 105-154. (14) Meloon, B. and Sprott, J. (1997) Quantification of determinism in music using iterated

function systems. Empirical Studies of the Arts 15: 3-13. (This article proposes a novel technique for exhibiting and quantifying the determinism in music. A written score of music is modeled as a dynamical system employing an iterated function system to generate a picture from the music.)

(15) Peruggia, M. (1993) Discrete Iterated Function Systems. A. K. Peters: New York. (16) Pickover, C. (1996) Fractal Horizons: The Future of Fractals. St. Martin's Press: New

York. (17) Prusinkiewicz, P. and Hammel, M. (1992) Escape-time visualization method for language-

restricted iterated function systems, pp. 24-42 in Fractal Geometry and Computer

Page 324: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

351

Graphics, J.L. Encarna9ao, H.-O. Peitgen, G. Sakas, and G. Englert, eds. Springer-Verlag: New York.

(18) Stewart, I. (1989) Order within the chaos game. Dynamics Newsletter 3:4-9.

Page 325: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 353

Chaos and Graphics

SOME NONLINEAR ITERATED FUNCTION SYSTEMS

MICHAEL FRAME and MAUREEN ANGERS Department of Mathematics, Union College, Schenectady, NY 12308-23II, USA

Abstract—We give examples of Iterated Function Systems where the usual affine functions are replaced by complex polynomials. Since these are not global contractions, some care must be exerted with the domain on which the functions are applied. On the other hand, the lack of unique inverse functions gives rise to multiple addresses for the same regions of the attractor, thus providing another degree of information available for determining other attributes—for example, colors or textures—of the image. Traversing a loop through parameter space reveals an 'explosion" of features and also what may be a curious cascade of self-intersections.

1. INTRODUCTION TO IFS

Mandelbrot's fractal geometry [1] has excited great in­terest in understanding hierarchical structures in nat­ural phenomena through processes repeated on many scales. This is a dynamic geometry, with function taking precedence over form. Within fractal geometry, the method of iterated function systems (IFS), popularized by Barnsley[2], is a relatively easy way to generate fractal images by repeated application of a collection of affine transformations

Tiix,y) = (aiX-\- biy-\- et, dx^ diy¥ ft).

Recall the eigenvalues X, and /u/ of T, are the roots of the equation

t^ - (at + di)t + {Uidi - bid) = 0

If both X, and M/ have modulus less than 1, T, is a contraction map with contraction factor r, = max {IX/1, IM/1}. Familiar arguments (Section 3.7 of [2]) show that if the affine transformations Ti, . . . , T„ are contraction maps, then the function T given by

T(A)=TdA)U'"UT„(A)

is a con.rraction map on the space Comp(R^) of com­pact subsets of the plane, with the HausdorfF metric. Recall that in the plane, compact subsets are the closed, bounded subsets, well represented by images consisting of pixels on a computer screen. Two images are nearby in HausdorfF distance if each is contained in a small expansion of the other (add a band a few pixels thick around the periphery of the image). The contraction factor of ris max { r i , . . . , r„}. Since Comp( R ) with the Hausdorff metric is a complete metric space, it follows from the contraction mapping theorem that for any A E Comp(R^), the sequence

A, T(A), T(T(A)) = T°2(^), T°\A), (1)

converges to a unique B E Comp(R^), the attractor of T. Moreover, B is the fixed point of T:

The set of affine transformations { T i , . . . , r„} is called an iterated function system (IFS) generating the set B. It is well-known (Section 3.8 of [2]) that the same set B can be generated as the closure of the orbit of a single point under repeated application of the T, in random order. This is the "random iteration algorithm," and the literature abounds with images generated by this method. For practical applications in image compres­sion and manipulation, there is considerable interest in finding an efficient solution to the "inverse prob­lem"—that is, given B E Comp(R^), find affine trans­formations { T i , . . . , T„} having B as their attractor.

Of course, there is no particular reason to restrict attention to affine transformations, except for the sim­plification of having contraction factors independent of the points at which the transformations are applied. In this paper we consider NIFS, iterated function sys­tems involving nonlinear functions. After pointing out that the inverse iteration method for generating Julia sets of quadratic polynomials can be viewed as an NIFS using the square root function, we give some examples of attractors of polynomial NIFS. Then we establish some estimates of parameter bounds guaranteeing each application of the functions is a contraction. Within this range, the convergence argument mentioned in the previous paragraph applies to NIFS. The lack of unique inverses for polynomial functions gives rise to multiple addresses' being assigned to regions of the attractor in the plane. Unique addresses can be recov­ered by passing to an appropriate covering space. Fi­nally, we illustrate the evolution of the attractors as we move through a path in parameter space.

We believe this extension of IFS to a wider class of functions opens new possibilities for image generation and encoding. In particular, though an affine IFS can produce any image to a given level of resolution, more efficient encodings may be achieved with nonlinear functions.

2. JULIA SETS AS NIFS

The Julia set J(c) for the function/(z) = z^ -\- c is the closure of the set of repelling periodic points of / ( z ) . It is well-known (Proposition 3 of [3]) that for any point ZQ of / (c) , the backward orbit {zo,/~'(zo, /~^(zo), • • •} is dense in /(c), where the inverse image /~^(zo) is defined as {z:/°^(z) = ZQ] . For example,

B = T(B) = Ti(B)U' • • UT„(B) (2) /"H^o) is gotten by solving Zo = z + c, or

Reprinted from Comput. & Graphics Vol. 18, No. 1, pag. 119-125, 1994

Page 326: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

354

• = -i. ZQ-z = +Vzo - c and

That is, writing

Ti(z) = + V z - c and r2(z) = - V z - c , (3)

we see

f-Hzo)={Tdzo),T2(zo)}

/-2(zo) = {r,(r,(zo)), r,(r2(zo)),

T2(TdZo)),T2(T2(Zo))}

and so on. Consequently, the backward orbit of ZQ is just the sequence

M. FRAME and M. ANGERS

~ T^{z) = -0.6'z" + (-0.35 - 0.35/)

r4(z) = 0.6-z^^-(0.35 -0.35/) (5)

{T(zo),T°2(zo), •} ,

Note that for this NIFS the pieces of the attractor are not exactly shrunken copies of the whole attractor. More will be said about this in Section 5.

Example 3.2. Figure 2 shows the attractor of the NIFS given by the functions

Ti(z) = -0,53'z" + (0.35 + 0.35/)

T2(z) = 0.53'z^ + (-0.35 + 0.35/)

T^iz) = 0.53• z^ + (-0.35 - 0.35/)

T4iz) = -0.53 • z" + (0.35 - 0.35/) (6)

Comparing this with Example 3.1, we have simply in­terchanged which functions involve conjugation and which do not.

where T(zo) = Ti(zo)U T2(zo), and so the Julia set J(c) is just the attractor of the NIFS T. The familiar "inverse iteration method" (page 35 of [4]) of gen­erating the Julia set Ac) is just the random IFS method Example 3.3. Figure 3 shows the attractor of the NIFS applied to the nonlinear functions (Eq. 3). In this pa- given by the functions per, we investigate NIFS with the nonlinearity's arising from polynomials instead of the square root function. Ti(z) = 0.6 • z^ + (0.35 + 0.35/)

3. POLYNOMIAL NIFS

We consider NIFS consisting of functions of the form

a'z"-\-b and z-^ a- z" + b.

where a and b are complex constants.

(4)

T2iz) = 0.6'z^ + (-0.35 + 0.35/)

T^iz) = 0.6'z^ + (-0.35 - 0.35/)

r4(z) = 0.6-z^ +(0.35 -0.35/) (7)

Example 3.1. Figure 1 shows the attractor of the NIFS given by the functions

r , ( z ) = 0.6-z2 +(0 .35+ 0.35/)

T2(z) = -0.6-z" + (-0.35 + 0.35/)

4. CONTRACTION ESTIMATES

To guarantee convergence in the Hausdorff metric of the sequence Eq. (1), it is sufficient to require each Ti(z) is a contraction. Of course, in general this is not the case, so we must restrict our attention to a subset of the plane. Let D(r, ZQ) denote the open disc of radius r and with center ZQ. We estimate the disc on which

Fig. 1. The attractor for the NIFS of Example 3.1, and a magnification.

Page 327: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Some nonlinear iterated function systems 355

Fig. 2. The attractor for the NIFS of Example 3.2, and a magnification.

r (z ) is a contraction, and the disc on which iteration of r (z ) is a contraction.

PROPOSITION 4.1. For T{z) of Eq. (4), we have

(1) r i s a contraction mapping on D{r, 0), where

ifllzll 1

. Substituting r, the radius of the disc

1

n\\a\\

and (2) r(Z)(r, 0 ) )C i ) ( r , 0)if

That is,

a • r" +

n- 1

< r.

1

n {n\\a\\y

(8)

n\\a\\ Z)(r, O),for ||z|| gives (8).

For part (2), observe

T(D{r, 0)) = D{ \\a\\ - r\ b) C D{ \\a\\ • r" + ||Z>||, 0),

so r(Z)(r,0))CZ)(r,0)if Ikll • r"+ ||Z?|| < r . Inequality (10) is obtained by substituting (8) into (9) and solving for \\bl III

For quadratic functions this becomes

(9) Corollary: For « = 2, T is a contraction on D{r^ 0) andr(Z)(r, 0 ) ) C i ) ( r , 0 ) i f

(10)

Proof:Since — r(z) = «*a 'z" \r(z)isacontraction az

1 and

1 •4.^11

(11)

For an NIFS Tx(z), . . . , ^ ( z ) , for / = 1, . . . , A: let r, satisfy (8) and \bi\ satisfy (10), so T, is a con­traction on D{^ri, 0) and TiiDin, 0)) C i)(r,, 0). Fur-

Fig. 3. The attractor for the NIFS of Example 3.3, and a magnification.

Page 328: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

356 M. FRAME and M. ANGERS

ther, suppose each KJ < \. In applying the random it­eration algorithm, to guarantee each application of each Ti (z-) is a contraction it suffices to require

r^(i)(r,,0))CZ)(r„,in,0)

for all / and m, \ <. i, m < k, (12)

where r in = minjri, . . ., r^}. Since r^(/)(r,, 0)) C D( \\aj • rf- + ||Z? ||, 0), condition (12) holds if

Ikmaxll • Ctx" + ll^maxll ^ ^n, (13)

That is,

PROPOSITION 4.2. In the random iteration algorithm, each application of T/ is a contraction if (13) holds.

In the special case ||<2 || = A, \\bn,\\ - B, and rim = «, for 1 < m < k, (consequently, all r = r by (8)) condition (13) becomes simply

Ar" -^ B < r. (14)

Using (8) to eliminate r, we obtain a relation between A and B:

\n-\Y-' 1 n" B"-

(15)

Starting the random iteration algorithm with z = 0, this bound is too strict. By iterating these functions, we produce a sequence of points with displacements from the origin generated by the translations. For in­stance, if Ti and T2 are the first two transformations applied, the points generated are

0,bi,a2'b1'-\-b2, • • •

and in general the moduli of the elements of this se­quence need not converge to any of the n. While the condition given in Proposition 4.2 guarantee Hausdorff metric convergence of the sequence (1), clean images

can be produced under less stringent bounds. For the examples given in Section 3, we have

. in-l)"~' 1 aiiipic

3.1 3.2 3.3

y i

0.6 0.53 0.6

n" B"-^

0.50576 0.50576 0.60469

Nevertheless, the bounds established in Proposition 4.2 give parameter values under which NIFS consisting of polynomials of the form (4) generate a unique attrac-tor. This provides a rigorous foundation for producing graphical images by this polynomial extension of the well-known affine IFS.

5. ADDRESSES, MULTIPLE COVERS

By using the decomposition (2), the transformation numbers can give addresses to regions of the attractor B. For example, Ti{B) has address (1), T\{T2(B)) has address (1, 2), and so on. In Example 3.1, the upper right quarter of the attractor has address (1), the upper left has address (2), the lower left has address (3), and the lower right has address (4). See the left side of Fig. 4. Of course, this addressing scheme is fa­miliar for affine IFS (Section 4.1 of [2]), but with polynomial NIFS there is a new feature.

For affine IFS, the address of a region is unique if the decomposition (2) consists of disjoint unions (Theorem 2, page 129 of [2], and the observation on page 118 that addresses are unique for "totally discon­nected" IFS). This no longer holds in the polynomial case. The right side of Fig. 4 shows that each region determined by a two-digit address in fact is determined by two diffisrent two-digit addresses. This "double cov­ering" is a result of the squaring in the functions (5). Specifically, decompose the attractor A into four "components"/ii = Ti{A),A2 = T2(A),Ai = T-^iA), and A4 = TAIA). Since A is symmetric across the real axis {i.e., A = A), and since —Tiiz) = T^{z), we see AT, - —A\. Similarly, A2 = —A4. Consequently,

Fig. 4. Left: the attractor for Eq. (5), the parts having addresses (1), (2), (3), and (4) are outlined. Right: the same attractor separated into regions determined by two-digit addresses. Note, for example, (11) and

(13) determine the same region.

Page 329: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Some nonlinear iterated function systems 357

A,,= T,(TM))=T,(-TM))

= T,(-T,{A))=T,{TM))=An,

where the penultimate equality results from the z^ in Tx. Repeating this argument for all components of address length two, we see that

An U ^ i 2 U ^ 2 i U ^ 2

U^31 U ^ 3 2 U ^ 4 1 U^42

and

••A,,UA,,UA23UA24

ifying two address digits determines not only the region of the attractor, but also in which of these two subsets, A ~ and A ^^, the region lies. Continuing in this way, three address digits determine two covers of each region of address length two. For example, both Axn U yi 112, and ^113 U ^114 cover yiii.

This suggests that an address string of length n spec­ifies not only the appropriate region of the attractor in the complex plane, but also one of the 2"" ' possible covers of this region. This additional structure provides another avenue for encoding information in the fractal structure. For example, cover addresses can be used to assign colors to particular subregions. This idea will be explored elsewhere.

U ^33 U ^34 U ^43 U ^ 4 4 6. A PATH THROUGH PARAMETER SPACE In this section we give an example of the kinds of

are just two copies of the attractor, but within each evolution attractors can exhibit as one of the translation copy the addresses (of length 2) are unique. So spec- factors varies along a loop in parameter space.

Fig. 5. Attractors for the NIFS (Eq. 5) with (Eq. 16). Left to right, top to bottom, the parameters of Eq. (16) are given in Eq. (17).

Page 330: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

358 M. FRAME and M. ANGERS

Figures 5 and 6 show the attractor A for a sample of some points along a path constructed from Eq. (5) by adding a function

and in Fig. 6

Ts{z) = a- z^ ^{b + C'i). (16)

Here b and c are varied to move Ts{A) along a loop around T\{A). Specifically, in Fig. 5 the values of «, b, and c are given by (left to right, top to bottom)

0.01 0.01 0.02 0.04 0.05 0.1

0.55 0.4 0.2 0.1 0 0

0.55 0.7 0.7 0.7 0.7 0.35 (18)

a

0.2 0.1 0.05 0.04 0.02 0.01

b

0 0.35 0.7 0.7 0.7 0.7

c

0 0 0 0.1 0.2 0.4 (17)

To minimize overlaps, the parameter a is reduced as 75(0) gets closer to the unit circle. Following the at­tractor around this path, we observe an "explosion" and subsequent reorganization.

Note at the beginning of Fig. 5 and at the end of Fig. 6 a particular feature, r2( r5(^)), has been marked

'0 \

• f ^ j /

• 1 /

1 ^-^^ i? \

/ • 3 • \ 1

Fig. 6. Attractors for the NIFS (Eq. 5) with Eq. (16). Left to right, top to bottom, the parameters of Eq. (16) are given in Eq. (18).

Page 331: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Some nonlinear iterated function systems 359

with an "x." Scrutinizing the second picture in Fig. 5 and the last picture of Fig. 6, we see as Ts(A) "turns the corner" at 0, the orientation of the marked feature seems to change. Magnifications of T2(T5iA)) along the path reveal that instead of a simple rotation, the feature seems to fold over on itself, calling into question the supposition that the attractor remains a Cantor set

of addresses can be viewed as providing a direction of information "perpendicular" to the attractor, and consequently allowing more compact encoding of such additional information as color or texture of the image. Examples of parameter space paths exhibit interesting manifestations of this multiple covering, including an explosion and a cascade of apparent self-intersections.

PSEUDOCODE

Random Iteration Algorithm for Quadratic Maps Set Parameters

A = number of transformations Shrink [7], Angle [7], ReTrans[7], ImTrans[7], Deg[7], Sgn[7] 7 = 1, . .

{For the function x -^ ((Rotate by Angle[7])(Shrink[7]*(z'^Deg[7]))) + (ReTrans[7] + ImTrans[7]*/)

Sgn[7]= 1; if z''Deg[7] is replaced by z"Deg[7], Sgn[7] = -1}

Set Initial Point X = 0, 3; = 0

Generate Points Randomly select an integer, 7, between 1 and N ifDeg[7] = 2 then

jcnew = Shrink[7]*(x'^2 - y^2) ynew = Shrink[7]*Sgn[7]*(2*jc*>^)

ifDeg[7] = 3 then xnew = Shrink[7]*(x''3 - 3*x*y^2) >;new = Shrink[7]*Sgn[7]*(3*x'^2*j;-3;'^3)

{In general, xnew = Shrink[7]*Re((x + y*iyn) ynew = Shrink[7]*Sgn[7]*Im(x + y*iyn)}

xtemp = xnew*cos(Angle[7]) - ynew*sin(Angle[7]) + ReTrans[7] ytemp = xnew*sin(Angle[7]) + ynew*cos(Angle[7]) + ImTrans[7]

X = xtemp y = ytemp

Plot(x,j;) Continue until new points stop appearing in the pic­ture.

,A^

all along the path. This matter will be pursued else­where, but here serves to show that magnifications of NIFS can reveal new types of behavior.

7. CONCLUSION

By incorporating complex polynomial functions into the standard affine IFS scheme, we are able to generate a different category of fractals, in which the subregions are covering spaces of the original. This nonuniqueness

REFERENCES B. Mandelbrot, The fractal geometry of nature, W. H. Freeman, New York (1983). M. Barnsley, Fractals everywhere, Academic Press, Bos­ton, MA (1988). L. Keen, Julia sets. In Chaos and fractals: The mathe­matics behind the computer graphics, R. Devaney and L. Keen (Eds.), American Mathematical Society, Provi­dence, RI, 57-74 (1989). H-O Peitgen and P. Richter, The beauty of fractals. Springer-Verlag, Beriin (1986).

Page 332: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 361

Chaos and Graphics

BALANCING ORDER AND CHAOS IN IMAGE GENERATION^

K A R E L C U L I K II and SIMANT D U R E Department of Computer Science, University of South Carolina, Columbia, SC 29208, USA

Abstract—We introduce new techniques to generate real-world images. Many of the natural images exhibit a hierarchical structure and a balanced combination of both order and chaos. We show how a controlled use of deterministic chaos yields a powerful method to concisely describe and to efficiently generate complex realistic images. The basic technique is the use of Mutually Recursive Function Systems (MRFS) possibly with additional control on the order of computations. Then we show that, surprisingly, regular sets of control sequences are convenient but not essential. Some examples are presented illustrating the power of the tech­nique.

1. INTRODUCTION

In recent years, Mandelbrot's fractal geometry [1] has drawn considerable attention of scientists and math­ematicians, as it provides methods for a concise de­scription of many of the seemingly complex forms and patterns in nature and the sciences. Fractal geometry has found applications in many areas, ranging from the study of chaotic (complex) systems[2] to the de­velopment of new techniques for image compression [ 3, 4]. In a way, fractals have helped in reconnecting pure mathematics research with both natural sciences and computing. Computer graphics has played an impor­tant role both in its development and rapidly growing popularity. Conversely, fractal geometry now plays a significant role in the rendering, modeling, and ani­mation of natural phemomena and of fantastic shapes in computer graphics.

It has been often cited that many of the natural ob­jects like trees, mountains, coastlines, clouds, etc. are fractal, i.e., they contain copies of themselves. How­ever, to provide a more accurate description of real-world images, one has to take into account the disorder seen in these natural objects. Therefore, though an ob­ject like a tree has self-similar geometrical shape, it has some amount of disorder (chaos) in the arrangement of its branches or leaves. This also applies to various textures as studied in computer graphics. Also, a natural image will typically have a hierarchical structure. Tak­ing again the example of a tree, the most accurate de­scription would be a hierarchical one. At the lowest-level of this hierarchy, a single leaf and a trunk is de­scribed, each of which is a fractal. Leaves and trunks are then combined in a different recurrent pattern, giv­ing us the whole tree. Moreover, branches of a tree at different levels will typically have different structures, which again follow certain regular patterns but manifest also considerable irregularity or randomness (possibly caused by the effect of environment on the growth of plant in addition to that of its genetic blueprint).

^This research was supported by the National Sciences Foundation under Grant No. CCR-8702752. Preliminary version of this paper has been presented at ICALP'91, Madrid, Spain.

The observation that the boundary region between order and chaos results in the most interesting and most complex behavior has been made in the case of cellular automata too, which are discrete dynamical systems capable of modeling physical systems. Most intriguing cellular automata belong to Class 4, which lies between Classes 1 and 2 (characterized by highly regular behavior) and Class 3 (characterized by chaotic behavior)[5]. Also see [6, 7] for the use of controlled disorder in crystallography.

An extensive work has been done on mathematical description and computer generation of fractals. The methods used can be classified as fitting in one of three basic methods.

1. Variants of the "Escape algorithm" use the fact that for many iterative processes the boundary between the domain where the process converges and where it diverges has fantastic fractal shapes. The prime examples are Julia sets[3] and the Mandelbrot set[l]. These fractals are mathematically interesting and artistically beautiful but are not useful for the approximation of real-world images.

2. Various deterministic recursive or iterative proce­dures like L-systems[8-13] and many others, e.g.,[\A-\6]. The most important has been the work of Bamsley and others on Iterative Function Systms (IFS)[3, 17-20] because it provides the possibility to encode (even automatically) a wide variety of real images. This method is based on the idea that a suitable, usually chaotic, dynamical system is de­signed that has a given image as its attractor. Barns-ley's Chaos Game algorithm uses the chaotic process to select the points that approximate the texture of the image, it does not necessarily make the image itself chaotically irregular.

3. Random fractals, (a) Some method of groups 2, e.g., L-systems can employ a random selection of rules or parameters to generate randomly irregular images. It should be noted that Barnsley's IFS are not suitable for this, (b) Truly random fractals are generated, for example, by simulating fractional Brownian motion and then using rendering tech­niques [ 18 ]. In this way realistic looking landscapes

Reprinted from Comput. & Graphics Vol. 17, No. 4, pag. 465-486, 1993

Page 333: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

362 K. CuLiK II and S. D U B E

of mountainous terrains and rivers have been ob­tained.

For the random fractals every run of the same gen­erating program produces a different image of the same character, unless one uses a pseudo-random generator with a fixed seed. Therefore group 3 methods do not seem suitable for image compression.

A number of methods belonging to group 2 are au­tomata-theoretic. Specifically, we would like to men­tion that strings over alphabet 2„ = {0, . . . , « - 1} can be interpreted as rational numbers in [0, 1] and hence regular sets over S„ interpreted as subsets of [0, 1] as was done already in the 60s [19, 21]. Extending this method fractals can be defined by rational expres­sions, finite automata, or equivalent devices, see [14, 16, 22] for images of finite resolution and[15] for the extension of this method to limiting attractors and, more importantly, to texture-images generated by probabilistic finite automata (generators). In[23] we have shown that these methods (both deterministic and probabilistic) are a special case of the MRFS con­sidered here and that the conversion of the finite au­tomata to MRFS gives about tenfold speed-up of the generating algorithm.

In this paper we develop a new deterministic method (group 2) that could be used to generate apparently random complex real world images that might look like the ones produced by the methods of group 3. The idea is to generate such irregular images by simulating deterministic chaos in a controlled manner. The well-developed automata theory is applied for this purpose. The important aspect is that the rules (the sizes of the description) are relatively simple, however, the behav­ior of the dynamical system, generating the image, is complex. In some image generation systems (^.^.[12, 13]) one has a post-processing phase called rendering, which uses some images like flowers, leaves, etc., not created by the system. However, in the method de­scribed in this paper all these additional images are also created by the same system.

The organization of this paper is as follows. In Sec­tion 2, we formalize the notion of an image and present basic definitions. In Section 3, we briefly discuss some known methods to generate images, which include fi­nite generators and mutually recursive function sys­tems. In Section 4, we illustrate why the IFS method is not suitable for the generation of irregular images. This leads to the development of a simple technique that allows one to obtain an irregular version, as the attractor of a suitable MRFS, of any object defined by an IFS. In Section 5, we generalize the MRFS by im­posing control on the sequencing of the computations. We call this generalization as Controlled MRFS. We illustrate in Section 6, by giving some examples, that this makes the design of natural images much more convenient and the description more concise. However, surprisingly, we show that if the set of the control se­quences is regular then the power of MRFS is not in­creased. In Section 7, we generalize the control se­

quences to texture images. In Section 8, we make con­cluding remarks.

Actually, it is clear from this work that all the meth­ods fitting into group 2 can be simulated by Controlled MRFS. In particular, for the simulation of DOL-sys-tems by Controlled MRFS see [24].

2. PRELIMINARIES AND DEFINITIONS

2.1. Two notions of an image See[3] for the definition of basic concepts from the

theory of metric spaces and measures. In this paper, we will be concerned with the 2-D

Euclidean plane as the underlying complete metric space. In fact, one can work with the unit square U = [0, 1]^ as the underlying space X without any loss of generality. The set of Borel subsets ^ is the c-field generated from the open subsets of X, by the Boolean operations of complementation and countable union. A measure n on Borel subsets is a real non-negative function ii: 5B ^^ [0, co) that is additive on a countable union of pair-wise disjoint Borel sets. If M ( ^ ) = 1, then IJL is called normalized.

If we want to make precise statements about images and accuracy of their approximations we need to for­malize the notion of an image and of the distance be­tween two images. Following [ 3 ], we will consider two kinds of images, each type with finite or infinite reso­lution.

Consider a complete metric space X with metric d. Typically X will be the unit square of 2-dimensional Euclidean space.

1. A c-image of infinite resolution is a compact subset ofX. It formalizes a black-and-white image (no grey tones).

2. A c-image of finite resolution is a map 7 : C -*- {0, 1}, where 2 is a set of pixels and y(p) = 0(1) means that pixel p is assigned white (black), respectively.

The set of compact subsets of X (c-images) is denoted by ^(X). Endowed with the HausdorfF metric it forms a complete metric space [ 3 ]. Simi­larly, we have two notions of a texture image (/-image):

3. A /-image (greyscale image) of infinite resolution is a normalized Borel measure on space X. It for­malizes the distribution of greyness over X. For a color image (in RGB representation) we specify three measures one for each basic color component.

4. A /-image of finite resolution is a map ^ : Q^*- [0, 1] where C is a set of pixels and IJL{P) is interpreted as grey tone of the pixel p. For a color image, we need three functions. The set of all normalized Borel measures on X(/-images) is denoted by P(X) . En­dowed with the Hutchinson metric it forms a com­plete metric space [ 3 ].

A /-image O is formalized as a normalized measure such that IJL{0) = 1. Informally, the image O can be viewed as a distribution of infinitely fine sand, of total mass one, lying upon its support (support of ^ is the set of all those points in X whose all (-neighborhood

Page 334: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation

Table 1. Two notions of an image.

363

Type of image Resolution Definition Metric

c-image

t-image

black-and-white

texture (greyscale)

finite infinite finite infinite

y: Pixels -^ {0, 1} compact subset fx: Pixels-*- [0, 1] normalized measure

Hausdorflf metric

Hutchinson metric

balls, € > 0, have nonzero measure). The measure (greyness) of a Borel subset of 5 of X is the mass of sand which lies upon B.

See Table 1 for the summary of the two notions of an image.

2.2. Languages of infinite words We assume that the reader is familiar with the basic

automata theory, which includes definition of finite automata and regular sets. A language is a set of strings over some alphabet of symbols. In formal language theory, the computation domain is the language 2* of all finite strings over a finite alphabet 2 . This domain can be extended by adding the set of infinite strings 2*^[24]. Formally, 2'^ denotes all infinite (co-length) strings a = ^i«2«3 • • •, <2/ E 2 , over 2 . An element a of 2'^ is called an co-word or ui-string. An o)-language is any subset of 2 ' . The superscript co means infinite repetition, e.g., (00 )* 1 ' denotes an co-set of strings that has an even number of zeroes followed by an infinite number of consecutive ones.

3. TOOLS FOR GENERATING IMAGES

3.1. (Probabilistic) ftnite generators We briefly discuss how finite generators can be used

to represent images [15]. Considering binary notation, a string over alphabet 2 = { ( 0 , 0 ) , (0, 1 ) , ( 1 , 0 ) , ( 1 , 1 )} , say (0, 1)(1, 1)(1, 0 ) , is interpreted as a 2-D point (0.011, 0.110), which is the lower left corner of the shaded subsquare in Fig. 1. Correspondingly, an co-word is interpreted as a 2-D point with real coor­dinates. Finally, the 2-D image represented by a regular set i? c 2* is the set of 2-D points obtained by inter­preting adherence {R). The adherence of a language L is the set of co-strings that are algebraic limits of pre­fixes of L, formally adherence (L) = {w E 2'^|Pre­fix (H^) c Prefix(L)}, see[24]. This regular set R can be effectively given as aftnite generator (FG) or a ra­tional expression [15].

For example, the rational expression 2* represents the unit square ^ = [0, 1]^, and the rational expression

p = { ( 0 , 0 ) + ( 0 , 1 ) + ( 1 , 0 ) } *

represents the classic Sierpinski triangle. A probabilistic FG (PFG) M defines a ^image, where

the greyness of the image is given by defining measure on a countable base of Borel subsets, namely, the set of all subsquares specified by the strings in 2* (a string w speciftes the square represented by the regular set W' 2 * ) . The greyness of the square specified by string w is the sum of the probabilities of all the paths (the

probability of a path means the product of the prob­abilities on its transitions) labeled by w in M.

For example the string (0, 1)(1, 1)(1, 0) specifies the subsquare shown in Fig. 1. Its measure is the mul­tiple of the three probabilities associated with the path (0, 1)(1, 1)(1, 0) in the PFG representing the given image.

In[15] , it is shown that (P )FG are special case of (P)MRFS, which we discuss in the next subsection.

3.2. Mutually recursive ft^nction systems MRFS were introduced in [23] as a generalization

of IFS [ 3 ] , where also their equivalence with affine au­tomata and afiine regular sets was proved.

We will informally define an MRFS and state a theorem about the existence and uniqueness of its at-tractor. We first explain the meaning of the following notions in the definition of MRFS.

A variable is a symbol whose "value" is a c-image. Some variables are marked as "display" variables.

An equation is a rule of the form

A = w,{B,)^ W2(B2)U' ' 'UWn{B„)

stating that execution of the rule updates the value of A to be the union of the (current) values of variables Bi, B2, . . ., B„ under affine transformations Wi, W2, . . . , w„, respectively.

A Mutually Recursive Function System (MRFS) is a system ofn equations defined for n variables, exactly one equation for each variable.

An MRFS M defined for n variables can be repre­sented by a digraph G with n nodes, each representing a variable. Let ^ 1 , ^ 2 , . • •, ^« be the n variables, and let node Vj represents variable ^ / , 1 < i < n. Then, if Ai is defined by the equation

Fig. 1. The subsquare specified by the string (0, 1)(1, 1) (1,0).

Page 335: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

364 K. CULIK II and S. DUBE

then Vi has incoming transitions from Vj^, Vj^, . . . , Vj^, which are labeled with affine transformations w,,, vv/j, . . . , Wj^, respectively.

If there exists a unique assignment of values, say A\, A'2,..., A'n, to variables^1, ^2, • • •, ^«, respec­tively, which remains invariant under one single ap­plication of the mutually recursive equations, then these values constitute a fixed point of this system of equations. Now, we give a condition for the existence and uniqueness of this fixed point.

An MRFS Mis called loop contractive if the product of the contractivity factors of the transformations la­beling any loop in the underlying digraph G of M is strictly less than one.

Theorem 1: An MRFS has a unique attractor if it is loop contractive.

For proof see[25]. Let D c [A^, A2, . . . , A„} be the set of display variables. Then,

The Attractor of M = U A'i.

This attractor is the c-image defined by M. In other words, the attractor of Mean be expressed in terms of the unique fixed point (^'1, ^ 2 , . . . , ^'„) of the natural mapping W: {^{X)Y -^ (^{X)Y defined by M.

The c-image defined by M can be computed by the following Deterministic Algorithm.

• Initialization: Choose arbitrary nonempty compact subsets of the underlying complete metric space X (the unit square U = [0, 1]^) as initial "values" of the n variables.

• Iterations: Apply the n mutually recursive definitions of these variables iteratively to compute their new values. This is done for m > 0 iteration steps.

The union of the limiting values of display variables when m -> 00 is the c-image defined by M.

3.3. Probabilistic MRFS Now a variable ^ is a symbol whose value is a t-

image, i.e., a normalized measure on Borel subsets of X. To emphasize that it is a /-image, we will denote this value by fiA. An equation of the form

A = w,{C,)U W2{C2)U' "U w„{C„)

has n associated probabilitiesPi,p2, • • • ,Pn summing to unity, and indicating the "weight" of the contri­bution of each of the ^images ^c,, MCZ. • •» Mc„ re­spectively, in the computation of^.

Mathematically speaking, ix^ is computed to be the weighted sum of the values of Ci, C2, . . . , C„,

HAiB)= 1: PiUc^iwrHB)) (1)

for all 5 G ^ (Recall that 5B is the set of all Borel subsets ofX).

Consider an MRFS and its underlying digraph G. By labeling the edges of the digraph G with probabil­ities, so they sum up to one of all the incoming edges for each node, we obtain a probabilistic MRFS (PMRFS). We also define a final distribution function / from the set of variables {Ai, A2, ..., A„} to the

n

unit real interval [0, 1], such that 2 / ( ^ / ) = 1. Just /=i

as an MRFS defines a unique c-image, which is the fixed point of the equations, a PMRFS defines a unique ^image in terms of the fixed point of the equations now interpreted as in Eq. (1) with respect to the com­plete metric space of normalized Borel measures with Hutchinson metric.

Let a PMRFS M have n variables Ai, A2, ..., A„. Then there exists a unique assignment of values (t-images) jn . to each variable Aj, i = 1, 2, . . . , «, such that it remains invariant under one application of equations, where an equation is applied as in Eq. (1). Then, the /-image HM defined by M is the weighted sum of these n /-images according to the final distri­bution / :

M M ( ^ ) = 2 / ( ^ / ) M ^ . ( ^ ) ,

where B is any Borel subset. The support of this /-image IIM can be approximated

by the Chaos Game Algorithm. Consider the digraph of M and view it as a systolic architecture, in which each node is like a simple processor with the compu­tational capability of applying an affine transformation to a point. Initially, each node "stores" some random point in y . Then at each iteration step, all node syn­chronously recompute their stored point. This updating is done as follows. Each node randomly chooses an incoming transition (and therefore a neighbor con­nected by the transition) according to the given prob­abilities on the incoming transitions, and applies the transformation labeling the selected transition on the point stored in the neighboring node. Let the total number of iterations done be m. Let GA = {^1, ^2, . .., Xn,} he the collection of all the points generated at node (variable) ^ . Then GA is an approximation of the support of the /-image IIA defined by A.

To compute this /-image as a measure, we generalize the Chaos Game Algorithm to the Hit Counting Al­gorithm, in which we keep a count of the number of points that fall inside a Borel subset (here we can work with a countable base of the set of Borel subsets [ 3 ]). The measure (/-image) M^ defined by A is given by

I1A(B) = Iim —^, «-Qo m

where m^ = | G^ H 51 and B is any Borel subset ofX.

Page 336: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 365

The support of the ^image HM is the c-image defined by M when probabilities are ignored and M is viewed asanMRFS[23].

3.4. MRFS as generalization oflFS An iterated function system (IFS) is nothing but an

MRFS defined for exactly one variable. Call this vari­able A. There is exactly one equation for A. Let it be

A = Wi{A)Uw2(A)U' • -Uw^iA)

for some contractive affine transformations Wi,W2,..., Wjs^. For /-images, one associates a probability pi with

N

Wi, such that 2 A = 1- This also implies that the /=i

underlying digraph of this IFS consists of a single node with iV self-loops, labeled with the transformations Wi, W2, . . . , WAT and having probabilities (for the Chaos Game Algorithm)pi,pi, • - •,PN-

In [ 15 ], incomparability of IFS and PFG is shown. Since MRFS are generaUzations of both IFS and PGF[15, 23], we have the following result.

Lemma 1. The class of images defined by IFS is a proper subset of the one defined by MRFS.

Example 1: The well-known Sierpinski triangle is gen­erated by an IFS with the following three affine trans­formations:

wi(x, y) = (0.5x, 0.5>^),

^^2{x,y)= (0.5JC + 0.5, 0.5>^),

H 3(- , y) = (0.5x, 0.5y + 0.5).

Since IFS are a special case of MRFS when there is just one variable, an equivalent MRFS is defined for a variable A and has the equation

A = Wi(A)U W2{A)U WsiA).

First 9 steps of the Deterministic Algorithm starting from the filled unit square are shown in Fig. 2, and similarly first 9 steps from two line segments are shown in Fig. 3. In Fig. 4a, we show 50000 points approxi­mation of Sierpinski triangle, generated by the Chaos Game Algorithm, first with uniform probability (grey-ness) distribution, i.e., P\ = P2 = P3 , and then in Fig. 4b with probabilities pi = 0A5, p2 = 0.3, p^ = 0.55. The Hit Counting Algorithm will give an ap­proximation of the r-image of the Sierpinski triangle in both cases. D

Kpy^r^vhi.

I K I K 1 1 l k ^k l k rt. £V Fv cv Ck ^^ Fw rw KK PV QV EL.

Fig. 2. Sierpinski triangle starting from filled square.

Page 337: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

366 K. CuLiK II and S. DUBE

\A

M AA

//VWUAA

MA iAA A( ' ' ' . 'A ' ' 'A

<y^^ ^ ^ ^ ^ /y^A

P^^ fa^ ^ ai. ^ ^ ^ ^

pyfeh

^^b^k

^

^y^K

^kh Ssv

Ek

P-, pK^

Kk KK KK KK

Fig. 3. Sierpinski triangle starting from two line segments.

Example 2: Figure 5 shows a complex recursive image and the PMRFS that generates it. An equivalent MRFS is given by the following equations:

t = left(0 U right(0 U trunk(/)

segment = up (segment) U down (segment)

circle = point (circle) U rotate (circle)

tree = i d ( 0 U <2(segment) U /?(circle)

U c(tree) U c(shadow)

shadow = sh(tree)

Clearly, this multivariable MRFS defines an image not definable by an IFS. In Subsection 4.1, we show that MRFS can encode some irregular images more efficiently than IFS. Example 2 shows that this is the case also for regular recursively defined images. D

4. GENERATING RANDOM FRACTALS

First we show how Barnsley's IFS method can be possibly used to generate random (irregular) images by using a random number generator. Since, we have two algorithms—the Deterministic Algorithm and the Chaos Game Algorithm, we need to investigate how each can be modified to generate random fractals.

The basic idea behind the generation of random fractals by IFS is to have coefficients of each affine

transformation to be dependent on some parameter / that takes values from a real interval, for example, the unit interval [0, 1 ]. Now though the Deterministic Al­gorithm is an iterative algorithm, it can be naturally implemented by a recursive algorithm, which builds the image in a bottom-up fashion as shown in Fig, 6. The value of parameter / is randomly chosen at each recursive call, the coefficients of each affine transfor­mation are recomputed, and the resulting affine trans­formation is applied. One has to ensure that for each value of t, the transformations are contractive. The value of DEPTH should be chosen large enough to obtain an image with fine details, and the algorithm should be initially called with / = 0.

Essentially the same idea works for the Chaos Game Algorithm. The reason why Chaos Game Algorithm generates a sequence of points approximating the at-tractor of (7, is that for each point a in the attractor of G, it applies infinitely many prefixes of its address a (see [3] for the definition of address of a point) to some point in X. Thus, every neighborhood of a is visited infinitely many times with almost one proba­bility.

A straightforward modification of the algorithm Random IFS shown in Fig. 6 allows us to generate a set of points by approximating an address by its finite prefix of length equal to DEPTH. The application of these prefixes to arbitrary points in X gives one an ap­proximation to the image defined by G. But since we

Page 338: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 367

KrwcwK.

Ck r^ Kk. BiL

gKfeKfe>tM>.

PK P . tKftKhKKK.

Sfek p w

CkKkEkKW

cw rv. Ck Ck

SikO^hi.

Jk k ?k Kk bwk.krkCkk.rkfck

(a)

(b)

Fig. 4. Sierpinski triangle generated by the chaos game algorithm.

are applying slightly different transformations at each recursive call, thus we will obtain an irregular or ran­dom version of the attractor of G. Note that if we plot m points using this algorithm, then we are approxi­mating the attractor of the IFS by prefixes of length O(logivm), whereas in the case of the Chaos Game Algorithm, an address is approximated by a prefix of length 0(m). The randomized Chaos Game Algorithm loses its sequential nature and it is therefore more dif­ficult to implement.

4.1. Defining irregular images by MRFS The previous discussion indicates that it is desirable

to develop simpler methods to generate irregular im­ages, in particular it would be more desirable to have a purely deterministic method that does not use any random number generator.

The aim of this section is to show that MRFS can be used to generate images in a purely deterministic manner that have some apparently random or chaotic properties.

We now show one of the ways by which irregularity or randomness can be added to "pure" fractals. Let O be a "regular" object defined by the following IFS

A = Wi(A)U W2(A)U' ' '[Jw„{A).

To obtain an irregular version of (9, we define an MRFS M with several variables that are defined in terms of each other in some arbitrary fashion and by using affine transformations that are "slightly" different from Wi, . . . , w„. Two affine transformations are slightly dif­ferent from each other if their corresponding coeffi­cients differ by a small amount, i.e., if Wi(x, y) = [a\iX-\- any -^ aU, a^iX-\- a^y + ^23] and H^2(X,3^) = la]ix + a]2y + «i3, ^hx + 22 ^ + ^23], then they are said to be e-different if \a]j — ajj\ < e, where e is a small number.

Suppose, MRFSMhas m variables^1 ,A2,.. . ,An, where each of the variables is updated by the equation of the form

A, = w^.iAj,) U w,,iAj,)U' . -U w,„(4J

where Wi^ and Wk are 6-different for some small number e. One of the m variables is marked as a display variable. Let O'he the attractor of M. Then, O' can be regarded as an irregular version of O that retains the character­istics of O but has some level of irregularity in it. If €

Fig. 5. A tree with a hanging mirror.

Page 339: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

368 K. CULIK II and S. DUBE

A l g o r i t h m RandomlFS (i)

** DEPTH is the maximum recursion depth

** u?i(<), W2{t),..., WN^t) are N parameterized transformations

if i = DEPTH t h e n return (arbitrary c-image);

else

for each z € { 1 , 2 , . . . ,iV} do

choose randomly a value of t,

Ai = iwi{t)) (RandomIFS(i + 1));

return(Ai U A2 U . . . U AN);

end RandomlFS;

Fig. 6. A recursive IFS algorithm to generate random fractals.

is chosen to be sufficiently small then h(0,0') will be less than b where 5 is a small number. This follows from the following theorem, which can be extended to ^images as well. This theorem can be proved by ex­tending a similar theorem for IFS in [ 3 ].

Theorem 2: Let M be an MRFS. Let the affine trans­formations of M depend on a parameter p, which takes the values from a closed interval of reals, such that for all these values the loop contractivity condition is sat­isfied. Then, the at tract or of M depends continuously on p with respect to the Hausdorff metric.

4.2. Examples of irregular images generated by MRFS In this subsection, we combine the technique de­

scribed above with some others to achieve deterministic chaos causing the desired irregularity.

Example 3: Consider the self-similar tree shown in Fig. 7c generated by the repetitive application of the equa­tion

A = Wi{A)UWriA)Uw,(A)

where w/, Wr and Wt stand for transformations gener­ating the left branch, the right branch and the trunk, respectively. See Fig. 7a for the underlying digraph of the corresponding MRFS (which is also an IFS) defin­ing this image.

To obtain a '^chaotic" tree we consider transfor­mations obtained from w/and w, (but keeping the trunk same) by changing slightly their coefficients such that the angle and the length of the left and right branches in each case are slightly different. In addition, we might choose to "flip" a branch, which will yield even more irregularity. Other methods for the generation of ir­regular trees have been discussed in [12, 27].

In our example, we have chosen an MRFS with three variables ^ 1 , A2 and A3, which are mutually recursively defined in terms of each other, as shown in Fig. 7b.

(a)

(c) (d)

Fig. 7. Generating "chaotic" trees by MRFS. (a) MRFS for a "regular" tree; (b) MRFS for an "irregular" tree; (c) a "regular" tree; (d) an "irregular" version of the tree in (c).

Page 340: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 369

We have chosen Ai to be the display variable. The attractor is shown in Fig. 7d. The arrangement of branches in this tree clearly follows a pattern that has both order and chaos.

In Fig. 8a, a row of such chaotic trees with hanging mirrors is shown. This image can be generated by an MRFS, however, it was actually produced more effi­ciently using a control string discussed in the next sec­tion. In Fig. 8b, we have shown an MRFS that will generate such a row consisting of regular trees. D

Example 4: In this example, we first give an IFS defin­ing a rather natural-looking tree. The IFS is specified by six affine transformations—two for the trunk and one for each of the four branches. This tree is shown in Fig. 9a. Though this tree looks much better than the one in Fig. 7c, it should be noted that the tree is perfectly regular. MRFS can not only add some level of disorder but also remove the pattern "two branches on the left, two on the right." The same technique as the one used in Fig. 7 is employed to come up with such an MRFS. The resulting tree is shown in Fig. 9b.

We give the specific parameters used in this example. An affine transformation can be completely specified by six parameters r, 5, 6, 0, e and / , where r is the

contraction factor of the x-coordinate, s is the con­traction factor of the >;-coordinate, 6 is the angle through which the jc-axis is rotated, cf) is the angle through which the > -axis is rotated, e is the translation in the x-direction and / i s the translation in the y-direction. That is, the point (x, y) is mapped by the affine transformation to the point

{rcos(d)' X - s sin((/))- y -\- e,

rsm(d)' X -\- scos((f))' y-\-f).

Using the above notation, the tree in Fig. 9a is generated by the first six affine transformations shown in Table 2. The transformations to and ti give the trunk, /i and I2 the lower and upper left branches respectively, and ri and rj the lower and upper right branches, respec­tively.

For Fig. 9b, we have used five more transforma­tions—^3 for a middle branch on the right, /'i as a slight variation of A, /i and 12 of I2, and ^2 of ^2. The tree is generated by and MRFS defined on four variables A, B, C, and D, out of which A is the display variable. These variables are mutually recursively defined as follows:

\

(a)

trunk

bottom

(b)

Fig. 8. Generating "chaotic" trees by MRFS. (a) a row of chaotic trees; (b) MRFS for generating a row of "regular" trees.

Page 341: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

370 K. CULiK II and S. DUBE

(a) (b)

Fig. 9. Another example of chaotic trees by MRFS.

A = to{D)UtdD)UldB)Ur,(C)

Ul2{D)Ur2(D)

B = toiD) U tdD) U 1\{B) U r2iA) U r,(D)

C=to(D)UtdD)Ul'i(D)Ur'2iB)

D = to(D)UtdD)Uh(D)Ur,iD)

Ul'2(A)Ur'2{A)

Note that A, B,C, and D define tree with four, three, two, and four (main) branches, respectively. Since they are mutually recursively defined, and we have chosen additional transformations, which only differ from the original ones slightly, the tree in Fig. 9b is more irreg­ular than the one in Fig. 9a and does not have "two branches on the left, two branches on the right" pat­tern. D

Finally, we give two techniques by which a large number of basic "textures" as studied in computer graphics can be generated.

Example 5: Two simple square subdivision MRFS are shown in Figs. 10 and 11. The former just subdivides squares into quadrants with some deterministic, but essentially chaotic, rotations, the latter resembles "weaving." Notation r^{X„) in Fig. 10 means clockwise

Table 2. Affine transformations used in Example 4.

Transformation

to U /. h r\ rj

r^ /'. I'l I'l r'l

r

.05

.05

.6

.5

.55

.5

.55

.62

.48

.52

.55

s

.6 - .5

.5

.45

.4

.55

.4

.53

.43

.46

.5

6

0 0

40 20

-40 -30 -35

36 23 18

-28

0

0 0

40 20

-40 -30 -35

36 23 18

-28

e

0 0 0

.05 0 -.02 0 0 0 0 0

/

0 1 .6

1.05 .7

1 .85 .6

1.1 1.1 1

rotation by a degrees. The specific rotations used in the rules of Fig. 10 have been chosen randomly. By choosing simple random initial conditions and running several steps of the deterministic MRFS algorithm for either one or successively both above systems one can rapidly obtain a wide variety of "textures," which, es­pecially in colors, are very intriguing. Some of them are shown in Fig. 12. They suggest a great potential for using these methods for simulating basic textures in computer graphics. Similar to the chaotic tree in Fig. 7b we are getting a right mixture of chaos and order. D

5. CONTROLLED MRFS

In the previous section, we demonstrated how we can achieve a balance of order and disorder by MRFS. In this section, we introduce a simple technique that is so much more convenient to define real-world images that at first glance it would appear that it is more pow­erful. The essence of the technique is to apply MRFS in a sequence determined by finite control.

We start with some definitions. A simple initial condition is any finite resolution

image that we would like to assign to a variable initially. Therefore, it is a finite set of lines and filled or unfilled polygons.

Let be a variable. Then an equation of the follow­ing special form

where ^^ is some arbitrary simple initial condition is called an initializing equation.

Every variable has a default value that is the filled unit square ^ = [0, 1] X [0, 1] (for 2-D images), the underlying compact space X. This default value changes when an equation (possibly an initializing equation) with the variable on its L.H.S. is applied.

A label is a symbol that simply labels an equation. The same symbol can be used to label more than one equation but no two equations labeled by this symbol can have same variable on their L.H.S. Also, an equa-

Page 342: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 371

Fig. 10. Simple textures.

tion can be labeled by more than one symbol. If the symbol a labels an equation e, then we write it as:

Executing a label means simultaneous execution of all the equations labeled by it. The image obtained by this execution is the union of the values of the display variables after the execution.

Example 6: Let a and ^ be any two labels. Then, there exists a label 7 such that executing 7 is equivalent to executing first /? and then a. As an example, if

^:A = wM) U W2(5), ^\B = w^{A) U w^{C),

^iD^WsiA)

a:A = We{A), a:B = Wj(B) U Ws{E)

then, 7 labels equations with affine transformations that are compositions of affine transformations in equations denoted by a and /?,

y :A = We(Wi(A)) U We{w2{B)),

y:B= w-j{w2(A)) U W7(W4(C)) U w^iE),

y:D=Ws{A). D

Example 7: Consider two labels a and P,

a : A = Wi(B), a : B = W2(C)

^:A = W3iD),^:C= W4iA)

Now, in total, there are four variables A, B, C, and D. Using identity equations, one could have defined

A.+i =

r27o{Bn)

id(Cn)

r9o(Cn)

risoiAn)

Bn+l =

ri80{An)

MCn)

ri8o{An)

r27o{Bn)

^ n +

id(A.)

riso(Cn)

id(B.)

270 (C'n)

Fig. 11. A tiling pattern generated by a finite control string.

Page 343: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

372 K. CULIK II and S. DUBE

Fig. 12. Simple textures.

a and /? such that they label equations for all these four variables,

a\A = w^(B), a:B=W2(C), a\C=id(C),

a:D = id(D)

p:A = Wi(D), p:C=W4(A), f3 : B = id(B),

(3:D = id{D)

Therefore, one can consider a normal form of labels in which a label labels exactly one equation for each and every variable. D

5.1. Definition of controlled MRFS A Controlled MRFS is a set of finitely many labeled

equations with a control string or a control set over the set of labels. A control string can be finite or infinite, and we restrict ourselves to regular control sets.

In other words, a Controlled MRFS M i s completely specified by:

1. A finite set of equations E. 2. A finite set of labels 2 . 3. A labeling relation I ^ i: X E such that (a, e) B I

if « labels equation e. 4. A controlling component, which is either a finite

control string s E S*, or an infinite control string p G 2*^, or a regular control set R ^ 2*.

M defines a c-image obtained by executing the labels in 2 in a sequence determined by the controlling string or set as follows.

Control String: There are two cases depending on whether the control string is finite or infinite.

1. A finite control string s = aiaj' • •«„ G 2* is a finite sequence of labels. Then executing a 10:2 * * •«« means executing the labels one after another from right to left. The c-image defined by Af with control string s is denoted by I(M, s).

2. An infinite control string p = Q:ia2«3' • ' E 2* is an w-sequence of labels. The c-image defined by M with control string p, denoted by I(M, p ) , is the limit of the images defined by executing longer and longer prefixes of p, i.e.,

I(M, p) = lim I{M, a^aj* • -aj).

Control Set: There are two cases depending on whether the control set is finite or infinite.

1. A finite control set is a finite set F ^ 2*, and the image defined by M with control set F is

I(M,F) = ^S^FI{M,S).

Page 344: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 373

2. An infinite control set is an infinite regular set R ^ 2*, and the image defined by M with control set R is

I{M,R)= U I(M,p). pe adherence (i?)

Example 8: The intermediate approximations of Sier-pinski triangle in Fig. 2 are generated by Controlled MRFS with control strings of the form a", « > 0, where a labels the equation

A = Wi(A) U W2(A) U WsiA)

where Wi, W2, and W3 are given in Example 1. In Fig. 3, the control strings are of the form a"\,n>i 0, where X labels an initializing equation that assigns two line segments to ^ . D

Example 9: In Fig. 13, a tiling pattern is shown. This image is generated by 5 steps of Deterministic Algo­rithm on "mixing squares" MRFS M shown in Fig. 10, with appropriate initial values of variables. An equivalent representation is a Controlled MRFS with the finite control string a^X, where a labels the equa­tions of M, and X is a label of initializing equations that assigns an unfilled polygon to A, and filled poly­gons to B and C. If jS denotes the equation for "weav­ing" MRFS shown in Fig. 11, then each of the basic textures shown in Fig. 12 can be generated by a Con­trolled MRFS with a finite control string 5 E {a + 13}* X, where X assigns some appropriate initial con­dition for each basic texture image. D

Example 10: Let a and ^ be two labels of denoting some equations over some variables, such that the cor­responding Controlled MRFS with control strings a'^ and jS' both define irregular trees using the technique described in Example 3, and illustrated in Fig. 7. As­sume that in both trees the trunk is generated by the same transformation while left and right subtrees are

•^TiyMTMTrxV

^•^^TT^^^^XXg3X^TgS^^^XTg3^^^83^^T^g3><rX63^< XMX I<i MX < l4X^ X^ X^ < g3 ^ ^X 4 I S 4 2M :3M^ •^•^TS<MX^JiX><^I<i^Ji^^<X^^f<igSi>^iSM^^X^^X83XXXH^5^^^

XI^<ie3^^^X X ©•^•^•I^l^^^X X li<l li<llS3^^^X X • ^ ^ • ^ B X H X X S ^2MXt^<^I<l^SMe:<lTMS3^4^<^^^4^X^<I^M^<i^MXXX^MgSil^^< Mr^X^X63M^<iXMXS^Xli<M^TMXli4Xi^><g3^*4S^g3^4^^^< H^Tg3X^XrX>3^<83iXiSXXXgSiH^J(Xi^X]^<^2i^2iXM^XX MXTCiM^Ji^^^^^^TX^XiM>JiX^4^^XXS<i^4e3TMXX>Xi63^4TT M63^M^X^^gSS9XMl^XXX63^XMiSSXXX^<iMSS^^^^M^i i^i<i^<^x<H^X4TMX^i<iHe3^^^xi^^4i^i<^x<i^^e3^^^x<^^^^i^^x<ix^x^^^s<^^x^i<

Fig. 13. A tiling pattern generated by a finite control string.

generated by different transformations. Consider the regular control set

R = {« + /?}*.

Note that any co-string in {a + /?} ' defines an irregular tree. Therefore, the image defined by the Controlled MRFS with control set i?, is a union of infinitely many such irregular trees. However, since we have chosen the trunk affine transformation to be same for both a and /3, this union is a single irregular tree. Note that in this tree a branch gets divided into four branches. D

Example 11: Let M b e an MRFS defined on n variables. Define a Controlled MRFS M' by labeling n mutually recursive equations for these variables by a, and letting a* to be the control set. Then, the Controlled MRFS M' is equivalent to the MRFS M. Note that adher­ence (a* ) = {«'^}, and I(M', a"^) is precisely the image defined by the Deterministic Algorithm on M. D

The above example also proves the following obvious lemma. However, we provide a totally different proof which is interesting by itself

Lemma 2 : Let M be an MRFS. Then there exists an equivalent Controlled MRFS.

Proof: Consider the underlying digraph G of M . For each arc in G do the following. Let the arc be from variable ^ to ^ and labeled with affine transformation w. Then, create an equation B = w{A) and a label a, and let a label the equation B = w{A). Thus, in total, we create n equations and n labels, where n is the total number of arcs in G.

Now convert G into the transition diagram of a finite automaton Mi such that if there is an arc in G from A to B labeled by the affine transformation w, then there is a transition from 5 to ^ in M i , which is labeled by the symbol, e.g., a, labeling the equation B = w(A). Create an initial state and place transitions from it to each display variable of Af on e (null string) symbol. Let R be the regular set accepted by Mi over the al­phabet of labels. Now define a Controlled MRFS M2 with these n equations and n labels, and with control set R. From the definition of the c-image defined by a Controlled MRFS and by an MRFS, the equivalence of M and M2 follows. D

Example 12: Consider two labels a and /?,

a:A = Wi{A)Uw2(A)

^:A = w,{A)

Then the Controlled MRFS with infinite control string jSa' is equivalent to the Controlled MRFS with infinite control string 7'^, where

y : A = Wi(A) U W2{A), y : B = w^iA)

and B is the display variable. This example along with Example 6 shows that any Controlled MRFS with in-

Page 345: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

374 K. CULIK II and S. DUBE

finite control string of the form 131^2' * * /5««' is equiv­alent to some other Controlled MRFS with infinite control string of the form y'^. D

5.2. Some basic results on controlled MRFS A simple initial condition is like a "constant" that

we would like to assign to a variable initially. In this subsection, we show that these constants can them­selves be generated by MRFS (and finite generators), and therefore one can work only with variables. In other words, theoretically speaking, there is no need of initializing equations.

A generalized sequential machine (GSM) is a 6-tuple M = ( 2 , 2, A, 5, ^0, ^ ) , where Q, 2 and A are the states, input alphabet and output alphabet, respectively, 5 is a mapping from (2 X 2 to finite subsets of Q X A*, Qo is the initial state, and F is the set of final states. The interpretation of (p, w) in 8{q, a) is that M in state q with input symbol a may, as one possible choice of move, enter state p and output the string w. The domain of the transition function 5 can be extended to Q X 2* in the straightforward manner. Let M{x), where M is a GSM as defined above, denote the set

M{x) = {y\(p, y) is in 5{qo, x) for somep in F}.

A GSM defines a relation p c S* x A*

p= {(x, y) IJC E 2*, y e Mix)}.

Regular languages are preserved under GSM mapping, i.e., if L is a regular language then M(L) is also regular.

Now, we shall prove the observation that a finite union of line segments and polygons can be defined by a Finite Generator (FG). For this, we need the fol­lowing result from[ 15].

Theorem 3: Let T : [0, 1]^ -^ [0, \Y be an arbitrary affine transformation with rational coefficients. Then T can be implemented with a GSM M such that

T(A{p))=A(M{p)),

where p is a length-preserving relation.

In above, A(p) denotes the image defined by p by in­terpreting the adherence of p as 2-D points, as explained in Subsection 3.1.

Also, note that one can define triangles by FG's, as illustrated in the following example.

Example 13: Consider the following three rational expressions:

A,= {(0,0) + ( 0 , l ) + ( l , 0 ) + ( l , l ) } * ,

^2= {(0, 1) + (1,0)}*(0,0)A,,

A3= {(0,0) + ( l , 1)}*(1,0)A,.

X2, and X3, respectively, one being the unit filled square, and the other two being filled triangles:

Xi = {(a,b)G[0, l ] 2 | 0 < ^ , Z7< 1},

X2= {(a,b)G[0, \]^\a-\-b< 1},

X3= {(fl,/7)E[0, lf\a>b}. D

Lemma 3. Let C be a simple initial condition. Then there exists an FG M which defines C (and therefore, C is the attractor of an MRFS M').

Proof: Since C is a simple initial condition, it is a finite union of finite resolution line segments and filled or unfilled polygons. Since FG's are closed under finite union, it suffices to show that a filled triangle can always be represented by an FG. The argument for an unfilled triangle or a line segment parallels the following ar­gument for a filled triangle.

However, there is a tacit assumption that we need to make explicit—we are considering a triangle with rational end-points. So assume that a triangle AABC is specified by its three rational end-points A, B, and C. Now consider any triangle for which an FG is known to exist. For example, consider the lower left triangular part of the unit square, i.e., the one with the endpoints A' = (0,0), 5 ' = (0, l ) a n d C ' = (1, 0). There is an FG representing this triangle from Example 13. Now AABC can be considered as the image of AA'B'C un­der an affine transformation w with rational coeffi­cients. From Theorem 3, since affine transformations with rational coefficients can be implemented by GSM, there exists a GSM M implementing w. Therefore, if p is the rational expression for AA'B'C\ an FG equiv­alent to the rational expression M(p) defines AABC.

It should be noted that a triangle with real end-points can be defined by an MRFS. Let AABC be the given triangle with arbitrary real end-points and let A A'B'C be some triangle that is known to be the attractor of an MRFS. Then, there exists an invertible affine trans­formation w, possibly with real coefficients, such that AABC = w{AA'B'C'). Since, the class of images de­fined by MRFS is closed under invertible affine trans­formations [23 ], there exists an MRFS for A^^C. D

The following theorem shows that one does not really need any initializing equations.

Lemma 4. Let M be a Controlled MRFS with finite control string s. Then there exists a Controlled MRFS Mx with infinite control string p and a Controlled MRFS M2 with infinite control set R, both define the same image as defined by M, and none of the labels of Mi and M2 labels an initializing equation.

Proof Let Mhave variables {Ai, A2, .. •, Aj^}. Let s = a\a2' ' ' oLn. Consider a special label X that labels A initializing equations

Ai = UJE{\,2, • ,N},

These expressions represent three simple images Xi, where U, the unit square, is the default initial value of

Page 346: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 375

a variable. Then M with control string sX defines the same image as defined with control string s.

Consider each and every initializing equation labeled by some 0: ,7 E {1, 2, . . . , «} and let {Ci, C2, C^} be the set of simple initial conditions used on the R.H.S. of these initializing equations. Also, denote Uhy Cm+\ -

From Lemma 3, each C/, / E {1, 2, . . . , m + 1} is the attractor of an MRFS M,. Let Dj be the display variable of Af, (without loss of generality, it can be assumed that there is exactly one display variable in each Mi). Now replace each initializing equation

Ai = Cj by Ai = id(Dj) (2)

where id is the identity of transformation. Since, it can be assumed that the sets of variables

are disjoint with renaming, let M be an MRFS, which is nothing but all these m + 1 MRFS considered to­gether. Note that M is the union of M/'s and has m + 1 display variables, one for each simple condition C/. From Lemma 2, there is a label /? and a Controlled MRFS M' with the infinite control set /?*, which defines the same image as defined by M.

Let a}, 7 E {1, 2, . . . , «} and X' be new labels for all the equations labeled by aj and X, respectively, ex­cept that now initializing equations have been replaced as indicated above in Eq. (2).

Define two Controlled MRFS Mi and M2 with these new set of equations and of labels. Let Mx have the infinite control string a\a'2* • -a'^X'^"^, and let M2 have the infinite control set a\ Q;2 • • • a'„X'jS*. Clearly, both Ml and M2 define the same image as defined by M. D

Theorem 4: Let F be a finite control set of a Controlled MRFS. Then there exists a Controlled MRFS with an infinite control set R, an MRFS M, and an FG A s.t. F, R, M, and A are equivalent, i.e., they all define the same c-image.

Proofi Let F = {su S2,.. ., SM). Therefore, the image defined by F is the union of images defined by these A/ finite control strings. For each of these A finite con­trol strings Si, there exists an infinite control set Ri by Lemma 4. Since the class of images defined by infinite control sets are trivially closed under finite union, there exists an equivalent infinite control set R that defines the same image as defined by F.

Each of these N infinite control sets Ri are of the form aia2* • •««/?*, which can be defined by an equivalent MRFS M,. This is because the image de­fined by such a set is nothing but union of images, obtained by mapping the image defined by an MRFS equivalent to the Controlled MRFS with the control set jS* under finitely many affine transformations. These affine transformations are obtained from the se­quence of labels aia2* • • «„, by taking compositions of affine transformations as we scan the labels from right to left. See Examples 6 and 12 for the illustration of this argument. Union of these N MRFS's gives us the equivalent MRFS M.

Finally, from Lemma 3, every simple initial con­dition can be generated by an FG. Also, if the affine transformations consist of rational coefficients, then again the transformations obtained from string aia2' ' •«« by taking compositions of affine transfor­mations as we scan the labels from right to left, can be implemented by GSM. Since rational expressions are closed under finite union and GSM mappings, there exists an equivalent FG A. D

An interesting implication of the above result is that all the basic textures shown in Fig. 12 can be described by rational expressions (finite generators).

6. GENERATING REAL-WORLD IMAGES BY CONTROL SETS

Now, we show how control sets can be employed to generate natural images of plants, branches, and trees as shown in Figs. 14 and 15. But before we explain these examples, we will introduce the placement op­eration which here does the same job as is done in other systems ( . ., [ 10, 13 ]) by a post-processing phase called rendering, which uses some images like flowers, leaves, etc., not created by the system.

Without loss of generality, we will consider images which are subset of the unit square U = [0, 1] X [0, 1 ]. Let s = W1W2' ' ' w„hQ a. finite sequence of affine transformations, and let A be an arbitrary compact subset of U. Then, the image defined by the application of s on A, denoted by s(A), is given by

s(A) = Wi(w2(' ' • w„{A)' • •)).

Firstly, we make the following observations that fol­low from linear algebra and coordinate geometry.

Lemma 5. Let s be any sequence of affine transfor­mations.

1. Then s{ U) is a parallelogram. 2. Let A ^ U. Then siA) c s(U) [i.e., s{A) is the

placement of a copy of A in the parallelogram s{U)].

Lemma 6. Let X be a set of contractive affine transfor­mations. Let s E: 1^*. Then for all x E 2*, sx{ U) ^s{U).

In [22], affine regular sets are introduced and it is shown that for every MRFS there exists a correspond­ing equivalent affine regular set, and vice versa. We briefly define affine regular sets below, to facilitate our discussion.

Let {vwi, W2, . . . , Wiv} be A affine transformations. Let 2 = {1, 2, . . . , A } represent these A transfor­mations. 2 is called the underlying code alphabet. A regular set over 2 is called an affine regular set. The image defined by R is <p(adherence(i?)), where (f is defined in Section 4.

For a given MRFS M, the corresponding affine reg­ular set is the set accepted by an FA M' obtained from the diagram of M by reversing the directions of its transitions and making a new initial state that has e-transition to display nodes of M.

Page 347: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

376 K. CULIK II and S. DUBE

Fig. 14. Branches defined by control strings.

Fig. 15. A cactus plant defined by a control string.

Theorem 5: Let M be an MRFS satisfying loop con­tract ivity. Let R be the corresponding affine regular set. Let I be the length of the longest loop in the transition diagram ofR. Then there exists a constant c depending on M, such that for all x, yGR where y is an extension ofX and \y\ > \x\ -\- cl, y{U) ^ x(U).

For proof of the above theorem and also for a detailed characterization of the attractors of MRFS in terms of parallelograms, see [28].

The above theorems suggest, for example, we can efficiently place copies of a leaf or a flower at different places in a tree provided these "positions" (or paral­lelograms) have some pattern so that they can be con­cisely given by a regular set of strings of affine trans­formations. Note that the generation of the background image, generation of the images to be placed, and the placing itself are all done by the same MRFS.

Moreover, they suggest a test for self-similarity. Suppose an MRFS M corresponds to an affine regular

Page 348: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 377

set R such that R can be written as R = i?ii?2- Then it means that the attractor of M is nothing but place­ment of the image defined by R2 in parallelograms specified by Ri. And if i?i is infinite, then we are placing infinitely many smaller and smaller copies of the image, i.e., the object is scale-invariant or self-similar. It is interesting to note that a very special case of the above is Barnsley's IFS in which R = Ri= R2 = ^*, justifying our intuitive claim that the objects defined by IFS are "pure" fractals.

Furthermore, finite generators correspond to MRFS when 2 consists of the four standard quadrant trans­formations. Here, the parallelogram defined by a finite sequence of transformations of length « is a square of size 2"" X 2"" .

The above discussion lies at the heart of the gener­ation of images having hierarchical structure. Such images can be more conveniently represented by acyclic digraphs (DAG) , depicting their hierarchical structure.

Informally, a DAG control specifies the execution of labels in an order specified by the graph. The nodes of the DAG represent labels and how many times they have to be executed. Executing a node means executing the corresponding label appropriate number of times. That is, a node is either a", which means the label a is to be executed n times, or «*, which means a is to be executed infinitely many times (to obtain its limiting attractor). At the lowest level we have labels for ini­tializing equations. The nodes at the same level of the DAG can be executed in parallel (if necessary, the variables can be renamed so that the labels associated with the nodes at the same level of the DAG label equations with pair-wise distinct left-hand sides) but if there is an arc from node v to node u then node u can be executed only after node v.

Example 14: Figures 14 and 15 are examples of some natural images, several variations of a branch and a cactus plant, respectively. The basic idea has been to define images in a hierarchical manner and with the use of deterministic chaos. Therefore, for example, the cactus plant is defined by a control set that generates first the "thorns" and the " t runk" and then uses con­trolled chaos, similar to Example 3, to arrange them recursively in the self-similar pattern of a tree. The DAGs describing these images are shown in Fig. 16. Note that in Fig. 16b, we have shown two levels of branches, as in natural trees a bigger branch is made of smaller branches of possibly different structure.

We describe in detail how these images are generated. First consider the branches in Fig. 14. Consider the following system of labeled equations:

ao: leaf = TRIANGLE a'o : leaf = UNFILLED TRIANGLE a : leaf = ^(leaf) U Z?(leaf) U c(leaf)

U J(leaf)

: leaf = shrink(\eaif) : sq = SQUARE : stem = id(sq) U ^(stem) : twig = id(siem) U/ ( leaf )

p : longstem = id{stQm) U ^(stem) 00: sb = /W(longstem) U A:(twig)

U m(twig) U «(twig) U p(twig) U ^(twig) 0 : sb = /V/(longstem) U /:(sb) U w(sb)

U « ( s b ) U / ? ( s b ) U ^ ( s b ) ^0: mainbranch = sb 6 : mainbranch = zV/(stem) U left (sb)

U right (sb) U 0/7 (mainbranch)

6:

Note that ao, ^o and /3 label initializing equations. The variable "mainbranch" is the display variable. The

Filled Polygon Any Value

Filled Square Line Segment I s tem ] j ^1 f leaf ] )

y i ( t runk

GO' Uhorns) J ^2

ranch 1/ ) "•2

n3ranch2) j ^3

(a) (b)

Fig. 16. Hierarchical nature of natural images, (a) cactus plant; (b) branch/tree.

Page 349: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

378 K. CuLiK II and S. DUBE

transformations are suitably chosen and are easy to infer from the figures. The control strings for the branches shown in the figure, from top to bottom and left to right, are:

Branch 1 Branch 2 Branch 3 Branch 4 Branch 5 Branch 6 Branch 7 Branch 8

d%(l)(l)opy^8y^l3a^a'o e%(t>(l>opy^dy^l3a^ao e%(l)^(f)opy^8y^p(pa^ao d%(t>^<l)opy^dy^pa^ao d%(t>opy^h^(3a^oio d%<f)^(t>opy^dy^p^a^ao e%(f)opy^8y^Pa''

Now refer to Fig. 15. This cactus plant is generated by a control string over the following set of labels:

ao : thorns = LINE a : thorns = a (thorns) U ^(thorns)

U c(thorns) U ^(thorns) /So : stem = SQUARE /?: stem = e(stem) U/(stem) U ^(stem)

U /2(stem) 70* tree 1 = stem 7o: tree2 = /(thorns) UyXLINE) y : treel = A:(treel) U /(tree2) U id (stem) y : tree2 = m(treel) U «(tree2) U icl(stem)

The control string is:

7So/3'/?o«'«o

Note that we have used two variables "treel" and "tree2" (both of which are the display variables), which are mutually recursively defined, in order to generate an irregular tree and to place thorns only in few places. The label a creates thorns starting with a line segment, 13 creates the stem (trunk) starting with a filled square and 7 combines the thorns and the trunk in the pattern of a tree. The affine transformations a, b, . . ., n are suitably chosen. D

The advantage of the DAG control over the regular control is that the former expresses the hierarchical structure of images in a more explicit manner. How­ever, it is possible to simulate the DAG control by the regular control. A DAG can be converted into a leveled graph. Any valid linear ordering of the nodes of the DAG can be converted into an equivalent control set such that the order of execution of labels satisfies the constraints as specified by the DAG. However, not only acyclic graphs, but any general graphs of labels can be simulated by MRFS. This is because regular control sets are equivalent to such graphs, and as we now show a surprising normal form result that regular control over the execution of MRFS is not really essential.

Theorem 6: Let H be a Controlled MRFS with infinite control set R. Then there exists an MRFS M, which defines the same image as the one defined by H.

Proofi Consider the normal form of labels (see Example 7), in which each label denotes A equations, one for each of the A variables under consideration. The set of equations labeled by each label constitute an MRFS, and therefore, can be specified by a digraph. Let the set of labels be L = {/i, 4 , . . . , /p}, and the set of variables be V. Let the digraphs representing the label /in Lbe G/.

Let Ml be a DFA accepting R. Consider Mi ac­cepting reversal (/?). From Mj, construct a digraph G by converting edges of M2 into nodes as follows.

1. For each edge in M2 create a node. If the edge was labeled with a E: L, then the corresponding node is also labeled with a. Also, create a special node called the Display node, which is labeled with F. Let the set of nodes of G be VQ.

2. If w is an incoming edge of some state 5 in M2, and V is an outgoing edge of 5, then place an arc in G from the node corresponding to u to the node cor­responding to i;.

3. If u is an incoming edge of the final state of M2 (or, equivalently the initial state of Mi), then place an arc in G from the node corresponding to w, to the special node marked F.

The basic idea is to merge Gi^, . .., Gi^ with G, into a single digraph G' such that G' will represent the equiv­alent MRFS M.

The set of nodes V of G' is VG X V. Let VD ^ Fbe the set of display variables. Then each variable (node) of G' in subset {F} X F£, is a display variable.

For each edge ^ = (w, u) of G do the following: Let / be the label of node u. Consider G/, i.e., the digraph representing label u. For each arc e' = (A, B) labeled with affine transformation, e.g., w/mGi, place an arc in G' from {u, A)io (v, B) labeled with w.

Our claim is that the Controlled MRFS H with the control set R defines exactly the same image as the one defined by MRFS Mas diagrammatically given by the digraph G'.

To see why this is true, we consider a similar problem in a slightly different setting. Consider p finite automata Ml, M2,. . . , Mp, where M, = ( G , 2, 6,, ^ i , F,). The set of states of M, is

Qi = {QLQ'I, . •.,Q'N}'

Since each FA has A states, there is a natural one-to-one correspondence between the states of Qi and Q,, for any / and 7. A state q'k in Qi "corresponds" to state Qi in Qj and vice-versa. We denote this by Qk = (Q\)i, Qi = (Qk)j' Also, for each M/, we define a func­tion iii, which maps a state to the set of its "adjacent" states. The function /Lt, extended to a set of states is given by

M/(^) = {QE Qi\8iip. a) = g,pGP,aei:}.

Now, let r be a "controlling" finite automaton de­fined over alphabet A = {1 ,2 , . . . , / ?} , such that each

Page 350: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 379

string in L( r ) is a control string determining the order of application of M,'s. To be precise, let w E L ( r ) , and let w = w,W2 • • • w„, where w, E A. The control string w determines that we apply Afyi,,, M^^^ • • • ' Mw„ in this sequence. We start with MH,, in its initial state g = QQ^ and traverse all of its transitions from q to the adjacent states of ^. Then, we consider Mw2 and all of its states Q, which correspond to the adjacent states of g, and traverse all its transitions from each state in Q. Then, we consider My^,^ and its states, which correspond to the adjacent states of Q, and so forth. This determines a set of paths which switch from one FA to another depending on the control string. All the words labeling such paths are said to be "controlled" by w.

Formally, we start with Ri = {^o'}, and go to ad­jacent states ofRi in MH,,,

5i = Mw,(^i).

This we repeat for each w,, i.e.,

J^i = (Si-i)wi, Si = /Avv, (Ri)-

Now, consider the set of paths

P ( w ) = RiX SiX R2XS2X ' ' ' XRnX Srt

A valid path in'P(w) is one of the form

riSir2S2r3- ' Sn

where Si and r2 correspond, S2 and r^ correspond and so forth. Denote the set of all such valid paths by va l id (P(w)) .

Define the language controlled by T

R' = {X E 2* I X is label of some path

i n v a l i d ( P ( w ) ) , w ^ L{T)}.

Now, is R' regular? The answer is affirmative. One can construct an FA Mtha t simulates Tin conjunction with Mi,M2, . . . , Mp, such that L(M) = R'.

If each FA M/ is an affine regular set then R' is still an affine regular set. Since, for each MRFS there exists an equivalent affine regular set and vice-versa, this im­plies that a regular control over many MRFS's still can be simulated by an MRFS.

In our original problem, each Gi can be said to cor­respond to an FA M/ , and M2 is the controlling FA T. We had to consider reversal of Mi because control strings are interpreted from right to left. The digraph G' then simulates the control set, as for each control string in R, it applies the corresponding labels in the appropriate sequence. This can be proved by induction on the length of control strings in R as follows.

Let the initial value of a variable Abe AQ, which is either the default initial value or some other value as­signed by an initializing equation. Now, in G' let the initial value of variable (node) (v,A)bQAo, irrespective

of V. Then for each m, by induction, executing the Deterministic Algorithm on G'm times gives an image

O = U / ( / / , w).

In the limit case when m ^^ 00,

O = U I(H, a). a€ adherence (/?)

Hence, MRFS M given diagrammatically by the di­graph G' defines the same image as defined by the Controlled MRFS H. D

The above theorem also shows that H defines a unique image if the equivalent MRFS M is loop con­tractive.

Example 15: We define a Controlled MRFS H with two labels a and ^, and an infinite regular control set RAn Fig. 17, we show the two labels a and /? denoting the following equations for two variables A and B:

a:A = a(A), a:B = b{A) U c(B),

p:A = d(B), I3:B = e(B).

a(0.4)

Digraph G

A finite portion of G'

Fig. 17. Examples of simulation of a control set by an MRFS.

Page 351: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

380 K. CULIK II and S. DUBE

We also show the DFA Mi accepting the control set R over these two labels. We further show M2 obtained by reversal of Mi, and G obtained from A/2. In Fig. 17, we also show a finite portion of the underlying digraph G' of an MRFS M equivalent to the controlled MRFS H. The numbers in parenthesis are the prob­abilities to be considered when one is interested in t-images. D

7. TEXTURE (GREYSCALE) IMAGES

In this section, we show how /-images can be defined by the methods described in previous sections.

Recall the definition of PMRFS, and how equations are interpreted for r-images in Subsection 3.3. A prac­tical way to execute Eq. (1) is the following algorithm, which consists of the steps:

1. Choose randomly one of the variables Ci, C 2 , . . . , C„, the probability of choosing C, being/?,, 1 <7 < n. Let the selected variable be C,.

2. Choose randomly a point in X such that the prob­ability of X E ^ is M Q ( ^ ) for all 5 E ^ . Let the chosen point be x.

3. Generate the point W/(jc). Go to step (1).

Lemma 7. Suppose the above algorithm generates m points. Let G be the set of these points. Then, for all B E-g,

are executing the equations for ^images according to the algorithm discussed in the beginning of this section. Following the control string s backwards for each label, say a, all the equations labeled by a are executed as for PMRFS. The final ^image is the weighted sum of the /-images defined by each variable according to the final distribution. The t-image defined by M with the finite control string s is denoted by MM, . Let p = aiaj' ' ' be an co-sequence of labels. The /-image defined by M with the infinite control string p is given by

I^MJB) = Hm IXM,W„(B)

where w„ = aia2' • •«„.

Control Set: There are two cases depending on whether the control set is finite or infinie.

1. Let F= {vvi, W2,..., w„} be a set of (finite) control strings and let /7w,, Pw2, • •, Pw„ be some weights (summing to one) for strings Wi, W2, . . . , w„, re­spectively, in F. Then, the /-image defined by M with the finite control set F is given by

flMA^) = 2 PwilJiM,Wi{B)

HAB) = lim ^ m-*-(xj m

where mB = \GnB\.

Proof: It follows from the probability theory. IIA(B) is the weighted sum of the values fiCiiW^^B)), iJiCii^i^B)), ... . Now, step 1 selects one of HQ'S 1 <i<n, according to the probabilities A'S. Step 2 selects a point in wj^ (B) with probability iJiQ(wi^ (B)). Therefore, in the limit case, the points fall in 5 , at a rate which is the sum of the measures of w," (B), 1 < i < n, weighted down by the corresponding probabil­ities p/'s. D

Notice that Step 2 is effective only if measures can be specified in a finite manner (as a finite-resolution /-image).

Now we extend our definitions of Controlled MRFS to /-images. Just like PMRFS in Subsection 3.3, we define a final distribution function over the set of vari­ables that will determine the contribution of the /-im­ages defined by these variables in the final displayed image.

Let M be a Controlled PMRFS. It defines a /-image depending on its control string or control set.

Control String: There are two cases depending on whether the control string is finite or infinite.

1. The meaning (execution) of a finite control string 5 = ai«2 • * * ««j is defined in an analogous way as for c-images. The only difference is that now we

2.

where B is any Borel subset.

Let R be an infinite regular set of (finite) control strings and let it be accepted by a (probabilistic) finite automaton M in which probabilities on out­going transitions sum to unity. M assigns a proba­bility py,, to each string w in Prefix (/?), which is the sum of probabilities of all the paths in M labeled by w. The /-image defined by M with the infinite control set R is

UMAB) •• hm 2 P^^fiM.AB) "~^°^ \w\=n.wGPrefi\{R)

where B is any Borel subset.

The results for c-images can be generalized for /-images. For example, Lemma 2 is now generalized to:

Lemma 8. Let M be a PMRFS. Then there exists an equivalent Controlled PMRFS with an infinite con­trol set.

Similarly, Theorem 4 hold for /-images also. Finally, the important result stated in Theorem 6 holds for /-images too, and therefore, the regular control over the execution of MRFS is not essential irrespective of whether we are interested in black-and-white or texture images.

Theorem 1: Let H be a Controlled PMRFS with an infinite control set. Then, there exists an equivalent PMRFS M.

Page 352: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Balancing order and chaos in image generation 381

Proof: Consider the proof of Theorem 6. In the proof, for each edge ^ = (w, t;) of G we considered Gi (where / is the label of the node w in G), and for each arc e' = (A, B) in G/, labeled with affine transformation w, we placed an arc e" in G' from {u,A)to{v,B) labeled again with w. Now, let the probability associated with e = {u,v)be p, which is the probability of the corre­sponding state transition in the probabilistic FA Mi accepting R, and let the probability associated with e' be q. Then, we associate a probability pq to the newly created arc e" in G\ the underlying digraph of the equivalent PMRFS M. Let the final distribution func­tion over variables o f / / b e / . Then the final distribution function g over variables of M i s defined as ( ( F , ^ ) ) = f(A) and g((v. A)) = 0 where F is the Display node of the digraph G, ^ is any variable of M , and v ¥= Fis any node of G. It is easy to verify that M defines the same ^image as defined by / / . D

See Example 15 and Fig. 17 for an application of the above theorem. In these figures, the numbers in parenthesis are probabilities.

Example 16: See Fig. 18 for a ^image generated by a control set. To see how this image is generated consider the following labels, the transformations WQ, WJ, W2 and W2 being the four standard quadrant affine trans­formations (mapping the unit square to the lower left, lower right, upper left and upper right quadrants re­spectively):

a:A = Wo(A)U Wi{A)U W2(A)U w^iA)

iPi = P2= P3= P4 = 0.25) a:B = Wo(B) U Wi(B) U W2(B)

U w^{B) U Wi{A) U W2{A) U WiiA)

\P\ = P2= Pz= PA = 1,P5= P6 = T2»

Pi = b P:C= Wo{B) U Wi{C) U W2(B) U w^^C)

(P\ = P2= P3= P4 = 0.25) y:C=Wo{C) {pi = l.O)

b:C= W , ( C ) U W 2 ( C ) U H ; 3 ( C )

{P\ = Pi =P3 = 3)

^(.75) ^(.5)

7(-25) ^(•5) .

Fig. 18. A r-image defined by a control string.

Fig. 19. The control set in Example 16.

The infinite control set over this set of labels is

R = b*yP*a*.

In Fig. 19 we show a finite automation with probability distribution on outgoing transitions and accepting R, which is used to define the /-image. Note that this t-image can be generated by a PFG with suitably chosen probabilities. D

8. CONCLUSIONS

We investigated a new technique called Controlled (P)MRFS to model natural images and textures which has the following merits:

1. It generates hierarchical images (therefore, many real-world images) more efficiently than (P)MRFS.

2. It allows one to mix the Deterministic Algorithm and the Chaos Game Algorithm (consider initial­izing a variable to a set of points observed by exe­cuting the Chaos Game Algorithm).

3. One can explicitly specify a fixed finite number of iterations of the Deterministic Algorithm. This is practically useful since no real object is fractal over an infinite scale.

4. It is possible to alternate in a controlled way between the Deterministic Algorithm and the Chaos Game Algorithm for several different (P)MRFS.

5. It provides a purely deterministic method (without the use of a pseudo random number generator) to create random-like (irregular) images.

6. The entire image is generated by the same system without using any subimages created by different means. Even without any rendering, we can obtain natural looking images.

Acknowledgements—We thank the referee for suggesting the IFS described in Example 4 generating the tree in Fig. 9a and for other constructive remarks.

REFERENCES 1. B. Mandelbrot, The Fractal Geometry of Nature, W. H.

Freeman and Co., San Francisco (1982). 2. J. Gleick, Chaos-Making a New Science, Penguin Books,

New York (1988). 3. M. F. Barnsley, Fractals Everywhere, Academic Press,

New York (1988). 4. M. F. Barnsley, A. Jacquin, L. Reuter, and A. D. Sloan,

Harnessing chaos for image synthesis. Comp. Graph., SIGGRAPH Conference Proceedings (1988).

5. S. Wolfram, Theory and Applications of Cellular Auto­mata, World Scientific, Singapore (1986).

6. J. Allouche and O. Salon, Finite automata, quasicrystals, and Robinson tilings. In Quasicrystals, Networks and Molecules of Fivefold Symmetry, Istvan Nagittai (Ed.), VCH Publishers, Weinheim (1990).

Page 353: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

382 K. CULIK II and S. DUBE

7. F. Axel, Controlled disorder generated by substitutions or finite automata: The state of the art. Third International Meeting on Quasicrystals, Incommensurate Structures in Condensed Matter, Mexico (1989).

8. F. M. Dekking, Recurrent sets. Adv. Math. 44, 78-104 (1982).

9. F. M. Dekking, Recurrent Sets: A Fractal Formalism. Report 82-32, Delft University of Technology (1982).

10. P. Prusinkiewicz, Applications of L-systems to computer imagery. In Graph Grammars and Their Application to Computer Science: Third International Workshop, H. Ehrig, M. Nagl, A. Rosenfeld, and G. Rozenberg (Eds.), Springer-Verlag, Berlin, 534-548 (1987).

11. P. Prusinkiewicz, Graphical applications of L-systems. Proceedings of Graphics Interface'S6—Vision Interface'^, 247-253 (1986).

12. P. Prusinkiewicz and A. Lindenmayer, The Algorithmic Beauty of Plants, Springer-Verlag, Berlin (1990).

13. A. R. Smith III, Plants, fractals, and formal languages. Comp. Graph. 18, 1-10 (1984).

14. J. Berstel and M. Morcrette, Compact representation of patterns by finite automata. Proceedings Pixim '89, Paris, 387-402(1989).

15. K. Culik II and S. Dube, Rational and affine expressions for image synthesis. Discrete Appl. Math. 41, 85-120 (1993).

16. J. Shallit and J. Stolfi, Two methods for generating fractals. Comp. & Graph. 13, 185-191 (1989).

17. M. F. Barnsley, J. H. Elton, and D. P. Hardin, Recurrent iterated function systems. Const. Approx. 5, 3-31 (1989).

18. M. F. Barnsley, R. L. Devaney, B. B. Mandelbrot, H-0. Peitgen, De Saupe, and R. F. Voss, Science of Fractal Images, Springer-Verlag, Berlin (1988).

19. J. Hartmanis and R. E. Stearns, Sets of numbers defined by finite automata. Amer. Math. Monthly 74, 539-542 (1967).

20. D. B. Ellis and M. G. Branton, Non-self-similar attractors of hyperbolic IFS. In Dynamical Systems: Lecture Notes in Mathematics 1342, J. C. Alexander (Ed.), Springer-Verlag, Berlin, 158-171 (1988).

21. S. Even, Rational numbers and regular events. IEEE Trans. Electronic Comp. EC-13, 740-741 (1964).

22. L. Staiger, Quadtrees and the Hausdorff" dimension of pictures. Workshop on Geometrical Problems of Image Processing Georgental GDR, 173-178 (1989).

23. K. Culik II and S. Dube, Affine automata and related techniques for generation of complex images, Theor. Comp. Sci. (in press).

24. K. Culik II and S. Dube, L-systems and mutually recursive function systems. Unpublished manuscript (1991).

25. L. Boasson and M. Nivat, Adherences of languages. /. Comp. Sys. Sci. 20, 285-309 (1980).

26. R. D. Mauldin and S. C. Williams, Hausdorff dimension in graph directed constructions. Trans. Am. Math. Soc. 309,811-829(1988).

27. D. Arques, G. Eyrolles, N. Janey, and X. G. Viennot, Combinatorial analysis of ramified patterns and computer imagery of trees. Comp. Graph. 23, 31-40 (1989).

28. K. Culik II and S. Dube, Encoding images as words and languages. Int. J. Algebra Comp. (in press).

Page 354: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 383

Chaos and Graphics

ESTIMATING THE SPATIAL EXTENT OF ATTRACTORS OF ITERATED FUNCTION SYSTEMS

D. CANRIGHT Mathematics Dept., Code MA/Ca, Naval Postgraduate School, Monterey, CA 93943, USA

Abstract—From any given Iterated Function System, a small set of balls that cover the fractal attractor can be simply determined. This gives a priori bounds on the region of space in which the attractor may be constructed.

1. INTRODUCTION

As Barnsley, Demko, and others have shown [1-4], one effective method for producing fractal shapes (in any number of dimensions) is with Iterated Function Systems (IFSs), using the "Chaos Game" algorithm or some deterministic algorithm. This approach has been used for producing naturalistic shapes [ 4 ], finding fractal interpolants to given data [ 3, p. 274 ] and fractal approximations of given functions [ 5 ], and even for visualizing arbitrary discrete sequences[6]. Indeed, any contractive IFS will give an attractor (usually of fractal dimension); thus it is possible to generate IFSs at ran­dom to explore the graphical possibilities, as is done in some educational software[7]. Similarly, because the attractor depends continuously on the parameters in the IFS [ 1 ], small data sets from any source could be encoded as IFSs for visualization.

In implementing the IFS method, one important question is the prediction a priori of the region of space containing the fractal attractor. Without such a pre­diction, one could only approximately estimate the spatial extent based on calculating several points of the attractor, with no guarantee that these points are near the bounds. If as a result the portion of space repre­sented in the computation of the attractor is too small, the result will not yield the whole attractor. If the por­tion of space represented is overly large, then much computational space is wasted, reducing the effective resolution of the computed attractor.

Another concern is when the space itself has natural limits, for example the space of colors in Red-Green-Blue-space representable on a video monitor is limited (more or less) to a unit cube. Hence, if an IFS resides in, say, five-dimensional space with two spatial di­mensions and three color dimensions, the question be­comes whether the attractor (or its projection onto the limited dimensions) will fit in the space. (At least one implementation [ 7 ] includes color in the IFS, though that case uses only a single color dimension, repre­senting hue.)

Here we show how to compute, directly from the IFS, a set of balls whose union contains the attractor as a subset (see Fig. 1). The radii of the balls are min­imal in a certain restricted sense. This gives reliable bounds on the region of space that must be considered in constructing the fractal. The method is general, in­

dependent of the particular space and metric. We first describe the set of balls, then show how to compute their radii and prove that the algorithms work, and lastly give a detailed example.

2. IFS ENVELOPES

An IFS consists of a set of n contraction mappings W/ : X ^^ X on a metric space X with metric d : X X X ^^ :^. (For the "Chaos Game" algorithm, prob­abilities Pi are associated with each mapping; this idea has been extended to conditional probabilities [ 8 ]. Here only the former case is considered, where the attractor is independent of the nonzero pi.) Assume that for each contraction Wi the contractivity ratio 0 < / < 1 and the fixed point x, are known, where by definition Si satisfies d(Wi(x), W/(y)) < Sid(x, y) for all points X, y E X and X/ satisfies X/ = W/(x/). The action of the IFS Won 2i set S of points in X is defined as

W{S)^[J WiiS) (1)

where each contraction W/ is applied to the set S in a pointwise sense. The attractor^ is the set of points in X satisfying

A = W{A). (2)

That is, the attractor consists of n smaller "copies" of itself

We seek to cover each of the n "copies" with a closed ball Bi centered on the corresponding fixed point X/, so the radius r, must be chosen large enough that Bi D Wi {A). Call the union E of these balls the "envelope," in that £" D ^ by Eq. (2). Then relative to each X/, every point in the envelope will be within a distance Ri = maX; (dij -I- r,), where dij = d{Xi, x^), because for any point x in Bj, d(Xi, x) < dij 4- d(Xj, x) < dij + r,. Applying w, to such a point x will give an image point y, where d(Xi, y) < Sid(Xi, x) < SiRi. Hence if the radii r, are chosen to satisfy

5/max {dij -\- rj) (3)

Reprinted from Comput. & Graphics Vol 18, No. 2, pag. 231-238. 1994

Page 355: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

384 D. CANRIGHT

/ ^h>

Fig. 1. An attractor of an IFS is shown with its envelope of three disks, as computed by the direct algorithm. This IFS uses affine maps, with Si ,S2 i X, = (0, 0), X2 = (4, 0), and X3 = (0, 3).

for ij=\'*'n then Bt will contain the image Wi{E) of the envelope and so E will contain its own image under the IFS:

£•3 W(E). (4)

n = — di2

ri =

1 - 5,52

•^2(1 + 5 i )

1 - 5,52 dn. (5)

Iterating the IFS from any starting set (£ ' in particular) yields a sequence of sets that converges to the attractor. Since Eq. (4) implies E D W''{E) for any positive integer k, the envelope E, subject to Eq. (3 ) , does indeed contain the attractor.

3. A L G O R I T H M S

But for a given IFS, does one or more sets of radii Vi exist that satisfy Eq. (3) , and if so, how can they be found? Below we give a very simple iterative algorithm, as well as a more efficient direct algorithm. The sub­sequent proof of the validity of the direct algorithm also constructively proves the existence of a solution, and the structure of the algorithm suggests that the solution is unique. (Given that a unique solution exists, the system (Eq. 3) is equivalent to a linear program-

n

ming problem with an objective function / = 2 r/, as

pointed out by a reviewer. However, if one wishes to incorporate envelope calculation inlo an IFS rendering program, the algorithms given here are simpler than including a general simplex method solver.)

3.1. Trivial case: n = 2 When n = 2 the radii can be determined algebrai­

cally. Solving the pair of Eq. (3) gives:

But for « > 2 there is apparently no closed-form general solution, and the r, must be found algorithmically.

3.2. Simple iterative algorithm A natural approach for /? > 2 is to start with the

pairwise estimates

sM±^, 1 - SiSj

(1) r, = max r,y

(6)

(7)

but in most cases the r, will not satisfy Eq. (3) . The exceptional case is when r/, = rn, for every /, 7 ^ /, k ¥= i, i.e., when for each ball all the pairwise estimates for that ball give the same size. (This case is not always apparent from the attractor; Fig. 1 shows such an ex­ample.) Otherwise, some of the r, will be too small to contain some images Wi(Bj ) of the other balls. Then the obvious iterative scheme to try is

(A:+l) , , , (k). . . .

ri = max Siidij + rj ), i,j=\' (8)

Because this approach never overestimates the radii (k) (k-\-1)

and the iterates are nondecreasing (r / < r / ^ ^/),

Page 356: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Spatial extent of attractors of iterated function systems

1 + 5 , D.

385

(13) the algorithm must converge. What is not so obvious ^ ^ - ^ is that this process always succeeds in at most n — 1 iterations, including Eq. (7 ) , as shown below. Indeed, there is a direct algorithm (not iterative) that is more Algebraic manipulation of Eq. (13) gives efficient when n is large.

r^ > Sk[{ 1 + 5^)4m + Sn,rk] = Skidkm + rm) (14) 3.3. Direct algorithm

The key idea behind the direct algorithm is that the so the new r^ requires no alteration of r^. distances dij can be rescaled to account for the con- Similarly, for i ¥= k, i < m tractivities 5,, and the scaled distances Dij can be used to order the contractions Wi. Let

A.

D, (1 + 5 , ) ( 1 -\-Sj)

1 SiSj dij, i,j = 1 • (9)

(While Dij is clearly symmetric and nonnegative, it is not a metric because it doesn't satisfy the triangle in­equality.) Now reorder (and relabel) the W/ by decreas­ing maximum scaled distance, so that

i <j =^ max Dik > max D,/, k I

ij,kj= I" -n. (10)

In the new order, use the pairwise formula (Eq. 5) for the first two radii. Then proceed in order based on the previous results, letting

n = Si msix(dij + r,), i = 3- - • n. (11)

This is the direct algorithm, which, as shown below, solves Eq. (3) ; an implementation in the C program­ming language is given in the Appendix.

3.4. Proof of validity First note that in the exceptional case mentioned

above (after Eq. 7) , all the Ay (for i ^ 7 ) are equal. In this case, the direct algorithm will obtain the correct r, regardless of the order in which they are computed. If not all the Ay are equal, then some of the r, will need to be larger than the pairwise estimates r\^ , and hence larger than the nj in Eq. (6) , so in general Eq. (3) implies

n > 1 + 5 / A; (12)

for / ,7 = 1 • • • «. For the general case, the proof is by induction,

showing that each new r, computed requires no ad­justment of those previously computed. Clearly ri , 2 from Eq. (5) satisfy Eq. (3) for the subset i,j= 1,2. Now for the induction step, assume the first m - 1 radii, in the order Eq. (10) , satisfy Eq. (3 ) , and hence Eq. (12) , for /, y = 1 • • • m — 1. Choose r^ by Eq. (11) , and let k be the value of the index j in Eq. (11) for which the maximum is achieved. Then by Eq. (12) and the ordering Eq. (10)

1 + Si

> —; dim

1 - Sm

since 5/ < 1. Combining Eq. (15) with

ri > Si{dik + rk)

(15)

(16)

yields

ri > Si[( 1 + Sm)dim + Sm(dik + r^)]

> Si[dim + Sm{dkm + ^ t)] = /(<3 /m + ^m) ( 17)

by the triangle inequality. Hence the new r^ requires no adjustment of any of the previous r/ (for / < m) , and Eq. (3) is satisfied for /,7 = 1 • • • m; this completes the proof. Note also that because of how the direct algorithm works, the iterative algorithm will compute at least two of the r, ( r i , 2 in the order (10)) in the initial step, and will find at least one of the other r, at each successive step, and so can take at most n — 1 iterations to arrive at the answer.

3. MINIMALITY OF THE r, Can radii smaller than these r, be used and still have

the Bi cover the attractor? For any particular IFS, the answer is probably yes (as illustrated in Fig. 2 ) . The approach given here uses only a small amount of in­formation about the IFS: the ordering of the w, based on the maximal scaled distances; the 5,; and for each / one determining distance dik (where the maximum in Eq. (11) is achieved). Using more information it may be possible to reduce the size of the Bi. But if one considers the set of all the IFSs for which the direct algorithm yields the same r, in the same way {i.e., same ordered Si and same n — 1 determining distances), then the r/ are minimal for that set of attractors (see Fig. 3) . In fact, one can construct one member of that set such that each image W/(^) of the attractor includes a point at a distance r, from the fixed point x, .

To construct this IFS, let X = ^ with the Euclidean metric d{x, y) = \x - y\. Let Wi{x) = -SiX + (1 + Si )Xi, and let Xi = 0,X2 = dn, say. Then the attrac­tor includes the extremal pointsXei = Xi — ri, Xei = X2 + ^2, sinceXe\ = y^\{Xei) andXe2 = ^2{Xe\). Place each succeeding Xm at the determining distance dmk from the determining point Xk, in the opposite direction from

Page 357: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

386 D. CANRIGHT

Fig. 2. For an equilateral Sierpinski's Triangle (where H',(X) = 5^ + 2^1), the r, = dij by this method; in this particular case the radii could be half as large.

Xek' (Figure 4 illustrates the construction.) Then the attractor will include Xem = x,yj ± r^j = w^iXek)- Thus for this one-dimensional attractor yi, each image Wi{A) will include a point (Xe,) a distance r, from X/, so no smaller r, would suffice.

5. EXAMPLE For a detailed example of an envelope calculation,

consider the now familiar black spleenwort fern fractal of [4 ] . The IFS for the fern (in two dimensions) con­sists of affine contractions, each of which has the form

Fig. 3. Same 5/ and x/ as the previous figure, but here W/(x) -• are minimal.

-jx + 2X/; in this case the r, found above

Page 358: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Spatial extent of attractors of iterated function systems 387

Fig. 4. A one-dimensional attractor constructed from the following ordered data: 5i = 3, 52 = 4, 53 = 7, di2 = 1, and di3 = 5. The r, are minimal for such attractors.

€)=(: :)(;)^a)- ™ (cii bi ^

K Ci di,

or more compactly

W/(x) = M/X + hi.

where Mi is the matrix and b, is the offset vector. The various constants are given in [ 4 ] , but in terms of scal­ing and rotating each axis, using /?, q, 8, 0, where a = p cos 6, b = —g sin (f),c = psind,d=q cos 0; Table

(19) 1 is adapted from [4, p. 1977].

Fig. 5. Barnsley's fern[4] and its envelope (see text).

Page 359: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

388 D- CANRIGHT

Table 1. IFS for Barnsley's fern; each map consists of scaling and rotating each coordinate axis, followed by translation.

1 ( 2h \ (22)

Map / •

Scalings Rotations Translations

f, (»' I) COS p -sin (3

0 0.85 0.3 0.3

0.16 0.85 0.34 0.37

0 -2.5 49

120

0 -2.5 49

-50

0 1.6 1.6 0.44

Sin cos ^

X S{

) / cos0 -s in/3\ \ s in^ cos /? ; - ^^^^

Rotations are given in degrees. Adapted from M. F. Barnsley, V. Ervin, D. Hardin, and J.

Lancaster, Solution of an inverse problem for fractals and other sets. Proc. Nat. Acad. Sci. USA 83, 1975-1978 (1986).

5.1. Finding the Si The contractivity ratio 5, for an affine map Wi is the

largest singular value of the matrix M,. In the first three maps here, both axes rotate together, and so 5/ is the larger of A , Qi- In W4, the differential rotation causes a skewing effect, and the singular values of M4 must be found. The simplest way for a real 2X2 matrix is first to factor out a pure rotation to give a symmetric matrix (5), then diagonalize it to find its eigenvalues (Xi, X2) as shown below:

Then s = max( | Xi |, | X21). This approach also has a nice geometrical interpretation: The effect of multi­plying a vector x by M is to take components of x in the eigenvector directions, which are at an angle /5 rel­ative to the coordinate axes, scale each component by the corresponding X, and rotate the resulting vector by a.

Proceeding as above gives 54 = 0.379. The fixed point x/ for each map can be found by solving

( / - M , ) x , =b , (24)

a = arctan (20)

S^l' M = / - ^ « ^ - « W (21) \h kj \ -s in a cos a/

This gives the necessary starting information, sum­marized as "Input" in Table 2. (For affine maps in higher dimensions, the contractivity ratios are found by singular value decomposition, but for nonlinear maps the ratios and fixed points may be more difficult to find.)

5.2. Result Running the direct algorithm program ("enve-

lope.c") from the Appendix on this input gives the following results:

% envelope Enter number of contraction mappings: Map 1. Map 1: Map 2. Map 2: Map 3. Map 3: Map 4. Map 4:

Enter scale, x, y: .16 0 0 s = 0.160000, X = 0.000000, y = 0.000000 Enter scale, x, y: .85 2.45967 10.004734 s = 0.850000, X = 2.459670, y = 10.004734 Enter scale, x, y: .34 -0.601889 1.883961 s = 0.340000, X = -0.601889, y = 1.883961 Enter scale, x, y: 0.379216 0.155336 0.630251 s = 0.379216, X = 0.155336, y = 0.630251

radii in sorted order [ orig order ] ( sorted link ) : rl[2] ( ->2) : 16.700212 r2 [ 4 ] ( - >1): 9.993765 r 3 [ 3 ] ( - > 1 ) : 8 . 6 2 8 8 3 5 r 4 [ l ] ( - > 1 ) : 4 . 3 2 0 4 5 9

/ Si

Table 2. Envelope for fern IFS, computed by the direct algorithm.

Input

Xi yi Z)-order D ax

Output

dik r,

0.16 0.85 0.34 0.379

0 2.460

-0.602 0.155

0 10.005 1.884 0.630

25.59 36.35 30.26 36.35

dn: 10.30 d24: 9.65 6 32: 8.68 d42. 9.65

4.32 16.70 8.63 9.99

For each map w,, the maximal scaled distance D ax determines the order, and one distance do, determines the radius r,.

Page 360: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

spatial extent of attractors of iterated function systems 389

These results are illustrated in Fig. 5, and detailed in Table 2, including the D values used in re-ordering and the determining distances. (While in this example the determining distance for each map derives from the same pair that gives the maximum Z), that is not always the case.) So if we had no idea how big the fern attractor was, we could use a computational space ex­tending from Xmin = X2 - r2 = -14 ,24 to Xmax = X2 + r2 = 19.16 and y^in = y^' U = -9 .36 to >max = yi 4- r2 = 26.70 to contain the entire envelope. As it turns out, this is far more space than necessary for the fern itself, but there are many other IFSs, equivalent as far as the direct algorithm is concerned, with much larger attractors (e.g., what if 2 = 02 = 177.5 instead).

6. CONCLUSIONS To summarize, given any IPS (along with the con-

tractivities and fixed points of each of its constituent contraction mappings), an envelope that covers the attractor can be constructed of one ball for each map, centered on the corresponding fixed point. (In the case of affine maps in two dimensions, an explicit procedure for finding the contractivities and fixed points was given.) The spatial extent of the envelope thus gives a reliable bound on that of the attractor. (In addition, if the balls are disjoint, the attractor is totally discon­nected.) Two algorithms were given to calculate the radii of the balls: an iterative one for greatest simplicity.

and a direct one for greater efficiency. Both were proven to be effective. While the radii so found may not be minimal for the particular IPS, they are minimal for the set of all IPSs with equivalent information (in the sense described above).

Acknowledgements—Thanks to Aaron Schusteff and Ismor Fischer for stimulating, informative discussions and helpful suggestions.

REFERENCES 1. M. F. Barnsley, Fractals Everywhere, Academic Press/

Harcourt Brace Jovanovich, Boston (1988). 2. M. F Barnsley and S. Demko, Iterated function systems

and the global construction of fractals. Proc. Roy. Soc. Lond. A 399, 243-275 (1985).

3. S. Demko, L. Hodges, and B. Naylor, Construction of fractal objects with iterated function systems. Comp. Graph. 19,271-278(1985).

4. M. F. Barnsley, V. Ervin, D. Hardin, and J. Lancaster, Solution of an inverse problem for fractals and other sets. Proc. Nat. Acad Sci. USA 83, 1975-1978 (1986).

5. W. D. Withers, Newton's method for fractal approxi­mation. Const. Approx. 5, 151-170 (1989).

6. H. J. Jeffrey, Chaos game visualization of sequences. Comp. & Graph. 16, 25-33 (1992).

7. D. Canright, FrEd: the Fractal Editor. Freeware available as FREDEX.EXE from CompuServe IBMApp forum, Graphics library (1992).

8. M. F. Barnsley, J. H. Elton, and D. P. Hardin, Recurrent iterated function systems. Const. Approx. 5, 3-31 (1989).

APPENDIX /* The following program in C implements the direct algorithm for determining the "envelope"

of an attractor of an Iterated Function System on RA2, given the contractivities si and the fixed points ( xi, yi ) . written by David Canright, March 1993 .

*/ #include ^stdio.h) #include (math.h)

main( ) { int npts, i, j , m, n, index [ 64 ] , link[ 64 ] ; double d [ 64 ] [ 64 ] , x [ 64 ] , y [ 64 ] , s [ 64 ] , r [ 64 ] , Dmax [ 64 ] , t, tmax, dx, dy;

char line [ 81] ;

/* input n, si, xi, yi */ printf ( "Enter number of contraction mappings: " ); gets( line ); sscanf ( line,"%d",&npts ) ; for ( i = 1; i <= npts; i++ ) {

p r i n t f ( "Map %d. Enter s c a l e , x, y: " , i ) ; g e t s ( l i n e ); s s c a n f ( l ine,"%lf%lf%lf ", s + i , x + i , y + i ) ;

/ * en force 0 <= s < 1 * / i f ( s [ i ] < 0 . ) s [ i ] = - s [ i ] ; whi l e ( s [ i ] > = l . ) s [ i ] *= 0 . 1 ; p r i n t f ("Map %d: s = %f, x = %f, y = %f \n" , i , s [ i ] , x [ i ] , y [ i ] ) ; }

/ * compute d i s t a n c e s d i j & maximal s c a l e d D i j * / f o r ( i = l ; i < = n p t s ; i + + ) Dmax [ i ] = 0. ; for ( i = 1; i <= npt s ; i + + ) {

for ( j = i + 1 ; j <= npt s ; j + + ) { dx = X [ i ] -X [ j ] ; dy = y [ i ] - y [ j ] ; d [ i ] [ j ] = d [ j ] [ i ] = t = s q r t ( d x * d x + d y * d y ) ; t = ( l . + s [ i ] ) * ( l . + s [ j ] ) / ( l . - s [ i ] * s [ j ] ) * t ; i f ( t > Dmax [ i ] ) Dmax [ i ] = t ; i f ( t > Dmax [ j ] ) Dmax [ j ] = t ;

/ * Sort by s c a l e d d i s t a n c e s ; index p o i n t s to o ld order * / i n d e x [ 1 ] = 1;

Page 361: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

390 D. CANRIGHT

for ( i = 2; i <= npts; i++ ) { for ( m = i; m > 1 && Dmax [ i ] > Dmax [ index [ m-1 ] ] ; m- - ) index[m] = index[m-1];

index[ m] = i

} /* Direct algorithm; link points to determining distance */ i = index[1]; j = index[2] ; link[l] = 2; link[2] = 1; r[l] = (s[i]/(l.+s[i]))* Dmax [ i ] ; r[2] = ( s[j]/(l.+s[j]) ) *Dmax[j]; for ( m=3; m <= npts; m++ ) { i = index [ m] ; tmax = 0. ; for ( n = 1; n < m; n++ ) { j = index [ n ] ; i f ( { t = d [ i ] [ j ] + r [ n ] ) > tmax )

{ tmax = t ; l i n k [ m] = n; } }

r [ m ] = s [ i ] * tmax; }

printf ( "radii in sorted order [ orig order ] ( sorted link ) : \n" ) ; for ( i = 1; i <= npts; i++ ) printf (" r%d[%d]{ ->%d) : %f \n", i , index [ i ] ,link[i] ,r[i] )

return(0 ) ;

Page 362: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 391

Chaos and Graphics

AUTOMATIC GENERATION OF ITERATED FUNCTION SYSTEMS

J. C. SPROTT Department of Physics, University of Wisconsin, Madison, WI 53706, USA

Abstract—A set of affine mappings with randomly chosen coefficients is repeatedly iterated numerically using the random iteration algorithm to produce an attractor with fractal characteristics. The attractor is tested for boundedness, sensitivity to initial conditions, and correlation dimension. In this way, a computer can generate a large collection of fractal patterns that are all different and most of which have considerable aesthetic appeal. A simple computer program and examples of its output are provided. Many of the attractors have been systematically evaluated for visual appeal, and a correlation is found with the Lyapunov exponent and correlation dimension.

1. INTRODUCTION In an earlier companion paper, "Automatic Generation of Strange Attractors"[l], a method was described in which a system of coupled finite-difference equations with randomly chosen coefficients was iterated nu­merically and the solution tested for sensitivity to initial conditions (chaos). This method provides a powerful generator of new visual art forms and inspired a book that includes over 350 examples of such computer art[2]. This paper extends the technique to iterated function systems[3]. Such systems were originally studied by Hutchinson[4] and more recently applied to data compression and transmission by Barnsley[5, 6], who also introduced much of the terminology and the random iteration algorithm for their solution[7].

Whereas most previous work with iterated function systems has involved producing patterns to match some predetermined shape, this paper proposes a way for a computer to search a large class of potentially inter­esting mappings. The visual appeal of the patterns is shown to correlate with mathematical quantities that characterize them, such as the Lyapunov exponent[8] and correlation dimension[9], suggesting that it might be possible to refine further the automatic selection of patterns with strong visual appeal.

2. TWO-DIMENSIONAL AFFINE MAPS The simplest example of an iterated function system

is a set of two-dimensional affine maps:

Xnew = aix + a2y + as

new = a3X + a4y + ae

Such a mapping has a single fixed point (x*, y*) given by

X* = [-asiaA - 1) + a2ae]/[{ai - l){a4 - 1) - 2 3]

y* = [-ae(ai - 1) + a^as\/[(ax - 1)(«4 - 1) - 2 3]

This fixed point may either be stable (attracting) or unstable (repelling). A stable fixed point attracts initial

conditions within its basin of attraction, which in this case is the entire xy plane. With an unstable fixed point, successive iterates grow ever larger, and the system is unbounded. For simplicity, we consider saddle points (attracting in one direction and repelling in another) to be unstable, and we ignore periodic orbits, which seldom occur.

With each iteration, such an affine map takes a set of points in the xy plane and moves it to a new location in the plane, generally with scaling, translation, rota­tion, reflection, and shear. Stable solutions necessarily scale in such a way that the area of the new set is less than the area of the previous set, in which case we say that the set has contracted. Continually contracting mappings cause the set eventually to collapse into a region of negligible area surrounding the fixed point, and continually expanding mappings are unbounded. The amount of area contraction is determined by the magnitude of the determinant of the Jacobian matrix (hereafter simply "Jacobian") given by

/ = I 1 4 - «2^3l,

which is the ratio of the area after a contraction to the area before. Thus the condition for contraction is / < 1. Note that area contraction does not guarantee boundedness, since a set can continually contract in one direction and expand in another, approaching a thin filament of zero area and infinite length. We are generalizing the usual contraction mapping in which every pair of points is moved closer together by the mapping.

Now suppose that there exists a second different af­fine map,

Xnew = a-ix^- a^y + an

ynew = agx + a^y + an

which is applied to the set after some finite number of iterations of the first map. The result is to displace the set of points away from the original fixed point toward

Reprinted from Comput. & Graphics Vol. 18, No. 3, pag. 417-425, 1994

Page 363: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

392 J. C. SPROTT

which they were converging in the direction of a new fixed point in discrete steps of ever smaller size. How­ever, the progression toward the new fixed point need not be along a straight line but rather can spiral around it. Thus two attracting fixed points successively turned on and off can compete for the set, producing a succes­sion of points distributed over the xy plane in some pattern. Each point in the pattern can be transformed into another point in the pattern by some sequence of the two affine mappings. The collection of all such sequences is an iterated function system (IPS).

A practical method for producing iterated function systems is the random iteration algorithm in which a computer in essence repeatedly flips a coin and uses one map if it comes up heads and the other if it comes up tails. All possible sequences of heads and tails are eventually obtained, and long sequences of all heads or all tails, which would densely populate the regions near the fixed points, are rare. The locations of the fixed points are usually not obvious in such patterns. The patterns evolve much more quickly and uniformly if the coin is weighted so that the probability of applying each mapping is proportional to its Jacobian. The starting point can be chosen arbitrarily since the basin of attraction is the entire xy plane. However, the first few points should be discarded to ensure that the points have collapsed onto the attractor.

The resulting pattern is usually a deterministic frac­tal, despite being produced by a random algorithm. Different sequences of random numbers will produce the same eventual pattern. The pattern may have an integer dimension, but in such cases the boundary usually has a noninteger dimension. Although the at­tractor is a fractal, it is not usually called a strange attractor. That term is reserved for chaotic dynamical systems. Affine mappings cannot exhibit chaos because they lack the requisite nonlinearity.

3. SENSITIVITY TO INITIAL CONDITIONS

Like strange attractors, iterated function systems can be categorized by their sensitivity to initial conditions. Imagine two bounded iterated function systems pro­duced by the same pair of affine maps but with initial conditions that differ slightly. If the two are produced by a different sequence of coin flips, the sequences of (jc, y) values would bear no relation to one another. Indeed, this would be true even if they had the same initial condition. Thus there is extreme sensitivity to initial conditions resulting from the underlying ran­domness used to produce the sequence. However, if the same sequence of coin flips was used in the two cases, successive iterates would approach one another, implying insensitivity to initial conditions as expected for a deterministic nonchaotic process.

The difference between the two solutions decreases on average at an exponential rate. The rate of conver­gence is characterized by the Lyapunov exponent[8], which can be thought of as the power of 2 (or some­times e) by which the separation increases on average for each iteration. Thus if the separation halves with each iteration, the Lyapunov exponent is — 1 bit per

iteration. The Lyapunov exponent can be thought of as the rate at which information about the initial con­dition is lost. A negative value means that information is gained; with each iteration we are better able to pre­dict the result.

A two-dimensional IPS has two Lyapunov exponents since a cluster of nearby initial points may contract more in one direction than in another[10]. The least negative exponent is the one that dominates after a few iterations using the above procedure. The sum of the two Lyapunov exponents is related to the weighted average Jacobian (7) of the maps by

L,+L2 = log2</>

One difficulty is that the two solutions eventually get very close together, and the computer cannot re­solve the difference. This problem can be remedied if after each iteration the points are moved back to their original separation along the direction of the separa­tion [1 1]. The Lyapunov exponent is then determined by the average of the distance they must be moved for each iteration to maintain a constant separation. If the two cases are separated by a distance d„ after the n\h iteration and the separation after the next iteration is dn+\, the Lyapunov exponent is determined from

1 N-\

L = - ^ \0%2{dn+\ldn)

where TV is the number of iterations. After each itera­tion, the value of one of the iterates is changed to make dn^\ = d„. Por the cases here, dn is arbitrarily taken equal to 10~^

4. CORRELATION DIMENSION

The fractal patterns produced by iterated function systems arise from repeated affine mappings that make distorted copies of the pattern at successively smaller scales. Because the copies are generally sheared, they are not self-similar, but rather are self-affine. Purther-more, the mappings may overlap one another. There­fore, calculation of the fractal dimension directly from the equations is generally not straightforward.

It is relatively easy to calculate from the series of (x, y) values a related quantity, the correlation dimen-sion[9]. It is defined as the logarithmic slope of the correlation integral C(r), which is the probability that two randomly chosen points from the series are sep­arated by a distance less than r, where

r = V(x, - Xjf + (yi - yjf

The correlation dimension is a lower bound on the fractal dimension, but in practice it closely approxi­mates it. The two are identical if the points are uni­formly distributed over the attractor.

The correlation dimension can be calculated in real time as the pattern develops by taking each new point and calculating its separation from one or more ran-

Page 364: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic generation of iterated function systems 393

domly chosen previous points[12]. A counter TVi is in­cremented if the separation is less than ri, and N2 is incremented if it is less than r2, where Vi and r2 are chosen arbitrarily except that they should be much smaller than the size of the attractor, but large enough that A i and A2 are statistically significant and ri < Vi. In this case the correlation dimension is

F=\og{N2/N,)/\og{r2/r,)

with a statistical uncertainty of order N^^'^.

5. COMPUTER SEARCH PROCEDURE The procedure for implementing a computer search

for interesting iterated function systems is straightfor­ward. Choose the 12 coefficients a\ through a^ ran­domly over some interval, choose initial conditions for X and y, and iterate the equations for the maps (choosing randomly which mapping to use at each it­eration) while calculating the Lyapunov exponent and correlation dimension.

A computer program^ that repetitively performs these operations is listed in the Appendix. It is written in a primitive version of BASIC so as to be widely accessible and easily understood. The program should run without modification under Microsoft BASICA, GW-BASIC, QBASIC, QuickBASIC, VisualBASIC for MS-DOS, and PowerBASIC, Inc., PowerBASIC on IBM PC or compatibles. It assumes VGA (640 X 480 pixel) graphics. If the hardware or BASIC compiler does not support this graphics mode, change the SCREEN 12 command in fine 130 to a lower number {i.e., SCREEN 2 for CGA mode). A compiled BASIC and a computer with a math coprocessor are strongly recommended.

The coefficients are chosen in increments of 0.1 over the range -1.2 to 1.2 (25 possible values) in line 320. Smaller coefficients produce too much contraction, and larger coefficients produce mostly unbounded solu­tions. The increment was chosen so that each pattern is visibly different and so that the coefficients can be coded into letters of the alphabet A through Y (A = -1.2, B = -1 .1 , ^rc.) for easy reference and replication. Thus each pattern is uniquely identified by a 12-letter name. The number of possible cases is thus 25^^ or about 6 X 10* . Viewing them all at a rate of one per second would require about 2 billion years! Thus it is very unlikely that any patterns produced by the pro­gram will ever have been seen before, and like snow-flakes, nearly all of them are different.

Initial conditions are set arbitrarily to x = y = 0.05 in line 310. Other initial values produce the same result as expected for an attractor. Some computation time could be saved by choosing initial conditions at one of the fixed points. The Lyapunov exponent is calcu­lated using an initial condition in which x is increased

^ An IBM DOS disk containing the BASIC source code in the Appendix, an executable version of the code, and a more versatile menu-driven strange attractor program with 3-D glasses are available for $30 from the author. Specify 3.5 or 5.25-inch disk.

by 10~ (line 310). The correlation dimension calcu­lation begins after 200 iterations (line 910) and com­pares each new point with a randomly chosen previous reference point that is updated on average every 50 iterations (line 930). The correlation dimension is cal­culated at a scale of about 1% the largest dimension of the attractor with Vj = lOri (line 960 and 970). After 100 iterations, the program begins keeping track of the minimum and maximum values of x and y (lines 520-550) so that after 1000 iterations the screen can be cleared and resized to allow a 10% border around the attractor (line 560). After 1000 iterations the program begins testing the Lyapunov exponent and correlation dimension for a user-supplied criterion (line 650) for the case to be interesting. More will be said about such criteria in Section 7. If 21,000 iterations are reached with a bounded solution (line 630) and an acceptable combination of L and F, the result is assumed to be an interesting candidate IPS. The search immediately resumes after each case is confirmed and continues until a key is pressed (line 660).

The search procedure is surprisingly fast. On a 33-MHz, 80486DX-computer running PowerBASIC 3.0, the program finds about 600 interesting cases per hour. The listing in the Appendix only displays the patterns on the screen. A more versatile program would call a subroutine from line 630 to print the patterns, perhaps after user-confirmation or evaluation, or would save the coded coefficients in a disk file for later analysis.

6. SAMPLE ITERATED FUNCTION SYSTEMS

Figure 1 shows samples of the shapes that arise from the solution of such two-dimensional iterated function systems. These cases were selected for their beauty and diversity from a much larger collection. However, they are not atypical, and there are many others that would have served equally well. It is remarkable that such a diversity of shapes comes from the same simple set of linear equations with only different numerical values of the coefficients.

The cases shown were produced on a laser printer with 300 dots per inch resolution on an 8.5 X 11-inch page after about 500,000 iterations. Of course, the pro­gram needs modification to output the plots to a printer at high resolution. However, satisfactory results can be obtained by any of the various utilities that allow one to print a screen image.

Also shown on each figure is the code name pre­ceded by the letter a to denote a two-dimensional IFS with two affine maps, the Lyapunov exponent L (in bits per iteration), and the approximate cor­relation dimension F.

7. AESTHETIC EVALUATION

A collection of 7500 such patterns was systematically examined by the author. The evaluations were done by displaying previously stored but unseen cases se­quentially on the computer screen without any indi­cation of the quantities that characterize them. Each case was evaluated on a scale of one to five according to its aesthetic appeal. It only took a few seconds for

Page 365: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

394 J. C. SPROTT

aGNGUVETDSNWK F - 1.95 L =-0.44 aGOHRHRKVFLNO F = 1.48 L —0.47

alFEROWOSIRQI F " 1.57 L —0.37 allDQIKFMHUSK

^ :

""" - ^ r* 'MW^^^^^t^gk

alPUDJIHVEIQV F - 1.13 L —0.10 aKDOWQMMYEMWD F •= 1.38 L -

Fig. 1. Examples of iterated function systems produced by pairs of two-dimensional affine maps.

Page 366: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic generation of iterated function systems 395 aLGMRYBSCSSQR F = 1.83 L —0.10 aMCGMGGJQORXH F - 1 . 0 8 L — 0 . 5 4

aNYDEQPKLOOKY •P""^ ^ p ^

F = 1^73 L =-0.05 aRFUSIENUVCN F = 1.50 L =-0.16

aRIGIEDMIBOWR F = 1.76 L =-0.S4 aTLPVPLMQEIFC

F = 1.81 L =-0.05 aUIPUDROEPLPM

Fig. 1. (Cont'd.)

Page 367: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

396 J. C. SPROTT

each evaluation. Tests with other individuals show that the relative ratings are reasonably consistent.

Figure 2 shows the results using a gray scale on a plot in which the largest Lyapunov exponent (L) and correlation dimension (F) are the axes. The darkness of each box increases with the average rating of those attractors whose values of L and F fall within the box. There is a clear preference for patterns with correlation dimensions greater than 1 and large negative Lyapunov exponents. A similar result was found for strange at-tractors[ 1, 2], except that they are most appealing when their positive Lyapunov exponents are small.

The dimension preference is perhaps not surprising since many natural objects have dimensions in this range. The Lyapunov exponent preference is harder to understand. For a given dimension, the largest neg­ative values of Lyapunov exponent correspond to cases in which the two exponents are equal, implying the same contraction in all directions and perfect self-sim­ilarity. The largest negative Lyapunov exponent and fractal dimension are bounded by a curve

-FL < log O/log D

where O is the number of mappings (2 in this case) and D is the dimension of the system of equations (2 in this case). Points on the boundary correspond to exact self-similarity. For the 76 cases that were rated five (best), the average correlation dimension was F = 1.51 ± 0.43, and the average Lyapunov exponent was L = -0.24 ±0.15 bits per iteration, where the errors represent plus or minus one standard deviation. About 31% of the cases evaluated fall within the error bars.

These results suggest that the computer can be taught to select cases that have a high probability of aesthetic appeal. Various criteria have been used for this purpose. One such example is given in line 650 of the program

listing in the Appendix. Another criterion that has been effective is

[(2 - F)/\2f + [(2 + L/log 0)/L6f < 1,

which eliminates about 98% of the two-dimensional cases. The 2% that remain are nearly all visually in­teresting.

8. SUGGESTIONS FOR FURTHER WORK The method described above can be easily extended

in a number of ways. There is nothing special about two-dimensional pairs of affine maps other than per­haps simplicity. This simplest case was chosen to em­phasize the enormous diversity of patterns that can be produced. It is straightforward to apply the technique to cases with 0>2 and D>2. The fraction of visually interesting cases decreases with both O and D unless some appropriate selection criterion is used. One could also examine the infinite variety of nonlinear mappings.

The probabilities of the mappings can be altered to change the density of points on various regions of the attractor. The probabilities could be included among the search parameters. Different probabilities do not alter the final appearance of the pattern, but they can significantly affect the early stages of its development. The maximum number of iterations is another param­eter that can be adjusted. The development of the pat­tern is sensitive to the quality of the random numbers used to produce it[13], suggesting a possible test to distinguish chaos from randomness. Such tests have been applied to the analysis of DNA sequences[14].

Having found a visually appealing IFS, one can make small variations of the coefficients to optimize evert further its appearance. The attractors can be animated by producing a succession of frames, each with a slightly different value of one or more of the parameters.

- 2

L

e

7 5 B B C r i s e s

• • B"i

17jn^L_ pu^^^b|H m Bw^T^^JB^^B^^^^^^^^^^^^^^^B 1

Fig. 2. Results of evaluating 7500 iterated function systems, showing that the most visually appealing cases are those with large negative Lyapunov exponents (L) and with correlation dimensions (F) greater than one.

Page 368: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic generation of iterated function systems 397 Three-dimensional iterated function systems can be

explored using mappings of the form

Xnew = aix + a2y + a^z + aio

ynew = a4X -\- asy + a^z + au

Znew = a-fX + asy + a^z + a^

with a Jacobian

y = \a1a5a9 + <22 6 7 + a^a^a^

— a-iUsa-i - fl2<24a9 - « l « 6 ^ 8 I

Adding a third dimension raises interesting possi­bilities for new display modes. The simplest case is to plot X and y, but to ignore z, which is equivalent to viewing the projection (or shadow) of the attractor on the xy plane. Alternately, the attractor can be projected onto the yz or zx plane or rotated through an arbitrary angle. A gray scale can be used to represent the number of iterates that fall on a given screen pixel[ 15], thereby restoring some of the resolution lost by the finite res­olution of the screen.

Another possibility is to code the third dimension in color. Examples of three-dimensional iterated func­tion systems using 16 colors are shown in Fig. 3. These

eQrilP»M|Dlli«6Fiyf]|fimiHTI.

•'"^*^'^:SMfc|i||^

jpflp^ -^0^^^

/

X ^

' H J^ ••'^H

/ 1

I ^ /

f = 8.76 h «-8.M

\ \ ! / • M l / /

\ \ \ 1

eSifissiiGniniiTHiniiirimeiiiF r =* 1.65 L = 8.47

Fig. 3. Examples of iterated function systems produced by pairs of three-dimensional affine maps in which the color is determined by one of the variables.

Page 369: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

398 J. C. SPROTT

figures were produced directly from VGA screen im­ages using a color ink-jet printer. Some computer lan­guages allow one to cycle through a variety of color palettes to find the most pleasing combination of colors or to produce an animated color display. Modern ver­sions of BASIC have such a PALETTE command. In Fig. 3 the palette was adjusted to provide a rainbow sequence of colors.

It is also possible to produce an anaglyph[16] in which each {x, y) value is plotted twice, once in red and once in cyan, displaced horizontally by a distance proportional to z to produce a three-dimensional monochrome image when viewed through red/blue glasses. Color three-dimensional images can be pro­duced by plotting the two colored views side-by-side and either viewing them cross-eyed or through an in­expensive prism stereoscope.^ The attractors can be rotated to provide a view from the most pleasing angle or animated with successively rotated images.

Three-dimensional attractors can also be displayed using shadows to convey depth or contour bands as with topographic maps. One can slice the attractor like a loaf of bread and display the slices in an array or as an animated sequence. Combinations of these tech­niques permit visualization in dimensions higher than three. The attractors can be projected onto spheres, cylinders, tori, or other surfaces.

Iterated function systems can also be used to produce a crude kind of computer music. For a two-dimensional map, X might be used to control the pitch and y the duration of each note. The result is a not-displeasing, though alien-sounding, form of music that might ap­peal to those with exotic musical tastes.

Much more could be done with correlating the aes­thetic appeal of the attractors with the various nu­merical quantities that characterize them. The Lya-punov exponent and correlation dimension are only two such quantities; there are infinitely many oth-ers[17]. One could determine if there are discernible differences between the preferences of scientists and artists. Preliminary indications suggest that complexity might appeal more to artists than to scientists, who tend to see beauty in simplicity. There may be dis­cernible cultural differences. One could determine whether the results are the same for more complicated systems of equations and for different methods of dis­playing the results, such as color versus monochrome.

^ Stereoscopes and other 3-D supplies are available ft-om Reel 3-D, P.O. Box 2368, Culver City, CA 90231.

If quantifiable measures of aesthetics can be deduced for patterns produced by a computer[18], then perhaps the same could be done for patterns produced by hu­mans. Fractal compression schemes attempt to rep­resent arbitrary images by their IFS parameters. From these parameters, many quantities such as the spectrum of contractions can be easily deduced. It would make an interesting study to determine whether there are correlations between these quantities and the artistic quality of the original image. Perhaps such schemes could be used to detect forgeries if there are discernible differences in the fractal characteristics of works by various artists.

REFERENCES 1. J. C. Sprott, Automatic generation of strange attractors.

Comp. & Graph. 17, 325-332 (1993). 2. J. C. Sprott, Strange Attractors: Creating Patterns in

Chaos, M&T Books, New York (1993). 3. M. Barnsley and S. Demko, Iterated function systems

and the global construction of fractals. Proc. Royal Soc. London A 399, 243-275 (1985).

4. J. Hutchinson, Fractals and self similarity. Indiana Univ. /A/«//7. 30, 713-747(1981).

5. M. F. Barnsley, V. Ervin, D. Hardin, and J. Lancaster, Solution of an inverse problem for fractals and other sets. Proceedings of the National Academy of Sciences 83, 1975 (1986).

6. M. F. Barnsley and L. P. Hurd, Fractal Image Compres­sion, A. K. Peters, Wellesley, MA (1993).

7. M. F. Barnsley, Fractals Everywhere, Academic Press, Boston (1988).

8. H. G. Schuster, Deterministic Chaos, Springer-Verlag, New York (1984).

9. P. Grassberger and I. Procaccia, Characterization of strange attractors. Phys. Rev. Lett. 50, 346-349 (1983).

10. G. Benettin, L. Galgani, A. Giorgilli, and J. Strelcyn, Lyapunov characteristic exponents for smooth dynamical systems and for Hamiltonian systems; a method for com­puting all of them. Meccanica 15, 9-20 (1980).

11. A. Wolf, J. B. Swift, H. L. Swinney, and J. A.~ Vastano, Determining Lyapunov exponents from a time series. Physica 16D, 285-317 (1985).

12. W. Lauterborn and J. Holzfuss, Evidence for a low-di­mensional strange attractor in acoustic turbulence. Phys. Lett. A 115,369-372(1986).

13. I. N. Stewart, Order within the chaos game? The Dynamics Newsletter 3, 4-9 (19^9).

14. H. J. Jeffrey, Chaos game visualization of DNA sequences. Comp. & Graph. 16, 25-33 (1992).

15. C Pickover, A note on rendering 3-D strange-attractors. Comp. & Graph. 12, 263-267 (1988).

16. J. C. Sprott, Simple programs produce 3D images. Comp. Phys. 6, 132-138(1992).

17. J. D. Farmer, E. Ott, and J. A. Yorke, The dimension of chaotic attractors, Physica 7D, 153-170 (1983).

18. H. W. Franke, Computer Graphics, Computer Art, Springer-Verlag, New York (1985).

110 DEFDBL A-Z: DIM A(12) 120 RANDOMIZE TIMER 130 SCREEN 12 140 GOSUB 300 150 GOSUB 400 160 GOSUB 500 170 GOSUB 600 ISO ON T% GOTO 130, 140, 150 190 END

APPENDIX

'Reseed random number generator 'Assume VGA graphics 'Set parameters 'Iterate equations 'Display results 'Test results

Page 370: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic generation of iterated function systems 3 9 9

300 REM Set parameters 310 X = .05: Y = .05: XE = X + .00001: YE = Y 320 FOR 1% = 1 TO 12: A(I%) = .1 * (INT(25 * RND) - 12): NEXT 1% 330 J0 = ABS(A(1)* A(4)-A(2)* A(3)) 340 Jl = ABS(A(7) * A(10) - A(8) * A(9)) 350 IF JO + Jl = 0 OR JO > 1 OR Jl > 1 THEN GOTO 320 ^Not contracting 360 P = JO/(JO + J l ) 370 T% = 3: LSUM = 0: N = 1: Nl = 0: N2 = 0 380 XMIN = 1000000#: XMAX = -XMIN: YMIN = XMIN: YMAX = XMAX 390 RETURN

400 REM Iterate equations 410 IF X < > XE THEN IF RND > P THEN R% = 6 ELSE R% = 0 420 XNEW = A(l + R%) * X + A(2 + R%) * Y + A(5 + R%) 430 YNEW = A(3 + R%) * X + A(4 + R%) * Y + A(6 + R%) 490 RETURN

500 REM Display results 510 IF N < 100 OR N > 1000 THEN GOTO 560 520 IF X < XMIN THEN XMIN = X 530 IF X > XMAX THEN XMAX = X 540 IF Y < YMIN THEN YMIN = Y 550 IF Y > YMAX THEN YMAX = Y 560 IF N = 1000 THEN GOSUB 800 570 IF X > XL AND X < XH AND Y > YL AND Y < YH AND N > 1000 THEN PSET (X, Y) 590 RETURN

600 REM Test results 610 GOSUB 700 'Calculate Lyapunov exponent 620 GOSUB 900 'Calculate correlation dimension 630 IF N > 21000 THEN T% = 2 'Candidate IFS found 640 IF ABS(XNEW) + ABS(YNEW) > 1000000# THEN T% = 2 'Unbounded 650 IF N > 998 AND (F < 1 OR L > -.2) THEN T% = 2 'Uninteresting 660 IF LEN(INKEY$) THEN T% = 0 'User key press 670 X = XNEW: Y = YNEW: N = N + 1 690 RETURN

700 REM Calculate Lyapunov exponent 710 XSAVE = XNEW: YSAVE = YNEW: X = XE: Y = YE 720 GOSUB 400 'Reiterate equations 730 DLX = XNEW - XSAVE: DLY = YNEW - YSAVE: DL2 = DLX * DLX + DLY * DLY 740 DF = 10000000000# * DL2: RS = 1# / SQR(DF) 750 XE = XSAVE + RS * (XNEW - XSAVE): YE = YSAVE + RS * (YNEW - YSAVE) 760 XNEW = XSAVE: YNEW = YSAVE 770 LSUM = LSUM + LOG(DF): L = .721347 * LSUM / N 790 RETURN

800 REM Resize the screen (and discard the first thousand iterates) 810 DX = .1 * (XMAX - XMIN): DY = .1 * (YMAX - YMIN) 820 XL = XMIN - DX: XH = XMAX + DX: YL = YMIN - DY: YH = YMAX + DY 830 IF XH - XL < .000001 OR YH - YL < .000001 THEN GOTO 890 840 WINDOW (XL, YL)-(XH, YH): CLS 850 LINE (XL, YL)-(XH, YH), , B 890 RETURN

900 REM Calculate fractal dimension 910 IF N < 200 THEN GOTO 990 'Wait for transient to settle 920 IF N = 200 THEN D2MAX = (XMAX - XMIN) A 2 + (YMAX - YMIN) A 2 930 IF N = 200 OR RND < .02 THEN XS = X: YS = Y 'New reference point 940 DX = XNEW - XS: DY = YNEW - YS 950 D2 = DX * DX + DY * DY 960 IF D2 < .001 * D2MAX THEN N2 = N2 + 1 970 IF D2 < .00001 * D2MAX THEN Nl = Nl + 1: F = .434294 * LOG(N2 / Nl) 990 RETURN

Page 371: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 401

Chaos and Graphics

MODELING AND RENDERING OF NONLINEAR ITERATED FUNCTION SYSTEMS

E D U A R D G R O L L E R Technical University Vienna, Institute for Computer Graphics, Karispiatz 13/186/2, A-1040 Vienna,

Austria, e-mail: [email protected],ac.at

Abstract—Iterated Function Systems are typically defined through sets of contractive linear transformations. The theory of Iterated Function Systems is based on the contractivity but not on the linearity of the defining functions. Piecewise bilinear distortions of grids are used in this work to specify nonlinear Iterated Function Systems. Nonlinear Iterated Functions Systems are characterized by a higher degree of flexibility and greater modeling capability than their linear counterparts. Modeling and rendering aspects are discussed. Limit sets of* 2D nonlinear Iterated Function Systems are represented by approximating point sets. Limit sets of 3D nonlinear Iterated Function Systems are either rendered by displaying approximating point sets (z-buffer approach) or through ray tracing an approximate set of 3D solids. Example images of a test implementation are presented.

1. INTRODUCTION

An Iterated Function System (IFS) is a concise spec­ification of a typically complex and fractal geometric shape [ 1 ] . The following somewhat mathematical in­troduction describes the most important definitions and theorems Iterated Function Systems are based on. Given a complete metric space (X, d), with X being a set and d:X X X ^^ R being a distance function on elements ofX, an IFS is defined through a finite set of affine, contractive functions w,: X - ^ X ( notation: IFS {X;wi,.. . ,Wjs/}). A function w, is contractive if and only if there exists a so-called contractivity factor 5/ E [0, 1), such that

d{Wi{x), Wi(y)) < Si*d{x, y) Vx, y E X

The metric space (X, d) is now used to define a metric space ( / / ( X ) , /z), where H(X) contains the nonempty compact subsets of X a n d h{d) denotes the Hausdorff distance between elements A and B of H{X):

h(A,B)

max {max min d{x, y ) , max min d{x, y)]

As / / ( X ) contains only the nonempty compact subsets of X the distance h{A, B) is well-defined for A, B EL H{X). In our work set X will either be 2D or 3D space and H(X) will thus either consist of most 2D or 3D objects one can think of. The Hausdorff distance on elements of H(X) allows the comparison of 2D or 3D objects. Iterated Function Systems specify invariant limit sets where convergence is with respect to the Hausdorff distance h{). A function W/: X - ^ X is easily extended to w,: H(X) ^ / / ( X ) by

Wi(A)^ {Wi(x)\xeA}, ABH(X)

Given an IFS {X; Wi, . . . , Wj^} then the contractive functions w, (extended from functions X - ^ X t o func­

tions H(X) ^ H{X)) specify a function W.HiX) • H{X) as follows (Hutchinson operator):

W{A)= U Wi(A), AEH(X)

Function W{)'\s contractive with contractivity factor s = max { ^ 1 , . . . , 5AA} . Due to the contractivity of W() it can be shown that there is a unique set A', called the attractor of the IFS, that satisfies

A' = W(A')

Furthermore any element A E H{X) will be eventually mapped onto this attractor A' under repeated appli­cation of function W{), i.e.,

A' = lim W{A) ^AGH{X)

An IFS is thus a very concise descriptfon (e.g., an affine function in the plane is specified with only six numbers) of the attractor A\ which is very often a fractal set. Algorithms for calculating the attractor ^4' of an IFS are discussed in a later section. IFSs have been used in computer graphics, e.g., for modeling[2, 3] as well as for data compression [ 1, 4 ] . For further details on fractals and IFSs see for example [ 5 ] .

2. NONLINEAR ITERATED FUNCTION SYSTEMS

The theory of IFS, i.e., unique at tractor^ ' , conver­gence of any set A to this attractor A' under application of function W{), is based on the contractivity of the functions Wi and W. There are some reasons, which are however not imperative, to use affine maps for the specification of functions Wt: affine functions are easily manageable, they are well understood and they can be specified in a concise way through a matrix and trans­lation vector (see Fig. 1). Affine transformations de­scribe linear mappings, i.e., lines are mapped to lines,

Reprinted from Comput. & Graphics Vol. 18, No. 5, pag. 739-748, 1994

Page 372: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

402 E. GROLLER

^

W3

JT

<3=(o rx ro.5 oYfxV 10.2

^<yj ( o O.5JW lo.i Fig. 1. Linear IFS {R^; Wi, W2, W3}, attractor 4'.

and they can be intuitively visualized by showing the effect of the transformation on a simple shape, e.g., rectangle or triangle for functions w,:/?^ -^ R^ (see Fig. 1).

The usage of nonlinear functions for the specification of IFSs greatly increases the number of shapes that can be modeled. In fact there is a well-known group of shapes whose elements are attractors of nonlinear IFSs {C; vvi, ^2} of two functions in the complex plane C. These are the so-called Julia sets (see Fig. 2) . Julia sets separate, in case they are connected, points in the complex plane with vastly differing dynamic behavior under iteration ofX(^) = z^ + c. In the following a new class of nonlinear IFSs is presented. These new nonlinear IFSs are easy to specify and to model. An affine function is defined by specifying how the function transforms a simple shape, e.g., a rectangle. We now define a nonlinear function by specifying how the function transforms a rectilinear grid. Defining a func­tion through the nonlinear distortion of a regular grid (m X n grid in R^ and m X n X o grid in R^) offers additional modeling capabilities that are not achievable with affine transformations. Figure 3 shows two ex­amples of nonlinear variations of the Sierpinski tri­angle. The attractor in the upper half of Fig. 3 is defined by three nonlinear functions, the attractor in the lower half of Fig. 3 is given by one nonlinear and two linear functions. The transformation of an interior point P of a rectangular grid is now determined by bilinear

interpolation of the adjacent grid points. Figure 4 il­lustrates the situation in two dimensions. An extension to three dimensions is, however, straightforward. A two-dimensional point P = (P^, P^) is given by its two Cartesian coordinates and P denotes the point after transformation. Ps^ is an original grid point and Ps,t denotes the corresponding transformed grid point. Then the transformed point P of an interior point P is calculated as follows:

P = (l -v)*[Pij*i\ -u)-\-Pi^u>]

with

P^

Pf^i.j - PIJ and V

P' - Pjj py _ py

Defining the transformation only for interior points of the grid is sufficient if the transformed grid lies within the untransformed one. This ensures that the trans­formation of no exterior points is required for the sub­sequent calculation of the attractor of the IFS. Fur­thermore, if the transformed grid lies within the boundaries of the untransformed grid then contractiv-ity, which is essential for the existence of and conver­gence to a unique attractor, is guaranteed. Starting with

c=-0.7+0.1i c=-0.5+0.1i

Fig. 2. Nonlinear IFS {C; M I, ^2} with w, = +Vz - c and W2 = -Vz - c.

Page 373: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Nonlinear iterated function systems 403

=:W W2^

«AA ^ IL W2_

w^mi Fig. 3. Nonlinear variations of the Sierpinski triangle, IFS

{ i ? ^ ; H^i, W2, W 3 } .

a sufficiently large grid has the additional advantage of easily producing a bounding volume hierarchy, which is then used in rendering the attractor of 3D nonlinear IFS. Details are given in the following sec­tion. Figure 5 shows an example of a 2D linear IFS and Fig. 6 shows a similar 2D nonlinear IFS. There are different approaches to define nonlinear functions through grid distortion. One method specifies the transformation of each grid point explicitly. Although this gives a high degree of control on the final outcome it might be cumbersome for large grid sizes. Barr [6] describes some global deformation schemes, i.e., bending, twisting, tapering, that are also applicable to our 2D or 3D grids. Thereby groups of grid points are

transformed simultaneously and coherently. With ta­pering, for example, a nonlinear and nonuniform scal­ing is specified. Functions Wi and W2 of the nonlinear IFS in Fig. 6 are examples of the bending operation. Twisting describes a nonuniform rotation of grid points around a predefined axis. High level manipulation of the 2D or 3D grid enables a fast and intuitively easy definition of nonlinear IFS. Some of these techniques were applied to generate the color plates.

3. RENDERING OF NONLINEAR ITERATED FUNCTION SYSTEMS

There are basically two types of algorithms for the approximate calculation of the attractor of a linear IFS. Both types can be applied with some modifications to nonlinear IFS as well. The stochastic algorithm pro­ceeds as shown in Fig. 7. Starting with an arbitrary point P one of the functions vvi, . . . , w^ is selected at random and applied to point P. Repeatingly selecting a function and transforming the previously calculated point (P« = W/ (P„_i)) yields a sequence of points that, due to the chaotic dynamics of the process, closely approximates the attractor of the IFS (with very high probability). Depending on the choice for the initial point P the first few points of the above sequence may not yet be close to the attractor. They should therefore be eliminated from the approximating point set.

A probability Pi is assigned to each function Wi to account for varying contractivity factors. Probabilities should be chosen so that the generated point sequence uniformly converges to the attractor of the IFS, i.e., functions with low contractivity are assigned a higher probability. As nonlinear functions may have locally varying contractivity, determining these probabilities is not as easy as for linear functions. Peitgen and Saupe [ 7 ] present a simple algorithm that accounts for the locally varying contractivity of functions used for approximating Julia sets (Fig. 2). The same strategy, which basically ensures that the point sequence of the stochastic algorithm visits regions of the attractor with low contractivity more often, can be used for nonlinear IFS as defined above.

Drawing a point sequence of a 2D IFS is simple. For 3D IFS, however, an image plane and type of pro-

^y

V

Pijl

fc 4 w— • - ^

p

1

* u

1

Pi+lj+1

|Pi+lj

untransforaied grid transformed grid Fig. 4. Bilinear interpolation of interior point Pin R^

Page 374: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

404 E. GROLLER

Fig. 5. Linear IFS {R^; w,, W2, W3, W4} similar to Fig. 6.

wi :w wv

"1 W2 ^

-sy^ 3 Fig. 6. Nonlinear IFS {R^', Wi, W2, w^, W4} similar to Fig. 5.

jection (parallel or perspective) has to be defined. In this case we preserve depth information through depth cueing, which produces quite acceptable results. Thereby the color values of points farther away from the viewer are attenuated according to distance. A pixel may be assigned the color value of the point closest to the viewer or a weighted average of all points projecting onto the same pixel may be taken.

The second algorithm for approximating an IFS is an immediate result of the fact that every object A will approximate the attractor /i ' of an IFS under iteration of function IV{). Therefore the deterministic algorithm approximates the attractor as follows:

A' : W \A)

where nmax determines the level of accuracy of the approximation. We did use the deterministic algorithm for visualizing 3D nonlinear IFS. Although the sto­chastic algorithm is usually much faster, there are same advantages to using the deterministic algorithm. Start-

PO = P

for n = 1 to nmax do

begin

f wl(Pn-l)^ith probability PI

Pn = •!

I wN(Pn-l)yi^ith probability PN

draw Pn

end

Fig. 7. Stochastic algorithm for IFS {^; w,, . . . , w^}.

ing with a 3D solid A the deterministic algorithm pro­duces a 3D solid approximation of the fractal attractor instead of a mere point set as the stochastic algorithm does. So hidden surface procedures applied to such a 3D approximation greatly increase the depth percep­tion for the viewer. In addition the simulation of com­plex global lighting effects, e.g., shadowing, shading, reflection, transparency, is often tied to 3D models with surface normals. Fractal objects do not have surface normals that are, however, required to evaluate a more complex shading model. Hart and DeFanti[3] propose several strategies to simulate nonexistent surface nor­mals of their linear fractals. As we render only 3D ap­proximations, ^"'^^A), of the attractor of an IFS there is no problem with missing normal vectors.

Our algorithm for rendering 3D nonlinear IFS uses ray tracing[8] for high-quality image generation and follows [3] and [ 9 ] . Ray-object intersection testing is the most time consuming step in the ray-tracing process and is accelerated for linear as well as nonlinear IFS by using a hierarchical data structure. Nonlinear func­tions are chosen, as pointed out above, so that W{A) ^ A. Therefore

W^'^^^A) ^ W^" W\A) c W{A) ^ A

constitutes an efficient hierarchical data structure that bounds the attractor on all levels of approximation. Only if a ray intersects an object of W'(A) then the corresponding elements of W'^\A) must be further considered. Due to nonuniform contractivity W'^"'^''{A) contains objects of sometimes largely dif­fering sizes. So rendering ^^"""^"( 4), i.e., all objects on the same level of recursion, especially visualizes the zones with low contractivity. Hart and DeFanti[3] subdivide objects in low contractivity regions to a much higher level, so as to get the best approximation of the attractor that is possible with respect to the given image

Page 375: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Nonlinear iterated function systems 405

nonlin. IPS

"tapering"

"twisting"

"fantasy"

"plant 1"

1 "plant 2"

#of functions

4 nonlinear

4 nonlinear

5 nonlinear

5 linear

5 nonlinear

grid size

2x4x2

2x4x2

3x2x3

2x2x2

2x4x2

contract.

0.55

0.69

0.64

0.50

0.68

comment

tapering of Sierpinski tetrahedron

twisting of Sierpinski tetrahedron

tapering of grid

linear plant modeling

nonlinear plant modeling |

Fig. 8. Statistics of examples of IFSs.

resolution. As we are interested in the convergence process itself a fixed level of recursion is appropriate.

Two types of initial objects A were used in our de­terministic algorithm: spheres and the tessellated outer surface of the grids, which were used to define the non­linear functions, themselves. Taking a sphere as an ini­tial object has two advantages: First ray-sphere inter­section testing is cheap. Second if W'{A) contains only spheres then W''^\A) may be approximated with suf­ficient accuracy by transforming only the sphere centers and determining the radii of the spheres in W''^\A) considering the contractivity factors of functions Wi. With such an approach W^\A) is not determined exactly but only a superset is determined, which is, however, in most cases sufficient to visualize the con­vergence behavior of the approximation process. A sphere as initial object therefore allows a fast approx­imate determination of W"'^''{A), which in turn is an approximation of the attractor A'. Taking the initial (function w, defining) grid as initial object A produces results that are more exact but are, at the same time, also more time consuming: Ray-object intersection testing and recursive refinement (going from W'{A) to W''^\A))is much more costly with a grid surface than with a sphere.

Antialiasing has been done through oversampling. Refinement of objects may stop adaptively as soon as their projection onto the image plane is smaller than

a pixel area. For details see [ 3 ]. In addition shadow rays are cast to each given light source to determine if a point of intersection is in shadow or not.

4. IMPLEMENTATION, RESULTS

We have implemented a system for the interactive specification and rendering of 2D nonlinear IFS (in Turbo Pascal) and a system for the high quality ren­dering of 3D nonlinear IFS (in C++). The color plates (resolution 360 X 384) show some nonlinear and one linear 3D IFS, which have been rendered with either the stochastic or the deterministic algorithm. Corre­sponding statistics are given in Figs. 8 and 9. The ap­pendix contains a detailed specification of the IFSs of Fig. 8. A nonlinear function is thereby defined by spec­ifying the transformations of the points of a regular initial grid. Color plates 1 through 3 show nonlinear distortions of the Sierpinski tetrahedron. Plates 1 and 2 illustrate nonlinear scaling along the vertical axis (ta­pering). Plate 1 shows the object that results after ap­plying the tapering functions to the initial grid twice. The effects of the nonlinear functions are clearly visible. Plate 2 depicts the resulting attractor visualized with the stochastic algorithm. Plate 3 illustrates nonlinear rotation along the vertical axis (twisting). Portions of the Sierpinski tetrahedron with higher z-values are ro­tated more heavily than lower lying parts. Plate 4 is the image of a rather strange looking nonlinear IFS

1 plate

1

2

3

4

5

6

7

8

nonlin. IFS

"tapering"

"tapering"

"twisting"

"fantasy"

"plant 1"

"plant 1"

"plant 2"

"plant 2"

algorithm |

deterministic, A=grid, nmax=2

stochastic, 1.000.000 pts.

deterministic, A=sphere, nmax=6

deterministic, A=grid, nmax=6

deterministic, A=grid, nmax=l

deterministic, A=sphere, nmax=6

deterministic, A=grid, nmax=l

deterministic, A=sphere, nmax=7 |

Fig, 9. Statistics for color plates.

Page 376: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

406 E. GROLLER

Plate 1. IPS "tapering," nmax = 2. Plate 4. IPS "fantasy.'

Plate 2. IPS "tapering." Plate 5. IPS "plant 1," nmax = 1.

Plate 3. IPS "twisting.' Plate 6. IPS "plant 1," nmax = 6.

Page 377: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Nonlinear iterated function systems 407

Plate 7. IFS "plant 2," nmax

?-5;r "''B'lffc: f l y f l v' •11; r • ; f l i l i | j " f ' ;

Plate 8. IFS "plant 2," nmax = 7.

with five functions. Plates 5 through 8 show the dif­ference of linear and nonlinear IFS. Plate 6 displays a plant-like object that is defined by five linear functions. These functions could be defined by matrix operations as well. But as our program handles functions as grid distortions only, the Unear functions of IFS "plant 1" are specified accordingly: Plate 8 shows the object that results from somewhat similar but nonlinear functions than those used in Plate 6. Using the initial grid as initial object A and taking nmax to be one in Plates 5 and 7, allows to visualize how the defining functions of IFSs "plant 1" and "plant 2" work. Plate 7 illustrates the nonlinear grid distortions used to specify the func­tions of "plant 2." The greater flexibility of nonUnear IFS may be used to increase realism when modeling natural phenomena (compare Plate 6 and Plate 8) .

5. SUMMARY

Iterated function systems are usually defined by a set of linear contractive functions. Abandoning the

linearity of the defining functions allows the specifi­cation of nonlinear IFS with greater modeling flexi­bility. Nonlinear functions are defined through grid distortions. Currently we are working on an interactive module that should enable an easy and intuitive spec­ification of nonlinear functions. Rendering algorithms for 2D and 3D nonlinear IFS have been discussed. Examples show the wide variety of recursive objects that can be modeled with nonlinear IFS. Future work will include parametric approximation of grid points {e.g., with B-Splines or NURBS), more elaborate color assignment (each function of a nonlinear IFS is as­signed a color, then different strategies may be used to assign varying color values to different parts of the re­sulting attractor), grid point animation, etc.

There might be some future application of nonlinear Iterated Function Systems for fractal image compres­sion. Jacobs, Fisher, and Boss[10] discuss a pixel-based approach that makes use of so called local IFS. Local IFS do not transform the whole underlying metric space but only subsets thereof. As nonlinear IFS are defined on the interior of a regular grid they are local by def­inition. Right now pixel-based fractal compression techniques reduce the tremendous search cost involved to determine the compressing local IFSs by reducing the allowable class of functions (only simple affine transformations like scaling, rotation by 90°, 180°, 270°, horizontal and vertical reflection). Faster algo­rithms in the future should allow to enlarge the class of admissible functions that could then include non­linear functions. Nonlinear Iterated Function Systems may be more appropriate to encode pixel blocks which contain, e.g., curved edges, than simple affine trans­formations.

Acknowledgement—The author would like to thank Martin Schwarzinger for implementing an interactive 2D IFS mod­eling system. Thanks to Johann Schipfer for implementing the rendering software for 3D nonlinear IFS and for his help in generating the color plates. The helpful suggestions of an anonymous reviewer were much appreciated.

REFERENCES 1. M. Barnsley, Fractals Everywhere, Academic Press, New

York (1988). 2. E. Groller, Fractals and solid modeling. Comp. Graph.

Forum 11 (3), 415-424 (1992). 3. J. C. Hart and T. DeFanti, Efficient anti-aliased rendering

of 3D-linear fractals. Comp. Graph. 25(4), 91-100 (1991).

4. M. Barnsley and L. Hurd, Fractal Image Compression, AK Peters, Wellesley, MA (1992).

5. H. O. Peitgen, H. Jiirgens, and D. Saupe, Chaos and Fractals, New Frontiers of Science, Springer, Berlin (1992).

6. A. H. Barr, Global and local deformations of solid prim­itives. Comp. Graph. 18(3), 21-30 (1984).

7. H. O. Peitgen and D. Saupe, The Science of Fractal Im­ages, Springer, Berlin (1988).

8. A. Glassner (Ed.), An Introduction to Ray Tracing, Ac­ademic Press, New York (1989).

9. J. T. Kajiya, New techniques for ray tracing procedurally defined objects. Comp. Graph. 17(3), 91-102 (1983).

10. E. W. Jacobs, Y. Fisher and R. D. Boss, Image compres­sion: A study of the iterated transform method, Signal Processing 29, Elsevier Science Publishers, 251-263 (1992).

Page 378: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

408 E. GROLLER

APPENDIX In the following Tables the functions of the IFSs used for

the color plates are given. Each function is defined by distorting a regular initial grid. A table contains the point coordinates of the initial grid (column "initial") and for each function of the IPS the corresponding transformed grid point is given (columns "fl," "f2," • • •)• For reasons of uniformity the linear functions of IPS "plant 1" are given as grid distortions as well (Table 5).

Initial

0.00 0.00 0.00

0.00 0.00

100.00

0.00 33.33 0.00

0.00 33.33

100.00

0.00 66.67 0.00

0.00 66.67

100.00

0.00 100.00

0.00

0.00 100.00 100.00

100.00 0.00 0.00

100.00 0.00

100.00

100.00 33.33 0.00

100.00 33.33

100.00

100.00 66.67 0.00

100.00 66.67

100.00

100.00 100.00

0.00

100.00 100.00 100.00

Table A1. IPS

fl

0.00 0.00 0.00

0.00 0.00

50.00

6.67 • 16.67

4.17

6.67 16.67 45.83

13.33 33.33

8.33

13.33 33.33 41.67

20.00 50.00 12.50

20.00 50.00 37.50

50.00 0.00 0.00

50.00 0.00

50.00

43.33 16.67 4.17

43.33 16.67 45.83

36.66 33.33 8.33

36.67 33.33 41.67

30.00 50.00 12.50

30.00 50.00 37.50

"tapering"

f2

50.00 0.00 0.00

50.00 0.00

50.00

56.67 16.67 4.17

56.67 16.67 45.83

63.33 33.33

8.33

63.33 33.33 41.67

70.00 50.00 12.50

70.00 50.00 37.50

100.00 0.00 0.00

100.00 0.00

50.00

93.33 16.67 4.17

93.33 16.67 45.83

86.67 33.33 8.33

86.67 33.33 41.67

80.00 50.00 12.50

80.00 50.00 37.50

2 X 4 X 2 grid.

f3

25.00 0.00

50.00

25.00 0.00

100.00

31.67 16.67 54.17

31.67 16.67 95.83

38.33 33.33 58.33

38.33 33.33 91.66

45.00 50.00 62.50

45.00 50.00 87.50

75.00 0.00

50.00

75.00 0.00

100.00

68.33 16.67 54.17

68.33 16.67 95.83

61.67 33.33 58.33

61.67 33.33 91.67

55.00 50.00 62.50

55.00 50.00 87.50

f4

25.00 50.00 25.00

25.00 50.00 75.00

31.67 66.67 29.17

31.67 66.67 70.83

38.33 83.33 33.33

38.33 83.33 66.67

45.00 100.00 37.50

45.00 100.00 62.50

75.00 50.00 25.00

75.00 50.00 75.00

68.33 66.67 29.17

68.33 66.67 70.83

61.67 83.33 33.33

61.67 83.33 66.67

55.00 100.00 37.50

55.00 100.00 62.50

Table A2. IPS

Initial

-60.10 -25.00 -60.10

-60.10 -25.00 110.10

-60.10 8.33

-60.10

-60.10 8.33

110.10

-60.10 41.67

-60.10

-60.10 41.67

110.10

-60.10 75.00

-60.10

-60.10 75.00

110.10

110.10 -25.00 -60.10

110.10 -25.00 110.10

110.10 8.33

-60.10

110.10 8.33

110.10

110.10 41.67

-60.10

110.10 41.67

110.10

110.10 75.00

-60.10

110.10 75.00

110.10

fl

-42.50 -25.00 -42.50

-42.50 -25.00

42.50

-52.05 -8.33

-30.05

-30.05 -8.33 52.05

-58.06 8.33

-15.56

-15.56 8.33

58.06

-60.10 25.00 0.00

0.00 25.00 60.10

42.50 -25.00 -42.50

42.50 -25.00

42.50

30.05 -8.33

-52.05

52.05 -8.33 30.05

15.56 8.33

-58.06

58.06 8.33

15.56

0.00 25.00

-60.10

60.10 25.00 0.00

"twisting,"

f2

7.50 -25.00 -42.50

7.50 -25.00

42.50

-2.05 -8.33

-30.05

19.95 -8.33 52.05

-8.06 8.33

-15.56

34.44 8.33

58.06

-10.10 25.00 0.00

50.00 25.00 60.10

92.50 -25.00 -42.50

92.50 -25.00

42.50

80.05 -8.33

-52.05

102.05 -8.33 30.05

65.56 8.33

-58.06

108.06 8.333 15.56

50.00 25.00

-60.10

110.10 25.00 0.00

2 X 4 X 2 grid.

O

-17.50 -25.00

7.50

-17.50 -25.00

92.50

-27.05 -8.333

19.95

-5.05 -8.33 102.05

-33.06 8.33

34.44

9.44 8.33

108.06

-35.10 25.00 50.00

25.00 25.00

110.10

67.50 -25.00

7.50

67.50 -25.00

92.50

55.05 -8.33 -2.05

77.05 -8.33 80.05

40.56 8.33

-8.06

83.06 8.33

65.56

25.00 25.00

-10.10

85.10 25.00 50.00

f4

-17.50 25.00

-17.50

-17.50 25.00 67.50

-27.05 41.67 -5.05

-5.05 41.67 77.05

-33.06 58.33 9.44

9.44 58.33 83.06

-35.10 75.00 25.00

25.00 75.00 85.10

67.50 25.00

-17.50

67.50 25.00 67.50

55.05 41.67

-27.05

77.05 41.67 55.05

40.56 58.33

-33.06

83.06 58.33 40.56

25.00 75.00

-35.10

85.10 75.00 25.00

Page 379: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Nonlinear iterated function systems 409

Initial

0.00 0.00 0.00

0.00 0.00

50.00

0.00 0.00

100.00

0.00 100.00

0.00

0.00 100.00 50.00

0.00 100.00 100.00

50.00 0.00 0.00

50.00 0.00

50.00

50.00 0.00

100.00

50.00 100.00

0.00

50.00 100.00 50.00

50.00 100.00 100.00

100.00 0.00 0.00

100.00 0.00

50.00

100.00 0.00

100.00

100.00 100.00

0.00

100.00 100.00 50.00

100.00 100.00 100.00

Table A3.

fl

0.00 0.00 0.00

0.00 20.32 25.00

0.00 22.22 50.00

0.00 50.00 0.00

0.00 60.16 25.00

0.00 61.11 50.00

25.00 20.32 0.00

25.00 22.09 25.00

25.00 22.22 50.00

25.00 60.16 0.00

25.00 61.05 25.00

25.00 61.11 50.00

50.00 22.22 0.00

50.00 22.22 25.00

50.00 22.22 50.00

50.00 61.11 0.00

50.00 61.11 25.00

50.00 61.11 50.00

IFS "fantasy," 3 X 2 X 3 grid.

f2

50.00 22.22 0.00

50.00 22.22 25.00

50.00 22.22 50.00

50.00 61.11 0.00

50.00 61.11 25.00

50.00 61.11 50.00

75.00 20.32 0.00

75.00 22.09 25.00

75.00 22.22 50.00

75.00 60.16 0.00

75.00 61.05 25.00

75.00 61.11 50.00

100.00 0.00 0.00

100.00 20.32 25.00

100.00 22.22 50.00

100.00 50.00 0.00

100.00 60.16 25.00

100.00 61.11 50.00

B

50.00 22.22 50.00

50.00 22.22 75.00

50.00 22.22

100.00

50.00 61.11 50.00

50.00 61.11 75.00

50.00 61.11

100.00

75.00 22.22 50.00

75.00 22.09 75.00

75.00 20.32

100.00

75.00 61.11 50.00

75.00 61.05 75.00

75.00 60.16

100.00

100.00 22.22 50.00

100.00 20.32 75.00

100.00 0.00

100.00

100.00 61.11 50.00

100.00 60.16 75.00

100.00 50.00

100.00

f4

0.00 22.22 50.00

0.00 20.32 75.00

0.00 0.00

100.00

0.00 61.11 50.00

0.00 60.16 75.00

0.00 50.00

100.00

25.00 22.22 50.00

25.00 22.09 75.00

25.00 20.32

100.00

25.00 61.11 50.00

25.00 61.05 75.00

25.00 60.16

100.00

50.00 22.22 50.00

50.00 22.22 75.00

50.00 22.22

100.00

50.00 61.11 50.00

50.00 61.11 75.00

50.00 61.11

100.00

f5

25.00 100.00 25.00

25.00 100.00 50.00

25.00 100.00 75.00

25.00 61.05 25.00

25.00 61.11 50.00

25.00 61.05 75.00

50.00 100.00 25.00

50.00 100.00 50.00

50.00 100.00 75.00

50.00 61.11 25.00

50.00 61.11 50.00

50.00 61.11 75.00

75.00 100.00 25.00

75.00 100.00 50.00

75.00 100.00 75.00

75.00 61.05 25.00

75.00 61.11 50.00

75.00 61.05 75.00

Table A4. IFS "plant 2," 2 X 4 X 2 grid.

Initial

-21.20 -20.00 -23.37

-21.20 -20.00

23.37

-21.20 -6.67

-23.37

-21.20 -6.67 23.37

-21.20 6.67

-23.37

-21.20 6.67

23.37

-21.20 20.00

-23.37

-21.20 20.00 23.37

21.20 -20.00 -23.37

21.20 -20.00 23.37

21.20 -6.67 -23.37

21.20 -6.67 23.37

21.20 6.67

-23.37

21.20 6.67

23.37

21.20 20.00

-23.37

21.20 20.00 23.37

f l a. f3 f4

-2.10 -20.00 -0.10

-10.00 0.00

-10.00

-7.07 -17.07 -10.00

12.20 -17.07 -1.12

-2.10 -20.00

0.10

-10.00 0.00

10.00

-7.07 -17.07 10.00

-5.12 -17.07 -11.12

0.90 -13.33 -0.10

-8.00 6.67

-10.00

-11.79 -12.36 -10.00

14.55 -13.36 -5.21

0.90 -13.33

0.10

-8.00 6.67

10.00

-11.79 -12.36 10.00

-2.77 -13.36 -15.21

-1.10 -6.67 -0.10

-10.00 13.33

-10.00

-16.50 -7.64

-11.00

16.91 -5.64 -9.29

-1.10 -6.67 0.10

-10.00 13.33 10.00

-16.50 -7.64

9.00

-0.41 -5.64 -19.29

-0.10 0.00

-0.10

-8.00 20.00

-10.00

-21.21 -2.93 -7.00

19.27 -2.93 -13.37

-0.10 0.00 0.10

-8.00 20.00 10.00

-21.21 -2.93 13.00

1.95 -2.93

-23.37

2.10 -20.00 -0.10

10.00 0.00

-10.00

7.07 -2.93 -10.00

5.12 -2.93 11.12

2.10 -20.00

0.10

10.00 0.00

10.00

7.07 -2.93 10.00

-12.20 -2.93

1.12

1.10 -13.33 -0.10

12.00 6.67

-10.00

2.36 1.79

-10.00

7.48 0.79 7.04

1.10 -13.33

0.10

12.00 6.67

10.00

2.36 1.79

10.00

-9.84 0.79

-2.96

-0.90 -6.67 -0.10

10.00 13.33

-10.00

-2.36 6.50

-11.00

9.84 8.50 2.96

-0.90 -6.67 0.10

10.00 13.33 10.00

-2.36 6.50 9.00

-7.48 8.50

-7.04

0.10 0.00

-0.10

12.00 20.00

-10.00

-7.07 11.21

-7.00

12.20 11.21

-1.12

0.10 0.00 0.10

12.00 20.00 10.00

-7.07 11.21 13.00

-5.12 11.21

-11.12

f5

-5.12 -17.07 11.12

12.20 -17.07

1.12

-2.77 -13.36 15.21

14.55 -13.36

5.21

-0.41 -6.64 19.29

16.91 -6.64

9.29

1.95 1.07

23.37

19.27 1.07

13.37

-12.20 -2.93 -1.12

5.12 -2.93 -11.12

-9.84 0.79 2.96

7.48 0.79

-7.04

-7.48 7.50 7.04

9.84 7.50

-2.96

-5.12 15.21 11.12

12.20 15.21 1.12

Page 380: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

410 E. GROLLER

Initial

-42.43 -40.00 -23.37

-42.43 -40.00

23.37

-42.43 40.00

-23.37

-42.43 40.00 23.37

42.43 -40.00 -23.37

42.43 -40.00

23.37

42.43 40.00

-23.37

42.43 40.00 23.37

Table A5.

fl

-0.20 -40.00

-0.20

-0.20 -40.00

0.20

-0.20 0.00

-0.20

-0.20 0.00 0.20

0.20 -40.00

-0.20

0.20 -40.00

0.20

0.20 0.00

-0.20

0.20 0.00 0.20

IFS "plant 1,"2 X2 X 2 grid.

f2

-20.00 0.00

-20.00

-20.00 0.00

20.00

-20.00 40.00

-20.00

-20.00 40.00 20.00

20.00 0.00

-20.00

20.00 0.00

20.00

20.00 40.00

-20.00

20.00 40.00 20.00

f3

-14.14 -24.14 -20.00

-14.14 -24.14

20.00

-42.43 4.14

-20.00

-42.43 4.14

20.00

14.14 4.14

-20.00

14.14 4.14

20.00

-14.14 32.43

-20.00

-14.14 32.43 20.00

f4

24.39 -24.14

-2.25

-10.25 -24.14 -22.25

38.53 4.14

-26.74

3.89 4.14

-46.74

10.25 4.14

22.25

-24.39 4.14 2.25

24.39 32.43 -2.25

-10.25 32.43

-22.25

f5

-10.25 -24.14

22.25

24.39 -24.14

2.25

3.89 4.14

46.74

38.53 4.14

26.74

-24.39 4.14

-2.25

10.25 4.14

-22.25

-10.25 32.43 22.25

24.39 32.43 2.25

Page 381: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved

Part VI. Computer Art

Opinions have always been mixed about whether or not fractal computer graphics are art. For example, Roger James, a fluid dynamics programmer at Pratt and Whitney, wrote to me:

Art is the creation of the mind, an idea. A painting, a piece of music, or a sculpture is only the embodiment of that idea. Turning an idea into a work of art is a skill. There must be a direct relationship between what the observer senses and the original idea. You have to see exactly what the artist saw. Choosing coloration for Julia, Mandelbrot, and other fractal patterns is not art because the "artist" saw an equation and a set of rules, while the observer sees a colorful rendering of the Julia set. It may be interesting to look at, but it is not art.

Tom McMillan, Editor of Resolution, has a different view:

Art affects the sense of beauty, and we all know that beauty is in the eye of the beholder. Try as he or she might, an artist is not an artist unless his or her work affects someone else's sense of beauty. The so-called art world tends to discredit art in the computer graphics medium, making it difficult for artists even to get an audience. While [computer art] may not rank up there with Monet's paintings, it nonetheless does affect my sense of beauty.

You may decide for yourself if the images in this book should be considered high-quality art. I look forward to hearing from readers. See my web site for some of the latest information on fractal art and for web sites on fractals and chaos: http://sprott.physics.wisc.edu/pickover/home.htm. Also see the Usenet newsgroup sci.fractals for more references to chaos, fractals, and art. For a fascinating web exploration of fractal art by many different artists, see the webring "The Infinite Fractal Loop" at http://vv^w.fractalus.com/ifl/.

If Leonardo da Vinci were alive today, would he forsake canvas and brush for a computer terminal? Would he be interested in fractals and chaos? Even if Leonardo could not obtain funding from the National Science Foundation or the National Endowment for the Arts, he could - with just a personal computer - create, manipulate, and store sophisticated art works. Colors could be mixed and chosen from a palate of millions of different hues. Screen resolution could emulate the grit of the canvas. His colleagues from around the world could receive his images over the world wide web for their comment and collaboration. Probably Leonardo would spend a large amount of his time inventing entirely new computer input devices to substitute for today's standard mouse. These devices would allow him to precisely emulate his own masterful brush stokes, the viscosity and drip of wet paint, or a chisel chipping away at an imaginary chunk of shiny marble. Within the next decade, personal computers will increasingly feature hands-on manipulation of computer-generated images along with tactile sensations and force feedback. Artists such as Leonardo will work within an artificial reality, where computer sensors measure the position of the head, and track eye and hand movements. Voice recognition programs will allow Leonardo to make voice requests, and special goggles will allow him to peer into colorful new worlds limited only by computers and the imagination.

Today, computer graphics has become indispensable in countless areas of human activity -from colorful and lighthearted television commercials, to strange new artworks, to evolutionary biology, to processed images from the edges of the known universe. Whether advertising a commercial product, visualizing complicated data, or creating art just for fun, computer graphics allows human creativity and imagination to soar in ways never before possible. I

413

Page 382: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

414

conclude this introduction by adding my voice to the chorus of others who suggest there is often a fine line between science and art. Sven G. Carlson in his letter to Science News says it well:

Art and science will eventually be seen to be as closely connected as arms to the body. Both are vital elements of order and its discovery. The word "art" derives from the Indo-European base "ar", meaning to join or fit together. In this sense, science, in the attempt to learn how and why things fit, becomes art. And when art is seen as the ability to do, make, apply or portray in a way that withstands the test of time, its connection with science becomes more clear.

Page 383: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 415

Chaos and Graphics

AUTOMATIC PARALLEL GENERATION OF AEOLIAN FRACTALS ON THE IBM POWER

VISUALIZATION SYSTEM

CLIFFORD A. PICKOVER

IBM T. J. Watson Research Center, Yorktown Heights, NY 10598, USA

Abstract—Simple approaches to pattern generation using a parallel graphics computer are described. Using these methods, a computer can automatically select parameters and generate a large collection of diverse, aesthetically appealing fractal patterns. Computational recipes are included to encourage reader involvement. The described approaches will work using inexpensive personal computers, although computations done in parallel provide for much quicker generation.

1. INTRODUCTION

Science is not about control. It is about cultivating a perpetual condition of wonder in the face of something that forever grows one step richer and subtler than our latest theory about it. It is about reverence, not mastery.

Richard Powers, The Gold Bug Variations

The line between science and art is a fuzzy one; the two are fraternal philosophies formalized by ancient Greeks like Eratosthenes and Aristophanes. Computer graphics and mathematics help reunite these philoso­phies by providing scientific ways to represent natural and artistic objects [ 1 ].

This informal paper concerns the generation of mathematically and visually interesting patterns from formulas implemented on a parallel graphics super­computer. One of the most interesting challenges for those interested in aesthetic pattern formation by computational means is the development of algorithms for the automatic generation of interesting forms. The simple methods described here virtually guarantee users an infinite collection of attractive structures with only minimal user input. When human input is desired it usually only involves changes to the image boundaries and slight modifications to coloration. Aside from the artistic appeal of this approach, there is a more sci­entific, practical side to such explorations because the images reveal and characterize the intricate behavior of algebraic transformations in the complex plane.

The mathematics of the iteration of algebraic func­tions has been studied for many years. However, the striking beauty and complexity of patterns resulting from such iterative calculations has only been explored in detail within the last decade or two due, in part, to advances in computer graphics. B. Mandelbrot has been initially responsible for extending the theory and graphic presentation of iterated functions as a special class of the new geometry known as fractal geome­try [2]. Fractals represent objects or patterns that ap­pear "self-similar"; i.e., no matter what scale is used to view the pattern, the magnified portion of the fractal shape looks similar to the original pattern. Structures repeat at all size scales.

The following section describes a preferred hardware and software environment for computational speed, although the methods described in this paper will work on standard personal computers.

2. HARDWARE AND SOFTWARE OVERVIEW

Like the legal process of binding arbitration, all programming languages are a compromise between the way the programmer or user 'capitalist' thinks about solving a problem and the way the computer "laborer" actually goes about solving it.

Bill Caffery, The Gartner Group

Various software and hardware options facilitated the rapid generation of the high-resolution, high-iter­ation fractal images in this paper. The software for fractal generation was designed to run on 8 to 32 pro­cessors in parallel using a custom C-language program making Express calls on a graphics supercomputer known as an IBM Power Visualization System (PVS). Express (ParaSoft Corporation, Pasadena, CA, USA) is a software package addressing all phases of the par­allel application development cycle in an architecture independent manner.

The PVS consists of a computational server, attached disk array, and high-resolution video display controller. The server uses up to 32 RISC processors operating in parallel for computation. HiPPI (High Performance Parallel Interface) output from a PVS I/O processor drives a PVS Video Controller to provide real-time video output (Fig. 1). The PVS model 4 uses Intel i860XP processors. Each processor is tightly coupled with 16 MB of private local memory and can address up to 2GB of shared memory over a high bandwidth internal bus. Fractal images may be stored on a 21GB disk array which is HiPPI-attached to the server. The disk array uses parallel transfer to disks for optimum performance (transfer rate up to 5 5 MB/second).

3. MATHEMATICAL BACKGROUND

I computed all of the intricate Julia sets J{fc) in this paper by iterating the map

X: C ^ C, z„+, = zl-\- c, cGC (1)

Reprinted from Comput. & Graphics Vol 18, No. S, pag. 407-416, 1994

Page 384: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

416 C. A. PiCKOVER

Mainframe/Supercomputer

Disk Array Subsystem

Video Controller

Fig. 1. Configuration of the Power Visualization System.

for complex values of z and c. For a given value of c, the set of initial values ZQ for which z„ are bounded form the "filled-in Julia set." (The Julia set is the boundary of the filled-in Julia set.) Computer experi­ments have shown that different values of c can lead to a beautiful variety of Julia sets, minute changes in c often causing enormous changes in the shape of the Juliaset[l,2, 3, 4, 5, 6].

As is well-known, if the value of c is chosen outside the Mandelbrot set (denoted by M) for the self-squaring process in Eq. (1), infinity is the only attractor, and the Julia set dissolves into a cloud of points variously known as Fatou dusts[4], "floating-dust" Cantor sets [ 6 ], and Cantor dusts [ 3 ]. Mathematically speak­ing, this means that when the Julia set is a disconnected dust, the iteration in Eq. (1) has no attractive periodic points. The dust of points becomes thinner the farther c is from the Mandelbrot set. (It can be shown that if I c| > 2 then J{fc) is guaranteed to be "totally discon­nected" [5].) If c is near the boundary of Af, the dust makes fascinating figures, always fractal, self-similar and exhibiting chaotic dynamics.

In the method described here, I concentrate on re­gions near the Af cardioid and prominent circular disc abutting the cardioid. If c is in the main cardioid of M, then the Julia set is a simple closed curve. Such curves are sometimes referred to as quasi-circles [ 5 ]. (Jifc) will be a fractal curve if | c| > 0). If c is in the circular disc defined by | c + 11 < | then the iteration in Eq. (1) has an attractive periodic orbit of period 2. Pinch points exhibited by these "period-2" Julia sets make the Julia sets topologically more complicated than those in the cardioid case.

4. AUTOMATED GENERATION OF AEOLIAN FORMS

Then began the Aeolian Harp of the Creation to tremble and to sound.

Carlyle, 1869

The procedure for implementing a computer search for interesting Julia sets is straightforward. I call this

approach the "cardiodisc" method for reasons that will become clear. First, choose a random angle 6 on the cardioid defined by

r= aX[\ -cos(0)] +0.25

(Various values for a are discussed in following para­graphs.) Note that since the quantity ds/dB is constant only for a circle (where s is the circumference, and 6 the polar angle) the random selection of ^ values from a uniform distribution between 0 and 27r will not yield a uniform distribution along the circumference of the cardioid. In general, for polar coordinates, we expect:

^V('-(f)) In fact, a quick Monte Carlo demonstration of the re­sultant nonuniform probability distribution function is illustrated in Fig. 2a where one million random 6 values were selected, and then the distribution of radii in a cardioid defined by r = .5 X [1 + cos(^)] plotted. Even though the probability peaks at both ends, this does not imply that points will be sampled with equal frequency at both ends as shown in Fig. 2b. Figure 2b illustrates this by showing points for equal-spaced Q values. In fact, there is a higher sampling near the pinch point (r = 0). This higher concentration of sample points near the pinch point is useful for the automatic generation of fractals because it is in this region that some of the most visually interesting structures are manifested at a given magnification.

The entire iteration in Eq. 1, expressed in real (x) and imaginary (y) components in a computer program, therefore becomes:

w = x^ - / + a[( 1 - cos(^)] X cosiS) + .25

y=2xy-\- a[\ - cos(^)]sin(^)

X = W.

We also wish to perform the iteration for 6 values on a circular disc centered at — 1:

w = jc - y^ + a cos(^) - 1

y = Ixy -\- a sin(^)

X = w

for each (x, y) pair in the complex plane. In a computer program, the values of cos B and sin B are precomputed outside the standard iteration loops for computational efficiency. The use of a = 0.5 and a = 0.25 for the cardioid and disc respectively would correspond to a perfect outline of the body and disc of the M-set.

We desire that the computer automatically choose points slightly outside the M-set cardiodisc in order to encourage the formation of Cantor dusts, which tend to have a visually more complex structure than con­nected forms. Therefore, for the cardioid, I use a '^

Page 385: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic parallel generation of Aeolian fractals 417

(a)

(b)

40500

w 36000

i 31500

g 27000

2 22500 I 18000 E 13500

^ 9000

4500 n

1 1 1 1

1 Elephant Valley

1 1 1 1

1 1 1 1 1 1

4 Seahorse Valley _[

1 _ _ _ — — - ^

1 1 1 1 1 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0

Radius

Probability Distribution Function

u./u

0.56

0.42

0.28

0.14

0.00

-0.14

-0.28

-0.42

-0.56

1 1 1 1 1 1 1 1 1 •.

• • • • • • •

• • •

• • • •

• • •

• • • • • •

• •

< • • • • • • • • • • • • • • •

• • •• • •

' • • ••* 1 1 1 1 1 1 1 1 1 -0.90 -0.76 -0.62 -0.48 -0.34 -0.20 -0.06

X Cardioid Sampling

0.08 0.22 0.36 0.50

Fig. 2. Sampling the cardioid. (a) The nonuniform cardioid probability distribution function is easily illustrated in a Monte Carlo simulation (see text) for r = .5[1 + cos(^)]. (Equal sized r bins are used to create this plot.) Note the naturally high probabilities at the cardioid pinch point {r = 0) and opposite smooth end of the cardioid (r = 1). These regions correspond to the "Elephant Valley" and the "Sea Horse Valley" regions of the M cardioid defined by r = a[l — cos(^)] -f 0.25. (These regions have been so-named in the scientific literature {e.g., [11]) because many structural features in Sea Horse Valley vaguely resemble sea horses and their tails. Those in Elephant Valley sometimes remind viewers of elephantine forms.); (b) Uniform 6

sampling of the cardioid leads to higher point density near r = 0.

0.52. (This corresponds to the second inner circum­ference in Fig. 3.) For the circle, I prefer a ^ 0.252. You may like to think of the various rings in Fig. 3 as ascending energy levels in which the probability of chaotic fragmentation increases for each successive level. As one explores the different a levels for a par­ticular value of 6, a startling metamorphosis of forms occurs. You will certainly wish to try different values for a, although much higher values will usually lead to forms too sparse to be visually interesting. The

probability of selecting a "good" c value by random searching of the complex plane can be estimated by comparing appropriate areas of the complex plane. For example, the area of the dust-strewn region around the cardioid for (.5 > a > .52) is easily estimated from 3/27r(a2 ~ «?)• By contrast, sampling uniformly and randomly over the much larger bounding area (—2 > Re(c)> 1 ) , ( - 1 . 5 > Im{c)> 1.5) would yield a very small percentage of visually interesting forms. There­fore, the cardiodisc approach appears to provide a sen-

Page 386: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

418 C. A. PiCKOVER

1.5

0.9

0.3

-0.3

-1.2

-

-

1 1 1 1 No Attractive Orbits (The Land of Dust)

;;|[ P 2 ;; NlV

1 1 1 1

1 1 1 1

Period 1 1

Area = 3/2na^ J

{The Land of \ Quasi-Circles) 1

1 1 1 1

-

1 -2.0 -1.7 -1.4 -1.1 -0.8 -0.5 -0.2 0.1

X

How to Generate Aeolian Fractals

0.7 1.0

Fig. 3. Cardiodisc method for Aeolian art forms, a is 0.5, 0.52, 0.54, 0.56, 0.58, and 0.6 for the cardioid, and 0.25, 0.27, 0.31, 0.33, and 0.35 for the disc. In practice, I usually used a = .52 for the cardioid and a = 0.252 for the disc. Higher a values (dotted lines) lead to uninteresting, sparse Julia sets. Note that any starting values within the central cardioid are attracted to a period 1-orbit. Those in the disc have a period

2-orbit.

sitive test for excluding the vast majority of uninter­esting cases that would result from a random choice of c.

Of course, even with a > 0.5 and a > 0.25 for the cardioid and circle respectively, sometimes a randomly selected point will lie within M {e.g., on a small bud) where J(fc) is connected, or at a neck (e.g., where a bud touches a parent region that produces a Julia set with tendrils), or on one of the hairs of M that produces a dendritic tree-like form. Other possibilities are dis­cussed in [5 ] . What term then shall we use for the plurality of predominately dusty forms near the boundary of M for the given a values (denoted by M«)? When showing the images to artists friends, they often made remarks as to their dusty, atmospheric, wind-blown look. Therefore, I've called the shapes Aeolian fractals after Aeolus, the Greek god of the winds in classical mythology. (According to most dic­tionaries, "Aeolian" has come to mean "produced as if by the wind." Interestingly there exist all kinds of natural Aeolian structures such as "Aeolian geological formations"—rocks accumulated by the drifting action of the winds.)

To enhance the quality and connectivity of struc­tures in the images and visually bring out various fine structures, I used a computational technique called the "Milnor-Thurston distance estimator method" [3 ] . For M, one can estimate the distance d from a point c to the boundary of M by

(The derivation for this formula is discussed in [3] , which also presents Pascal-like pseudocode.) A similar approach can be used for Julia sets. In a practical im­plementation of Eq. (2) in a program, various threshold and overflow parameters are set to efficiently carry out this computation (see Appendix A) . In practice, we must save the orbit {Zo, Zi, Z2,. . . , } and compute the derivative z' of the real and imaginary parts of the orbit as outlined in the pseudocode.

I find it most useful to have the computer assign the final values of the image array A for the Julia set as follows:

A = rO, '\{d{zo)<b

[min[255, logio(m) X s)]

d{zo, Jc) = 2 — 7 - l n | z J . (2)

where m is the iteration count (see Appendices). (Note that for c outside the A/-set, the filled-in Julia set and the Julia set are the same set.) Here d = r X {xmax -xmin)/{nx - 1) where nx is the image resolution in the A'-direction, xmax and xmin are the high and low X-values of an image window, and r ~ 0.001. By de­fault, the program uses picture boundaries of ( - 1 > x > 1) and ( - 1 > y> 1), which always yield interesting images. The user is then free to quickly magnify regions of particular interest if desired. Table 1 gives a sampling of c and r values, which produce intriguing Julia sets. The number of iterations used for the images ranged from 1000 to 8000. Except for a few values in Table 1 (see Acknowledgments), all values were generated using the Aeolian approach. In a computer program.

Page 387: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic parallel generation of Aeolian fractals 419

Table 1. Typical parameters.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57

Real

-.7499385 -.749940 -.15652 -.773998 -.763715 -.198616272 -.742575 -.14347945 -.803861 .27914

-1.251 .372233 .012809 .237555 .261248 .369591 .272038 .377575 .279875

-.756138 -.793179

-1.25259 -.76540 -.821962 -1.244433 -1.253 -1.252504 -.833830 -.760809 -.805695 -1.248875 -1.006340 .-.892487 -1.144088 -.749049 -.747699 -.751449 -.749989 -.742806 -.750109 -.749388 -.747950 .252094 .252235 .251341 .252368

-.03249108 .4052405

-.74858089 .37953073

-.09571678 -.194 -.481762 .2739

-.39054 -.38 .279132

Imaginary

0.0169434 0.0169316 1.032247 .112351 .094920 1.100346063 .208924

-1.0189654 .17854

-.60527 .010877295

0.271274 .655364

-.532015 -.002406 -.143015 -.006791 .266555

-.010962 -.067383 .145719

-.014401 -.094844 .179754

-.065279 .000484

-.015757 -.190779 .082441

-.162033 -.045499 .250420 .229020

-.207961 -.067997 -.075680 -.027124 -.016770 -.099015 -.010990 -.032905 -.054731 .000189 .000208 .000097 .000227 .79245342 .1467907 .06360646 .20567030 .65403036 .6557

-.595 .00742

-.6 -.6 .473906

Tau

.0001

.001 1 .01 .01 .007 .05 .1 .05 .05 .00001 .005 .01 .01 .0001 .0001 .0001 .0001 .00001 .01 .01 .001 .015 .0001 .005 .005 .005 .005 .005 .005 .005 .005 .005 .005 .005 .005 .00005 .00005 .000005 .005 .000005 .000005 .000005 .000005 .000005 .000005 .001 .001 .001 .001 .001 .001 .001 .001 .01 .01 .01

A is an output array in which each array element is one byte, s is scale factor typically around 77 for the images in this article. Array elements that have value 0 correspond to black regions. Code Fragment 1 (Ap­pendix A) shows an implementation of this in the pro­gramming language C. Code Fragment 2 (Appendix B) shows the main loop structure for carrying out Eq. (1) in parallel on a number of nodes for a set of values in the complex plane. Note the relative ease with which a programmer using Express language conventions may

partition the job over an arbitrary number of nodes, n Nodes.

The final step in aesthetic Aeolian fractal presen­tation involves the automated mapping of escape times (image array values A) to color. To achieve rapid data coloration, custom software was used which runs on an IBM RISC System/6000 using the GL programming interface. The program selects a waveform for the red, green, and blue color components in RGB space. The frequency /may be user-determined but the phase 0 is random. For gradual (smooth) mappings, three sine waves are used (Fig. 4). If more discontinuous maps are desired, various ramps and truncated sines may be used for each of the RGB components:

\p = AX 127 X [sin(/X / + 0) + 1.], (sine wave)

\P=AX256X [|(sin(/X / + (/))|],

(sharpened sine)

\P =AX256X max[0, (sin(/X / + 0))],

(truncated sine)

4/ = AX (256/5) X mod(/ + 0, s),

(ramp, sawtooth)

where s = fX (160/.02). Here 0 < / < 255, corre­sponding to 255 entries in a 255 X 3 color table.

In this manner, an infinite variety of interesting color look-up tables are generated where coloration gives an indication of the rate of explosion for initial points in the complex plane. This waveform approach using random phases, of course, does not produce a color table filled with random numbers because the use of sinusoids naturally forces correlations between neigh­bor values in the color table. These correlated values are much more useful artistically, and for the purpose of revealing structures of the Julia set, than "white" noise tables. If desired, the user may have the computer generate and step through hundreds of random-phase tables and in real-time select the one with greatest ap­peal. For greater artistry, or to reveal structures in the map not as obvious with the automatic tables, the user may intervene and use a mouse to conveniently add or subtract Gaussians of a particular width and position to alter the RGB curves. In my program, 3-mouse but­tons alter the red, green, and blue maps, respectively. The width of the Gaussian is controlled by arrow-keys, and the color table is displayed on screen using three overlapping colored curves (intensity vs. position in color table) that change shape upon modification. GL calls to a high performance hardware board facilitate rapid 24-bit color selection.

Figure 4 shows a graphical representation of a typical RGB color look-up table for phase-shifted sinusoids. The solid line in the graph represents luminosity (in­tensity) defined by L = 0.30 X R-^ 0.59 X G + 0.11 X B.{L would be the component of a color TV signal that would be shown on black and white TV). Using

Page 388: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

420 C. A. PiCKOVER

\ \

/ / . /

V. y\ \ I '\ i>-'y I 26 51 77 102 128 154 179 205 230 256

Image Value

Typical Color Map

Fig. 4. A typical RGB color look-up table for three phase-shifted sinusoids. (Dotted, red; dashed, green; dot-dash, blue; solid, luminosity response curve).

three equal-frequency sinusoids, the resultant lumi­nosity usually changes in a useful way for an image. For example, for the most interesting images, both bright and dark areas should be present in the same image. The use of three equal-frequency sinewaves guarantees a sinusoidal luminosity response curve whose frequency is equal to the RGB frequencies but whose amplitude is determined by

a = ([0.30 cos((/),) + 0.59 cos((/)2) + 0.11 cos((/)3)]^

+ [0.30 sin(0,) + 0.59 sin(02) + 0.11 sin((/)3)]2)-'/^

and whose phase is determined by

tan(0)

[0.30 sin(0i) +0.59 sin(</)2) + 0.11 sin(</)3)] " [(0.30 cos((/),) +0.59 cos((/)2) +0.11 cos((/)3)]

(To derive this, recall that B sm(x -\- y) = B X sin(j\:)cos(>^) + B cos(x)sin(>^).) An interesting future experiment would be to determine a useful luminance contour, for example one that highlights a region of interest, and then have the computer automatically step through different RGB sinusoids that produce the target luminance curve.

5. IMPLICATIONS

Parallel Processing is the Heimlich maneuver on the Von Neumann bottleneck.

Bill Caffery, The Gartner Group

The idea that mathematics, pattern, and art are in­extricably linked is not new—and neither is the ap­plication of that idea in computer graphics. What is special is the use of rich software tools and powerful new hardware to quickly visualize mathematical forms

in an automatic fashion. Like an Aeolian harp—a stringed instrument that produces musical sounds on exposure to the winds—a parallel computer allows mathematicians, artists, and programmers to produce visually-interesting structures with little effort (see Fig. 5). Using the Power Visualization System, I was able to compute, store, and display low-resolution images in fractions of a second, and then store and print the most interesting Julia sets at higher resolution. Using typical parameters (e.g., 15 processors, 1600 X 2400 resolution, 1000 iterations) a high-resolution, high-it­eration image required approximately 2 minutes of elapsed time. (This time included computation of the distance estimator, disk storage, and screen display over a network.) For this paper, the images were subse­quently converted from a 1-byte/pixel image with a color look-up table to a postscript file, and imaged on a 35 mm slide via a Matrix QCR camera. Printing and format conversion were done in a parallel batch mode, so that the printing process did not delay additional Julia set computation.

To artists and computer graphics programmers, the automated generation of Aeolian Julia sets has great appeal because the speed with which the structures can be generated allows the human analyst the freedom to experiment with many parameters and even make mistakes. (Imagine typing in a "wrong" parameter, and waiting a day to find the resultant screen all black.) The dust-producing cardiodisc approach using random angles allows users to conveniently select from an in­finite reservoir of magnificent shapes.

Students and teachers will enjoy such an approach as they explore and demonstrate the complexity and chaos associated with simple formulas. Mathematicians may find the approach useful because the sheer number of different structures they can generate and observe has the potential for making complex behaviors ap­parent, which might have been overlooked using tra-

Page 389: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic parallel generation of Aeolian fractals 421

Fig. 5. Examples of Aeolian fractals produced using the methods described in the text.

ditional approaches. Interestingly, the use of parallel processing makes this approach a good example of the "ultimate" image compression method. For example,

the image generation is so fast that I never store the resultant images after they are sent to a printer. I merely regenerate them, as needed, from their single c value.

Page 390: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

422 C. A. PiCKOVER

Fig. 5. (Cont'd.).

"No two are alike!" the saying goes, when describing the intricate patterns found in snowflakes. Likewise, the few illustrations of the fractals here are a small set of the remarkable panoply of structures automatically generated by the algorithm. By "turning a dial" that controls a (or the other parameters in the program fragments), an infinite variety of attractive designs is generated with relative computational simplicity. For this reason, the Aeolian program may be of interest to designers of museum exhibits and other educational displays for both children and adults. Obviously the approach will work using inexpensive personal com­puters, although computations done in parallel provide for much quicker generation.

Interestingly, Professor J. C. Sprott (University of Wisconsin) has recently suggested the use of the Lya-punov exponent, L, as an alternative method for au­tomatically generating interesting Julia sets (personal

communication). He has found that cases with small positive L values (0 > L > 0.2) produce interesting dusts, such as the ones in this paper. He prefers sets that are slightly connected, and these can be found by searching for small negative exponents. This approach uniformly samples all regions of the boundary of the Mandelbrot set and works for mappings other than the self-squaring process. Thus it appears that the Lya-punov exponent method, although conceptually more difficult, also provides a sensitive test for excluding un­interesting cases that would result from a random choice of c over some appropriate interval.

For additional work in the area of automatic gen­eration of aesthetic chaotic structures including dy­namical systems see Sprott [7,8]. The automatic com­puter synthesis of mathematically-based ornamental patterns such as self-decorating Easter eggs, marble patterns, and other chaotic structures [ 9 ] has also been

Page 391: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Automatic parallel generation of Aeolian fractals 423

Fig. 5. (Cont'd.).

discussed in the past. For an informative discussion on the frontiers of parallel programming, and predic­tions for the future, see CafFery[10]. For a Usting of other unusual Julia set c values that produce visually-interesting graphics, see Philip [11].

Acknowledgements—I thank R. Walkup for introducing me to Express, and for his kind and able assistance with paral­lelizing my software. I thank D. Piatt, J. Sprott, T. Jackman, and M. Frame for useful comments. Jay R. Hill suggested the c value for set 3 in Table 1. Ken Philip suggested values for sets 1, 2, 4, 5, and 6 in Table 1.1 maintain a list of interesting c values contributed by researchers. Please contact me for more information or to contribute to the list.

REFERENCES 1. Pickover, C, Mazes for the Mind: Computers and the

Unexpected, St. Martin's Press, New York (1992). 2. Mandelbrot, B., The Fractal Geometry of Nature, Free­

man, New York (1982). 3. Peitegen, H. and Saupe, D., The Science of Fractal Images,

Springer, New York (1988).

10.

Peitgen, H. and Richter, P., The Beauty of Fractals, Springer, New York (1986). Falconer, K., Fractal Geometry, Wiley, New York (1990). Schroeder, M., Fractals, Chaos, Power Laws, Freeman, New York (1991). Sprott, J., Strange Attractors, M&T Books, New York (1993). Sprott, J., Automatic generation of strange attractors. Comp. & Graph. 17, 325-332 (1993). Pickover, C, Chaos in Wonderland, St. Martin's Press, New York (1994). The current paper on Aeolian fractals is number 100 in a "Mathematics and Beauty Series" which emphasizes the aesthetic side of mathematics. Most of the papers in the series have been collected in the fol­lowing books: Pickover, C, Computers, Pattern, Chaos and Beauty, St. Martin's Press, New York (1990); Pick-over, C, Computers and the Imagination, St. Martin's Press, New York (1991); Pickover, C, Visions of the Fu­ture: Art, Technology, and Computing in the Twenty First Century, St. Martin's Press, New York (1994). Caffery, W., Frontiers of parallel processing, MATTER 1(3), 11-55 (1991). {MATTER is published for clients of Advanced Technology Groups by Gartner Group Inc.

Page 392: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

4 2 4 C. A. PlCKOVER

Reprints available from: Gartner Group, 56 Top Gallant Julia set, and higher order spirals. In Spiral Symmetry, I. Road, Stamford CT 06904-2212.) Hargittai, and C. Pickover, (Eds), World Scientific, River

11. Philip, A., The evolution of a three-armed spiral in the Edge, NJ (1992).

APPENDIX A: PROGRAM FRAGMENT 1—DISTANCE ESTIMATOR /* Subroutine to enhance image quality with distance estimator method */ /* Routine called for each point—see Code Fragment 2*/ juliadistO {

int i; double temp; dist = 0; overflow = 1.0e20; huge = 100000; delta = tau*(xmax - xmin)/(res - 1); if(rsq>huge) {

xder = yder = 0; flag = 0; /* The values for m, xorb, yorb and kPix come from Program Fragment 2 */ for(i = 0 ; i < m ; i + + ) {

temp = 2*(xorb[i]*xder - yorb[i]*yder) + 1; yder = 2*(yorb[i]*xder + xorb[i]*yder); xder = temp; if (max(fabs(xder), fabs(yder)) > overflow) flag = 1;

} if (flag = = 0 ) dist = log(rsq)*sqrt(rsq/( xder*xder + yder*yder));

} /* Fill in values for image array, A */ if (dist < delta) A[kPix] = (unsigned char) 0;

else A[kPix] = (unsigned char) min(255, loglO(m)*77); }

APPENDIX B: PROGRAM FRAGMENT 2— MAIN COMPUTATIONAL LOOPS

/* . . . Determine the parallel environment (Express) variables -— */ exparam(&env); nNodes = env.nprocs; /* the number of nodes */ myNode = env.procnum; /* a particular current node */

/* V

res = 1600; xmax = 1; xmin = - 1 ; ymax = 1; ymin = - 1 ; maxit = 1000; /* 3-to-2 aspect ratio used for images */ dx = (xmax - xmin)/(res* 1.5); dy = (ymax - ymin)/res;

/* Number of rows each parallel processor evaluates */ numrows = 3*res/(2*nNodes);

/* Make sure program will work on an arbitrary number of nodes */ if ((3*res/2)%nNodes = = 0 ) pixpernode = 3*res/(2*nNodes);

else pixpernode = 3*res/(2*nNodes) + 1; if (myNode!=nNodes-1) numrows = pixpernode; if (myNode ==nNodes—1) numrows = 3*res/2 - (nNodes—1 )*pixpemode;

xwidth = (xmax-xmin)*pixpernode/(1.5*res); myxmin = xmin-l-myNode*xwidth; myxmax = myxmin-I-xwidth;

/* Allocate space for image array, A */ A = (unsigned char *) malloc(numrows*res*sizeof(char)); kPix = -1 ;

/* Each processor computes a strip in the i direction */ for(i=0, rrz=myxmin; (rrz<=myxmax) && (i < numrows); i+-l-, rrz += dx) {

for(j = 0, iiz = ymin; (iiz<=ymax) && (j<res); j++, iiz += dy) { kPix++; X = 0; y = 0; X = rrz; y = iiz; /* ru and ri were predetermined by cardiodisc method */ for (m=0; m<=maxit; m+-l-){

newx = x*x — y*y+ru; y = 2*x*y+ri; x = newx; x2 = x*x; y2 = y*y; rsq = x2 + y2; /* save orbit values for distance estimator */ xorb[m]=x; yorb[m]=y; if (rsq > huge) goto Break;

} Break: juliadistO;

} }

Page 393: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 425

Chaos and Graphics

JULIA SET ART AND FRACTALS IN THE COMPLEX PLANE

IAN D. ENTWISTLE 44 Woodside Gardens, Sittingbourne, KENT, ME 10 ISG, UK

Abstract—In this paper, computer graphics is used to explore the dynamical behaviour of the Julia sets and related iterated sets derived by using alternative divergence tests.

INTRODUCTION

The study of the dynamics of complex analytical maps started in the early 20th century[1, 2]; however, re­cently there has been renewed interest in this work due in part to advances in computer graphics[3]. The term "chaos" is often used to describe the complicated be­haviour of nonlinear systems, and complex maps are useful in describing certain aspects of dynamical sys­tems exhibiting irregular ("chaotic") behaviour [4, 5 ]. Algorithms for the generation of beautiful and com­plicated structures describing dynamic properties of

complex recursion are currently being studied, and their popularity is evidenced by the proliferating num­ber of articles in the scientific and popular Uter-ature[6, 7].

Patterns resulting from the iteration of complex al­gebraic functions have been described in detail, and probably the best studied (and understood) function has been the self-squaring generator, z ~> z- + /i[3, 6]. One of my goals is to demonstrate how research in iterated complex maps reveals an inexhaustible new reservoir of magnificent shapes and images. Extension

Fig. 3. Plot of a Julia set for z •

Fig. 1. Pattern of a Julia set for z -• z + M with bounded points mapped as minimum values of | z | .

Fig. 2. Pattern of a Julia set for z -* z" + ^ resulting from variation of the value of/x.

Fig. 4. Pattern of a Julia set for z -• (z^ + M)' " M with all points mapped as minimum values of I z j -.

Reprinted from Comput. & Graphics Vol 13, No. 3, pag. 389-392, 1989

Page 394: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

426 IAN D. ENTWISTLE

^^^ I ^UlUii

Fig. 5. Pattern of a Julia set for z - • sinh(r) with bounded points mapped as minimum values of |z |^

of the published methodology into the study of other polynomials and the use of alternative convergence tests have now resulted in a variety of exciting new maps.

GRAPHICS AND OBSERVATIONS

The Julia set for the dynamic / (r ) = z^ -\- n has been widely studied and some of the beautiful images resulting from a boundedness test \Zn\ > 2 have been widely published [ 3 , 8 ] . Fewer studies have been made on the patterns which emerge when alternative tests or additional ones are applied to the values of those numbers which do not diverge, e.g., by trapping the minimum values achieved during the iterative process for each point in the complex plane corresponding to

4tTTTTTrrmtlt1Tk Fig. 7. Magnification of the central part of r -* (:

in map Fig. 6. - A i ) ' - M

Fig. 8. Pattern of z ->• (z^ + ^l)^ + ^ in the complex plane mapping points converging for Izreail" > 10.

Fig. 6. Pattern of a Julia set for z -* (z' 4- ^)^ + ^ using double boundedness tests and low iteration values.

Fig. 9. Pattern of z - • (z^ + M)^ + M omitting mapping of values with low iteration in Fig. 8.

Page 395: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Julia set an and fractals 427

Fig. 10. Pattern resulting from variation of/* in generation of Fig. 8.

a point in the Julia set for z^ + fi, and mapping those values which fall close together alternatively in black or white, produces the maps shown in Fig. 1 ( AI = 0.11, 0.6557i) and Fig. 2 (M = 0.32, 0.043i).

Of more novel interest was the application of this method to the Julia set associated with the generator f(z) = (z^ + M)^ + M. My own study of the M plane set of this function (to be published separately) had yielded points in the fi plane which allowed generation of rather attractive Julia sets, e.g., see Fig. 3 (M = -0.53, O.Oi). Plotting the iterations for minimum values for all points, both divergent and bounded, results in im­ages of the type seen in Fig. 4 (^ = -0.48, O.Oi). This point is inside the n plane bounded set. The points of the bounded set are clearly distinguished.

Fig. 5 (M = -1.1666, -0.808642i) illustrates the use of this method for/(z) = sinh(z) + fi. The algorithms for a Julia set generating the hyperbolic sine function can be constructed by sines and cosines (see Appen­dix). The amount of CPU time to compute (Fig. 5) is very high on the average micro-computer, but access to a machine with 4 MIPS or greater performance.

Fig. 12. Pattern of a Julia set for z -• z + ^ at low iteration values and non-classical test.

even with high level languages, can alleviate this problem.

Earlier studies of complex polynomial iteration have used alternative criteria for convergence to achieve striking images. Using only a few iterations (f) and checking for IZ^zil or IZimagi being less than 10[9, 10]. Applying alternative tests such as these has yielded the new images (Figs. 6-12) from various transfor­mations.

In Fig. 6,/(z) = (z^ + M)^ + M is iterated for M =0.8, -0.2i and testing for convergence successively using I Zreai I + I imag I > 100 and then filtering this for AB­SOLUTE iZreall < 10 or ABSOLUTE |Zin,agl < 10. The number of iterations is 16. Fig. 7 is a magnification of the central part of Fig. 6 and illustrates the fractal nature of these images. If a simplified test is applied, such as I Zreai I ^ > 10, then Fig. 8 is obtained. By omit­ting low iteration points. Fig. 8 becomes Fig. 9. Setting

Fig. 11. Pattern ofz-^(z^-fM)" + M mapped by ignoring low iteration values in Fig. 10.

Fig. 13. Pattern comparable to Fig. 12 for the function z -•

Page 396: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

428 IAN D . ENTWISTLE

Table I.

Function Real part Imaginarv' part

r^ + M

sinh(2) + jj.

- 5 . „

x^ - y^ + a x^ - 3xy^ + a (1) xi-y] + a (2) xl -yl + b 0.5*(e"'^ - e'') 4- cos(>') + a x^ - 10;cV^ + 5 .v / + a

2xv + 6 3x'y -y^ + b (1) 2.x,y,+6 (2) 2x2^. + a -0.5*(e-^ + ^^)*sin(>') + Z7

the value of/x to 0.9, —0.1 i for the same function yields Fig. 10 which, when iteration values up to 4 are ignored, illustrates a "biomorph" [ 10], Fig. 11 resembles an ex­otic snail or a shell fish.

Application of the test |Zreail^ < 100 to the trans­fo rmat ion / ( r ) = z- + /u for f = 14 results in Fig. 12. When this test is used with the transformation/(z) - • z^ + /u, a pentastar is formed (Fig. 13). The low iter­ation numbers required to obtain this type of graphic allow for rapid study of various values for ^i. Of note is the observation that utilising higher iterations, does not change the image, as divergence occurs at low it­eration values, and the image disappears at high iter­ation values.

In order to encourage wider study of the images ob­tainable by the methods briefly alluded to, the Appen­dix contains some more detailed information on the computing techniques and algorithms needed. The basic computer programs for producing maps of po-lynominal functions have been widely reported for computers ranging from Atari to D e c [ l l , 12]. The references [9, 10, 13-15] are useful starting points for discussions of the methods used in this paper.

Acknowledgements—My thanks to the staff of Shell Research Ltd's Sittingboume Research Centre for help with the manu­script and image reproduction.

REFERENCES 1. P. Fatou, Sur I'iteration des fonctions transcendantes en-

tieres. Acta Math 47, 337-370 (1926) . 2. G. Julia, Iteration des applications fonctionnelles. / Math.

Pares Appl. 4, 47-245 (1918) . 3. B. Mandelbrot, The Fractal Geometry of Nature, Freeman,

San Francisco (1982) . 4. P. Fisher and W. Smith, Chaos, Fractals and Dynamics,

Marcel Dekker, Inc., New York (1985) . 5. G. Taubes, The mathematics of chaos. Discover Maga­

zine. September Issue, 30-45 (1984) . 6. A. Douady and J. Hubbard, Iterations des polynomes

quadratiques complexes. Compte Rendiis (Paris) 2941, 123-126(1982) .

7. A. K. Dewndey, A tour of the Mandelbrot set aboard the Mandelbus. Scientific American 260(2) , 88-91 (1989).

8. H.-O. Peitgen and P. H. Richter, The Beauty of Fractals, Springer-Veriag, Beriin, Heidelberg, New York, Tokvo (1986).

9. C. A. Pickover, Computer graphics generated from the iteration of algebraic transformations in the complex plane. Comp. & Graphics9{2), 147-151 (1985) .

10. C. A. Pickover, Biomorphs: Computer displays of bio­logical forms generated from mathematical feedback looks. Comp. Graphics Forum 5, 313-316 (1986) .

11. R. Waddilove, Zoom in on fractals. Atari ST User 5 , 4 6 -4 7 ( 1 9 8 7 ) .

12. S. D. Casey, Formulating fractals. Comp. Language. April, 2 8 - 4 0 ( 1 9 8 7 ) .

13. A. K. Dewdney, Beauty and profundity: The Mandelbrot set and a flock of its cousins called Julia. Scientific Amer­ican 251(5), 118-122(1987) .

14. H. J. Hubbard, Order in chaos. Cornell Engineering Quarterly 20 (3 ) , 20-26 (1986).

15. C. A. Pickover, Math and beauty. Comp. Graphics World. July, 143-146(1987) .

APPENDIX 1 For computation using languages where complex variables

are supported, e.g., FORTRAN 77, the polynomials can be calculated directly [12]. For applications using BASIC, analysis into real and imaginary parts needs to be undertaken. Table 1 above lists the analysis used.

^1 APPENDIX 2

plane coordinates. Values associated with the processes z -* z"

+ M. Z\

Fig.

1 2 3 4 5 6 7 8 9

10 11 12 13

plane pictures for Figs. 1-13.

n real

-0 .11 0.32

- 0 . 5 3 - 0 . 4 8 -1 .1666

0.8 0.8 0.8 0.8 0.9 0.9 0.6 0.7

/x imag

0.6557i 0.043i O.Oi O.Oi

-0.808642i -0 .2 i -0 .2 i - 0 .2 i - 0 .2 i -O . l i -O . l i -O . l i

0.0 li

Realr

-1.4, 1.4 -1.4, 1.4 - I , 1 -1.8, 1.8 -1 .8 ,2 - 2 , 2 -0.35, 0.35 - 2 , 2 - 2 , 2 - 2 , 2 - 1 , I -2.5, 2.5 -1.4, 1.4

+ /x, sinh(z)

Imagz

-1.4, 1.4 -1.4, 1.4 - I , I -1.8, 1.8 - 2 , 1.8 - 2 , 2 -0.35, 0.35 - 2 , 2 - 2 , 2 - 2 , 2 - 2 , 0 -2.5, 2.5 -1.4, 1.4

Real z and imaginary z are maximum and minimum co­ordinates in the z plane. Their difference controls the scale of the plots.

All of the black and white illustrations were printed on an Epsom FX1000 printer directly from an Apple He computer. These prints were made at 1620 X 2400 or 1280 X 1650 pixels. Colour prints (not shown in this paper) were obtained on an Integrex Colorjet 132 printer using either an Apple He or an Acorn Archimedes 440 computer. The calculations were run at 1280 X 1800 to 2600 pixels. Variations were chosen to control the aspect ratio of the picture frame. Much less CPU time would be required for screen plots or smaller prints. The visual impact of high resolution is, however, worth the longer CPU time.

Page 397: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 429

Chaos and Graphics

METHODS OF DISPLAYING THE BEHAVIOUR OF THE MAPPING z +

IAN D. ENTWISTLE 44 Woodside Gardens, Sittingbourne, Kent MEIO ISG, UK

Abstract—Variations in the disptay of the computer-generated patterns associated with the mapping z -• z^ + /I can be achieved by studying changes in the escape radius utilised to test the values of the real and imaginary parts of | z|. Additional graphic effects can be achieved by sorting the values of | z| generated for points within the main body of the Mandelbrot set.

INTRODUCTION

The mapping of the quadratic/^(z) = z^ + /i in the complex z plane has been widely studied following the observations of Mandelbrot [1,2] who first described the fractal nature and beautiful patterns of the map-ping[3]. The set of initial points for which all subse­quent values of I z I are bounded for this mapping has become known as the "Mandelbrot (M) Set." Diver­gent points in the z plane iteration of z + jLt are identified by the iteration value for which \z\ < 2. This definition of the escape radius was implemented by Mandel­brot [4] and is more rigorously defined by the lemnis-cate / * ( 0 , M) = 2. This determines that the curve for iteration value k = 1 is a circle. The other smooth curves familiar to students of the Mandelbrot set for values /c> 1 are topologically identical to circles. Their overall shape more closely resembles the M set as the value of A: increases. The iteration of z^ + /LI for diver­gent points in the z plane rapidly yields very high values after escape (with only a few additional iterations). Alternative larger values of the escape radius have thus been utilised, e.g., \z„\ = 100. This affects only the shape of the curvature of the lemniscate. Equipotential lines more closely representing the situation of the M set bearing an electrical charge have been widely illus-trated[5]. These observations prompted investigations of alternative tests for divergence as a means of wid­ening the appealing variations of images.

In order to increase the speed of computation, es­pecially on microcomputers without floating point processors, the value of | z | ^ is compared with an escape radius. This avoids calculation of a square root. The rate at which both components of | z| increase during iteration is significantly different. The real part is the major component which diverges itself towards infinity. Alternative mappings are thus obtained if the two components of \z„\ are compared separately.

An additional feature of the mapping of z^ + /u, which has not been widely reported, is the variation of the values of | z„ | for points which are contained in the M set. An illustration of such behaviour has been published [ 6 ].

Differentiation of the values of | z„ | on iteration for the points in the M set is most conveniently achieved by classifying the minimum value of |z„| reached for each point and by coding ranges of values with different plotting colours. The combination of this method and the variations in escape radius gives rise to Figs. 1 and 2.

METHOD

The M set consists of those complex numbers z such that the sequence, z = 0, Zi = z, Z2 = z^, Z3 = (z^ + z)^, . . . , never satisfies \z„\ > 2. A number of al­gorithms has been successfully applied for carrying out the iterative process[7, 8], and program listings for many types of computers[9] have been published. A modification of the commonest approach [10] was used to obtain Figs. I and 2 on an Acorn Archimedes 440 computer outputting to an Integrex 132 Colorjet printer. In order to convert the standard algorithm to produce the divergent points as "petals," the test for convergence used for Fig. 1 was |z„real| < 100 and for Fig. 2 I z„imag| < 10. The significant difference in the patterns is readily discerned. In order to classify the minimum value of | z„ | reached for each point, an additional variable (e.g., min = 5) is set along with ZQ = 0. The value of \z„\ is then compared to min. If \z„\ < min then min = \z„\. This value is then clas­sified as being in a range and accorded a colour value. Figs. I and 2 illustrate the miniature M set centered at -1.768, 0/. The plotting data for use with the stan­dard scanning algorithm is listed in Table 1. Some variations in colour allotment can be seen in Figs. I and 2.

Other variations of petalation are possible, and a wider variation in colours and narrowing of plotting ranges produce even more fascinating views of the Mandelbrot set. These are more easily realised using screen output. It is hoped that this study helps to widen the appeal of the beautiful images that computer graphics yields using the mapping of the quadratic z -> z^ + /i.

The reader may wish to examine additional work using similar graphic methods applied to Julia sets[9].

Reprinted from Comput. & Graphics Vol 13, No. 4, pag. 549-551, 1989

Page 398: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

430 IAN D. ENTWISTLE

Fig. 1. Petalation resulting from comparing |z real| with escape radius 100.

Fig. 2. Petalation resulting from comparing |z imagi with escape radius 10.

Page 399: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Displaying the behaviour of the mapping z -*- z^ -^- n 431

Table 1.

Maximum z Plane M dwell (k) pixels

-1,801, 0.0898/ 100 1280 X 2800

Scale

0.066, 0.0898

Acknowledgements—My thanks to the reprographics staff of the Sittingboume Research Centre of Shell Research Ltd. for the figure reproductions.

REFERENCES 1. B. B. Mandelbrot, On the quadratic mapping of z -* z

+ At: The fractal structure of its "A/" set and scaling. Physica 7D, 224-239 (1983).

2. B. B. Mandelbrot, The Fractal Geometry of Nature, Free­man, San Francisco (1983).

3. H.-O. Peitgen and P. H. Richter, The Beauty of Fractals. Springer-Verlag, Berlin (1986).

4. P. Fisher and W. Smith (Eds.), Chaos. Fractals, and Dy­namics, Marcel Dekker, New York (1985).

5. A. K. Dewdney, Beauty and profundity: The Mandelbrot set and a flock of its cousins called Julia. Scientific Amer­ican 257(5), 118-122(1987).

6. Mapart, Frontiers of Chaos. University of Bremen, FRG (1985).

7. A. K. Dewdney, A computer microscope zooms in for a look at the most complex object in mathematics. Scientific American 255(7), 16-32 (1985).

8. H.-O. Peitgen and D. Saupe (Eds.), The Science of Fractal Images, Springer-Verlag, Beriin (1988).

9. I. D. Entwistle, Julia set art and fractals in the complex plane. Comp. and Graphics 13(3), 389-392 (1989); C. Pickover, Chaotic fragmentation in Halley's Paradise. Physica Scripta 39, 193-195 (1989); C. Pickover and E. Khorasani, Computer graphics generated from the iter­ation of algebraic transformations in the complex plane. Comp. and Graphics 9, 147-151 (1985).

Page 400: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 433

Chaos and Graphics

AUTUMN—A RECIPE FOR ARTISTIC FRACTAL IMAGES

JAMES E . LOYLESS Simons-Eastern Consultants, Inc., P.O. Box 1286, Atlanta, GA 30301

Abstract—The artistic value of fractal imaging is demonstrated in a black-and-white cubic Julia set using staggered alternation.

INTRODUCTION

Fractal geometry is more than mathematics; it is art as well. Fractals can be seen as mysterious expressions of beauty representing exquisite preordained shapes that mimic the universe. Surely they show the practical connections between mathematics and the mysteries ofar t [ l ] .

The image shown in Fig. 1, entitled "Autumn" (1988), demonstrates this assertion in black-and-white. Complex plane fractal images have several important attributes: the iteration formula and escape criteria, the region of the complex plane to be explored, and the artistic display of raw data as texture and shade.

THE CUBIC SET

The mathematical set employed here is based on Newton's method for cubics, an algorithm more in­volved than the self-squaring process so familiar to fractal devotees. The cubic equation was provided by Dr. Homer Smith of Cornell, through ArtMatrix, Inc. Cubic sets typically appear to be surrounded by struc­tures resembling soap bubbles. Dr. Smith's version (program name: JLNAP) was originally written in Fortran, which can interpret complex formulas. To run the set in BASIC requires a derivation, as follows.

For each complex grid point z, where z = x -^ yi using seed point c, where c = a + bi\

Considerable magnification must be employed before one of the bug-like forms is apparent. A cubic Julia set can be generated in the usual manner, by using a seed point from a particular nodule or point in the Mandelbrot set. This particular Julia set was seeded from a nodule of bifurcation order five, and thus has six arms. Dr. Mandelbrot affectionately refers to these kinds of Julia sets as dragons, and so this is a six-armed dragon[2]. The seed point is c = 0.8738 + 0.9201/. The overall Julia set is similar to the Mandelbrot set except that it has three interlocking webs imbedded with tiny six-armed dragons. The portion of the Julia set presented in Fig. 1 is centered at zero and requires a zoom factor of 15. The grid coordinates are (real) -0.26 to 0.26 and (imaginary) -0.2167 to 0.2167. Iteration cut-off (dwell) is 600.

STAGGERED ALTERNATION

The medium used for the image is a 24-pin printer with a dot matrix array 1440 by 1440 points: something over 2 million points in all. Double strike was used to improve the technical quality of the print. Calculations were done on an 8088 processor with a math co-pro­cessor. The visual power of a fractal image, however, lies as much in the way color or shade is assigned to each point's iteration value as in its technical features.

asq=a*a\bsq=b*b

for iter = l to \\xmV.xsq=x*x:ysq=y*y

p=2*x*xsq-6*x*ysq-asq+bsq+.25:q=6*xsq*y-2*ysq*y-2*a*b

r=3*xsq-3*ysq-asq-\-bsq-J5:s='6*x*y-2*a*b:rs=r*r-\-s*s

x={p*r-\-q*s)/rs:y = (q*r-p*s)/rs

i;=x-l:if(i;*i;+>;*j;)<.000001 then (escape)

v=x-a-\-.5:w=y-b:if{v*v-\-w*w)<.00000\ then (escape)

v=x-\-a-\-.5:w=y-\-b:if{v*v-¥w*w)<.00000l then (escape)

next iter: iter=iter - 1

The algorithm is only the compass with which to explore the fractal landscape. One must find an ap­propriate region on the complex plane before a worth­while image emerges. The cubic Mandelbrot set is a thin and lacy curved form of two interlocking torus structures, strewn with tiny Mandelbrot-like forms which resemble bugs caught in a torn spider's web.

Artistic experimentation is required to achieve an ef­fect. A simple swirling form surrounded by alternation can be dramatic, but alternation of black and white usually yields a predictable effect. If the alternation is interrupted randomly, a sense of variety results.

Notice that the cavities surrounding the Julia set

Reprinted from Comput. & Graphics Vol. 15, No. 1, pag. 87-88, 1991

Page 401: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

434 JAMES E. LOYLESS

Fig. 1. Autumn—a fractal image using staggered alternation.

dragon are filled with concentric alternating circles, like peering eyes with haunting stares. As the eyes get smaller, they begin to take on personalities of their own, almost as if a family of bats were issuing from the dragon's lair. This effect is achieved by staggering the usual alternation pattern with bands of solid, elud­ing its precitability. Assignment of black and white values follows:

Alternation : 1-15 iterations

(black=even; white=odd)

White:

Black:

White:

Black:

White:

Black:

16-18 iterations

19-20 iterations

21-23 iterations

24-25 iterations

26-599 iterations

600 iterations (cut-ofT value)

REFERENCES 1. Jack Fredrick Myers, The Language of Visual Art, Holt

Rinehart and Winston, New York, 185 (1989). Computer graphic image created by fractal geometry (Mandelbrot set) as an example of design by process.

2. Benoit B. Mandelbrot, The Fractal Geometry of Nature, Freeman, New York, 180-192 (1983). The original trea­tise which introduced the Mandelbrot set as a fractal con­struct.

BIBLIOGRAPHY A. K. Dewdney, Computer Recreations, Scientific American

16-20, August (1985). An introduction to the Mandelbrot set and fractal images.

Margaret Livingstone and David Hubel, Segregation of form, color, movement, and depth: anatomy, physiology, and perception. Science 740-749, May 6 (1988). Summarizes the anatomical, physiological, and psychological factors in perception to the primate visual system.

Heinz-Otto Peitgen and Dietmar Saupe, (Eds.), The Science of Fractal Images, Springer-Verlag, New York (1988). An overview of fractal geometry by various contributors, including B. B. Mandelbrot.

H.-O. Peitgen and P. H. Richter, The Beauty of Fractals, Springer-Verlag, New York, (1986). Illustrations of color and monochrome fractal images with the theory behind their creation.

Readings from Scientific American, Image, Object and Illu­sion, Freeman, New York, 46-58 (1971). Discussion of spacial perception in vision.

Page 402: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 435

Chaos and Graphics

BIOMORPHIC MITOSIS

DAVID STUEDELL All Saints School, P.O. Box 6081, St. Thomas, Virgin Islands 00804

Abstract—Presented is an informal computer graphics investigation of biomorphs. These graphical entities resemble biological structures which undergo mitosis (cell division) as a parameter in a mathematical feedback loop is varied.

The term "biomorph" is a name given to a computer graphic representation which resembles a biological morphology, hence the name "biomorph" [ 1 ]. As the term implies, biomorphs look like simple lifeforms, and the natural extension of the biomorph would ob­viously be their reproduction and cell division. It is amusing to note that as one varies the constant c as­sociated to the complex function z" + c, the interior region goes through stages which resemble biological mitosis (cell division) (see Fig. 1). This is especially interesting in z^ + c, as c varies from 0 to 2, because the change resembles the natural cell division closely. If one continues to increase c, the original biomorph will split into n new baby biomorphs, where n is the power to which z is raised.

The mitosis of the biomorph may lead computer graphics investigators to create a mathematical "tis­sue." In this process, biomorphs in each cell go through

various stages of mitosis. The constant could then rep­resent the time it takes cells to divide and die.

The pictures were created using the same algorithm described in Scientific American[2], with a loop for the constant c. These forms are related to JuHa sets, which have been described in ref. [3]. The graphics were generated on a Macintosh SB computer and an Imagewriter printer.

Acknowledgements—I thank J. Harper for the useful ideas and encouragement.

REFERENCES 1. C. Pickover, Biomorphs: computer displays of biological

forms generated from mathematical feedback loops. Computer Graphics Forum 5(4), 313-316 (1987).

2. A. Dewdney, Computer recreations. Scientific American 110-113 (July, 1989).

3. B. Mendelbrot, The Fractal Geometry of Nature, W. H. Freeman, New York (1982).

Fig. 1. Biomorphic mitosis produced by the iteration of z = z + c in the complex plane as c varies from 0.7 to 1.0.

Reprintedfi-om Comput. & Graphics Vol. 15, No. 3, pag. 455, 1991

Page 403: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 437

Chaos and Graphics

COMPUTER ART REPRESENTING THE BEHAVIOR OF THE NEWTON-RAPHSON METHOD

DAVID JOHN WALTER Nanyang Technological University, BEE, Nanyang Avenue, Singapore 2263

Abstract—The Newton-Raphson method is used to solve a family of 786,432 complex cubic equations. The resulting beautiful fractal images in the complex plane indicate the intricate behavior of this method.

The Nev^on-Raphson method (or more commonly, "Newton's Method") is a well-known algorithm that can converge rapidly to yield the solution of nonlinear equations[l]. Recently computer graphics has become an important tool for studying this and similar algo-rithms[2], and many useful and beautiful fractal im­ages have resulted [3,4] .

As part of a study of fractals and Newton's method, the family of complex cubic equations

/ ( z ) = {z- \){z-c + 0.5) (z + c + 0.5) = 0

was solved using Newton's algorithm modified by pa­rameter p 1 :

Z„+i = Z „ - / ( z ) / ( / ' ( z ) + /7l)

Z„+i = Zn- {z^ -{c^ + 0J5)z + c^

- 0.25}/ {3z2 - (c^ -h 0.75 + pi)}

The initial value for z was chosen as the coordinate of each pixel in the complex plane:

z(0) = pixel = X + iy.

In addition, the complex constant c takes on the value of the coordinates of each pixel, thereby enabUng

Fig. 2. Pinkmask Xmin/Xmax/rmin/ymax = -0.361324/ 0.586676/-0.638263/0.625737 PI = -0.6 maxiter = 3000.

us to look at a family of 1024 X 768 = 786,432 equa­tions (1024 X 768 is my screen resolution). The re­sulting fractal images were coloured to indicate the number of iterations necessary to converge to the so­lution within lOE—6.

The graphics display gives an immediate indication of the rate of convergence of the method for each member of the family, because the color of each pixel corresponds to the number of iterations used to seek the solution of the equation for that pixel. The 256

Fig. 1. Earing Xmin/Xmax/rmin/ymax = 1.500580414/ 1.50147007/-0.05016097/-0.04897476 PI = -1.0 maxiter

= 3000.

Fig. 3. Picasso ^min/Xmax/rmin/rmax = 1.50509231/ 1.50790363/-0.14496525/-0.14121682 PI = -1.0 maxiter

= 3000.

Reprinted from Comput. & Graphics Vol 17, No. 4, pag. 487-488, 1993

Page 404: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

438 D. J. WALTER

Fig. 4. Whale Xmin/Xmax/ymin/rmax = 1.50782656/ 1.50967758/0.07084562/0.07331365 PI = 1.0 maxiter =

150.

colour palette may be edited to enhance the beauty of the pattern.

Varying parameter p 1 allows us to study the sensi­tivity of Newton's method to variations in the deriv­ative term, and enables a substantial range of different patterns to be created, such as seen in Figs. 1 to 4, which represent different regions of the complex plane.

Acknowledgement—The author wishes to acknowledge the use of the FRACTINT software, which is supplied with [4], and two of the authors for their help: Mark Peterson (70441,3353 on CIS, who wrote the formula interpreter used for this equation), and Timothy Wegner (e-mail: [email protected]).

REFERENCES R. L. Burdon and J. Douglas Faires, Numerical Analysis, PWS Publishers, Boston MA (1985). H.-O. Peitgen and P. H. Richter, The Beauty of Fractals, Springer Verlag, Berlin (1986). Mieczyslaw Szyskowicz, Computer art generated by the method of secants in the complex plane. Comp. & Graph. 14,509(1990). T. Wegner and M. Peterson, Fractal Creations, The Waite Group Mill Valley, CA Press, (1991).

Page 405: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 439

Chaos and Graphics

SYSTEMISED SERENDIPITY FOR PRODUCING COMPUTER ART

D A V I D WALTER Signals Processing Group, Electrical Engineering Department, Imperial College of Science, Technology

and Medicine, Exhibition Rd, South Kensington, London SW7 2BT

Abstract—Serendipity applied to Newton's method, and its derivative the Secant Method, produces unusual and beautiful fractal patterns. Serendipity may be systemised, for example, by the introduction of a perturbation parameter PI, [I] to facilitate searches for interesting pattern variations.

Recursive methods for the solutions of nonlinear equations are a rich source for the generation of fractal patterns [2 ] . As part of a study of nonlinear equations, the equation

/ ( z ) = ^" + 2 -" - 2 cos 2 - 6 = 0

was solved using Newton's Method [ 3 ] , perturbed by parameter P I :

^«+i = z„-f{z)/lf'{z) + P\],

^n+i = Zrt - (e^ + 2 ^ ~^2 cos z - 6 ) /

( ^ ' - 2 -^ lnz + 2 sin z + P I ) .

ing the sign of 2~^ln z in the derivative from minus to plus gave rise to the most unusual pattern shown in Fig. 1. I've called it "The Winged Temple." The equa­tion was coded as a FRACTINT FORMULA as fol­lows:

^x4cwithPl = { z = pixel: ex = exp(z); 2z = 2 ( -z ) ; n = ex^lz- 2*cos(z) - 6; d= ^x + 2z*0.69314718

+ 2*sin(z) + P 1 ; z = z - n/d, 0.001 <= \n\

COMMENTS

*Name of formula *initial estimate *start iteration

*numerator

*denominator *Newton's formula *tolerance condition.

The initial estimate ZQ of the solution was chosen to be the coordinate of each pixel.

This was coded for computation as a formula in the fractal generating program called FRACTINT[4] , which resulted in interesting patterns on the screen. However, serendipitously setting PI = 0.5 and chang-

The Secant Method [ 3 ] was also used as a comparison to Newton's Method, and Figs. 2 and 3.resulted. The Secant Method has been proposed as an alternative to Newton's method if it is impossible or not desired to find the der ivat ive/ ' (z) analytically.

In essence, the derivative is approximated by:

Fig. 1. The Winged Temple. Coordinates of corners: top left X = -0.15519, F = 1.49606; bottom right X = -2.39919, Y= -1.49605. Parameter PI = 0.5, maximum iterations = 511.

Reprinted from Comput. & Graphics Vol. 17, No. 6, pag. 699-700, 1993

Page 406: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

440 D. WALTER

/ ' ( z ) ^ [ / ( z , ) - / ( z o ) ] / [ z , - z o ] ,

and requires two initial estimates ZQ and Zx of the so­lution. The second estimate Zi may be avoided by re­lating it to the first estimate using the fundamental definition of the derivative:

/ ' ( z ) ^ [/(zo + deltaz) - / ( zo ) ] / de l t a z .

This was coded such that deltaz could be varied by changing PI as shown below, and parameter PI was used to perturb the secant formula in order to change the pattern. It would not converge to give a coherent picture even if the tolerance condition was set to 0.1 and deltaz = 0.1. The sign of the "derivative" was changed by making d = {n — «J)/deltaz as shown in the FRACTINT FORMULA code below:

ex4csecdav = { deltaz = P2 + 0.0001 z = pixel zd = z -\- deltaz: n = exp(z) + 2 ( -z )

- 2*cos(z) - 6; nd = exp{zd)

+ 2(-z^) -2*cos{zd) - 6;

d = (n - nd)/de\Xa.z; z = z - n/{d -\- P\y, 0.01 < = \n\

COMMENTS

*formula name *delta varied by P2 *first estimate *second estimate

*start iteration

*incremented function *"derivative" *P\ is perturbation *tolerance condition.

Fig. 3. Super Dudu. Coordinates of corners: top left X = -1.78704, y = -1.06399; bottom right ^ = -0.19104, Y = 1.06399. Parameter P\ = 0, P2 = 0.5, maximum iterations

= 150.

Note that the sign of 2 ^In z in the "derivative" has not been changed—it has not been "serendipitated."

f?S?v.

Fig. 2. Surgeon Fish. Coordinates of corners: top left X = 0.01036, Y = 1.49223; bottom right X = -2.23263, Y = -1.49842. Parameter PI = 0, P2 = 0.1, maximum iterations

= 511 .

Figure 2 is a photograph of the SVGA display (1024 X 768 X 256 colours) when PI = 0 and P2 = 0.1, and which I've called "Surgeon Fish." Changing P2 to 0.5 gives rise to the "insect" shown in Fig. 3, which is called "Super Dudu," ("Dudu" is Swahili for "insect.") The secant method took about 40% more computation time than Newton's Method, and converged less readily. The "floating point" option in FRACTINT was used. The tolerance had to be reduced to about 0.001 to facilitate convergence, and decreasing it to 0.01 also increases the size of the image. Serendipity and variants of the Secant Method can yield very strik­ing examples of computer art, often radically different from those obtained using Newton's method as Newton intended.

Acknowledgement—The author wishes to acknowledge the use of the FRACTINT software that is supplied with [4], and two of the authors for their help: Mark Peterson (70441, 3353 on CIS, who wrote the formula interpreter used for this equation), and Timothy Wegner (e-mail: [email protected]).

REFERENCES 1. D. J. Walter, Computer art representing the behaviour of

the Newton-Raphson method. Comp. & Graph. 17,487-488(1993).

2. C A. Pickover, Computers, Pattern, Chaos and Beauty, St Martin's Press, New York (1990).

3. R. L. Burden and J. Douglas Faires, Numerical Analysis, PWS Publishers, Boston, MA (1985).

4. T. Wegner and M. Peterson, Fractal Creations, The Waite Group, Mill Valley, CA (1991).

Page 407: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V. All rights reserved 441

Chaos and Graphics

COMPUTER ART FROM NEWTON'S, SECANT, AND RICHARDSON'S METHODS

DAVID WALTER Signals Processing Group, Electrical Engineering Department, Imperial College of Science,

Technology and Medicine, Exhibition Rd, South Kensington, London SW7 2BT

Abstract—1992 is the 350th anniversary of Newton's birthday, and the equation he used to demonstrate his iterative method for solving equations is used to create some interesting fractal patterns. The secant variation was used to create a pattern called "Newtons Powerful Brain," and a "Pointillist" version of "Newton's Ghost." For highly magnified fractal patterns Richardson's Extrapolation was used to compute f'{z) numerically, because it is fundamentally more accurate than the secant method.

1. INTRODUCTION

Newton was born on December 25th, 1642 (old style calendar)[l], andiractographers the world over should celebrate this anniversary, because Newton's Method produces beautiful fractal patterns[2]. The equation he first used to demonstrate his method is z^ — 2z — 5 = 0, and every student of numerical mathematics should solve this venerable equation [ 3 ]. In this paper it is solved in order to create fractal patterns, which show bands of colour representing areas of constant iteration number, in three ways:

1. Newton's method, but with the derivative perturbed by parameter Pl : / ' (z) + PI [4]. Patterns produced this way serve as reference patterns for comparison with those produced using numerical approxima­tions to the derivative.

2. The Secant Method, where/'(z) is approximated by [/(z + /z) —/(z)]//z, with an error of the order ofh. This error is a useful tool for creating unusual patterns.

3. Richardson's Extrapolation for / ' (z ) , which ap­proximates/'(z) with an error of the order of h"^, or better. This method is vastly superior to the Se-

newtonseqn (XAXIS) = { z = pixel: fz = z^3 - 2*z - 5; /dashz = 3*z^2 - 2; z = z - / z / ( / d a s h z + Pl); 0.001 < \fz\

}

cant Method at higher magnifications, (for example 6 million), when the small values of /z (such as 10"^) necessary using the Secant method to com­pute a sufficiently accurate numerical derivative suffer from computer round off". Using h = 10"^ in Richardson's method, is generally equivalent to us­ing /z = 10"^ in the Secant method.

The three methods are coded as FORMULAS in the fractal generating software called FRACTINT[5] in a unified way, so that readers may easily edit them for other equations.

2. NEWTON, SECANT, AND RICHARDSON

2.1. Newton's method The method is to solve/(z) = 0 by iterating the

equation:

z „ ^ i = z „ - / ( z ) / [ / ' ( z ) ] ,

until/(z) < TOL, where TOL is the allowable toler­ance. If the parameter PI is added to the derivative it may be used to vary the number of iterations leading to a solution, and thereby allows a variety of fractal patterns to be created for the same equation[4, 6]. Applying this to Newton's venerable equation we get

z„+ z„- ( z ^ - 2 z - 5 ) / ( 3 z 2 - 2 + P l ) .

The initial estimate z of the solution was chosen to be the coordinates of each pixel, and the code for the FRACTINT formula is:

COMMMENTS

*Name of formula *initial estimate *start iteration derivative of function *Newton's formula *tolerance condition.

2.2. The Secant method The Secant Method[3] is useful in situations where

it is impossible or undesireable to find the derivative / ' ( z ) analytically. The derivative was approximated by truncating Taylor's series for/(z + h) and rear­ranging:

r(z)^[fiz-\-h)-f(z)]/h.

Reprinted from Comput. & Graphics Vol 18, No. 1, pag. 127-131, 1994

Page 408: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

442 D. WALTER

which incurs an error E given by:

E=-hf"{z)l2-h^r''{z)/6

- h^f%z)/2A

As an idea of magnitude, if z = 2 and h = 1, the ap­proximation gives the derivative as 17, whereas the actual value is 10. This source of large errors was ex­ploited to create interesting variations on the "correct" fractal patterns produced by Newton's Method.

The Secant Method was coded such that h could be varied by changing P2 as shown below, and parameter P\ was used to perturb the secant formula in order to change the pattern. (Parameters PI and P2 may be changed at run time when using FRACTINT.)

Newtsec (XAXIS) = { h = F2 z = pixel: fz = z^3 - 2*z - 5; zplh = z -\- h; fzplh = zplh^3 - 2*zplh - 5; fdsLshz = {fzplh-fz)/h; z = z-/z/(/dashz + Pl); 0.001 ^ |/z| {

Figure 1 shows the variations due to h and P\ in the default pattern on a VGA screen using a 640 X 480 X 256 colour driver in FRACTINT, and the floating point option. The patterns were printed by using FRACTINT's print facility on an HP Deskjet at 300 dpi. Figure la, with h = lO"'*, is identical to that pro­duced using the analytical derivative. Figure 1 b shows the substantial change caused by putting P\ = 2, and Fig. Ic shows the effect of increasing h to 1.0.

Figure 2 was computed using the same parameters, but the tolerance was set at 10. It can be seen that the

effect of varying the tolerance TOL is surprisingly less powerful at changing the pattern than hor PI.

Varying P\, h and TOL leads to many interesting patterns such as Figs. 3 to 5. Figure 3 represents the "Mitosis," which leads to "Newton's Powerful Brain" shown in Fig. 4, and Fig. 5 "The Galactic Squadron Returns Home," honours Newton's attraction to grav­ity. Figure 6a show^ a pattern I call "Newton's Ghost," which appears in many fractals using Newton's method, and is produced here at a magnification of 5.96 million. (A magnification of 1 corresponds to a pattern having Ymin = —1 and F max = +1.) Figure 6b shows the Pointillist effect achieved by using the

COMMENTS

*formula name *h varied by P2 *first estimate ZQ *start iteration *z plus h *incremented function *numerical derivative *P\ is perturbation *tolerance condition.

Secant method when h = 10~^. The "head" has also moved. It was not possible to reproduce Fig. 6a using the secant method on either my 286 or my 486 IBM PC, because of round off* errors. Values of h greater than 10"^ produced clear but different patterns at the same location, and smaller values produced increas­ingly blurred patterns. However, using Richardson's Extrapolation to compute more accurate approxima­tions to the derivative overcame this effect (when viewed as a problem).

(a) (c)

Fig. 1. (a) PI = 0;h = 10-^ (b) PI = 2.0; h = 10-^ (c) PI = 0; /? = 1. FRACTINT default patterns produced by Newton's venerable equation. Tolerance TOL = 0.001, Coordinates of corners: top left:

X = -2.0; Y = 1.5, bottom right: X = 2.0; Y = -1.5. Floating point used, maximum iterations = 150.

Page 409: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Computer art from Newton's, Secant, and Richardson's methods 443

Fig. 2. FRACTINT default pattern produced by Newton's venerable equation. Tolerance TOL = 10; PI = 0, h = lO""*. Coordinates of corners: top left: X = -2.0; Y= 1.5, bottom right: X = 2.0; Y = -1.5. Floating point used, maximum

iterations = 150.

2.3. Richardson 's extrapolation An outline of the derivation of this ingenious

method [ 3 ] of reducing the errors in computing the derivative numerically is given to show readers where the errors are and how they are reduced. The Taylor's Series for/(z + /z) and/(z - h) were manipulated to give the derivative as

f'{z) = [fiz + h) -f{z - h)]/2h - h'f'''{z)/6

-h'riz)/120 ,

which already shows an improvement in that the order of the error is reduced to 0(/z^) if the derivative terms are ignored. Putting z = 2 and h = 1 gives the derivative as 11, and the error is 1 instead of 7 in the Secant example above.

Fig. 3. Mitosis. Coordinates of corners: top left: X = 6.6829; Y = 11.8743, bottom right X = 5.4654; r = 7.5154, bottom-left A-= 4.7630; Y= 11.4988. Parameter PI =-5, h = 0.5, maximum iterations =150.'

Fig. 4. Newton's Powerful Brain. Coordinates of corners: top left: X = 0.0774; Y = 0.0395, bottom right-X = 0.0190; Y = -0.0382, bottom left: X = 0.0190; Y - 0.0395. Parameter P\ = -2.5, h - 0.5, maximum

iterations = 150.

Page 410: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

444 D. WALTER

Fig. 5. The Galactic Squadron Returns Home. Coordinates of corners: top left: X = 0.1880; Y - 0.0755, bottom right: X = 0.8760; Y = -0.0772, Parameter PI = -1.5, /? = 0.5,

maximum iterations = 150.

Fig. 6a. Newton's Ghost. Coordinates of corners: top left: X = -0.4133450; Y = -0.0036638, bottom right: X= -0.4133445; Y= -0.0036641. Magnification 5,963,029.

Parameter PI = 0, maximum iterations = 150.

Put ^{h) = [f(z + h) -f(z - h)]/2h,

thcn^ih) = f'(z)-^h'f{z)/6

+ /zV"(z)/120+ • • • , (1)

and<^(/z/2) =f'(z) + (/2/2)V"'U)/6

+ (/z/2)V^(z)/120 + . . . (2)

To eliminate the error term proportional to /z , we multiply Eq. (2) by four, and subtract that from Eq. (1). Rearrangement then gives

nz) = ^ih/2) -^ H<Pih/2) - <pih)]

-^{hyriz)/4so-^ .••, (3)

and we see that the order of the error reduced toOih"^), lfh = say 10~^, then the first error term is of the order of 10~^ . The procedure may be repeated to kill off further error terms, and is known as Richardson's Ex­trapolation. However, for polynomials of degree four or less—such as Newton's Venerable Equation—the error is analytically zero, because the fifth derivative is zero.

The coding for this method of solving Newton's Ve­nerable Equation as a FRACTINT formula is:

Fig. 6b. Newton's Ghost Pointillist Style. Parameters as above buth = W-\

Page 411: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Computer art from Newton's, Secant, and Richardson's methods 445

NewtonRich (XAXIS) = { h = P2 hovl = h/2 z = pixel: zplh = z -\- h\ zminh = z — h\ zplhovl = z + hovl; zminhovl = z — hov2\ fz = 2^3 - 2*z - 5; fzplh = zplh^3 - 2*zplh - 5; fzminh = zminh^3 - 2*zminh - 5; fzplhov2 = zplhov2^3 - i*zplhov2 - 5; fzminhov2 = zminhov2^} — 2*zminhov2 - 5; M = (fzplh - fiminhyip'h); flhov2 = (fzplhov2 - Jzhiinhov2)/h; fdashz = fihoy2 + {fihov2 - fih)/3; z = z-fz/{fdashz-VP\)\ 0.001 < \fz\

}

This coding reproduced Fig. 6a "Newton's Ghost" for values of/z from 10"^ to more than 1000 (!), and a "Pointillist" version (but not shifted as Fig. 6b) , for h = 10~^. A "Rectilinear Pointillist" version of Fig. 6a, which tended towards a tartan pattern resulted as h was increased beyond 10"*.

Acknowledgement—I wish to acknowledge the use of the FRACTINT freeware software, which is supplied with [ 5 ]. I think that FRACTINT is a shining example of excellence in software because it is very easy to use, has a clear manual, and is highly versatile. It will run from a single floppy if nec­essary, but will make use of available extended memory and many different graphics cards without the user having to do much, if anything. It is produced by the Stone Soup Group and contributors as an experiment in collaboration. The 108-page manual is informative, easy to understand, and funny.

COMMMENTS

*Name of formula *Use P2 to vary h

•Initial estimate

*The / ( z ) to be solved */(z + h) *fiz - h) *f(z + h/2) *f{z - h/2) Mh) V(h/2) •Derivative o f / ( z ) •Newton's Formula •Tolerance condition.

REFERENCES The New Encyclopaedia Britannica, Micropaedia (Vol. VII), Encyclopaedia Britannica Inc., Chicago/London, 305(1976). C. A. Pickover, Computers, Pattern, Chaos and Beauty, St Martin's Press, New York (1990). W. Cheney and D. Kincaid, Numerical Mathematics and Computing, Brooks/Cole Publishing Company, Mon­terey, CA. D. J. Walter, Computer art representing the behaviour of the Newton-Raphson method. Comp. & Graph., 17, 487-488(1993). T. Wegner and M. Peterson, Fractal Creations, The Waite Group Press, Mill Valley, CA (1991). D. J. Walter, Systemised serendipity for producing com­puter art. Comp & Graph., 17, 699-700 (1993).

Page 412: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V All rights reserved

Author Index

Angers, M., 353

Baier, G., 79 Balkin, S.D., 321 Bow^man, R.L., 133

Canright, D., 383 Collins, J.J., 115 Corbit, J.D., 19 Culik II, K , 361

Davis Philip, A.G., 269, 331 Diichting, W., 15 Dube, S., 361

Entwistle, I.D., 425, 429

Frame, M., 149, 263, 269, 331, 353

Garbary, D.J., 19 Gilbert, WJ., 327 Golebiewski, E.L., 321 Grim, P., 111 Groller, E., 401

Hess, B., 73 Holden, A.V, 33 Hooper, K.J., 255 Hudson, J.L., 79 Hv^ang, S.C., 193

Jeffrey, H.J., 5 Jones, J.D., 259

Kahlert, C , 79 Kim, H.O., 301, 313 Kim, H.S, 301, 313 Kim, Y.B., 313 Klein, M., 79

Lakhtakia, A., 185, 191, 247 Li, W., 177

Lopes, A.O., 93 Loyless, J.E., 433

Mar, G., I l l Markus, M., 73 McCarty, K., 201 Messier, R., 247 Michelitsch, M., 69, 251, 287 Miller, G.T., 297 Mullin, T., 103

Neiger, M., 111 Norton, A., 235 Nugent, J., 207

Panfilov, A.V, 33 Parisi, J., 79 Passoja, D.E., 185 Peinke, X, 79 Philip, K.W., 291 Pickover, C.A., 27, 41, 127, 201, 341, 415 Pottinger, D., 103 Pulsifer, J.E., 155

Qammari, H., 35

Reeves, R., 253, 281 Reiter, C.A., 61, 155, 169, 283, 321 Robertson, J., 263 Robucci, A., 269, 331 Rodrigues, I., 103 Rojas, R., 121, 225 Rosenstein, M.T., 115 Rossler, O.E., 69, 79, 287

Shepard, S., 161 Shin, S.Y., 301,313 Shirriff, K.W., 23, 307 Simoson, A., 161 Skeldon, A., 103 Sprott, J.C, 53, 341, 391

447

Page 413: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

448

St. Denis, P., 111 Venkatesan, A., 35

Stuedell, D., 435 Walter, D., 411, 439 Szyszkowicz, M., 217 ^^j^^^^ ^ j ^ ^^^

Todd, S., 103 Yang, H.S., 193

Page 414: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V All rights reserved

Subject Index

Aeolian fractals Amalgamated Research, vii Apollonian packing, 27 Art, 341 ,413^45 Artificial intelligence, 53, 61, 341, 415 Attractors, 49-142

Fractal Antenna Systems, vii Fractal fiberoptics, vii Fractal Loop, viii Fractals, practical, vii Fractals, terrain, 41 Fractint, viii

Bamsley, M., 349 Basins of attraction, 79, 341 Batrachions, 127 Bifiircation, 103 Biology, 5, 15, 33, 435 Biomorphs, 435 Blaschke products, 301 Bubbles, 31

Cancer grow^th, 15 Cantor cheese, 201 Cardiac tissues, 33 Cellular automata, 145-218 Chaos game, 5 Chaos, control of, 35 Chaos, filtering, 115 Chaotic forcing, 79 Chemistry, 35 Circle packing, 27 Clarke, A., 222 Complex maps, 221-345 Correlation dimension, 391 Critical points, 263, 321

Diffusion limited aggregation, viii DNA, 5 Dueling symmetry, 61

Eigenvalue estimation, 283 Elliptic curves, 321 Epsilon cross, 255

Field lines, 291 Filtering, 115 Fischer, Y., 349

Games, 161 Gaskets, 145-218 Gauss sums, 247 Genetic sequences, 5 Goose fractal, vi

Halley's method, 253, 281 Henon's map, 69

Integer sequences, 127, 247 Iterated fiinction systems, 349-410

Julia sets, 221-345

Koch curves, 145-218

L-systems, 19

Leaf patterns, 23 Lebesgue measure, 93 Life, game of, 155 Logic, 111 Logical operators, 217 Logistic map, 73 Lyapunov exponent, 50, 53, 73, 391

Mandelbrot set, scaling, 269 Mandelbrot sets, 221-345 Mandelbrot, B., vi Mathematica, 133 Menger sponges, 169 Midgets, 269, 331 Moon, E, vii Mountains, 41 Multidimensionality, 103 Mutually recursive fiinction systems, 361

449

Page 415: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

450

Nature, 3 ^ 5 , 79 Neural networks, 121 Newton's method, 313, 327, 437, 439, 441 Noise spheres, 137

Oscillations, 35 Osculatory packing, 27

Paradoxes, 111 Pascal's triangle, 207 Pendula, 103 Phase portraits, 103 Phase transition, 93 Plants, 19, 23 Poincare cross-section, 108 Practical fractals, vii Prime numbers, 191

Random numbers, 133 Rayleigh quotient iteration, 283 Repellers, 93 Root-finding, 253, 259, 283, 313, 327, 437,

439, 441

Seaweed, 19 Secant method, 259, 439, 441 Self-similarity, 79 Siegel disks, 297 Sierpinski gaskets, see Gaskets Solenoid, 201 Spatio-temporal chaos, 33

Terrain, 41 Tumor growth, 15 Tutorials, 225, 297

Quaternions, 225 Voronoi diagrams, 23

Page 416: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

Chaos and Fractals: A Computer Graphical Journey C.A. Pickover (Editor) © 1998 Elsevier Science B.V All rights reserved

About the Editor

"Pickover has published nearly a book a year in which he stretches the limits of computers, art and thought."

Los Angeles Times

Clifford A. Pickover is currently a Research Staff Member at the IBM TJ. Watson Research Center v^here he has received numerous av^ards for his work. He received his Ph.D. from Yale University's Department of Molecular Biophysics and Biochemistry.

Dr. Pickover became an associate editor for the "Chaos & Fractals" section of the journal Computers & Graphics in 1989. He is also an associate editor for the scientific journals Computers in Physics and Theta Mathematica Journal Dr. Pickover is an active editorial board member for the follovv ing journals: Odyssey, Speculations in Science and Technology, Idealistic Studies, Leonardo, and YLEM.

Dr. Pickover has published numerous books including: Strange Brains and Genius: The Secret Lives of Eccentric Scientists and Madmen (1998) Time: A Traveler's Guide (1998) The Alien IQ Test (1997) The Loom of God (1997) Black Holes - A Traveler's Guide (1996) Fractal Horizons (1996) (Editor) Keys to Infinity (1995) Visualizing Biological Information (1995) (Editor) The Pattern Book: Fractals, Art, and Nature (1995) (Editor) Future Health (1995) (Editor) Chaos in Wonderland: Visual Adventures in a Fractal World (1994) Visions of the Future: Art, Technology, and Computing in the Next Century (1993) (Editor) Mazes for the Mind: Computers & the Unexpected (1992) Computers for the Imagination (1991) Computers, Patterns, Chaos and Beauty (1990) Dr. Pickover received first prize in the Institute of Physics' "Beauty of Physics Photographic

Competition." His computer graphics have been featured on the cover of many popular magazines, and his research has recently received a considerable amount of attention by the press.

451

Page 417: C.A. Pickover Chaos and Fractals A Computer Graphical Journey 1998

452

Pickover has received U.S. Patents for a 3-D computer mouse, strange computer icons, and for black-hole transporter interfaces to computers.

For more information regarding Clifford A. Pickover, please visit his website at: http://sprott.physics.wisc.edu/pickover/home.htm or write him at RO. Box 549, Millwood, New York, 10546-0549, USA.