Zipf's Law: Word Frequency vs Rank
Interactive 3D simulator of Zipf's law in language: generate a synthetic Zipfian corpus, fit the power-law exponent live from the log-log rank/frequency plot, and overlay real pasted text to see the same pattern in natural language.
Every large body of natural-language text obeys a strikingly simple pattern: if you rank its words by how often they occur, frequency falls off as a power of rank, f(r) ≈ C / r^s, with s close to 1. This simulator makes that pattern tangible by generating a synthetic corpus from an explicit Zipfian probability table — draw N tokens from a vocabulary of V words weighted by 1/r^s — and rendering the resulting rank/frequency counts as a 3D skyline in log-log space, where a true power law shows up as a straight descending line. A second row tokenizes whatever text you paste into the box, counts real word frequencies, fits the same log-log line live, and overlays it in amber next to the synthetic teal city, so you can watch a genuine paragraph of English land on almost exactly the same slope as the mathematical model.
Generate a synthetic Zipfian word corpus, watch its log-log rank/frequency plot fit a straight line live, and overlay real pasted text to see natural language land on nearly the same power-law slope.
3D · Three.js / WebGL renderer · 60 FPS target · runs fully client-side, no install