{"id":5641,"date":"2011-01-07T23:00:00","date_gmt":"2011-01-08T04:00:00","guid":{"rendered":"http:\/\/blog.kenperlin.com\/?p=5641"},"modified":"2012-09-09T13:19:05","modified_gmt":"2012-09-09T18:19:05","slug":"exogeometry","status":"publish","type":"post","link":"http:\/\/blog.kenperlin.com\/?p=5641","title":{"rendered":"Exogeometry"},"content":{"rendered":"<p>Today I thought it would be fun to create shapes by writing a program that computes and then draws one continuous line &#8212; sort of a mathematical Etch-a-Sketch or Spirograph.  This is actually the oldest idea in computer graphics, since <a href=http:\/\/en.wikipedia.org\/wiki\/John_Whitney_(animator) target=1>John Whitney<\/a> pretty much started the field of computer animation over half a century ago by doing something like this.<\/p>\n<p>My goal was to see whether some very simple rule could produce a large variety of beautiful shapes.  I didn&#8217;t have any specific approach in mind, other than this general idea.  I tried all kinds of different things this evening, and the result I liked best was a little program that lets you create a very large variety of shapes, including all of the shapes below, by moving your mouse around:<\/p>\n<p><center><br \/>\n<a href=http:\/\/mrl.nyu.edu\/~perlin\/patterns target=1><img decoding=\"async\" src=\"http:\/\/blog.kenperlin.com\/wp-content\/uploads\/2011\/01\/patterns.jpg\"><\/a><br \/>\n<\/center><\/p>\n<p>Looking at all these lovely forms, I feel as though I&#8217;ve stumbled across some mathematical <a href=http:\/\/en.wikipedia.org\/wiki\/Burgess_Shale target=1>Burgess Shale<\/a>.  Or maybe this is just a single fabulous creature who lives in some higher dimensional space.   Perhaps it looks to us like different creatures because it keeps turning in various directions, as it swims around in its high dimensional world.<\/p>\n<p>I suspect there are many more shapes to be found in my program.  You can click on the image above to find them for yourself.<\/p>\n<p>The recipe is very simple:<\/p>\n<p><b>&nbsp; &nbsp; &nbsp; x = y = &theta; = 0<br \/>\n&nbsp; &nbsp; &nbsp; Repeat 8000 times: <font color=white>x<sup>2<\/sup><\/font><br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; x += cos<small> <\/small>&theta; \/ 10 <font color=white>x<sup>2<\/sup><\/font><br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; y += sin<small> <\/small>&theta; \/ 10 <font color=white>x<sup>2<\/sup><\/font><br \/>\n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &theta; += ( (x<sup>2<\/sup>q)<sup>p<\/sup> + (y<sup>2<\/sup>\/q)<sup>p<\/sup> ) \/ 20<\/b><\/p>\n<p>When you move your mouse, you are varying <b>p<\/b> and <b>q<\/b>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today I thought it would be fun to create shapes by writing a program that computes and then draws one continuous line &#8212; sort of a mathematical Etch-a-Sketch or Spirograph. This is actually the oldest idea in computer graphics, since John Whitney pretty much started the field of computer animation over half a century ago &hellip; <a href=\"http:\/\/blog.kenperlin.com\/?p=5641\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Exogeometry&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=\/wp\/v2\/posts\/5641"}],"collection":[{"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=5641"}],"version-history":[{"count":37,"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=\/wp\/v2\/posts\/5641\/revisions"}],"predecessor-version":[{"id":5674,"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=\/wp\/v2\/posts\/5641\/revisions\/5674"}],"wp:attachment":[{"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=5641"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=5641"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.kenperlin.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=5641"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}