The specimen
A cell made of tetrahedra
Each cell is a signed distance field: ellipsoids, tori and tapered tubes fused by smooth unions (for yeast, a mother and a bud meeting at a narrow neck). That shape is filled with a body-centred cubic lattice of tetrahedra, clipped to the surface, with boundary particles snapped onto it. It is solved with XPBD at a fixed 60 Hz step split into 12 substeps. Each tetrahedron is pulled, with finite compliance, toward its best-fit rotated rest shape. That co-rotational constraint also flips inverted elements back out. A volume constraint on either side of it keeps the cytoplasm close to incompressible, so a stretched cell necks in.
Every tetrahedron knows what it sits in. Wall and cortex, the nucleus and stress fibres are stiffer than cytoplasm; the yeast wall is four times stiffer. Damping acts only on relative velocity along mesh edges, so the cell still falls and tumbles freely while its wobble dies away.
Cutting
Your stroke fixes a vertical blade plane. For each piece it crosses, the piece's current pose is fitted with a best rotation, and the plane is carried back into rest space. Each side becomes a new piece: the cell's signed distance field intersected with its half-spaces, rebuilt as a fresh tetrahedral mesh. The knife then presses a groove, breaks through, and hands every new particle the position and speed of the flesh it came from. The blade wedges the faces apart on its way down.
Deformation
The Deformation view colours each point by its mechanical strain: the Green–Lagrange strain of the tetrahedra around it, which is the part of the deformation left once rotation is taken out. A cell that is only tumbling stays dark; pull it and the colour gathers where it stretches or is squeezed. The field is averaged onto the particles and carried to the surface by the same barycentric weights as the skin, so knife faces show it inside too.
Seeing inside
The skin and the organelles (nucleus, nucleolus, vacuoles, a cortical mitochondrial network, the septin ring) are separate meshes. Each vertex is pinned to a tetrahedron by barycentric weights, so they all wobble together. Every vertex also remembers its rest position. A knife face looks up the anatomy's distance fields at that position, so it shows an exact section through whatever organelle lies in the plane, membranes included.
Light through jelly
WGSL shaders draw the floor, organelles and knife first. Then, piece by piece from back to front, they draw the jelly's back faces to measure how much cytoplasm each view ray crosses. The front faces refract what lies behind by that thickness and absorb it with Beer–Lambert colour. They add a milky wall film, a thin-edge glow, Fresnel reflections of a procedural studio and GGX highlights.
Growing between stages
Press ▶ (or drag the stage slider) and the cell morphs from one stage to the next. Between stages i and i+1 the body's signed distance is blended,
ds(x) = (1 − t) di(x) + t di+1(x), t = s − i,
so new flesh appears first where it is nearest the old surface: a bud swells out of the mother, an axon regrows from its stump. Organelles are matched one to one, and one without a partner grows out of (or shrinks into) its nearest relative, so the daughter nucleus leaves the mother's. A worker thread keeps re-meshing the cell a little further along. Each new particle at rest point X starts at the old flesh it pulls back to,
Y = X − (ds(X) − ds′(X)) ∇ds(X),
so the new mesh begins in the old shape and its own elasticity pulls it into the new one. The growth is carried by the same physics as a poke, and the Deformation view shows it.
The equations
Each frame (Δt = 1/60 s) is split into 12 substeps of h = Δt/12. Particles first move freely under gravity:
v ← v + hg, x ← x + hv.
Each tetrahedron's deformation gradient is F = Ds Dm−1, where the columns of D are its edge vectors now (s) and at rest (m). Two constraints act on it: shape, CD = ‖F − R‖F, where R is the rotation part of F (extracted iteratively and warm-started), and volume, CH = det F − 1. Together they are the energy per unit rest volume
ψ = μ‖F − R‖F2 + ½λ(det F − 1)2, μ = E/3, λ = 100 μ,
which is nearly incompressible. E = E0·101.8(f − 0.4) runs from 0.19× to 12× its default across the firmness slider f, and each material scales μ and λ by its own factor k (4× for the yeast wall). Each constraint is projected once per substep in the XPBD form, with compliance α = 1/(2μkV) for shape and 1/(λkV) for volume, V being the tet's rest volume:
Δλ = −C / ( Σj wj ‖∇jC‖2 + α/h2 ), Δxj = wj ∇jC Δλ,
where wj is the inverse mass and λ starts from zero each substep. Volume is solved before and after shape. Velocities are then read back from positions, v = (x − xprev)/h. Along every mesh edge the relative normal velocity is reduced by a factor 1 − e−ch, with c = 1 + 260 d2 s−1 for damping d, so the wobble dies away while the cell still falls and tumbles freely.
The Deformation view shows the Green–Lagrange strain, which ignores rotation,
E = ½(FTF − I), shown as ‖E‖F, full colour at 30%.
XPBD: Macklin, Müller & Chentanez, MIG 2016. Substepping: Macklin et al., SCA 2019. Rotation extraction: Müller et al., MIG 2016.
After “Melon Jelly” (Material Studies No. 009). Anatomy is stylised but proportioned after S. cerevisiae.