City Landscape: Procedural City Plan (2D)

Plan view of the same generator as the 3D page: highways and streets grow, lots fill with houses and towers, a river is bridged. Drag to pan, wheel to zoom.

Switch to 3D

Presets

Playback

Road network growth

Rules of the L-system: centres that attract highways, grid regularity, branching.

Land use and zoning

River, building heights, parks, industry and lot sizes.

View

Oblique extrusion of buildings and growth animation length. The Time speed slider above multiplies the growth speed.

Layers

Model checks

The science

Growing a road network: a stochastic L-system

Roads are grown like the branches of a plant. Each live road end carries a small rule: extend a segment of length l in direction a, then maybe branch left and right at 90 degrees. Highways (long segments) are steered towards the highest population density within about 50 degrees of their heading; streets follow a grid axis blended with smooth noise, a = a_grid + (1 - g) * noise, where g is the grid regularity. Growth is processed in order of creation time, so the animation is simply the order in which segments were accepted (Parish and Mueller, 2001).

Every candidate segment is tested against what already exists: it is cut at the first crossing (the crossed road is split and a junction is created), snapped to a nearby node, or rejected when it would run parallel to another road closer than a fraction of the block size, would stop in water (only highways may bridge the river) or lies where the density is below a threshold. That last rule is what makes the city end naturally in a ragged edge.

Population density, zoning and lots

Density is a sum of Gaussian centres, rho(x) = sum_i s_i exp(-|x - c_i|^2 / (0.9 r_i^2)), modulated by fractal noise. Along every street, lots are cut on both sides at about the lot width and kept only if they do not overlap a road or an earlier lot. The zone follows density: above 0.62 high-rise, above 0.36 mid-rise (with industrial pockets from a second noise field), below that houses, with parks where a third noise field is high. Heights are floors of 3 m (4.5 m for industry): tall towers get a power-law-like distribution floors ~ rho^1.2 * u^k with u uniform, so a few buildings are very tall and most are modest, as in real skylines.

Network measures

For a planar network with V nodes and E edges, the Kansky gamma index is gamma = E / (3 (V - 2)) (the share of the maximum possible planar connectivity). A tree-like medieval town sits near 0.33, a full triangulation at 1, a square grid near 0.67. Floor-area ratio is FAR = total floor area / (lots + roads + parks). Population assumes about 38 m2 of floor per resident in houses and a share of mid- and high-rise floor area as dwellings. The radial graph fits Clark's law of urban density, rho(r) = rho_0 exp(-b r), by least squares on the logarithm and prints R2.

Independent numerical checks

Euler's formula. The road graph is embedded in the plane, so V - E + F = 1 + C where F counts every face including each component's outer face and C is the number of connected components. F is obtained by walking half-edges around the faces (turning to the next edge in angular order), a completely different procedure from the growth code, and C is computed twice (union-find and flood fill). Equality proves no two roads cross without a junction.

Monte Carlo coverage. 60 000 random points in the map are tested against the oriented lot rectangles; the hit fraction times the map area must equal the exact sum of lot areas within four binomial standard deviations (plus a 3 % allowance for rare corner overlaps).

Honest simplifications

This is a generator, not a planning model: there is no traffic assignment, land market, topography-based street routing (the terrain is flattened under the city, rivers are crossed by straight highway bridges), no building codes and no sunlight rights. Population and floor-area numbers are order-of-magnitude. The 3D scene uses Blender-baked facade textures (glass, concrete, brick and corrugated cladding with emissive window maps) and a Blender kit of houses, trees, street lamps, cars, a landmark tower and a tower crane.

What to try
  • Press Grow (or drag the growth slider) and watch the highways appear first, then streets, then lots and buildings, with cranes at the growth front.
  • Set grid regularity to 1 and then to 0: a Manhattan grid versus a medieval tangle; the Kansky gamma index and the number of dead ends change.
  • Raise the number of population centres to 3-4 to get a polycentric city and a poor Clark fit (R2 drops).
  • Turn the river off, or widen it, and see how many highway bridges appear.
  • Switch on the zoning overlay to see red high-rise cores surrounded by orange mid-rise, green housing and blue industry.
  • Drag the time-of-day slider to night: windows light up and the street lamps and car lights glow.
Skyline: buildings per height class
Network growth: road length
Density profile and Clark fit
Made with 🟠 Blender