PulseCore

Chapter 9 · Section 2

The Saturation Law

The BPT law

BPT does not state this; it is a game method. It serves the theory's own scale rule, that the game is a scale model of the true level (Chapter 1), by choosing how much of the model to draw.

The established physics

The law is two classical forms joined, and its nearest named use is in computer graphics.

  • The inner form is the Weber–Fechner law (Fechner 1860): a sensed magnitude grows with the logarithm of the stimulus, so equal ratios read as equal steps. A universe's numbers grow by powers of two with every level; a logarithm turns each such step into an equal visible step.
  • The outer form is the hyperbolic saturation of Michaelis and Menten (1913), the rate of an enzyme against its substrate, and of Langmuir (1918), the coverage of a surface against pressure: y = V·u/(1 + u). It rises with u, is half of V at u = 1, and never reaches V.
  • Tone mapping uses the same shape for the same problem. A real scene's brightness has no top and a display's does. Reinhard et al. (2002) map scene luminance L to L/(1 + L); Drago et al. (2003) map it on a logarithmic scale. Both fit an unbounded quantity onto a device with a fixed maximum, which is the game's problem exactly.

The game's math

For a real count x and a device ceiling V (both counts of the same thing):

u      = ln(1 + x/V)                 (Weber–Fechner: the count as the eye reads it)
S(x,V) = V · u / (1 + u)             (Michaelis–Menten / Reinhard: the saturation)
m      = V / (1 + u)                 (the share of V left undrawn;  S = V − m)
drawn  = V − max(1, round(m))        (whole things; at least one place is always left)

Its properties, each one a line of algebra:

  • It never draws more than there is. ln(1 + y) ≤ y, so u ≤ x/V, and u/(1 + u) ≤ u; hence S ≤ x.
  • When few, it draws nearly all. For x ≪ V, S ≈ x − 1.5·x²/V: at x = V/10, 87 % are drawn; 10 wells draw 10, 100 draw 96.
  • It is half full at u = 1, that is at x = V·(e − 1) ≈ 1.72 V.
  • It never reaches V. S = V − m with m = V/(1 + u) > 0 for every finite x. Whole things round m, and since m > 0 at least one place is always left undrawn: the drawn count is at most V − 1 however large x grows. This is not a cap: the bound is the device's own V, and it is never met.
  • It keeps rising. dS/dx > 0 for all x, so every larger universe draws more, by a little each time, without end.
  • It never overflows. The game knows the real counts by their logarithms (the law is 2^(L/3), the pixels 16·4^L). For x ≫ V, u = ln x − ln V to within e^(−u), so u is computed from log₂ x as u = log₂x · ln 2 − ln V, and no level, however deep, overflows a number.

Why not the simpler curve V·(1 − e^(−x/V))? Its undrawn share falls as e^(−x/V): at x = 10 V it is 0.005 % of V, which rounds to nothing, and the drawn count sits at V for every larger universe. That is a cap with extra steps. The logarithm inside makes the undrawn share fall as 1/ln x instead, so it stays visible at every scale there is.

Worked case: Proto Wells on a phone (V ≈ 4,000 from the screen, Part 9.3):

Real wells x Drawn
10 10
100 96
645 (level 28) 520
920 686
4,000 1,637
16,000 2,467
1,000,000 3,387
10^9 3,702
10^30 3,935
10^100 3,982

On a desktop (V ≈ 28,000) the same column reads 10, 99, 623, 876, 3,298, 8,716, 21,917, 25,561, 27,532 and 27,873.

The scale model

The law decides only how many are drawn or simulated. Each one drawn stands for x ÷ drawn real ones (Part 9.1), and the totals the physics uses (mass, light, counts in the census) are the real totals.

Fixed numbers

Number Where What it is Kind
1 (in ln(1 + x/V) and 1 + u) the law makes S ≈ x for small x and S = 0 at x = 0 METHOD (the forms of Fechner and Michaelis–Menten)
1 (in max(1, round(m))) the law whole things: m > 0 leaves at least one place METHOD (rounding a positive share)

The law adds no other number. V is measured (Part 9.3).