Wormhole

Two rooms. One curved space. Look around before you step through.

Warm room
↑ ↓ walk · ← → turn · drag to lookWASD move / strafe · R restartTouch: drag vertically to walk, horizontally to turn

Description

A traversable wormhole joins an amber room and a blue room through curved three-dimensional space. The spherical-looking mouth is not a screen or a physical tunnel wall. Sightlines follow geodesics of the wormhole metric, so the rooms bend, magnify, wrap around the throat, and appear in distorted images. You can walk around the mouth, pass through it, look sideways inside, and return.

Instructions

  • ↑ / ↓: walk forward and backward. ← / →: turn. These work without clicking the canvas first.
  • Drag: look left, right, up, and down. W / S: walk. A / D: move sideways, which lets you circle the mouth while watching it.
  • R: return to the starting position. On touch screens, drag vertically to move and horizontally to turn.
  • Approach the blue image, then stop inside and turn around. The small wireframe is a lower-dimensional embedding analogy; the white dot shows your actual radial coordinate and angle. Its mesh is not a wall in the room.
The geometry behind the view

The spatial metric is ds² = dl² + r(l)²(dθ² + sin²θ dφ²), with r(l)² = b² + max(|l| − a, 0)², b = 1.8 and a = 1.6 in scene units. Two outer regions are connected by a finite cylindrical throat in this metric. The full static spacetime uses −c²dt² plus this spatial metric. There is no horizon or gravitational time-dilation gradient in this model.

Every sightline follows the spatial projection of a null geodesic, integrated numerically using conserved angular momentum. The implementation uses spherical symmetry and an interpolated ray table, with finite sampling and a finite tracing distance; very high-order images close to critical directions can show aliasing or dark unresolved slivers. Room surfaces and furnishings are intersected along these curved paths. The image sharpens when you stop moving to keep the browser workload bounded. Ray tracing runs in a background worker where supported, with a compatible main-thread fallback.

The inset embeds a two-dimensional equatorial slice in ordinary 3D for illustration. The main space has three spatial dimensions; curvature is intrinsic and does not require a physical surrounding fourth spatial dimension. The inset suppresses one dimension and is not a literal map you could stand outside to see. Walking is constrained to the equatorial plane, while sightlines explore the full 3D geometry. The hypothetical metric is prescribed, not an evolving simulation of matter creating a wormhole.

Functionality inspired by Kurzgesagt’s Wormhole Explorer and the geometry documented by sirxemic. Rooms, visuals, and implementation are original to this page. Further reading: James, von Tunzelmann, Franklin & Thorne, Visualizing Interstellar’s Wormhole.