Subway Tunnel Light-Guide: Refraction (2D)
2D Snell's-law lab: light travels inside a subway tunnel's acrylic light-guide and hits the air boundary — drag the incidence angle past the critical angle to watch refraction give way to total internal reflection, with wavelength-driven dispersion colouring the transition.
This 2D companion drops the 3D version's tunnel flythrough and instead isolates the one piece of real physics its title promises but its camera ride never modelled: refraction. A single boundary line separates the tunnel's acrylic light-guide (the fibre-optic strip real subway tunnels use to edge-light their walls) from the open air above it. Drag the incidence angle and watch the transmitted ray bend away from the normal exactly as Snell's law predicts, right up until it crosses the critical angle — set by the guide's refractive index — at which point the ray stops escaping entirely and the boundary turns into a perfect mirror, total internal reflection. A live readout tracks θ₁, θ₂, the critical angle, and the exact Fresnel reflectance/transmittance split at every angle; a wavelength slider (with an adjustable Cauchy dispersion coefficient) recolours the ray and shifts its critical angle slightly, and a full-spectrum toggle fans every visible wavelength out at once so you can see red and violet part company right at the TIR threshold, the same dispersion that splits a prism's rainbow.
2D geometric-optics lab: exact Fresnel equations for reflectance/transmittance, Snell's law for the refraction angle, a Cauchy-equation dispersion model tying refractive index to wavelength, and a critical-angle test that switches the boundary into total internal reflection.
2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install