Three Categories Explored
mysimulator.uk tracks category depth as one quality metric. Wave 55 strengthens three distinct domains — from the timeless mathematics of polyhedra to the computational physics of particle-based fluids.
Geometry
Platonic and Archimedean solids, Bézier curves, fractal attractors, and topological invariants.
Swarm Intelligence
Emergent collective motion from local rules: Boids flocking, ant-colony optimisation, flock formation.
Fluid Dynamics
Lagrangian particle methods, boundary-layer flow, Bénard convection cells, and wave propagation.
🔷 Discrete Geometry — Polyhedra and Euler’s Formula
The study of polyhedra — solid figures bounded by flat polygonal faces — stretches from Plato's Timaeus (c. 360 BC), which identified four solids with the classical elements, to Euler's surprising topological theorem, to modern applications in crystallography and computer graphics.
Why only five Platonic solids?
A Platonic solid requires (a) all faces to be the same regular polygon and (b) the same number of faces to meet at each vertex. For the solid to close up, the total angle at each vertex must be less than 360°, otherwise the faces lie flat or fold back on themselves. There are exactly five solutions:
- Tetrahedron — 3 equilateral triangles per vertex, angle sum 180°.
- Cube (Hexahedron) — 3 squares per vertex, angle sum 270°.
- Octahedron — 4 equilateral triangles per vertex, angle sum 240°.
- Dodecahedron — 3 regular pentagons per vertex, angle sum 324°.
- Icosahedron — 5 equilateral triangles per vertex, angle sum 300°.
Six equilateral triangles would tile a flat plane (360°), not close; five squares would exceed 360°. The constraint is tight — there is no room for a sixth Platonic solid.
Euler's characteristic: V − E + F = 2
In 1752 Leonhard Euler noticed that for every convex polyhedron the quantity V−E+F equals exactly 2. This was remarkable because it held regardless of the shape: a tetrahedron (4−6+4=2), a cube (8−12+6=2), an icosahedron (12−30+20=2), and even a truncated icosahedron (60−90+32=2).
Archimedean solids and truncation
The 13 Archimedean solids are convex, vertex-transitive polyhedra with two or more types of regular polygon face. They arise naturally from the Platonic solids by truncation (cutting off vertices), rectification (cutting to edge midpoints), snubbing (twisting), and cantellation (expanding faces outward). The truncated icosahedron — 60 vertices, 90 edges, 32 faces of pentagons and hexagons — is identical to the pattern on a standard football and to the C₆₀ buckminsterfullerene molecule (Buckball).
🐟 Swarm Intelligence — Emergence from Local Rules
Swarm intelligence describes the collective, self-organised behaviour emerging from local interactions between simple agents. No central controller directs the swarm; each individual follows only nearby information. Yet the group-level patterns — coherent flocks, branching trail networks, coordinated panic responses — can rival the output of any centralised system.
Craig Reynolds' Boids (1986)
Reynolds' original Boids paper (SIGGRAPH '87) showed that three rules suffice to produce realistic flocking:
- Separation: avoid crowding immediate neighbours.
- Alignment: steer toward the average heading of nearby neighbours.
- Cohesion: steer toward the average position (centre of mass) of nearby neighbours.
The three radii — rsep < rali < rcoh — create nested zones of influence. Fish School 3D uses rsep=28, rali=55, rcoh=80 px with three depth layers giving pseudo-3D appearance at Canvas 2D cost.
Predator-prey dynamics in flocks
The new Fish School 3D adds a hunting shark that triggers a panic response in fish within its patrol radius. This reproduces several documented field phenomena:
- Fountain effect: the school splits around the predator and rejoins behind it, creating constant motion that confuses the predator's sensory tracking.
- Flash expansion: when a predator lunges, the nearest fish accelerate explosively outward — an instantaneous density collapse that forces the predator to commit to one target.
- Dilution effect: each individual's predation probability is 1/N for a school of N, making larger schools safer on a per-fish basis even though they are more conspicuous.
- The confusion effect: the rapid motion of many identical prey overwhelms the predator's object-tracking system. Experiments with guppies show predators catch fewer fish from larger schools even when attack rate is held constant.
💧 Computational Fluid Dynamics — SPH
Computational fluid dynamics (CFD) is the numerical simulation of the Navier–Stokes equations. Two families of methods dominate: Eulerian (mesh-based: finite-volume, finite-element, finite-difference) and Lagrangian (particle-based: SPH, DEM, MPM). SPH belongs to the Lagrangian family and has properties that mesh methods lack.
Why go Lagrangian?
Mesh methods struggle with problems involving large deformations, free surfaces, and multi-phase flows: the mesh must be regenerated or deformed at every step. In SPH the particles carry the flow with them — free surfaces are automatically tracked, no mesh is needed, and fragmentation is trivial. The price is that SPH is O(N²) naively (though spatial hashing reduces this to O(N log N)) and less accurate than high-order finite-element methods for smooth flows.
The pressure-viscosity-gravity system
The simulator integrates three force contributions every substep:
- Pressure — from localised density excesses above rest density ρ₀. Uses the symmetrised spiky kernel gradient: Fp = −m (pᵢ+pⱼ)/2ρⱼ ∇Wspiky
- Viscosity — diffusion of momentum, smoothing velocity differences: Fν = νm(vⱼ−vᵢ)/ρⱼ ∇²Wvisc
- Gravity — constant downward body force pulling all particles.
Boundary elastic reflection with damping factor 0.4 models the energy absorption of real concrete walls. Three substeps per animation frame (dt=0.004 s each) keep the CFL stability condition satisfied at 60 fps.
1977 — Lucy and independently Gingold & Monaghan invent SPH for astrophysical collapse simulations.
1992 — Monaghan adapts SPH to free-surface flows and dam breaks.
1996 — Desbrun & Cani improve the kernel choice for graphics-quality water.
2003 — Müller, Charypar & Gross popularise SPH for real-time game fluids.
2010s — GPU-accelerated SPH reaches tens of millions of particles in interactive demos.
Today — SPH is standard in tsunami modelling, galaxy collision simulations, and industrial forming processes.