#btconf Düsseldorf, Germany 07 - 09 May 2018

Jared Tarbell

Jared S Tarbell is a computer programmer interested in the intersection of graphic arts and generative design.

In July 2005, Jared co-founded Etsy, the global marketplace to buy and sell handmade goods. More recently he built a toy factory to bring algorithmic design into the material world.

Jared holds a Bachelor of Science degree in Computer Science from New Mexico State University.

When programming, he enjoys nodes, vectors, colors, physics, creating intricate structures, and also smashing them to pieces.

When not engaged in programming, Jared nearly always tries to find himself outside, exploring mysterious wilderness areas of the American southwest.

Want to watch this video on YouTube directly? This way, please.

Generative Spaces

Generative algorithms have the capacity to produce complex and beautiful designs. Often times just a few simple rules can manifest incredible phenomena. The application of this particular class of programs have practical value and artistic beauty.

Jared explored these types of programs early in his career. Now his interest in these systems has deepened. No longer are we trapped in the domain of the pixel. Generatively designed computational artifacts can now be brought into the physical world with digital fabrication.

Through the use of several examples, a variety of techniques in the world of generative programming will be explored. Algorithms will be explained, secrets will be revealed, and haunting questions asked in this highly visual presentation designed to inspire.


[Digital music]


Jared Tarbell: Thank you very much. Yeah, it is super great to be here. In fact, I was in Germany just a month ago, and I had such a great time that I’m back, and I brought my whole family. My wife is here, my two daughters, and even my mother.

Audience: [Laughter, cheers]

Jared: Thank you. [Laughter]


Jared: This is an amazing conference. I want to thank Marc before I get started. He really does have a heart of gold, and I can really feel the love and attention that he puts into this conference. Guido and all of the volunteers, you guys are doing an amazing job.

Then the speakers today, I saw every one of the presentations. As a speaker myself, you almost don’t want them to be very good.

Audience: [Laughter]

Jared: But, they were fantastic, so no pressure.

Let me just get started here. I’m going to begin my story in the jungles of Peru. This is a nature reserve called the Tambopata. It’s an island. The entire island has been designated a preserved area for the study of the species and the flora and fauna that live there. It was in this jungle that a young graduate student awoke in his tent to discover this mysterious structure had appeared overnight. And, more disconcerting, it was on the inside of his tent.

Audience: [Laughter]

Jared: Being the scientist that he was, naturally, he took a photograph of it. It’s difficult to tell from this photograph, but it’s very small. It’s about the size, the diameter of a pencil eraser. Having never seen anything like this before, he posted it on the Internet asking, “What is this thing?”

It quickly went viral because nobody knew what it was. There were a lot of hypotheses that were thrown out there from some kind of a spider web to a spermatozoon, which is a sack of sperm and nutrients that insects sometimes will use to attract a mate, to even more bizarre theories.

Eventually, more of these things were found, not only in Peru, but elsewhere in the Amazon, and even one was found in Florida, in the United States. But still, what was it? Nobody knew.

One of them, they found some mites crawling around on the inside of it. They almost looked like they had been trapped. The theories grew even more bizarre and even extraterrestrial.

Eventually, somebody with enough patience sat and watched with a camera, and this happened. This creature emerged, not just one, but two, from this strange tower-like structure on the inside. And, it was determined that it is, in fact, a spiderweb of some sort, a spider egg.

Who here saw this when it happened? It was about four years ago that this kind of went around the Internet? Oh, good. Okay, so a couple people. Yeah, very mysterious, but the mystery was solved, eventually.

Of course, we still don’t know exactly what spider this is. The spiders that they took back to the lab did not survive, and no spider has ever been witnessed actually creating this structure.

Why am I telling you a story about spiders in the jungle? I’m going to get back to it. But, for now, we’re going to jump over to the desert in the southwestern part of the United States where I live. It is here that I studied computer science and learned that I really enjoy the process of writing code to create graphic images.

Anybody that knows me knows that I love cubes, and I’ve brought some here with me today. The cube, I think, is like a three-dimensional extension of the pixel. As a computer programmer, the pixel is very dear to my heart and, by extension, the cube. I will get to the process of how these cubes are made, later.

But, I’m going to start with something brand new. This is a maze cube, and I brought this here. This is actually a gift for Marc. I do like to bring gifts to show my appreciation for everything you do here. But, I wouldn’t let him have it yet because I wanted to actually hold it up. It’s a solid block of maple, and laser engraved onto this cube is a perfect maze. Perfect not in any sense of judgment, but a mathematically perfect maze where every part of the path is reachable by some other part of the path. There are no loops, and there are no islands.

How do I generate these? I write computer programs that generate these. What I’m going to be showing you today are many examples of programs that I have written that demonstrate a particular class of programs, which are called generative programs.

I usually start with paper and pen, and I will define objects. An object is usually something that is imaginary that you invent, and it has a list of attributes and then relationships with other objects. In this case of the maze, I have something called the cell. The cell has neighbors north, east, south, and west, and then, using several different algorithms to connect those cells together, basically tunneling through the walls and creating these mazes.

If I take a 2x2 grid and create every possible maze in that grid, this is what I get. It’s pretty simple. You can write this down on paper. If I eliminate any rotational variations, I actually just get this maze. A 2x2 grid produces exactly one maze, and it looks like this. I think that’s actually a pretty cool symbol. It could be a great logo for a company if you’re involved with labyrinths or puzzles.

A 3x3 grid gets a little more interesting. This is every possible maze that can be generated in a 3x3 grid. There are 52, and I don’t know why there are 52. I don’t know the mathematical proof, but just exhaustively going through and running this program, these are the ones I generated. I do allow mirrored mazes, which I might also eliminate, which mean there’s only 26.

Are there any guesses about how many mazes there are with a 4x4 grid? If you get the number right, I’ll give you Marc’s cube.

Audience: [Laughter]

Audience member: Ten thousand sixty-three.

Jared: Yeah, even an order of magnitude. Here are some examples. These are five different mazes possible with a 4x4 grid. There are 12,600 possible mazes in a 4x4 grid. Here, I’m visually representing only a tenth of those.


Jared: Isn’t this surprising? In this very simple system with very simple rules, just increasing the amount of squares linearly, we get this kind of complexity. Of course, I have no idea how many cubes there are or mazes there are with something like a 100x100 maze, which I do enjoy generating.

Here, I’ve colored the maze based on its difficulty. If you look in the top left corner, there’s a dot. Every other cell in the maze is colored based on how far away it is to get to that dot. The furthest possible point to be on this maze would be that cell. That would take you the longest to get to the edge. I do this, when I generate the mazes, for me to get an idea of the complexity--just how complex is this maze--before I sent them to the laser cutter.

Of course, we’re not limited to a grid. Mazes can occupy any kind of neighbor space. Here is a polar grid. There’s the solution from the bottom, if you’re curious.

When I generate these mazes for a cube, this is basically what it looks like. What you’re not seeing is that some of the cells are warped to the other faces. I lay it out like this. It’s a bitmap. Then I engrave it into the cubes. I brought three of these, which I’m giving away. In fact, I’m giving all these cubes away. The way it’ll work is, if you’re sitting close to the stage after my presentation -- [Laughter]

Audience: [Laughter]

Jared: You’re likely to get one. I just ask that everybody choose just one.

Here’s a simpler algorithm. This is the way I work. Let’s imagine dots arranged in a circle. Let’s draw lines from one dot to every other dot in the circle. This is the structure we get.

Oh, what did I do? [Laughter]

There we go. I’ve used this to great effect. This is my daughter, Sky. She’s just two years old. I have printed this.

This algorithm here is something I called Substrate. According to Google, this is my most popular algorithm. Let’s imagine a system where we draw straight lines. We’re starting with just three of them. There are two rules: a line will continue until it hits the edge of the screen or another line at which point it stops and two new lines are created. Very simple rules. But, if we let this run, let’s just see what happens.
[Piano music]

Jared: We can see here that something actually quite complex and beautiful was created even from just simple rules.

There’s some coloring effect that’s going on here. I like to use a lot of highly transparent pixels, so I’ll put a pixel down at, like, 1% or 2% opacity, just do that thousands and thousands of times, and build up a watercolor effect. I think that’s a trick that I’ve learned growing up in the desert and seeing the effect of sand accumulating. Sand, it looks brown and gray. But, if you look at it really closely, it’s actually every color.

I’ve done this with quite a few different algorithms. Most of these things are rule-based. There’s almost no esthetic judgment or decisions. It’s mostly based on mathematical ideas, another version of Substrate, a lot of recursion iteration, combination, a lot of mandalas.

This final image is something called the Buddhabrot. It’s a revisualization of the Mandelbrot set, a fractal with infinite detail. At the time that I created that, it took six days on my fastest computer to render it. While it was rendering, I didn’t know what it was going to look like and wasn’t sure if it would even work. Day six, when it actually arrived, I thought, “Oh, this is it! Let there be light.”

Audience: [Chuckles]

Jared: This is the Triforce, the ultimate symbol of strength. When I say, “Programming,” What do I really mean? These days, I’m using an environment called Processing. It’s a free Java-based development environment from MIT. You can download it and use it. There’s a huge community of users. But, of course, like many people here, my days originally were as a Flash programmer.

Processing has a very simple editor, very simple syntax. In this example, there are two functions: a setup function, which is called exactly once; and a draw function, which is called on repeat. In this program, I am setting the screen to be 1,000 pixels by 1,000 pixels. I’m setting the background to zero. In the draw function, I set the stroke, which is the color of the line, and I’m drawing the line from 00 to the mouse. In this case, I’ve just modified it to start at the center of the screen, which is half the width and half the height to the mouse - very simple.

Here’s another example. Again, it’s the setup routine. I’m showing these examples because many people see this work and want to approach it but aren’t sure where to begin. Processing is a great place. This is actually me typing, which is funny because I’ve stopped coding live on stage. I’ve learned that lesson a long time ago.

Audience: [Laughter]

Jared: But, I still make mistakes, even in the prerecorded version of this. Here, in my draw loop, I’m setting up another loop that starts at zero and goes to 100. In a loop, you specify the number you start, the number you end at, and then the increment, and it increments by one each time.

Inside this loop, I’ve created two variables, X and Y. I’m setting them to something random between zero and the width of the screen. Then I create a circle or an ellipse at that position with a diameter of W. W is another random variable between two and five. That’s in pixels. I set the fill color to white with a little bit of transparency with no outline. When I run this, that’s the result.

This is my process. I see what the code gives me, and then I modify the semantics of the program to get the visual result that I’m looking for. Sometimes I know what I’m doing; sometimes I’m just exploring.

Here, just white circles, very boring. Another one of my tricks; alternate between black and white. Here, half the circles are white; half the circles are black.

With a little bit more complexity, I can create images like this. This is an algorithm called Happy Place. I was doing this as a programmer in my free time after my day job. I worked for the gas company in Texas doing online bill presentment and payment, so pay your bill online. That the year 2002. Very boring so, when I came home, I would do this.

In addition to posting the work, I would also post the source code, which was a way of encouraging other people to take my code, learn from it, incorporate it in their own projects. It was a scary thing to do at first, but the karma is just amazing. I got so much back from this. I got improvements in my code. People would say, “I saw you did it this way. Try it this way.” So, I would learn that way. I got book deals. I got invited to these amazing conferences.

I continued to do this at another site called Complexification.net, and I got a little more academic, a little more serious where I would write about the algorithm, write about why I did it, and I even began to try to sell prints. So, I was starting to recognize that I was creating these images that were interesting. But, the only way I could share them was online, and I was just giving it all away.

By printing it, it was a way to raise some money and also make the work real. My grandpa wouldn’t even accept my work on the computer. He’s like, “That’s not art. It’s on the computer.” I don’t think we have that problem so much these days.

This is an algorithm that takes images of tornados and creates a box filling algorithm that recreates them.

I was selling my work online. I wrote my own shopping cart. This whole process was extremely difficult. I should say, now I’m publishing my work at a website called Infinite.center. I don’t know why I just keep changing the name. It’s like I’m shedding skin, becoming a new person. But, it was while I was doing this that I discovered a laser cutter.

I went to the first Maker Faire in San Francisco, California. I saw a laser cutter and, immediately, I knew I needed to do that. It was one more way of bringing these algorithms into the real world and actually creating physical, tangible artifacts from the code, more cubes, spheres, pyramids, some staircase algorithms. All these objects are created from an algorithm that then goes to the laser cutter and is cut.

This is just a photograph of the waste of a laser cutter. Who here has experience or has gotten to use one or is part of a maker space?

Yeah, they’re amazing. It’s really fun to watch. It was while I was doing this that something strange happened, and I was kissed by a machine elf or lady luck or whatever you want to call it. I met some friends in New York who saw the work that I was doing, and they invited me to come work on this project with them. It was a marketplace for handmade goods, which eventually became Etsy.

That was a phenomenal experience, starting a company from scratch, creating a better way for artists to get their work to market and, for me, having tried to do that myself and working as an artist, I recognized that this was something important. I lived in Albuquerque the entire time that I worked on Etsy. I’d fly out to Brooklyn, where the headquarters were, occasionally. This is a completely other story for another presentation. But, if you are in the startup game right now and you’re struggling or have questions, I would love to talk to you about this and my own experience. Tonight, I want to stick to generative algorithms.

Of course, Etsy’s success allowed me to do a great number of things. One of them was to buy this old building in downtown Albuquerque. We renovated it into the Levitated Toy Factory which, for me, was a dream come true. Inside, we have a great number of digital fabrication techniques. I hired all my friends, and we went to work. [Laughter] It was at this toy factory that I really just explored what I love doing, which was this type of work; using algorithms to create a great number of things that are basically Lego-like where we can give you the pieces and you can build what we’re showing to build, or you can use them to build your own things.

It turns out that I’m not a very good businessperson. I’m a much better computer programmer. As a toy factory, you’ve never heard of it. We’re working on that. [Laughter] But, we’ve laser cut almost everything. This is gingerbread. I can tell you, when you laser cut gingerbread in the studio, it’s the most amazing--

Audience: [Laughter]

Jared: --experience. It’s like s’mores on the campfire because the laser cutter is literally burning as it cuts.

On the other side is wool, which is hair, and leather, which is skin. Those are terrible things to laser cut.

Let’s look at an algorithm that is particularly fond to a great number of generative artists. It is defined as a line drawing algorithm that defines the space between points. If I create points on the screen, this line is drawn so that all the space in this area is closest to that point, all the space in that area is closest to that point, and so on. This is something called Voronoi after the mathematician that discovered it or formalized it.

You can see that, as I add points, these lines are automatically calculated. I’ve got a super click that, when I click, it’ll create a great number of points in a spiral. No matter where these points originate, the lines are drawn in such a way that this graph is maintained.

Now, isn’t this interesting? All we’re doing is drawing lines to divide space to define which is closest to which. Yet, the results that come out of this are very organic and lifelike. We see this in leaves. We see this in the way mud cracks. We see this in the way metals fall apart and decay, systems of decay.

We’ve used this to create something that I’m quite proud of. It was really fun. We defined the cell block, so the cell has two faces and then a cell membrane or a cell wall. We’re using the Voronoi twice: in the definition of the cell size and then also as the face, to cut away the face. That was mostly to reduce the weight because we took these cells and assembled them into this spherical structure.

Of course, this is a very small-scale model cut out of chipboard. But, we eventually cut this out of cardboard. We would take this to the park, and we would take it to the markets. We would sell our wares inside of the sphere. The idea was, we wanted to attract people over, and it really worked. Unfortunately, it was made out of cardboard so, eventually, it fell apart.

Here we are assembling it. This was the first day that we really had some of the pieces coming together. Of course, we didn’t design just one of these. We designed a system that generates these structures. Really, every time we would click, we could generate an entirely new structure.

Using the same basic rules but being different or unique, the outside, the kids loved it.

Those are some of my coworkers.

It had this strange effect of actually feeling bigger on the inside, like a magic holding bag or something. It really did feel bigger.

Audience: [Laughter]

Jared: We moved it around in the back of the truck, and pieces literally fell out of the back of the truck. The last time we installed it, it kind of looked like this, and I promised my guys that we wouldn’t repair it again.

Of course, laser cutting is not limited to cardboard. This could be laser cut out of plate steel or plywood, and these things could be created quite large, which I’m seeing is quite prevalent here in Germany. You have some amazing architecture using these computational principles.

I did it again.

Audience: [Laughter]

Jared: Here’s another image. This is a halftone image. We’re all familiar with this. How do you get a grayscale image using only black and white? Well, this is a great trick. You size the white dots according to the brightness that you want to achieve so that, when you zoom out, you see a grayscale image.

But, how can we use a halftone image on a laser cut project? If you laser cut this, which I tried to do, immediately you lift it out, you have 10,000 pieces, and everything falls through the grid. It’s just a complete mess. How do we create a grayscale image in a laser cut?

I wrote an algorithm that uses radio lines. Given a point, and Emma Watson’s portrait, I create radio lines around this point. The thickness of the line is determined by the brightness of the image underneath it. In this way, when I laser cut it, I get a single piece that pulls out of the laser. Here’s the detail of that.

It turns out, this is actually a filter in photoshop, so it’s really no big deal.

Audience: [Laughter]

Jared: But, it sure is fun and great to be able to lift a single piece out of this laser cutter.

I’ve noticed that also you have cottonwood trees here in Dusseldorf, these trees that have these cotton seeds that blow in the wind. They’re blooming right now. We have them in New Mexico. I can stare them for hours because I love particles. Particles are interesting because you define a very small, single element, but then create thousands of them. Together, they form a system that is larger than the sum of the parts.

I’m going to show just a little more code. I’ll go through this very quickly. How do you create a particle that moves? A particle has two attributes: X and Y. X is its horizontal position, and Y is its vertical position. Then, in a loop, you just randomly add numbers to it, and you get this kind of behavior.

Another way to expand on this is to create a velocity. You have velocity in the X direction and velocity in the Y direction. Then you modify velocity and add velocity to the position. A little calculus here; you can have acceleration, which modifies velocity, which modifies position.

In this example, instead of modifying the position directly, you modify the direction that you’re heading and then the speed that you’re heading. You get this kind of an effect. It’s this final example that is my favorite because I have the most control over where these particles go.

Here is an example where particles are being instantiated. They leave behind the trail of their movement. I’m also introducing bilateral symmetry and reflecting about the vertical axis. In doing that, it tricks our minds into seeing something almost lifelike because things that are alive tend to have this lateral symmetry. This is another one of my tricks is to just mirror something, and you automatically begin to have more affection towards it.

Here are 100 particles, but computers are like ants, are like us, and they love to work, so let’s create 10,000 particles. Let’s create those 10,000 particles. [Laughter]

Audience: [Laughter]

Jared: Sven tried to give me the other remote, but I picked this one.

Here are 10,000 particles. They’re being instantiated on a ring with lateral symmetry, and I’m also alternating between ages of light and dark. So, at certain points, all the particles are dark and, at other points, all the particles are light. I’ll just stop talking, and we’ll watch this unfold.

[Pulsing humming music]

Jared: Very cool effect. Very simple rules. Oh, and I don’t just work in black and white. Sometimes I will add a little color. This particular algorithm is interesting because the particles have a lifespan. So, after a certain amount of time, they slow down, they stop and fade away.

There’s this amazing animated children’s film called Song of the Sea. In it, there are these magical moments where the girl, the character of the story, is experiencing something wonderful. The film uses these little particles to represent when those moments are happening. You can’t see it in these still frames, but these particles basically look like this.

I recognized that they’re following a very simple rule in their construction, the way they’re created. This is a combinatoric system where, given a certain number of elements to choose from, you arrange them in a certain number of ways. They have a body, and a body is either a solid body or a series of concentric rings. Then they have these orbital particles, and the particles are either equally distributed or sequential.

I thought it was so beautiful that I implemented an algorithm that randomly generates these things. Here, we can see, with those rules, this program just instantiates these little floating particles. You, as a designer, could sit down and draw these things, but I much prefer building the system that generates them so that -- well, I’m lazy.

Audience: [Chuckles]

Jared: Here are 2,000 of them. You’d be hard-pressed to find two identical particles, which is interesting just given those simple rules like the maze example, this combinatoric effect of combining elements, the breadth of complexity possible.

[Chiming music]

Jared: Here, I’m letting them float around. They’re actually attracted to each other in a small way. A great many more of them. And, as a computer programmer, life can be pretty boring because, when you’re in university, you learn all your sorting algorithms. So, here’s a list of numbers. Your sorting algorithm puts them in order. If your program works correctly, there’s your list of numbers in order. [Laughter] No surprises. Very boring.

When I discovered these generative systems where surprises are possible or where you’re tapping into a world that’s so big you can’t see it all, it gives me, as a programmer, excitement. It’s the reason why I do these things.

Here’s another algorithm. It’s like the TRON light cycle. It’s a path that follows a grid. Initially, it takes very large steps, and it looks ahead. If it sees a barrier or an obstruction, it actually reduces its step by half and changes direction. It keeps reducing its step until it eventually just gets to one pixel and then stops.

Here’s just a few. Let’s have a couple thousand. Also, let’s pull the color from a background image that’s not seen and let this unfold.

[Upbeat chimes symbols music]

Jared: Here’s a detail of that.

The title of this presentation is “Generative Spaces,” and I like thinking about spaces and subdividing them. This is one of the classic approaches to subdividing a space. Given a rectangular space, arbitrarily pick if you want to divide it in half vertically or horizontally, and then choose the ratio, also randomly. Then, with the two resulting rectangles, repeat the process. This is something that’s best implemented using a trick called [laughter] recursion.

Audience: [Laughter]

Jared: The best way to describe recursion is that, in order to understand recursion, you must first understand recursion.

Audience: [Laughter]


Jared: Each rectangular space is also on a delay on the time that it takes to subdivide. Although the delay remains the same throughout this program, it’s going to appear as if it’s speeding up, but that’s just due to the number of rectangular regions that we have. And so, my function is very simple in this program. It’s maybe four lines long. The function calls itself. Through this process, we get amazing complexity. I’m embellishing this a little bit by highlighting one side of the divided region and then sliding it over. But, the process is very simple.

[Drum beats]

Jared: Recursion is one of my favorite tricks in computer science, and I like it because it’s a little bit dangerous because you can infinitely call a function and get to the point where you run out of memory and literally crash your computer and lose your work. In fact, sometimes when I do crash, it’s like a celebratory moment because I know it’s working. It’s actually working too good.

Here’s another example using recursion. Much quicker. Same idea. I’m not limiting it to a rectilinear space. I’m actually allowing it to be a little trapezoidal using something called a Quad Tree. I’m randomly placing black dots in the center for artistic effect, I think. The coloring in this example is also representative of how deep the recursion was. It starts at one color and then moves through the rainbow as it gets deeper.

Switching gears, this is an old algorithm. Marc mentioned it. It’s a combinatoric system. Given a 5x5 grid and only two elements, a black tile and a white tile, placing those tiles into the grid on just the first three columns and then introducing lateral symmetry, we generate these symbols, which I affectionately call “invaders.” Here, I’m taking those invaders and generating every possible one. There’s actually 32,768 invaders. That’s 2 to the 15th power and placing them into that subdivided grid. So, two very simple algorithms combined give this amazing complexity.

In this algorithm, I allow you to click an invader to destroy it. Oh, I should say, any time you generate invaders, you should be able to destroy them. And so, at the toy factory, we did create this game where you could play the game; destroy invaders. You get kind of a -- every invader you destroy is kept track of. Then, those invaders are laser engraved into a cube.


Jared: I’m showing this video because it’s so satisfying to me, like blowing out the sawdust on a laser engraved piece. It’s like erasing a chalkboard or mixing paint. These were the cubes that I sent to Munich eight years ago. Does anybody have one of these invader cubes?

Audience member: Yes.

Jared: Oh, I should have brought more. John has got one.

John: I love it.

Jared: [Laughter] Then, magically, these cubes levitate. [Laughter] No, not really. There’s a ferrous core in the middle of this cube, and there’s a magnetic levitation plate underneath the paper.

Now, this is the fun part I really enjoy talking about is why are we here today. What made you decide to come to this conference? It’s a Monday. You could be out doing anything, but you chose to be here, and I think that was the right decision because it’s at conferences like these that you meet the people that will be in your future.

I can tell you, these are some of the people that I’ve met at these conferences. A bus full of Flash nerds. This was taken so long ago; half these people are dead.

Audience: [Laughter]

Jared: [Laughter] Is anybody here that’s in this photo? I don’t think I--

Audience member: (Indiscernible)

Jared: [Laughter] But, I love these conferences because I think that it’s interesting to hear the presentations and to learn these new ideas, but it’s more about the relationships that you’re making here and the experiences that you’re sharing. Whether you know it or not, these are the decisions that will influence your future.

I’ve tried to replicate this feeling in my hometown I Albuquerque and, every Tuesday night at the Levitated Toy Factory, we gather, drink beer, and show each other’s work. We kind of focus on game-making, so it’s called the Albuquerque Game Developers Guild. It’s great because it’s a forum to show your work get feedback from others, create new projects. I’ve seen some amazing projects come out of the friendships that are formed at these meetups.

It was on the airplane on the way to the Reasons To conference in 2008 that I wrote this algorithm, thinking about the people I was going to meet. In it, I tried to imagine that every one of these randomly generated blue areas is an individual and the breadth of your interests. Then the overlapping areas are the areas where you share interests with other people, so you could see these very bright areas. Sometimes there are areas or parts of you that extend out into space, and you’re all alone out there. That’s just fine. But, it’s these areas of intersection that I think are important and are happening right now.

There are always times in our life, as artists or as workers, where we get to a point where you hit the wall and you don’t know why you’re doing what you’re doing, and you don’t know what to work on or what’s important. In times like those, for me, I go back to my childhood, and I try to remember what it was that was fun for me at those times. This is one example of that. This is the yarn -- I don’t know what you call it -- a yarn game, but you nail a bunch of nails. You string the string between and create these patterns.

I can do that now, computationally, very quickly without the time of nailing the nails or stringing the yarn. Actually, that’s the part of the bit that I miss, I’ve realized. But, I can also experiment very quickly with what the patterns are -- the types of patterns I can generate. No matter what, I always seem to come back to just randomly assembled objects. I don’t know what it is. I think it’s in the randomness that you discover what it is you truly like.

Whoop - that’s not supposed to do that.

Here is something great. This was Windows 3.1. This was the screensaver, and so it was so great to see this for the first time as a kid. I think I was about 14 years old. The illusion of flying through space three-dimensionally was just amazing. I saw this animated GIF. It reminded me of that process, and so I recreated it in Processing. Of course, computers have gotten a lot faster, and now I can simulate 10,000 stars in three dimensions.

[Deep sounding music]

Jared: Put against a background image from the Hubble Space Telescope and, because this is being generated randomly, you really can fly through space infinitely.


Jared: If you look really closely at the stars, in addition to just being a star, they actually have these orbital systems around them. This is all Processing. Processing is really good at two-dimensional stuff, and it’s also really good at three-dimensional work.

[Deep sounding music]

Jared: Here it is without the space telescope image. You can see I’m drawing constellations as well. This was about two days’ work and very rewarding. You get to the end of this, and you’re like, “Wow! This is great! Now I do remember why I like doing this.”

Another example is the random walking line. The very first program I ever created was in Logo, and it’s the idea of having a single block of color and then randomly moving up, down, or to the left or to the right, and doing the same thing; putting down some color.

Even this; even the colors here, these are just randomly generated mathematical colors. Garish, very ugly, but just looking at these, I love it. It brings back the feelings of having a computer in front of me. This is amazing. There’s a Commodore 64 on stage. Taking this random walking line, it’s very simple, but what can I do with it?

Here, I’m implementing random walking lines, both in black and white. They’re just walking all over each other, generating this image. But, let’s introduce a background image into it. Instead of immediately putting down the color, let’s look at the color below, move a few steps, and then put the color down, and keep a history of doing that.

On the left, the history is very short. On the right, the history is very long. It’s about 20 steps here, so it’s looking at the color, moving 20 steps, and then putting it down. Here’s a detail of that.

Of course, I ended up spending the entire evening working with this algorithm because I found it very interesting. It almost looks like topology or a satellite photograph or some kind of a very natural system. But, of course, I’m just using these very simple rules. And, a background image of an eye, that helps.

Here’s the very first thing I ever created in Flash.

Audience: [Laughter]

Jared: It was with my wife Laurie, actually. We sat at the computer doing it together. It was a Christmas card that we were working on for some friends. It’s got some snow coming down, some interactivity. You can shovel - nothing.

Audience: [Chuckles]

Jared: But, boy, I mean I should have given up, right?

Audience: [Laughter]


Jared: But, luckily, I didn’t. Thank you.


Jared: Here’s another Flash. This is maybe one of the final things that I created in Flash. I thought, “Wouldn’t it be great to simulate a system where these plusses that are orbiting, on collisions the larger plus consumes the smaller plus.” I thought, “Wow! This would be really cool. What’s going to happen?” Let’s watch this.

[Guitar music]

Jared: Of course, it’s really boring, what happens. There’s a large plus that emerges, and then nobody else has a chance.

[Guitar music]

Jared: It’s like capitalism.

Audience: [Laughter]

Jared: But, of course, I can click. I can destroy it and start all over again. That’s the way it goes. Sometimes the results are not what you expect.

Okay, so this is one of my favorite things to do: circle packing. Click somewhere. Create a circle. Allow it to grow until it hits the edge of the screen or another circle, and then stop. Repeating this process, I get a surface that is completely filled with circles. And, it’s almost like a texture. And, there’s no complex math here. There’s no Apollonian circles or Kepler’s spheres or anything like that going on here. It’s just one circle looking at every other circle and, when it gets close enough, it stops, and then just repeating that process.

Here, I’m just trying to generate as many circles as I possibly can. In this example, when a circle is created inside of a circle that already exists, it switches its color to black and repeats the process. Of course, I’ve used these now as a texture for these cubes. These are laser cut cubes. They have a box tooth algorithm that is so precise, there’s no glue required. They just snap together. Each face is randomly packed with circles so that every cube is unique.

This is the workspace leading up to this conference, creating the cubes that I’ve brought. This is solid hardwood. One is maple and one is cedar. They smell amazing, I think. To me, these are even more valuable than they were when I made them because I brought them in this giant box the whole trip here. Scared they would disappear somewhere, but they made it here, and so I really am happy that I can give these away to you here today.

This was a noise field that I’m just going to skip through - on the interest of time. Although, it’s algorithms like this that make me sometimes question if we’re living in a simulation.

[Beeps and clicks]

Jared: Then another algorithm, a node network creating nodes that randomly connect to each other. In this system, the nodes are either radially created around a center point or linearly created away from the center point. Again, I’m not designing the particular machine that is here. I’m designing a system that generates an infinite number of these machines.

Here’s another one of my tricks. You saw the system working. This is the same system but, instead of drawing white lines, I’m drawing 2% opacity lines over time and never erasing the background so that you actually see a representation of time in the image and not just one particular snapshot.

[Beeps and clicks]

Jared: When drawing networks, groups of nodes that are connected together, it’s nice to draw them in a way where the connections do not cross because our minds have a hard time following that connection. This is an algorithm called force repulsion. In it, nodes that are connected to other nodes pull closer. They pull closer to the nodes they’re connected to while simultaneously pushing away from every other node in the system. This is kind of a sandbox that I’ve created where the nodes are randomly created. Then I can fiddle with the attributes how strong is the attraction, how strong is the force, and then I can pull them around.

This is a very nice algorithm that gives you these really beautiful graphs with almost not having to think about it. One neat thing about it is that, when nodes are created in a loop, you have kind of a cell membrane. I’m going to take some cells and try to pull them inside.

Things can get kind of jittery. The math can get a little weird at the extreme. Here, I’m taking a little group of three nodes and putting them in there where I want them to be. Yet, you can see they just don’t want to be in there, and they push themselves out.

This behavior is almost lifelike. There are examples of this where I accentuate these qualities. I can really get a lifelike thing where these nodes actually appear to be thinking, yet they’re following just those two rules: go closer to the things you’re attached to, push away from everything else, which is a little bit like life.

Here is a system, a drawing system where I am able to draw with those nodes. Every time I press the mouse, I create those nodes, and they automatically connect to nearby nodes. But then, they also have age limits so, eventually, they decay and die.

It turns out that it’s systems like these that are actually used in a lot of the new, really painterly iPad apps when you have the brushstrokes that you get the real painterly effects. They’re implementing systems like this. Of course, they’re not drawing the actual mechanics. They’re drawing pixels. That’s how they do it.

I’ve used this algorithm recently on a new project where the nodes are now towers and the connections are walls. I get to draw these vast castle empires. When I’m happy with the castle that I’ve generated, I can output that to a laser cutter.

Audience member: Wow.

Jared: And, custom build a castle. You can imagine; these are very small, very intricate, but it would be easy to change the scale and actually move these things into an architectural scale where you could get inside these things. That’s something that I’m currently working on.

Who knows what these shapes are?

Audience member: It’s platonic solids.

Jared: Yeah, the platonic solids. Yes. These are the only five shapes that we know of that can be created from the regular polygons. And, you know, I just learned about these recently, which is interesting. They keep coming back to me now, and I make them. I use the same box tooth algorithm as the cubes. Yes, I can create them there. I make them very small. The laser cutter is very precise. And, I make them very big.

That’s my daughter. And, if you’ve ever sat inside of a dodecagon, it’s a weird feeling.

Audience: [Laughter]

Jared: [Laughter] Let me show you something strange. I’m getting to the end of the presentation, and I’m returning to the spider. This is a construction technique that’s purely geometric called The Flower of Life. In it, you begin with the unit circle. On the edge of that circle, you create another circle with the same radius. At the intersection points, you create more circles. You continue that process until you create this object. This is the lattice, the flower of life. It’s from the realm of sacred geometry.

In this structure, if you highlight these particular cells -- Do you see the ones that are just a little thicker? -- and then you connect lines from those cells to every other cell, like we did in that first example, something truly amazing happens, something called The Metatron. Here are those cells. I’ve eliminated the other cells. All the lines have been connected to every other cell. Within this lattice of lines, every one of the platonic solids can be transcribed. Not just two-dimensional transcriptions, but the three-dimensional perspective of the platonic solids is in this very fundamental, basic geometric construction.

This is in the realm of sacred geometry. Why does this happen? I don’t know. I really don’t know.

Audience: [Chuckles]

Jared: But, I think that exploring these things -- “to explore geometry is to explore eternal truth, so a line is always a line; a circle is always a circle. Here on earth or anywhere in the universe, a circle is always going to be a circle.” If we are ever going to have communication with other intelligence, it’s going to be through geometry. This just blows my mind.

That brings us to this point. I’ve talked about what I’m doing, how I do it, where I do it, but why do I do it? Why do I sit in front of the computer writing these algorithms, exploring emergent phenomena?

I’m in this position where I can do almost anything, yet I find myself going back to the computer. The reason is because there is true mystery here. Why do these simple systems produce this complex geometry or this complex behavior? Why do we have cities? Why do we behave the way we do? Do we have free will, or are we machines operating without free will?

I really don’t know. Actually, I kind of go back and forth like, “Oh, we don’t have free will. I’m just a machine.” Or, “No, I just made a conscious decision and I changed my reality.”

For me, exploring these algorithms is a way of exploring the mysteries of the universe. Let me show you a classic from computer science. These are red ants. They are completely blind. They have no idea what they’re doing. They’re randomly walking around. The white things are grains of sand.

These ants are operating on two rules. If they bump into a grain of sand, they pick it up and carry it. If they bump into a grain of sand and they’re already carrying one, they drop the grain of sand that they’re carrying and turn around. Those are the only two rules that these blind ants are operating on. Yet, if you allow this simulation to run, something very mysterious happens.

Here, I’ve introduced a lot more ants. I’m speeding the system up. It’s still doing the exact same thing that it started with, but you can start to see what happens. When I first saw this algorithm, I thought, “No way. There’s no way this actually happened,” so I had to program it myself. Sure enough, it happens.

What happens is that eventually there is one pile of sand. The ants somehow, with no intelligence, take these grains of sand and all move them into the center of the screen into one pile. Eventually, if you want to wrap your mind around this, you can actually start at the end and go backward. You’ll eventually realize why this happens. But, that’s emergence.

Okay. I’ve got one more algorithm, but I have two examples leading up to it. This is an old algorithm called Orbitals where I create particles and drag them down the screen. Then, each particle as a bunch of other particles around it that orbit it. They’re orbiting the particle and other particles orbit that, and so it’s this big system. Then the root nodes are pulled down. It creates this image.

Orbital B was another variation of that. There’s only one fixed node in the very center of the screen, and all other nodes orbit either that or some other node in the system, and I get this.

Then, recently, I’ve created Orbital C, and I’m showing here the mechanics of it. In this system, a node randomly picks another nearby node to orbit. But, at random times, it’s allowed to switch orbits - very simple.

Oh, and there’s one other rule. You can’t orbit a node that’s already orbiting you. This is basically what’s happening. But, what I want to do is let this run. I want to not show the mechanics and just show you the system that emerges. I think you’ll be reminded of natural phenomena, so we’ll just get started here.

[Piano music]

Jared: It starts off very chaotic.

[Piano music]

Jared: But then, it organizes itself.

[Piano music]

Jared: Thank you very much.


Jared: (Indiscernible)