We already mentionned the book **The Nature of Code** in a **previous post** and on our **bibliography** page, a fantastic book to understand basic concepts of “computational design” with **Processing** such as vectors and fields. Daniel Shiffman now has great videos to teach these concepts on his **VIMEO Page**, here is the first of the series:

# Category: Processing

## The Burning Ship Set

Arthur C. Clarke’s documentary on Fractals:

A basic set with fractal behaviour is the set of Complex numbers (C):

No matter how much one zooms in or out, the set is self-similar with infinite detail.

The typical fractal sets (Mandelbrot, Julia, Fatou) follow a pattern of 3 infinities: an * infinite* number of points is run an

**number of times through a recursiveÂ polynomial and it will/will not reach**

*infinite*

*infinity:*To make the step to 3d, the major issue is that the 2d rules cannot beÂ generalizedÂ because there is no corresponding set of numbers for 3d space. 1d space has Real numbers, 2d space has Complex numbers, but there is no 3d equivalent. However, Quaternions (hypercomplex numbers) are a theoretical set of points corresponding to a 4d space. Therefore there are two possible approaches: a) Define a three dimensional set of points in polar coordinates and switch them back to aÂ cartesian coordinates in order to build it in computer space. b) Build a theoretical 4d fractal using hypercomplex numbers and cast its 3d shadow in 3d.

Either way, results are similar:

Dealing with infinite numbers, infiniteÂ iterationsÂ and infinite sets of points, computation times become an issue. One way around this is to build ray-traced images estimating distances to a virtual fractal (not physically storing the points of the fractal in memory):

The image above is magnified ~3.10e13 times. In other words, presuming the size of the sectional model is 1m, it scaled up to roughly the size of the Solar System.

Building 3d models in computer space is slightly trickier because of the huge number of points involved to define even a limited section of a fractal. The issue is to define anÂ algorithmÂ for the correct order of the points in order to build a mesh. A rather neat solution is to ray-trace consecutive sections through a fractal (ray-tracing involves a Z-buffer anyway) and work from there. Here is an example (a 38,000,000 face-mesh obtained from 1,000 sections):

An important tool in exploring 3d fractals is building Julia sets (the only difference is that they use a constant increment at each iteration rather than the initial step):

Software used for my project: Processing, ImageJ FIJI, MeshLab, Netfabb Studio, Jesse’s MandelBulb 3D, Autodesk 3dS Max, Chaos Pro, Adobe Premiere.

## The Nature of Code

Here is the book that I kept mentionning in the tutorial: ** The Nature of Code** by Daniel Schiffman

The book explains many algorithm that attempt to reproduce natural systems (including swarms and fractals) using **Processing**, the java-based scripting interface.

You can download the book and make a donation or buy the hard copy. Try some examples, register to the **Processing forum** and to **StackOverflow.com**. Ask for help on the **Processing IRC Channel**.

For some example, you will need to need to download the **Toxiclibs **library and you might want to use the **Eclipse IDE** to speed up your workflow. You can also follow the great Plethora-Project.com tutorials by Jose Sanchez.

## Reaction-Diffusion – Alan Turing

Below are several **Reaction Diffusion System **apps which help to understand the parameters at play on the famous algorithm developed by Alan Turing (1912-1954).

The first one is programmed in Java: **http://cgjennings.ca/toybox/turingmorph/**

The source code is available for you to tweak in a java app, you can use the **Eclipse IDE** (integrated development environment) to program in Java and test the results: **Â http://cgjennings.ca/toybox/turingmorph/TuringMorph.java**

The second one is programmed using Processing which is a language based on Java: **http://www.openprocessing.org/sketch/15905**

To download and try Processing go to **Processing.org** you can download the interface for free and access the forum for help.

A 3D processing app and pavillion design was done by BioThing (Alisa Andrasek and Jose Sanchez) based on the same Turing patterns: **http://www.biothing.org/?p=449Â **Biothing also held a workshop with the DRL studio based on 3D reaction diffusion patterns:

Some of Biothing’s code is available on their **Genware website**. Some Processing tutorials are available on this great website by Jose Sanchez: **http://www.plethora-project.com/**

Finally, the creators of Hoopsnake, **Volatile Prototype**,Â have created a processing library,** ReactP5** to create Reaction-Diffusion patterns in 3D: **http://volatileprototypes.com/libraries/ReactP5/**

## Digital Representation

This is my submission for the Digital Representation module at the University. The first part focuses on learning how to use Bentley’s Generative Components to explore geometry and in particular ruled surfaces. The module tries to give an insight into understanding how to construct geometry and how the process can be developed parametrically. It then explores creating your own object classes and feature types to expand the abilities of the software and increase efficiency in modelling. Finally the module looks at developing an understanding of scripting and the syntax needed to code 2D and 3D computer programmes and models using both Processing and scripting within Generative Components. The second part looks at using the tools to develop our studio proposals, in my case the proposal for a pavilion at Burning Man Festival.

## Processing Workshop with Toxiclibs

Karsten SchmidtÂ has just posted the **source code** from the Processing Workshop which I organized Â atÂ **Metropolitan WorkÂ **with Marcus Bowerman. On **Toxiclibs,** he explains how to import the files using the java editor **Eclipse.**Â I posted some pictures on **my website** too. Below are couple images and pictures of the workshop:

Â *Above: The class on the first workshop dayÂ *

*Above: Karsten showing how to make mesh faces on Processing*

Â *Above: The Rapid Prototyped model exported from Processing developed on the first day*

*Above: The Processing Â faÃ§adeÂ app which wasÂ developedÂ on the second day : Define aÂ faÃ§adeÂ in plan on the right using a curve, add and control points on theÂ faÃ§adeÂ with particle physics and use voxels to solidify. More info.*

## 3D Fractals

Tom Beddard, Physicist, Animator and Web Developer, explores the relatively new field of 3D fractals. By writing his own software to render new sets of mathematical algorithms that generate 3D structures with unlimited detail. He investigates the resulting wide range of structures ranging from the natural and organic to geometric and artificial, appearing from purely mathematical space.

A collaborative effort on developing 3D fractal algorithms on fractal forums has enabled many programmers to start exploring this new field; free web software generates interactive 3D fractals in real time.

Generating fractal images is more like exploration than design and Tom Beddard explores an entire â€˜fractal planetâ€™ shown in the videos below. More information at **SubBlue**.

## Generative Design Work

**Processing** is an open source programming language and environment for people who want to create images, animations, and interactions and created by **Casey Reas** and **Ben Fry**.

It has been used Â by Architect, Graphic Designers,Â JewelleryÂ makers and anyoneÂ interestedÂ in Generative processes based on simple rules with a beautiful graphical and interactive output.Â Below are a few examples:

First lets start with the creators of “Libraries” which are like Plugins one can add to Processing in order to use pre-determined functions such as 3D viewer or Physics.Â One of the most famous libraries, **Toxiclibs**, isÂ developedÂ by the self-taught designer Karsten Schmidt, director of **PostSpectacular.**

*Above: Kartsen Schmidt’s work exhibited at the V&A as part of their Cult Of Beauty aestheticismÂ exhibition.Â *

**N-E-R-V-O-U-S** is a design studio which uses Processing to generateÂ jewellery and furniture based on natural systems and simple laws.Â Thanks to an online Processing interface and Toxiclibs library, the “product” is generated according to the buyers’ wishes and then fabricated using a 3D printer. Below are images and **videos** of their work:

*Above: Image and video of Laplacian Growth System*

*Above: Hele-Shaw Cell experiments with Paint and Plastic*

*Above: Hyphae Growth Process Diagram and Lamp Images*

**Biothing** is an Architectural Practice led by Alisa Andrasek and Jose Sanchez, below is a project they haveÂ developedÂ with the large scale 3D printer **D-Shape** based on the Turing Patterny:

*Above: TuringÂ Pavilion by Biothing using Processing Â Â *

One of the **AA DRL** Masters team (**Thiago Mundim**, Sanhita Chaturvedi and Esteban ColmenaresÂ taught by Marta MalÃ©-Alemany,Daniel Piker & Jeroen Van Ameijde), developed a revolutionary technique to knit on a building scale:

*Â Above: the Knitectonics Project Interface, using Processing and the Toxiclibs Library*

## Processing Resources

Ways to start learning theÂ **Processing**Â Programming Language:

-Have a look at **Open Processing**Â where people share their sketches.

*Above: Field Line Designer, a Sketch by bitcraft*

–**The Plethora Project**, Â Video Tutorials by Jose Sanchez, partner at **Biothing**

*Above: Processing Video Tutorial 1 by Jose Sanchez*

And of course, **The Processing Forum**