Animating Mathematics

GIFs aren’t just for cat videos

Clayton Shonkwiler

Colorado State University

/icerm

this talk!

GIFs? Really?

Really?

Yes, really

Spiral Light, by Dave Whyte (@beesandbombs)

Unoriented

Reveal

Reinvention

Coalesce

My First GIF

Geodesic

A to Z

Closure

Tiling

...?

Spherical Dodecahedron

a.k.a. pentagonal tiling of the sphere

+ Stereographic Projection

= Stereographic Dodecahedron

Rotation

...of what?

z \mapsto \frac{i (z+1)}{z-1}
zi(z+1)z1z \mapsto \frac{i (z+1)}{z-1}

The Hyperbolic Plane!

Source Code

inv[z_] := I (z + 1)/(z - 1);
circleinversion[z_] := z/Norm[z]^2;

HRot = ParallelTable[
     ParametricPlot[
      Flatten[{{10 (t - π), 0}, 
         {ToReal[inv[E^(I t) + #]], 
           ToReal[inv[
             circleinversion[E^(I t) + #]]]} & /@ (E^(I θ)*
           DeleteCases[
            Flatten[Table[a + I b, {a, -4, 4, 2}, {b, -4, 4, 2}]], 
            0 + 0 I])}], {t, 0, 2 π}, PlotRange -> 4, 
      Axes -> False, 
      PlotStyle -> 
       Directive[Thickness[.003], RGBColor[{227, 156, 188}/255]], 
      ImageSize -> {540, 540}, 
      Background -> GrayLevel[.2]], 
     {θ, 0., π/2 - #, #}] &[π/400];

Export[NotebookDirectory[] <> "HRot.gif", HRot, 
 "DisplayDurations" -> {1/36}]

And much more mathematics...

Schwarz–Christoffel Mapping

Langer & Singer's Trefoil

Brownian Bridges

Lawson Surface

The Klein Quartic

4-D Rotations

Roman Surface

Polytope Cross-Sections

Pentagon Tilings

How?

The Answer for Most People:

Processing

processing.org

+

ImageMagick / gifsicle

imagemagick.org / lcdf.org/gifsicle

Official @beesandbombs

GIF-making guide

The Answer for Me

Example

Backstory

Only certain pentagons tile the plane

But all quadrilaterals tile!

So I decided to build a quadrilateral tiler...

(requires free Wolfram CDF player)

Colors

Last Step: gifsicle

> gifsicle -O2 -k128 input.gif > output.gif

“optimize”

# colors

(≤256)

Download from lcdf.org/gifsicle/ or install from your favorite package manager

Thank you for listening!