Home

Awesome

Digital morphogenesis is the exploration of how shapes, forms, and patterns emerge in nature through the use of computational modeling and generative systems based on biological, chemical, and physical processes. It draws upon research from practically every area of the natural sciences and has applications in architecture, digital fabrication, art, engineering, biomedicine, and more.

With such a cross-disciplinary topic it can be hard to keep track of and correlate all the interesting bits of knowledge that one comes across, which is where this list comes in. The goal of this list is to succinctly catalog various growth algorithms and lab experiments along with relevant math, physics, and programming concepts in one place in order to (1) serve as a sort of "cheat sheet" reference for developers and computer artists, and (2) spark new insights by making it easier to see relationships between seemingly disparate topics.

Contributions are always welcome! If you'd like to add a description for any topic, or have some interesting and relevant links to share, or know of a topic that should be included somewhere in this document, please feel free to open an issue or a PR with your changes.

<br> <table> <thead> <tr> <th>Table of contents</th> </tr> </thead> <tbody> <tr> <td> <details> <summary>Growth algorithms <a href="#growth-algorithms">[#]</a></summary> <p> <ul> <li><a href="#dielectric-breakdown-model-dbm">Dielectric breakdown model (DBM)</a></li> <li><a href="#diffusion-limited-aggregation-dla">Diffusion-limited aggregation (DLA)</a></li> <li><a href="#differential-growth">Differential growth</a></li> <li><a href="#eden-growth-model">Eden growth model</a></li> <li><a href="#physarum">Physarum</a></li> <li><a href="#primordial-particle-system">Primordial Particle System</a></li> <li><a href="#reaction-diffusion">Reaction-diffusion</a></li> <li><a href="#space-colonization">Space colonization</a></li> </ul> </p> </details> <details> <summary>Math and physics topics <a href="#math-and-physics-topics">[#]</a></summary> <p> <ul> <li><a href="#archimedean-solids">Archimedean solids</a></li> <li><a href="#cellular-automata-ca">Cellular automata</a></li> <li><a href="#cymatics">Cymatics</a></li> <li><a href="#delaunay-triangulation-and-voronoi-diagrams">Delaunay triangulation and Voronoi diagrams</a></li> <li><a href="#fibonacci-sequence">Fibonacci sequence</a></li> <li><a href="#fourier-series">Fourier series</a></li> <li><a href="#fractals">Fractals</a></li> <li><a href="#geodesic-dome">Geodesic dome</a></li> <li><a href="#golden-angle">Golden angle</a></li> <li><a href="#golden-ratio">Golden ratio</a></li> <li><a href="#implicit-surface">Implicit surface</a></li> <li><a href="#inverse-and-forward-kinematics">Inverse and forward kinematics</a></li> <li><a href="#laplace-transform">Laplace transform</a></li> <li><a href="#lissajous-curves">Lissajous curves</a></li> <li><a href="#medial-axis">Medial axis</a></li> <li><a href="#minimal-surface">Minimal surface</a></li> <li><a href="#packing-problems">Packing problems</a></li> <li><a href="#percolation-theory">Percolation theory</a></li> <li><a href="#phyllotaxis">Phyllotaxis</a></li> <li><a href="#platonic-solids">Platonic solids</a></li> <li><a href="#saffmantaylor-instability">Saffman–Taylor instability</a></li> <li><a href="#spherical-harmonics">Spherical harmonics</a></li> <li><a href="#strange-attractors">Strange attractors</a></li> <li><a href="#superellipse">Superellipse</a></li> <li><a href="#superformula">Superformula</a></li> </ul> </p> </details> <details> <summary>Natural phenomena</summary> <p> <i>See <a href="https://github.com/jasonwebb/morphogenesis-resources/blob/main/Natural-phenomena.md">Natural-phenomena.md</a></i> </p> </details> <details> <summary>Lab experiments <a href="#lab-experiments">[#]</a></summary> <p> <ul> <li><a href="#belousovzhabotinsky-bz-reaction">Belousov–Zhabotinsky (BZ) reaction</a></li> <li><a href="#chladni-plate">Chladni plate</a></li> <li><a href="#hele-shaw-cell">Hele-Shaw cell</a></li> <li><a href="#schlieren-imaging">Schlieren imaging</a></li> </ul> </p> </details> <details> <summary>Useful code patterns and techniques <a href="#useful-code-patterns-and-techniques">[#]</a></summary> <p> <ul> <li><a href="#agent-based-modelling">Agent-based modelling</a></li> <li><a href="#boids">Boids</a></li> <li><a href="#collision-detection">Collision detection</a></li> <li><a href="#constructive-solid-geometry-csg">Constructive solid geometry (CSG)</a></li> <li><a href="#dithering">Dithering</a></li> <li><a href="#flow-field">Flow field</a></li> <li><a href="#fluid-simulation">Fluid simulation</a></li> <li><a href="#lloyds-relaxation">Lloyd's relaxation</a></li> <li><a href="#marching-squares">Marching squares</a></li> <li><a href="#marching-cubes">Marching cubes</a></li> <li><a href="#metaballs">Metaballs</a></li> <li><a href="#noise">Noise</a></li> <li><a href="#particle-system">Particle system</a></li> <li><a href="#physics-engine">Physics engine</a></li> <li><a href="#polygon-clipping">Polygon clipping</a></li> <li><a href="#ray-tracing">Ray tracing</a></li> <li><a href="#recursion">Recursion</a></li> <li><a href="#shaders">Shaders</a></li> <li><a href="#signed-distance-function-sdfs">Signed distance functions (SDFs)</a></li> <li><a href="#spatial-index">Spatial index</a></li> <li><a href="#vectors">Vectors</a></li> <li><a href="#wave-function-collapse-wfc">Wave Function Collapse (WFC)</a></li> </ul> </p> </details> ▸ <a href="#books-publications-and-talks">Books, publications, and talks</a><br> ▸ <a href="#software">Software</a> </td> </tr> </tbody> </table> <br>

Growth algorithms

Dielectric breakdown model (DBM)

TODO

Articles:


<a href="https://www.jasonwebb.io/2019/05/diffusion-limited-aggregation-experiments-in-javascript/" target="_blank"><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/diffusion-limited-aggregation-1.gif?raw=true" width="300" height="300" align="right" title="Jason Webb - Diffusion Limited Aggregation Experiments"></a>

Diffusion-limited aggregation (DLA)

Process in which particles of matter stick together (aggregate) as they chaotically move (diffuse) through a medium that provides some sort of resistive (limiting) force. As these particles clump together over time they form characteristic fractal branching structures known as Brownian trees.

Very interesting macro-structures begin to emerge at around the 1-10 million particle range in 3D, but in order to get there you'll need to be smart about your rendering pipeline and make use of optimized code in a performant language or environment (C/C++, CUDA, GLSL shaders, Houdini, etc).

Algorithm at a glance:

  1. Add initial point(s) or shapes to seed growth.
  2. Add a number of walker particles.
  3. In each tick of the simulation, do the following:
    1. Move each walker a small amount in a random direction.
    2. If any walker particle is colliding with a fixed/clustered particle, convert that walker particle into a fixed/clustered particle.

Key terms:

Articles:

Code projects:

Creative projects:

Notable software:

Videos:


<a href="https://www.jasonwebb.io/2019/05/differential-growth-experiments-in-javascript/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/differential-growth-1.gif?raw=true" width="300" height="300" align="right" title="Jason Webb - Differential growth experiments in JavaScript"></a>

Differential growth

Process that acts on continuous chains of nodes connected by lines using simple rules (attraction, repulsion, alignment; not unlike boids) in order to produce undulating, buckling forms that mimic or simulate meandering rivers, rippled surface textures of plants/seeds/fruits, space-filling behaviors of worms, snakes, intestines, and much more.

Algorithm at a glance:

2D:

  1. Begin with a set of nodes connected in a chain-like fashion to form a path (or multiple paths). Each node should have a maximum of two neighbors (one preceding, one following).
  2. In each tick of the simulation, for each node:
    1. Move node towards it's connected neighbor nodes (attraction).
    2. If node gets too close to any nearby nodes (connected or not), move it away from them (repulsion).
    3. Move node towards the midpoint of an imaginary line between it's preceding and following nodes (alignment). It wants to rest equidistance between them with as little deflection as possible.
  3. In each tick of the simulation, evaluate the distances between each pair of connected nodes. If too great, insert a new node between them (adaptive subdivision).
  4. At some interval, insert new nodes in the chain to over-constrain the system and induce growth. The bends and undulations that emerge are a result of the system trying to equalize the forces using the rules defined in step 2.

Articles and discussions:

Code projects:

Creative projects:


<a href="https://www.researchgate.net/figure/color-online-A-small-Eden-cluster-with-6000-particles-The-border-is-depicted-in-red_fig1_1858140" target="_blank"> <img src="https://raw.githubusercontent.com/jasonwebb/morphogenesis-resources/main/images/eden-growth-model-1.png" width="300" align="right" title="Silvio Costa Ferraria et al - Figure 1 from Pitfalls on the determination of the universality class of radial clusters"></a>

Eden growth model

Created by Murray Eden in 1961, this is a type of surface fractal growth process where material randomly accumulates on the boundary of clusters. Sort of like DLA but without all the empty space between branches. Thought to be a good way to model certain kinds of bacterial and lichen growth.

Articles:


<a href="https://cargocollective.com/sagejenson/physarum" target="_blank"><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/physarum-1.gif?raw=true" width="300" align="right" title="Sage Jenson - Physarum"></a>

Physarum

Image credit to Sage Jenson (@mxsage)

Technique for modelling the observed behaviors of the slime mold physarum polycephalum using agent-based modelling. Originally described in 2010 paper by Jeff Jones, and more recently popularized by artist Sage Jensen (@mxsage), this algorithm produces highly dynamic and organic-looking webs that can seem very life-like and biological in nature.

Algorithm at a glance:

* indicates a potential simulation parameter

  1. Consider the simulation space as a grid, with each cell storing a number representing the combined strength of pheromones left by the agents who have passed through it.
    • Pheromones in each cell diffuse at some rate* to neighboring cells as they decay (at some rate*) in each step of the simulation.
  2. Add a set of points, each representing an autonomous agent.
  3. Each agent leaves a trail of decaying pheromones behind by adding a number* to the cells it passes through.
  4. Each agent senses the total phermone strength of cells in front of it defined by a distance* and a field of view angle*.
  5. An agent will gradually adjust its direction* to steer towards the cell(s) with the most pheromones.
  6. Render the trails (not the agents) by mapping the pheromone strength number in each cell to a range or gradient of colors.

Articles:

Code projects:

Creative projects:


Primordial Particle System

TODO

Articles:


<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/reaction-diffusion-1.jpg?raw=true" width="250" align="right" title="Author unknown"></a>

Reaction-diffusion

Grid-based process that generates complex and dynamic patterns based the interactions of two chemicals as they diffuse through a medium and react with one another. At every location on the grid these chemicals (usually referred to as A and B) have a chance of causing a reaction that converts chemicals of one type to another based on their relative concentrations at that location.

Throughout the simulation chemical A is added at a particular feed rate (f) and chemical B is removed at a particular kill rate (k) - adjusting these rates can result in wildly different emergent patterns.

Equation (via Karl Sims): Karl Sims - reaction-diffusion equation

Key terms:

Articles:

Notable tools:

Code projects:

Creative projects:

Videos:


<a href="https://www.jasonwebb.io/2020/03/space-colonization-branching-experiments-in-javascript/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/space-colonization-1.gif?raw=true" width="300" height="300" align="right" title="Jason Webb - Space colonization experiments in JavaScript"></a>

Space colonization

Process for iteratively growing networks of branching lines based on the distribution of growth hormone sources (called "auxin" sources) to which the lines are attracted. Originally described by Adam Runions and collaborators at the Algorithmic Botany group at the University of Calgary, this system can be used to simulate the growth of leaf venation patterns and tree-like structures, as well as many other vein-like systems like Gorgonian sea fans, circulatory systems, root systems, and more.

The original algorithm describes methods for generating both "open" (as seen in the example GIF) and "closed" venation networks, referring to whether or not secondary or tertiary veins connect together to form loops (or anastomoses).

Algorithm at a glance:

For both the open and closed variants of this algorithm, begin by placing a set of points on the canvas representing sources of either the auxin growth hormone (as in leaves) or ambient nutrients (as in trees).

Open venation:

  1. Associate each auxin source with the single closest vein segment within a pre-defined attraction distance.
  2. For each vein segment that is associated with at least one auxin source, calculate the average direction towards them as a normalized vector and generate a new vein segment that extends in that direction at a pre-defined segment length (by scaling the normalized direction vector by that length).
  3. Remove any auxin sources that have vein segments within a pre-defined kill distance around it.

Closed venation:

  1. Associate each auxin source with all of the vein segments that are both within a pre-defined attraction distance and within the source's relative neighborhood.
  2. For each vein segment that is associated with at least one auxin source, calculate the average direction towards them as a normalized vector and generate a new vein segment that extends in that direction at a pre-defined segment length (by scaling the normalized direction vector by that length).
  3. Remove any auxin sources that have been reached by all of their associated vein segments.

Auxin flux canalization:

  1. Give each vein segment a uniform default thickness to start with.
  2. Beginning at each terminal vein segment (that is, segments with no child segments), traverse "upwards" through each parent vein segment, adding their child vein segment thickness to their own until you reach a root vein segment (a segment with no parent segment).

Key terms:

Articles and papers:

Creative projects:

Code projects:

Videos:

<br>

Math and physics topics

<a href="https://kids.britannica.com/students/assembly/view/230371" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-1.webp?raw=true" width="300" align="right" title="Britannica Kids - Archimedean solids"></a>

Archimedean solids

Set of 13 semi-regular convex polyhedra composed of regular polygons meeting in identical vertices, excluding the 5 Platonic solids (which are composed of only one type of polygon) and excluding the prisms and antiprisms.

Each shape can be constructed by starting with one of the Platonic solids and truncating it's corners or edges in various ways.

List of Archimedean solids:

NameFacesEdgesVerticesImage
Truncated tetrahedron4 triangles<br>4 hexagons1812<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-truncated-tetrahedron.gif?raw=true" width="50">
Cuboctahedron8 triangles<br>6 squares2412<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-cuboctahedron.gif?raw=true" width="50">
Truncated cube8 triangles<br>6 octagons3624<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-truncated-cube.gif?raw=true" width="50">
Truncated octahedron6 squares<br>8 hexagons3624<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-truncated-octahedron.gif?raw=true" width="50">
Rhombicuboctahedron8 triangles<br>18 squares4824<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-rhombicuboctahedron.gif?raw=true" width="50">
Truncated cuboctahedron12 squres<br>8 hexagons<br>6 octagons7248<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-truncated-cuboctahedron.gif?raw=true" width="50">
Snub cube32 triangles<br>6 squares6024<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-snub-cube.gif?raw=true" width="50">
Icosidodecahedron20 triangles<br>12 pentagons6030<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-icosidodecahedron.gif?raw=true" width="50">
Truncated dodecahedron20 triangles<br>12 decagons9060<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-truncated-dodecahedron.gif?raw=true" width="50">
Truncated icosahedron12 pentagons<br>20 hexagons9060<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-truncated-icosahedron.gif?raw=true" width="50">
Rhombicosidodecahedron20 triangles<br>30 squares<br>12 pentagons12060<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-rhombicosidodecahedron.gif?raw=true" width="50">
Truncated icosidodecahedron30 squares<br>20 hexagons<br>12 decagons180120<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-truncated-icosidodecahedron.gif?raw=true" width="50">
Snub dodecahedron80 triangles<br>12 pentagons15060<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/archimedean-solids-snub-dodecahedron.gif?raw=true" width="50">

Articles:

Videos:


<a href="https://softologyblog.wordpress.com/2018/06/29/multiple-rules-cellular-automata/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/cellular-automata-1.gif?raw=true" width="300" align="right" title="Softology - Multiple Rules Cellular Automata"></a>

Cellular automata (CA)

A regular grid of cells with states that are updated each iteration in according to rules. Developed by Stanislaw Ulam and John von Neumann at the Los Alamos National Laboratory in the 1940s, this system has been used to model physical, biological, and social phenomena with remarkable variety and accuracy.

Key terms:

Types:

Wolfram's classification:

Stephan Wolfram defined four classes that can be used to describe any cellular automaton or other simple computational model based on their observed behaviors. These definitions are qualitative in nature, with some room for intepretation, but are nonetheless considered the most effective classification scheme that currently exists for cellular automata.

Well-known rules and rule families:

Articles, books, and other writings:

Code projects:

Creative projects:

Notable software:


<a href="https://en.wikipedia.org/wiki/Cymatics" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/cymatics-1.jpg?raw=true" width="300" align="right" title="Wikipedia - Cymatics"></a>

Cymatics

See Chladni plate

Study of the visible effects of sound and vibration on physical media. Typically involves the vibration of a plate or membrane onto which fine powder or fluids have been placed, which subsequently arrange themselves into highly symmetrical, complex patterns based on the intensity of displacement of various regions of the vibrating plate. Areas that are moving a lot will "kick" material away from them while areas that are moving very little allow material to settle and accumulate. These areas of relatively little vibration are caused by destructive interference of waves as they propagate across the plate/membrane and become out of phase with one another, creating "dead zones" where these waves cancel each other out.

Articles:

Creative projects:


<a href="https://en.wikipedia.org/wiki/Delaunay_triangulation" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/delaunay-voronoi-1.png?raw=true" width="300" align="right" title="Wikipedia - Delaunay triangulation"></a>

Delaunay triangulation and Voronoi diagrams

Delaunay triangulation is a way of connecting a set of points to form a network of non-overlapping triangles. One of the key properties of Delaunay triangulations is that the circumcircles associated with each triangle contains no other points than their three triangle vertices. When extended into 3D, Delaunay triangulation is useful for creating meshes.

Voronoi diagrams are the dual of Delaunay triangulations. This means that once a Delaunay triangulation has been computed for a set of points, a Voronoi diagram can be drawn without any additional data - just draw lines connecting the centers of the circumcircles!

Voronoi diagrams are very useful for efficiently and organically partitioning (splitting up) both 2D and 3D space. They are especially good for accurately modelling the way soft bodies (like biological cells) get smushed together in constrained environments, like embryonic cells undergoing mitosis.

Voronoi diagrams are often used (perhaps overused) in digital fabrication applications, especially 3D printing, for their characteristic aesthetic style and their ability to reduce material usage while preserving overall form. Given their popularity among amateur 3D printing enthusiasts, this effect is probably best used sparingly in serious applications.

Articles:


<a href="https://en.wikipedia.org/wiki/Fibonacci_sequence" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/fibonacci-sequence-1.png?raw=true" width="300" align="right" title="Wikipedia - Fibonacci sequence"></a>

Fibonacci sequence

Related to Golden ratio

Sequence of numbers in which each number is the sum of it's two preceding numbers. Binet's formula shows that the ratio of two consecutive numbers tends towards the golden ratio as the sequence progresses. Fibonacci numbers appear unexpectedly often in biology, having been observed in branching of trees, the arrangement of leaves on a stem, the fruit sprouts of a pineapple, the flowering of an artichoke, an uncurling fern and the arrangement of a pine cone's bracts.

<table> <thead> <tr> <th><center>Formula</center></th> </tr> </thead> <tbody> <tr> <td> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/fibonacci-sequence-2.svg?raw=true"><br> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/fibonacci-sequence-3.svg?raw=true"> </td> </tr> </tbody> </table>

Sequence begins with:

<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/fibonacci-sequence-4.svg?raw=true">

Articles:


<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/fourier-series-1.gif?raw=true" width="300" align="right" title="Author unknown">

Fourier series

Series of sinusoidal wave functions that get added together to generate a different, more complex function. In the context of morphogenesis (form generation), any line drawing can be "deconstructed" into a series of arc segments which can in turn be represented by a series of circles whose radii and rotation speeds correspond to the radii and lengths of the arc segments.

Fourier series and Fourier transforms are deeply mathematical topics with applications and research far beyond the scope of this resource list. They are extremely useful in the field of digital signal processing for noise reduction, compression, audio analysis, and so much more. A very well-known algorithm known as the fast Fourier transform (FFT) enables extraction of waveforms from music for the purposes of audio visualization.

Articles:

Videos:


<a href="https://en.wikipedia.org/wiki/Mandelbrot_set" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/fractals-1.jpg?raw=true" width="300" align="right" title="Wikipedia - Mandelbrot set"></a>

Fractals

Infinitely complex patterns generated via recursion that are self-similar across all scales. Thought to be found in abundance in nature, though "true" (infinite) fractals are not possible because nature uses physical matter, which has particular structures at the microscopic and smaller scales (molecules, atoms, elementary particles, etc).

Fractal features can be observed in nature in tree branching structures, leaf veins, terrain, surface textures, coastlines, rivers, succulents, snowflakes, rivers, lightning bolts, nautilus shells (both form and pattern), and so much more.

Key terms:

Notable fractals:

Articles:

Notable software:


Geodesic dome

TODO

Articles:


<a href="https://en.wikipedia.org/wiki/Golden_angle" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/golden-angle-1.png?raw=true" width="300" align="right" title="Wikipedia - Golden angle"></a>

Golden angle

Related to the golden ratio and phyllotaxis.

Radial version of the golden ratio. It is the smaller of the two angles created by sectioning the circumference of a circle according to the golden ratio; that is, into two arcs such that the ratio of the length of the smaller arc to the length of the larger arc is the same as the ratio of the length of the larger arc to the full circumference of the circle.

In degrees the angle is approximately 137.5077640500 ..., or just 137.5 for brevity.

Articles:

Creative projects:


<a href="https://en.wikipedia.org/wiki/Golden_ratio" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/golden-ratio-1.png?raw=true" width="300" align="right" title="Wikipedia - Golden ratio"></a>

Golden ratio

Related to the Fibonacci sequence.

Also expressed as the Greek letter phi (φ), this irrational number pops up when the ratio of two numbers is the same as the ratio of their sum to the largest of the two numbers. It has been observed in many fields of the natural sciences at every scale and is has become associated with aesthetic beauty, giving it a nearly mythic reputation for some.

Expressed algebraicly:

<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/golden-ratio-2.svg?raw=true">

Expressed as line segments:

<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/golden-ratio-3.svg?raw=true">

Articles:


<a href="https://en.wikipedia.org/wiki/Implicit_surface" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/implicit-surface-1.png?raw=true" width="300" align="right" title="Wikipedia - Implicit surface"></a>

Implicit surface

A surface defined by an equation in the form of <img src="https://wikimedia.org/api/rest_v1/media/math/render/svg/f797686e3ef2f8f21155bd4f035b8d40f288ab95">. The surface itself is defined by the set of zeros of such a function. Implicit surfaces are infinitely scalable, and are much more smooth / "blobby" than surfaces defined explicitly by vertices and faces. However, they are more difficult and computationally expensive to render, requiring an algorithm like raymarching or marching cubes in order to represent the surface on a 2D screen.

Examples of implicit surface equations:

SurfaceEquation
Plane<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/implicit-surface-2.svg?raw=true">
Sphere<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/implicit-surface-3.svg?raw=true">
Torus<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/implicit-surface-4.svg?raw=true">
Surface of genus 2<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/implicit-surface-5.svg?raw=true">
Surface of revolution<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/implicit-surface-6.svg?raw=true">

Articles:

Notable software:


<a href="https://en.wikipedia.org/wiki/Robot_kinematics" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/inverse-forward-kinematics-1.gif?raw=true" width="300" align="right" title="Wikipedia - Robot kinematics"></a>

Inverse and forward kinematics

Equations used to calaculate the positions of a series of rigidly-linked segments (called the kinematic chain) based on the location of the end effector, usually located at the tip of the last segment. Useful for robotic systems like drawing machines, robot arms, and more.

Inverse kinematics calculate the angles of each linked segment given the desired location of the end effector. Will give you the angles of each segment, which can in turn be converted into motor positions for a robot.

Forward kinematics calculate the location of the end effector given the angles and lengths of each linked segment.

Articles:

Videos:


Laplace transform

TODO

Lissajous curves

Also known as Bowditch curves, these figures plot the trajectories of a point as it follows the path of two simultaneous sinusoidal motions.

Can be created using various physical systems including oscilloscopes, harmonographs, and more.

Equations:

<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/lissajous-1.jpg?raw=true"><br> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/lissajous-2.jpg?raw=true">

Articles:

Videos:


<a href="https://www.researchgate.net/figure/Medial-Axis-Transform_fig25_296196212" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/medial-axis-1.jpg?raw=true" width="300" align="right" title="Ashish A Gupta - Figure 3 from Writer Dependent Handwriting Synthesis"></a>

Medial axis

The medial axis is sort of like the "skeleton" of a shape. It consists of a set of lines and curves upon which every point is equidistant between at least one closest point on the shape's boundary. In 2D this skeleton can also be thought of as a set of lines/curves whose points are the centers of circles that are tangent to at least two points on the shape's boundary.

Has applications in computer vision, pose estimation, 2D/3D character rigging, architecture, BIM (escape route optimization), and more.

Related terms:

Articles:

Notable Tools:


Minimal surface

TODO

Articles:


<a href="https://en.m.wikipedia.org/wiki/Packing_problems" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/packing-problems-1.png?raw=true" width="300" align="right" title="Wikipedia - Packing problems"></a>

Packing problems

Class of optimization problems that involve determining efficient ways to arrange (pack) objects into containers. Packing problems can be tackled using discrete mathematical methods, physics systems (as seen in Nervous System's Kinematics series), and even genetic algorithms and machine learning.

Has major applications in digital fabrication, manufacturing, and shipping logistics where material and space usage is directly related to costs. In 2D, packing/nesting problem solutions are useful for minimizing waste material in sheet goods like plywood and sheet steel, even for hobbyists. In 3D these solutions are useful for fitting as many objects as possible into 3D printer build envelopes (see article from Sculpteo).

Related terms:

Articles:

Notable tools:

Videos:


Percolation theory

TODO

Articles:

Code projects:


<a href="https://en.wikipedia.org/wiki/Phyllotaxis" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/phyllotaxis-1.jpg?raw=true" width="300" align="right" title="Wikipedia - Phyllotaxis"></a>

Phyllotaxis

Related topics include the golden ratio, the golden angle, and the Fibonacci sequence.

Refers to the arrangement (taxis) of leaves (phyllo) on a plant stem. Also can refer to seed arrangements and succulent geometry.

Types:

Articles:

Code projects:

Videos:


<a href="https://mathmonks.com/platonic-solids" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/platonic-solids-1.jpg?raw=true" width="300" align="right" title="Math Monks - Platonic Solids"></a>

Platonic solids

Set of regular, convex polyhedra constructed using congruent, regular polygonal faces with the same number of faces meeting at each vertex. Euclid (and perhaps Theaetetus proved mathematically that there are only five shapes that fit this criteria (below).

NamePolygon typeFacesEdgesVerticesImage
TetrahedronTriangle464<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/platonic-solids-tetrahedron.gif?raw=true" width="50" title="Wikipedia - tetrahedron">
CubeSquare6128<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/platonic-solids-cube.gif?raw=true" width="50" title="Wikipedia - cube">
OctahedronTriangle8126<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/platonic-solids-octahedron.gif?raw=true" width="50" title="Wikipedia - octahedron">
DodecahedronPentagon123020<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/platonic-solids-dodecahedron.gif?raw=true" width="50" title="Wikipedia - dodecahedron">
IcosahedronTriangle203012<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/platonic-solids-icosahedron.gif?raw=true" width="50" title="Wikipedia - icosahedron">

Articles:

Videos:


Saffman–Taylor instability

Related to the Hele-Shaw cell experiment.

Also known as viscous fingering.

TODO

Articless:


Spherical harmonics

TODO

Articles:


<a href="https://en.wikipedia.org/wiki/File:Attractor_Poisson_Saturne.jpg" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/strange-attractors-1.jpg?raw=true" width="300" align="right" title="Wikipedia - File:Attractor Poisson Saturne.jpg"></a>

Strange attractors

TODO

Notable attractors:

Articles:


<a href="https://en.wikipedia.org/wiki/Superformula" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superellipse-1.png?raw=true" width="300" align="right" title="Wikipedia - Superformula"></a>

Superellipse

Also known as the Lamé curve, this equation describes a closed curve that can generate shapes that look like pinched or inflated ellipses. At the extremes of the parameter space the shapes can range from an outline of a plus (+) symbol to a nearly rectangular shape with rounded corners.

Equations:

<table> <tr> <td valign="top">General form</td> <td><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superellipse-2.svg?raw=true"></td> </tr> <tr> <td valign="top">Parametric</td> <td><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superellipse-3.svg?raw=true"></td> </tr> </table>

Articles:

Videos:


<a href="https://andrewmarsh.com/software/supershapes-web/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superformula-1.png?raw=true" width="300" align="right" title="Andrew Marsh - Supershapes"></a>

Superformula

Generalized version of the superellipse formula proposed by Johan Giellis around 2000, capable of far more variety than the original superellipse. Unfortunately, Johan has patented use of the formula (via his company Genicap) in both the US and the EU, which means you should avoid using it for any kind of commercial work, or work that could be commercialized in some way later.

The superformula can be used to generate both 2D and 3D forms. To create 2D forms, use the general form equation to obtain polar coordinates that can be converted into Cartesian coordinates for drawing on a screen. To create 3D forms, compute the polar coordinates for two 2D supershapes, then "mix" them together using the 3D equations below.

Equations:

<table> <tr> <td valign="top">General form</td> <td> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superformula-2.svg?raw=true">

Where r is a radius and φ (phi) is an angle

</td> </tr> <tr> <td valign="top">3D equations</td> <td> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superformula-3.svg?raw=true"><br> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superformula-4.svg?raw=true"><br> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/superformula-5.svg?raw=true">

Where φ (latitude) varies between −π/2 and π/2 and θ (longitude) between −π and π.

</td> </tr> </table>

Articles:

Code projects:

Videos:


<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/tsp-1.gif?raw=true" width="300" align="right" title="Author unknown">

Travelling salesman problem (TSP)

Asks the question "Given a list of cities and the distances between each pair of cities, what is the shortest possible route that visits each city and returns to the origin city?" This classic problem is computer science classrooms to teach algorithm design and optimization techniques.

Useful for creating single-line drawings for use with pen plotters, laser cutters, CNC machines, and more.

Articles:

Notable software:

<br>

Lab experiments

<a href="https://commons.wikimedia.org/wiki/File:Belousov_Zhabotinsky_reaction_(3572095252).jpg" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/belousov–zhabotinsky-1.jpg?raw=true" width="300" align="right" title="Wikipedia - File:Belousov Zhabotinsky reaction (3572095252).jpg"></a>

Belousov–Zhabotinsky (BZ) reaction

Oscillating chemical reaction that can produce complex, regularly-spaced shapes that intersect (combining or cancelling) in predictable ways. The actual chemical reaction is very complex and is thought to involve around 18 distinct steps; the original discoverers struggled to get their work published because of their difficulties in explaining the underlying mechanisms of this reaction!

It may be possible to simulate this reaction, at least superficially, using either reaction-diffusion systems or cellular automata (see the Hodgepodge Machine specifically).

TODO: is it possible to succinctly describe "recipe" for reliable BZ reaction in petri dish?

Articles:

Code projects:

Videos:


<a href="https://commons.wikimedia.org/wiki/File:Quadratic_Chladni_plate.JPG" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/chladni-1.jpg?raw=true" width="300" align="right" title="Wikipedia - File:Quadratic Chladni plate.JPG"></a>

Chladni plate

Apparatus consisting of a suspended metal plate covered in a light dusting of fine sand or powder, then vibrated by either a bow or a voice coil (speaker). Beautiful, consistent nodal patterns known as Chladni figures emerge based on the specific resonance characteristics of the plate and the frequency of vibration inducued in it. Different sizes, shapes, and thicknesses of plates create different patterns, as do different frequencies, vibration methods, and audio samples.

Examples of Chladni figures: <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/chladni-2.jpg?raw=true">

Articles:

DIY projects:

Products:

Due to its popularity as a demonstration aid in science classrooms, good-quaity Chladni plate's are available from multiple dealers including:

Videos:


<a href="https://n-e-r-v-o-u-s.com/blog/?p=1546" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/hele-shaw-1.jpg?raw=true" width="300" align="right" title="Nervous System - experiments"></a>

Hele-Shaw cell

Related to Saffman-Taylor instability.

Apparatus for demonstrating and studying a pheonmenon known as viscous fingering (a.k.a. Saffman-Taylor instability), which is defined as "the formation of patterns in a morphologically unstable interface between two fluids in a porous medium" [1]. It occurs when a less viscous fluid is injected into a more viscous fluid, displacing it in a series of blobby, fractal-like fingers resembling (perhaps related to) the patterns formed by diffusion-limited aggregation or differential growth.

Setup:

The Hele-Shaw cell typically consists of two plates, usually glass or plexiglass, separated by a very short distance (TODO: how short?). A viscous fluid such as glycerin is injected through a hole either in the center of one of the plates or between the plates from the side, followed by colored water. As the colored water is injected and pressure is built up, the glycerin partially resists it's flow resulting in complex, wavy lines where the two liquids meet. For added effect, illuminate the cell by placing a light underneath, shining towards the viewer through the cell.

TODO: provide more details step-by-step instructions
TODO: note about lifted Hele-Shaw cells

Articles:

Videos:

Images:


<a href="https://sciencegifs.csullender.com/2017/12/09/Imaging-a-Flame-with-Schlieren-Photography.html" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/schlieren-imaging-1.gif?raw=true" width="300" align="right" title="Science GIFs - Imaging a Flame with Schlieren Photography"></a>

Schlieren imaging

Technique for visualizing density variations in transparent media, usually air. Essentially exaggerates the effects of refraction in different densities of air caused by heat (hot air expands, cool air contracts) or pressure (like ultrasonic transducers). Effect can be observed using just a few low-cost components:

  1. Concave mirror with a long focal length (3-4ft or more) - spherical mirrors work best, but parabolic mirrors can work
  2. Point light source - the brightest, smallest light source you can find/make. Lasers don't work well, but a simple LED with a pinhole cover or a strand of fiber optic will work. Doesn't need to be very bright.
  3. Razor blade or color filter
  4. Camera

Diagram of typical setup:

<a href="http://www.ian.org/Schlieren/HowTo.html" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/schlieren-imaging-2.png?raw=true" title="Ian Smith - Schlieren Photography - How Does It Work?"></a>

Articles:

DIY projects:

Videos:

<br>

Useful code patterns and techniques

<a href="https://flashyprogramming.wordpress.com/2010/03/22/boids-perlin-noise-flow-field/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/agent-based-modelling-1.png?raw=true" width="300" align="right" title="Flashy Programming - Boids + Perlin Noise Flow Field"></a>

Agent-based modelling

Methods for simulating the actions and interactions of autonomous entities and the complex emergent behavior they exhibit collectively. Used for simulating and analyzing collective social and biological phenomena like flocking animals (e.g. birds or fish), colony behaviors (e.g. ants and termites), crowd movement, and more.

This topic has a lot in common with the related topic of multi-agent systems, but with a different intent. Agent-based models tend to seek explanatory insight into the collective behavior of agents (often real-world organisms or systems), whereas multi-agent systems tend to be more focused on solving practical or engineering problems through optimization of the design of agents.

Insights from this topic can be directly applicable in large-scale kinetic art or LED installations, swarm robotics research, architecture, and city planning.

Characteristics of agent-based models relevant to biological modelling [1]:

  1. Modular structure: The behavior of an agent-based model is defined by the rules of its agents. Existing agent rules can be modified or new agents can be added without having to modify the entire model.
  2. Emergent properties: Through the use of the individual agents that interact locally with rules of behavior, agent-based models result in a synergy that leads to a higher level whole with much more intricate behavior than those of each individual agent.
  3. Abstraction: Either by excluding non-essential details or when details are not available, agent-based models can be constructed in the absence of complete knowledge of the system under study. This allows the model to be as simple and verifiable as possible.
  4. Stochasticity: Biological systems exhibit behavior that appears to be random. The probability of a particular behavior can be determined for a system as a whole and then be translated into rules for the individual agents.

Notables systems:

Articles:


<a href="https://ayearincode.tumblr.com/post/107414487116/this-morning-i-added-some-new-rules-to" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/boids-1.gif?raw=true" width="300" align="right" title="aYearInCode();"></a>

Boids

Related topics include agent-based modelling.

Well-known type of agent-based system that realistically simulates the complex flocking behaviors of birds and fish using simple rules. Each "boid" is an autonomous agent that is only aware of its immediate neighbor boids, all following the same three rules:

  1. Separation (collision avoidance): steer to avoid crowding local flockmates
  2. Alignment (velocity matching): steer towards the average heading of local flockmates
    • Note: remember that a vector is a combination of a speed and a direction (heading)!
  3. Cohesion (flock centering): steer to move towards the average position (center of mass) of local flockmates

And here is what those rules look like when applied to a set of agents (boids):

SeparationAlignmentCohesion
<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/boids-2.gif?raw=true" width="150"><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/boids-3.gif?raw=true" width="150"><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/boids-4.gif?raw=true" width="150">

Additional rules can be implemented to simulate specific behaviors like obstacle avoidance, predator-prey interactions, bait balls, and more.

Articles:

Code projects:

Videos:


<a href="https://en.wikipedia.org/wiki/Constructive_solid_geometry" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/csg-1.png?raw=true" width="300" align="right" title="Wikipedia - Constructive solid geometry"></a>

Constructive solid geometry (CSG)

Technique for 3D solid modeling that allows for the creation of complex surfaces by using Boolean operators to combine simpler objects (usually primitives like cubes, spheres, cylinders, etc). Most CAD and 3D modeling applications (like Blender, Fusion, Rhino, and more) include CSG operations, sometimes even through parametric or procedural interfaces.

Operations:

NameDescriptionnIllustration
UnionMerger of two objects into one<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/csg-2.png?raw=true" width="200">
DifferenceSubtraction of one object from another<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/csg-3.png?raw=true" width="200">
IntersectionPortion common to both objects<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/csg-4.png?raw=true" width="200">

Articles:

Code projects:


<a href="https://euryperez.dev/android-pearls-pixel-perfect-collision-detection-with-no-framework-53a5137baca2" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/collision-detection-1.png?raw=true" width="300" align="right" title="Eury Pérez Beltré - Android pearls: Pixel perfect collision detection with no framework"></a>

Collision detection

Computational methods for determining when two or more shapes are intersecting either statically (right now) or predictively (in the future). In technical terms, a posterior and a priori respectively. Detecting and reacting to collisions is extremely important in videos games and physical simulations, and takes quite a lot of brains and computational muscle to do effectively in real-time, especially in large-scale systems.

Building your own collision detection code is a fun and educational exercise, but is so complex and difficult to achieve in practice that it is generally a good idea to use an establisihed physics library or VFX/modelling application for performance. See the Physics engine and Tools sections for options.

Relevant topics:

Articles:

Books:


<a href="https://en.wikipedia.org/wiki/Dither" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/dithering-1.png?raw=true" width="300" align="right" title="Wikipedia - Dither"></a>

Dithering

In an image using a limited color palette, dithering can provide an illusion of a continuous gradient, or a field of color not in the palette. Using colors that are close to the target color, the technique applies a granular pattern of varying sizes and spacing of solid, single-color dots or lines. The human eye then interpolates between the colors at a larger scale.

Some techniques (like halftones) predate modern digital technologies because of their usefulness in traditional printmaking and engraving processes. There are even relevant techniques in the fields of painting and drawing; see stippling and pointillism! In digital imaging, modern palettes are usually comprehensive enough to reach a satisfactory visual fidelity for general purposes, but limits are still often reached in professional contexts.

Dithering is useful for realizing grayscale images with various digital fabrication equipment like laser cutters, pen plotters, CNC routers/mills, and more.

Types of dithering:

Articles:

Code projects:


<a href="https://en.wikipedia.org/wiki/Vector_field" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/flow-field-1.png?raw=true" width="300" align="right" title="Wikipedia - Vector field"></a>

Flow field

Related topics include fluid simulation.

Also known as a vector field, this technique involves assigning a unique vector to each point in a 2D or 3D space describing the direction and magnitude of varying forces. Flow fields are often used together with particle systems to model complex, dynamic movement caused by wind, fluid flow, electromagnetism, and more.

Vector fields are often populated using data generated with noise or image data. Curiously, flow fields have also been used in pathfinding.

Articles:

Code projects:

Videos:


<a href="https://www.karlsims.com/fluid-flow.html" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/fluid-simulation-1.jpg?raw=true" width="300" align="right" title="Karl Sims - Flow Field Tutorial"></a>

Fluid simulation

Simulates the highly complex and dynamic nature of flows in fluid volumes using computationally-efficient implementations of the Navier-Stokes equations. Can be thought of as a 2D or 3D flow field that is constantly changing based on the velocity, viscocity, and density of the fluid at each point in space and its surrounding area. This flow field is made visible through the use of digital "dyes" (usually particles) that get distributed, diffused, sheared, and blended through the system by the flow forces.

To appear realistic it is necessary for these simulations to have high fidelity, which introduces significant computational challenges, especially if one wants to run the simulation in real-time. Luckily, there are several great code packages available, and many VFX, CAD, and game development tools like Blender, Houdini, Unity and Unreal include robust fluid simulation functionality built in or available through plugins.

Fluid simulation has many practical and visual applications across a variety of disciplines. Its used in the analysis of aerodynamic properties of objects, vehicles, and buildings, in weather simulation and prediction, engine and combustion analysis, industrial systems design and analysis (plumbing, HVAC, public utilities, etc), visual effects for TV, movies, and games, and more.

Related terms:

Articles and papers:

Books:

Code projects:

Notable tools:

Videos:


<a href="https://www.jasondavies.com/lloyd/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/lloyds-relaxation.gif?raw=true" width="300" align="right" title="Jason Davies - Lloyd's Relaxation"></a>

Lloyd's relaxation

Related to voronoi diagrams.

As explained by Jason Davies, Lloyd’s relaxation algorithm (named after Stuart P. Lloyd) generates a centroidal Voronoi tessellation, which is where the seed point for each Voronoi region is also its centroid.

The algorithm computes the Voronoi diagram for a set of points, moves each point towards the centroid of its Voronoi region, and repeats.

Important concepts:

Articles:

Code projects:


<a href="https://catlikecoding.com/unity/tutorials/marching-squares-2/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/marching-squares-1.png?raw=true" width="300" align="right" title="Catlike Coding - Marching Squares 2"></a>

Marching squares

Method of generating contours for a 2D scalar field (a grid of individual numerical values), like turning elevation data into a banded topographical map. The scalar values get associated with vertices of the 2D grid, then lines are drawn across each cell in different ways based on the values of their four corner vertices.

There is only a finite number of lines possible, so they can be precomputed into a lookup table and referenced quickly later for faster performance. These lines can also be linearly interpolated to smoothly transition from cell to cell, resulting in very realistic blobby / fluid structures.

Key terms:

Illustration of algorithm:

<a href="https://en.wikipedia.org/wiki/Marching_squares" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/marching-squares-2.png?raw=true" width="500" title="Wikipedia - Marching squares"></a>

Articles:

Code projects:

Videos:


<a href="https://www.youtube.com/watch?app=desktop&v=LC0IbOZ0jkw" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/marching-cubes-1.jpg?raw=true" width="300" align="right" title="Screenshot from Proxy Design Studio - Marching Cubes Algorithm in Processing"></a>

Marching cubes

3D version of marching squares. Whereas marching squares uses lines and cells to trace the contours of a 2D scalar field, marching cubes uses polygons and voxels to trace the contours of a 3D scalar field, resulting in a mesh. Marching cubes can be thought of as a mesh conversion algorithm that produces meshes based on 3D scalar fields.

Originally developed by William Lorensen and Harvey Cline of General Electric in 1987 (see original paper in Articles section) for use in the medical imaging (MRI/CT) field, this algorithm has become widely used in many areas of computer graphics

TODO: add note on dual marching cubes

Algorithm [link]:

The algorithm proceeds through the scalar field, taking eight neighbor locations at a time (thus forming an imaginary cube), then determining the polygon(s) needed to represent the part of the isosurface that passes through this cube. The individual polygons are then fused into the desired surface.

  1. Choose a threshold (called an isovalue) to determine which level of values are considered inside or outside the mesh, thus setting where the mesh boundary is created.
  2. Pre-compute an array of all 256 (2^8) possible polygon configurations within a cube, where each entry is a set of IDs associated with edges of the cube (see Figure B below).
    • Note that of these 256 configurations, only 15 are unique due to repetition and symmetry (see Figure A below).
  3. For each set of 8 scalar values (forming a cube), compute an 8-bit integer where each bit corresponds to a unique scalar value (corner of the cube).
    • If the scalar value is higher than the isovalue (i.e. inside of mesh), set bit to 1
    • If lower, set bit to 0
  4. Generate polygons for each set of scalar values by drawing lines between the edges referenced in the polygon lookup table from step 2.
    • To do this, parse the 8 bits from step 3 into an integer, then use that integer as an index in the lookup table.
    • For example 00101001 = 41. Therefore the list of edges to draw lines between can be found in lookupTable[41].
  5. Each vertex of the generated polygons is placed on the appropriate position along the cube's edge by linearly interpolating the two scalar values that are connected by that edge.
  6. Calculate normals - TODO: how?
  7. Perform boolean union with all polygon fragments to form a mesh
<table> <thead> <tr> <th><center>(Figure A) diagram of 15 possible polygon configurations based on vertex bit values</center></th> <th><center>(Figure B) diagram of edge and vertex numbering</center></th> </tr> </thead> <tbody> <tr> <td valign="top"><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/marching-cubes-2.png?raw=true" width="500"></td> <td valign="top"><img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/marching-cubes-3.png?raw=true" width="500"></td> </tr> </tbody> </table>

Key terms:

Articles:

Videos:


<a href="https://discourse.mcneel.com/t/how-to-grow-expand-curves-polygons-until-touch-each-other/65224" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/metaballs-1.gif?raw=true" width="300" align="right" title="Rhinoceros Forums thread 'How to grow/expand curves (polygons) until touch each other'"></a>

Metaballs

Related to implicit surfaces, marching squares (2D) and marching cubes (3D)

Often confused with marching cubes, this is more of a mathmematical concept that describes a way to define the values in 2D or 3D scalar fields based on distance to one or more points in space. They are a type of implicit surface that define blobby shapes as pure mathematical formulas rather than explicit polygons and vertices.

They can be visualized using the marching squares (2D) or marching cubes (3D) rendering algorithms. Can be used for naive fluid simulations by applying physics to the metaball center points as if they were particles. They can also be helpful in modelling soft bodies by adding elastic constraints between the center points.

A typical function chosen for metaballs is:

<img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/metaballs-2.svg?raw=true">

Where <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/metaballs-3.svg?raw=true"> is the center of the metaball.

Articles:

Videos:


<a href="https://blog.demofox.org/2021/04/11/perlin-noise-experiments/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/noise-1.png?raw=true" width="300" align="right" title="The blog at the bottom of the sea - Perlin Noise Experiments"></a>

Noise

In the context of computer graphics, refers to pseudo-random functions useful for creating natural-looking textures and patterns. Often used to procedurally generate organic surface textures (bark, waves, rocks, etc) and to organically distribute objects across surfaces (like grass or barnacles).

Useful for adding fine details and smooth asymmetry to otherwise pristine objects - use it in displacement maps for subtle natural features.

Also helpful for creating looping animations because reproducable results can be achieved when using the same function inputs. Just iterate through a series of cyclical values (perhaps even based on frame count) and you'll end up with smoothly transitioning noise that can be mixed in with geometry, colors, and transformations that continuously loop.

The noise() function in many creative coding frameworks usually makes use of Perlin noise.

Articles:

Videos:

TODO: add note on curl noise

<a href="https://www.udemy.com/course/blenderparticlesystemcourse/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/particle-system-1.jpg?raw=true" width="300" align="right" title="Stephen Pearson's Udemy course 'Beginners Guide to the Particle System in Blender"></a>

Particle system

Collection of independent objects (often points, shapes, images/sprites/textures, or meshes) called particles that are manipulated using dynamic forces and constraints to simulate a wide variety of natural phenomenon like fire, smoke/fog/clouds, fluids, bubbles, and so much more. Often combined with clever visual effects like transparency, blending, and light emission to create the appearance of a coherent but ever-changing entity.

Particle systems are most useful when they can handle large quantities of particles, which means that performance and smart memory management is very important. Like collision detection, building your own particle system can be fun and educational, but if you need to achieve something complex at a large scale and/or with high framerates then it's definitely a good idea to leverage dedicated libraries and tools. Many physics engines come with well-made particle systems out of necessity so be sure to consider them even if you don't need all the fun physics functionality.

Articles:

Notable software:


<a href="https://html5gamedevelopment.com/planck-js-javascript-rewrite-of-box2d-physics-engine/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/physics-engine-1.png?raw=true" width="300" align="right" title="HTML Game Development - Planck.js – JavaScript Rewrite of Box2D Physics Engine"></a>

Physics engine

Related topics include collision detection and particle systems

Simulates the movements and reactions of objects using real-world concepts like mass, velocity, constraints, and forces (like drag, gravity, and friction). Makes use of extremely optimized algorithms for collision detection, physics calculations, geometry management, and more.

Articles:

Notable open-source libraries:

Commercial libraries:

If you're looking to do physical-based simulations, also take a look at game development and VFX environments like Unity, Unreal, and Houdini for their built-in physics engines.


<img src="https://www.cc.gatech.edu/grads/h/Hao-wei.Hsieh/Haowei.Hsieh/pic6.gif" width="300" align="right">

Polygon clipping

Effectively a Boolean intersection operation that "clips" (removes) parts of one polygon that are outside of another polygon. This can be useful when working with geospatial datasets and vector graphics (like SVGs), which in turn make this useful for plotter artists.

Algorithms:

Code projects:


<a href="https://en.wikipedia.org/wiki/File:Glasses_800_edit.png" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/ray-tracing-1.png?raw=true" width="300" align="right" title="Wikipedia - File:Glasses 800 edit.png"></a>

Ray tracing

Rendering technique used to create photorealistic images of 3D scenes by tracing the path of individual light rays. Rather than simulate all light rays' journeys from every light source to the camera, only the light rays that actually reach the camera are simulated.

For each pixel of the screen, a ray is cast into the scene until it hits an object. Based on the scene's lighting and the material properties of the hit object, a color value is calculated for the corresponding screen pixel. Using the angle of the specific triangle that was hit along with material properties like surface roughness, refraction, diffusion, one can also determine what direction that light ray must have come from, tracing that path and incorporating it's color information into the pixel color calculation.

The number of "bounces" examined can increase the photorealism of the resulting image, at the cost of computational resources / time.

This process is extremely computationally expensive, so it has historically only been used in pre-rendered applications like movies, animations, and still images. However, recent advancements in graphics card technology (like NVIDIA's RTX series) are beginning to make this technique available in real-time applications.

<a href="https://en.wikipedia.org/wiki/Ray_tracing_(graphics)" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/ray-tracing-2.png?raw=true" width="500" title="Wikipedia - Ray tracing (graphics)"></a>

Articles:

Code projects:


<a href="https://www.flickr.com/photos/torley/2361164281" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/recursion-1.jpg?raw=true" width="300" align="right" title="TORLEY - Recusion: It recurs."></a>

Recursion

See recursion.

Method of solving a problem where the solution depends on solutions to smaller instances of the same problem (as opposed to iteration). In programming terms, recursion is when a function calls itself during execution. Recursion is fundamentally connected to the concept of fractals.

Example: computing factorial

function factorialize(n) {
  if(n < 0) {
    return -1;
  } else if(n == 0) {
    return 1;
  } else {
    return n * factorialize(n - 1);
  }
}

Articles:


Shaders

Shaders are programs that are run on the GPU when processing a certain unit of rendering, usually vertices or pixels/fragments; they allow rendering programmers to manipulate their rendering output in any way they see fit.

While shaders, as the name implies, were originally conceived to allow different kinds of lighting/shading calculations, today they're used for a variety of things from lighting calculation through stylized rendering to 2D compositing or post-processing, and even complex geometry manipulations and particle effects.

Types of shaders:

Key concepts:

Languages:

Articles:

Code tools:

Videos:


Signed distance function (SDFs)

Related to implicit surfaces.

A function that returns the distance between a point in space to a mathematically/algorithmically defined surface (called an implicit surface). This allows algorithms like raymarching and marching cubes to efficiently render complex 3D surfaces in 2D.

SDFs are increasingly commonly used in computer art, where defining an SDF that describes a large 3D scene entirely in a single pixel shader allows the code to be ran entirely on the GPU.

Articles:

Notable open-source libraries:

Videos:


<a href="https://commons.wikimedia.org/wiki/File:Point_quadtree.svg" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/quadtree-1.png?raw=true" width="300" align="right" title="Wikipedia - File:Point quadtree.svg"></a>

Spatial index

Data structure (most commonly a binary tree) that enables fast and efficient storage, manipulation, and querying of large amounts of spatial data (points in space). Commonly used by particle systems.

Common types:

Related topics:

Articles:

Videos:


<a href="https://natureofcode.com/book/chapter-1-vectors/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/vectors-1.png?raw=true" width="300" align="right" title="Daniel Shiffman - Figure 1.3 of Chapter 1. Vectors"></a>

Vectors

Vectors (specifically Euclidean or geometric vectors) are simple data structures that store spatial information representing discrete points, displacement, or forces. Understanding how to work with vectors is one of the most critical skills to learn when working with physically-based simulations and digital morphogenesis.

Vectors can be manipulated using familiar algebraic operations like addition, subtraction, multiplication, and division, which makes them extremely useful when simulating physically-based systems with objects (or agents) in motion. We can have one vector that represents a point in space and another that represents a force (like gravity or wind), then apply that force to the point by adding the two vectors together.

The term "vector" has slightly different meanings and uses in mathematics, physics, machine learning, biology, and more. In the context of digital morphogenesis, you'll most often encounter vectors as they are used in physics, representing discrete physical properties like position, displacement, velocity, direction, and more.

Properties:

Key concepts:

Algebraic operations:

<table> <thead> <tr> <th scope="col" align="left">Operation</th> <th scope="col" width="45%" align="left">Using two vectors</th> <th scope="col" align="left">Using a vector and a scalar</th> </tr> </thead> <tbody> <tr valign="top"> <td><a href="https://natureofcode.com/book/chapter-1-vectors/#13-vector-addition">Addition</a></td> <td><code>v1 + v2</code> = <code>{v1.x + v2.x, v1.y + v2.y, ...}</code></td> <td><code>v + 10</code> = <code>{v.x + 10, v.y + 10, ...}</code></td> </tr> <tr valign="top"> <td><a href="https://natureofcode.com/book/chapter-1-vectors/#vector-subtraction">Subtraction</a></td> <td><code>v1 - v2</code> = <code>{v1.x - v2.x, v1.y - v2.y, ...}</code></td> <td><code>v - 10</code> = <code>{v.x - 10, v.y - 10, ...}</code></td> </tr> <tr valign="top"> <td><a href="https://natureofcode.com/book/chapter-1-vectors/#vector-multiplication">Multiplication</a></td> <td><code>v1 * v2</code> = <code>{v1.x * v2.x, v1.y * v2.y, ...}</code></td> <td><code>v * 10</code> = <code>{v.x * 10, v.y * 10, ...}</code></td> </tr> <tr valign="top"> <td>Division</td> <td><code>v1 / v2</code> = <code>{v1.x / v2.x, v1.y / v2.y, ...}</code></td> <td><code>v / 10</code> = <code>{v.x / 10, v.y / 10, ...}</code></td> </tr> <tr valign="top"> <td><a href="https://www.mathsisfun.com/algebra/vectors-dot-product.html">Dot product</a></td> <td><code>v1 · v2</code> = <code>(v1.x * v2.x) + (v1.y * v2.y) + ...</code> (produces a single number)</td> <td><em>Not applicable.</em></td> </tr> <tr valign="top"> <td><a href="https://www.mathsisfun.com/algebra/vectors-cross-product.html">Cross product</a></td> <td><code>v1 × v2</code> = <code>mag(v1) * mag(v2) * sin(θ) * n</code> where <code>θ</code> is the angle between <code>v1</code> and <code>v2</code>, and <code>n</code> is the unit vector at right angles to both <code>v1</code> and <code>v2</code>. Produces a vector.</td> <td><em>Not applicable.</em></td> </tr> </tbody> </table>

Articles:

Videos:

Notable implementations:


<a href="https://robertheaton.com/2018/12/17/wavefunction-collapse-algorithm/" target="_blank"> <img src="https://github.com/jasonwebb/morphogenesis-resources/blob/main/images/wfc-1.png?raw=true" width="300" align="right" title="Robert Heaton - The Wavefunction Collapse Algorithm explained very clearly"></a>

Wave Function Collapse (WFC)

Method of procedurally generating textures and tilemaps that are similar to a single source image using ideas from quantum mechanics.

TODO - add description of algorithm

Articles:

Code projects:

Videos:

<br>

Books, publications, and talks

Books

Publications

Talks

TODO: Add link


 Entagma's Patreon series
<br>

Software

Tools

<table> <thead> <tr> <th>Application</th> <th width="50%">Description</th> <th>Cost</th> </tr> </thead> <tbody> <tr> <td valign="top"><a href="https://www.sidefx.com/products/houdini/" target="_blank">Houdini</a></td> <td valign="top">Industry-level procedural VFX application with graphical node-based workflow. Excellent for creating high-quality renderings and animations based on generative algorithms. Allows for scripting with <a href="https://www.sidefx.com/docs/houdini/hom/index.html" target="_blank">Python</a> and <a href="https://www.sidefx.com/docs/houdini/vex/index.html" target="_blank">VEX</a> (proprietary language).</td> <td valign="top"> <ul> <li>Aprrentice - free for non-commercial users with watermarked renders </li> <li>Indie - $269/yr for no watermarks for commercial <$100k annual profit</li> <li>Thousands for commercial users, with complex pricing model</li> </ul> </td> </tr> <tr> <td valign="top"><a href="https://www.rhino3d.com/" target="_blank">Rhino</a></td> <td valign="top">NURBS-based CAD program popular with architects and industrial designers. Strong ecosystem of advanced computational design plugins built by highly skilled community. Less focus on rendering, animation, and interactivity; more for form-finding with fabrication in mind. Allows for scripting with <a href="https://developer.rhino3d.com/guides/#rhinopython" target="_blank">Python</a>, <a href="https://developer.rhino3d.com/guides/#rhinoscript" target="_blank">RhinoScript</a>, and <a href="https://developer.rhino3d.com/guides/" target="_blank">more</a>.<br><br> <details> <summary>List of useful Rhino plugins</summary> <p> <ul> <li><a href="https://www.grasshopper3d.com/" target="_blank">Grasshopper</a> - extremely popular graphical node-based algorithm editor tightly integrated with Rhino’s 3D modeling tools. Highly recommended for digital morphogenesis work. Was a third-party plugin for many years, but is now a part of Rhino 6+.</li> <li><a href="https://www.food4rhino.com/app/lunchbox" target="_blank">Lunchbox</a> - very powerful collection of utilities for generative geometry, math, data manipulation, and even machine learning.</li> <li><a href="https://www.food4rhino.com/app/kangaroo-physics" target="_blank">Kangaroo</a> - live physics engine for interactive simulation, form-finding, optimization and constraint solving.</li> </ul> </p> </details> </td> <td valign="top"> <ul> <li>Rhino 6 for Win - $995</li> <li>Rhino 5 for Mac - $695</li> <li>$195 for students (both platforms)</li> </ul> </td> </tr> <tr> <td valign="top"><a href="https://unity.com/" target="_blank">Unity</a></td> <td valign="top"> Full-featured game engine with tools for interactivity, physics, lighting, level/character design, and more. Allows for scripting with <a href="https://docs.unity3d.com/Manual/ScriptingSection.html" target="_blank">C#</a>.<br><br> Direct competitor of Unreal, with a reputation for being more focused on "user friendliness" and less on hyper-realism, though the gap is shrinking rapidly.<br><br> <details> <summary>Notable features</summary> <p> <ul> <li><a href="https://unity.com/shader-graph" target="_blank">Shader Graph</a> visual node-based editor for shaders</li> <li><a href="https://unity.com/visual-effect-graph" target="_blank">Visual Effect Graph</a> for particles</li> <li><a href="https://docs.unity3d.com/Packages/com.unity.render-pipelines.high-definition@6.7/manual/index.html" target="_blank">High Definition Rendering Pipeline</a> (HDRP)</li> </ul> </p> </details> </td> <td valign="top"> <ul> <li><a href="https://store.unity.com/products/unity-personal" target="_blank">Personal</a> - free for hobbyists</li> <li><a href="https://store.unity.com/products/unity-plus" target="_blank">Plus</a> - $35/mo or ~$25/mo for prepaid year</li> <li><a href="https://store.unity.com/products/unity-pro" target="_blank">Pro</a> - $125/mo</li> </ul> </td> </tr> <tr> <td valign="top"><a href="https://www.unrealengine.com/en-US/)" target="_blank">Unreal</a></td> <td valign="top">Full-featured game engine with very similar feature set to Unity (it's direct competitor).<br><br> Has reputation for being more focused on hyper-realism, and thus is used more by high-end games studios. [?]</td> <td valign="top">Free with <a href="https://www.unrealengine.com/en-US/faq" target="_blank">royalty on commercial products</a></td> </tr> <tr> <td valign="top"><a href="http://structuresynth.sourceforge.net/" target="_blank">Structure Synth</a></td> <td valign="top">Application for generating surprising and complex fractal 3D structures using a design grammar.</td> <td valign="top">Free</td> </tr> <tr> <td valign="top"><a href="https://www.derivative.ca/" target="_blank">TouchDesigner</a></td> <td valign="top">Visual node-based environment for real-time interactive multimedia content useful for performances, installations, and fixed media works. Has roots in Houdini 4 and is considered a <a href="https://en.wikipedia.org/wiki/Houdini_(software)#TouchDesigner" target="_blank">spin-off</a> optimized for real-time performance work (hence the company name, Derivative).</td> <td valign="top"> <ul> <li>Free for non-commercial projects</li> <li>Educational - $300 for schools, educators, schools only</li> <li>Commercial - $600</li> <li>Pro - $2200</li> </ul> </td> </tr> <tr> <td valign="top"><a href="https://www.maxon.net/en-us/" target="_blank">Cinema 4D</a></li> <td valign="top"></td> <td valign="top">Four versions ranging from $995-$3695</td> </tr> </tbody> </table>

Languages and frameworks

Uncategorized