Thought Toys · Emergence · Exhibit 41

Small-world networks

A ring where everyone only knows their nearest neighbors has painfully long social distance — to reach someone across the circle you cross half of it, one link at a time. Randomly reroute a tiny fraction of those links to strangers, and the whole network suddenly shrinks — without losing its tight local cliques.

The ring — nodes and their links lattice linkrewired shortcut

This ring so far: —

At a larger reference network (200 nodes), vs. rewiring probability path length ratioclustering ratio

your turn — drag past 0 and watch the ring's own numbers move

What you're seeing

Every node starts wired only to its nearest neighbors on a ring — an ordered lattice. It has two honest properties. First, it takes many hops to cross the ring — a long average path length: the mean number of links on the shortest route between every pair of nodes. Second, any two friends of a friend are usually friends themselves — high clustering: how often a node's neighbors are also neighbors of each other. Drag the dial and each edge gets, independently, a small chance of being torn out and reattached to a uniformly random node anywhere on the ring. That is a "shortcut" — drawn in amber, cutting straight across the circle instead of hugging its rim.

Watch the amber path-length line in the lower chart: it falls off a cliff in the first sliver of the dial, while the cyan clustering line barely moves. A rewiring rate of just 1% already collapses the average distance to under two-thirds of its ordered value — and local clustering is still above 90% of what it was. That gap — short paths and tight local cliques, at the same time — is the "small world". It is Watts & Strogatz's 1998 answer to why acquaintance networks, neurons and power grids can all be crossed in a handful of hops (the folk claim of "six degrees of separation") even though almost everyone knows only their immediate neighbors. Keep dragging toward 1 and the shortcuts pile up until almost nothing is left of the original ring — clustering keeps falling toward zero even as path length has nowhere further to go.

It isn't randomness alone that does this. A network wired entirely at random, with the same number of links as the ring, gets the short paths for free — but never the high clustering (verified below). The small-world effect needs both ingredients: an ordered base to keep local structure, and only a few long-range shortcuts layered on top.

The rule, exactly. Ring lattice: N nodes, each linked to its K nearest neighbors. Rewiring: for each edge, independently with probability p, move its far endpoint to a node drawn uniformly at random (no self-loops, no duplicate edges) — the standard Watts–Strogatz construction (1998). Verified in node (improve/verify/41-small-world.js): at p=0 the clustering coefficient matches the exact closed form 3(K−2)/(4(K−1)) to machine precision; at p=0.01 (N=200, K=6, averaged over trials) path length has already dropped below 65% of its ordered value while clustering stays above 90%; at p=1 clustering has collapsed below 15% of its ordered value. Negative control: a purely random graph with the identical node and edge count has short paths too (as cheap as the fully-rewired ring) but its clustering never exceeds about 15% of the lattice's — random wiring alone buys short paths, never the high-clustering "small world" combination.

Also in Emergence: The Ising model →

All 16 in Emergence
  1. 01Phantom Traffic Jams
  2. 02Schelling's Segregation
  3. 07Conway's Game of Life
  4. 107Half a link each is dust. One link each is a web.
  5. 11Percolation
  6. 15Reaction & diffusion
  7. 18Sandpiles & self-organized criticality
  8. 22Diffusion-limited aggregation
  9. 29The simplest rule that makes complexity
  10. 32Fireflies that sync
  11. 41Small-world networks — you are here
  12. 43The Ising model
  13. 45Preferential attachment
  14. 81Nobody panicked, and the factory went haywire
  15. 84The tragedy of the shared field
  16. 88Nobody's leading. The flock turns as one.

← the cabinet · Thought Toys — a cabinet of explorable explanations. Exhibit 41.