disk of radius r/2 new edges (d < r) giant component
Random geometric graph

How to build a random geometric graph

Scatter N points uniformly in the unit square and connect every pair closer than a radius r. Equivalently, draw a disk of radius r/2 around each point and link points whose disks overlap. Growing r shows the percolation transition.

    Fraction of nodes in the largest component vs mean degree ⟨k⟩
    final ⟨k⟩
    N
    speed

    Random geometric graphs: E. N. Gilbert, “Random plane networks”, J. SIAM 9, 533 (1961); M. Penrose, Random Geometric Graphs (Oxford, 2003). The radius is set from the target mean degree via ⟨k⟩ ≈ (N−1)πr², ignoring boundary effects; the 2D continuum-percolation threshold is ⟨k⟩c ≈ 4.51.