PulseCore

Chapter 4 · Section 6

The Zel'dovich Start

The BPT law

BPT Part 3.11 (The First Ripples) lays down the matter's start as cosmology does. The Zel'dovich Displacement, x = q + D · ψ: "each piece of matter starts at its own place and is moved along the ripples, more as the universe grows", q its place on the even grid it began on, D = a the growth of the ripples, ψ the displacement field, "the gradient of the ripples, pointing toward where the density is higher"; the contrast it makes is δ = −D·∇·ψ. The Growing-Mode Velocity, u = D · H · ψ: "each piece moves with the ripples' growth from the start", so that every ripple is in its growing mode from the first instant ("started at rest instead, half of every ripple would be lost"). In BPT "the ripples are not put in by hand: they are the data", the unevenness of the data on the scaffold, so the web that grows from them "is laid out by the scaffold".

BPT Part 3.12 (The Character of the First Ripples) adds that they are a random field with the Primordial Ripple Spectrum, Δ²(k) = A⊚ · (k / k⊚)^(n⊚ − 1), n⊚ = 0.965, A⊚ = 2.1 × 10⁻⁹ in ours, and that the matter carrying them must begin "not on a grid, whose rows would survive into the web, but as a glass". Part 3.11 then describes this very code: the ripples are "a third the data on the scaffold and two thirds the random field of Part 3.12, smoothed over two cells, on a grid jittered within each cell", scaled "so that, grown linearly, their spread would reach about three by the final well", and "ripples longer than a quarter of the universe are left out"; "those three sizes are the simulation's choices here".

The established physics

  • Zel'dovich approximation (Zel'dovich 1970): x = q + D(t)·ψ(q), ψ = ∇g with ∇²g = −δ, so δ = −D·∇·ψ; velocities in the growing mode, u = D·H·ψ for D = a.
  • Einstein–de Sitter growth, D = a and H = 2/(3t).
  • Nearly scale-invariant primordial spectrum, n_s = 0.965 (Planck Collaboration 2020). In two dimensions the amplitude per mode goes as k^((n − 3)/2) (code comment zeldovich.js:24–28).
  • Glass initial conditions (White 1996, cited in BPT Part 3.12); the jittered grid is the code's approximation to one.

The game's math

zeldovichStart({ rows, cols, weight, N, aInit, tInit, seed }) zeldovich.js:56, called at app.js:1230 with aInit = expansionA() and tInit = t₀ (Part 4.4).

  1. The scaffold's contrast. δ_s(x) = weight/mean − 1 (zeldovich.js:65). Each row's own mean is subtracted (zeldovich.js:71), so no band of the torus is preferred (ruling 2026-10-28: "the wells are still gathering around the equator").
  2. The random field. Gaussian white noise (Box–Muller, zeldovich.js:59) in Fourier space, each mode scaled by k^((N_S − 3)/2) (zeldovich.js:81).
  3. The mix. Both normalized to unit power, then δ_k = SCAFFOLD_SHARE·δ_s,k/√P_s + (1 − SCAFFOLD_SHARE)·δ_n,k/√P_n (zeldovich.js:84–85), SCAFFOLD_SHARE = 0.35.
  4. The displacement. For each mode with k² above k_min² (k_min = 2π/(RIPPLE_LONGEST·max(rows, cols)), zeldovich.js:90): smoothing sm = exp(−k²·RIPPLE_SMOOTH²/2); g_k = δ_k·sm/k²; ψ = ∇g = i·k·g_k; back to real space (zeldovich.js:86–97).
  5. The scale S. The rms of the grid's linear contrast −∇·ψ is measured, and S = RIPPLE_TODAY / rms (zeldovich.js:99–105), so that at a = 1 the contrast would spread to RIPPLE_TODAY = 3.
  6. The bodies. nc = round(√(N·cols/rows)) columns, nr = round(N/nc) rows; each body at q = ((i + u₁)·rows/nr, (j + u₂)·cols/nc), u random in [0, 1) (the jitter, zeldovich.js:118), then
x = q + D·S·ψ(q),   u = D·H·S·ψ(q),   D = aInit,   H = 2 / (3·max(10⁻⁶, tInit))

ψ is read between cells bilinearly. Each body gets mass q from Part 4.5. The ripples' phases are seeded from the universe's own data (an FNV hash of every third cell, app.js:1229), so the same universe gives the same start.

The rowArea option (zeldovich.js:109–116) puts bodies per row in proportion to each ring's real area; sendOutMatter() does not pass it, since the field is drawn equal-area (app.js:1228).

In the game

At the burst the sky looks smooth: the bodies sit almost evenly over the torus where the data was, slightly thicker along the lattice's lines. Nothing turns yet. Over the first part of the life the player watches the ripples grow: matter drains from the voids and gathers along the lattice's lines into filaments, with knots where lines cross. The first toast of the growth names it at a = 0.25: "a quarter grown: The universe is a quarter of its final size · the ripples are growing: the first clumps gather along the lattice's lines" (app.js:671). In 3D the lattice still shows faintly under the stars (Part 4.5), so the player can see the web following it.

The contrast can be read directly in the 2D field with "Colour by → Density" (index.php:188–189): each cell is colored by the matter's density on the gravity mesh, from dark blue where there is none to bright orange at a cloud's mass or more, hsl(0.66 − 0.55·ρ, 0.9, 0.1 + 0.55·ρ) with ρ the block's matter over one cloud's mass, at most 1 (app.js:364–367, sample() matter.js:520). No control changes the start: its sizes are the simulation's choices, and its phases come from the universe's own data.

The scale model

The ripples are laid on the drawn field at the drawn resolution; ripples shorter than about two cells are smoothed away and longer than a quarter of the field dropped. The spread RIPPLE_TODAY is set against the end of the life, so the web is formed by the final well on every field. The start is a scale model of the shape of the web, not of its amplitude in our universe (A⊚ ≈ 2.1 × 10⁻⁹ in BPT Part 3.12 is not used).

Where the game and the theory differ

  • A third, or 0.35. BPT Part 3.11 says the ripples are a third the scaffold's and two thirds the random field's; the code's SCAFFOLD_SHARE is 0.35 of the amplitude, each part normalized to unit power first.
  • A jittered grid, not a glass. BPT Part 3.12 says the matter must begin as a glass, with no preferred direction; the code, as Part 3.11's reading of it says, lays the bodies on a regular grid jittered within each cell, an approximation to one.

Fixed numbers

Number Where What it is Kind
3 RIPPLE_TODAY zeldovich.js:16 Linear contrast the ripples would reach at a = 1 METHOD (named choice: web formed by the end)
2 RIPPLE_SMOOTH zeldovich.js:18 Smoothing width, cells METHOD (named choice: width of the lattice's lines)
0.25 RIPPLE_LONGEST zeldovich.js:23 Longest ripple kept, share of the field METHOD (named choice; universe smooth on its largest scales)
0.965 N_S zeldovich.js:28 Spectral index PHYSICS (Planck Collaboration 2020)
0.35 SCAFFOLD_SHARE zeldovich.js:28 Share of the ripples' strength from the scaffold METHOD (named choice; BPT 3.11 says "a third")
3, 2 zeldovich.js:81 Amplitude exponent (n − 3)/2 in two dimensions PHYSICS (2D power spectrum)
2, 3 zeldovich.js:106 H = 2/(3t) PHYSICS (Einstein–de Sitter)
10⁻⁶ zeldovich.js:106 Floor on tInit METHOD
10⁻¹² zeldovich.js:59 Floor in the Box–Muller log METHOD
0x6D2B79F5, 15, 7, 14, 61, 4294967296 zeldovich.js:58 Seeded random generator (mulberry-style) METHOD (reproducible draws)
1 zeldovich.js:56 Default seed METHOD