drag body: move · drag ○ handle: rotate · wheel: zoom · right-drag / space: pan · dbl-click: fit · del: remove · h: help
LUMEN LAB
an interactive ray-optics workbench
The physics
Refraction — Snell's law at every glass boundary, with a per-wavelength refractive index from the Sellmeier equation (BK7 crown glass + your Δn offset), which is why white light fans into a rainbow.
Fresnel reflection — every interface splits the ray: part reflects, part transmits (unpolarized Fresnel coefficients). Watch faint ghost rays leave every surface.
Total internal reflection — beyond the critical angle a ray is perfectly trapped. Tilt a laser into a slab to build a light-pipe.
Beer–Lambert absorption — glass dims rays exponentially with distance travelled (raise σ on any element and the energy budget shifts from "escaped" to "absorbed").
Energy budget — the top-right panel audits where every photon ends up: screens, escape, absorption, or still in flight.
Working the bench
Add emitters and optics from the toolbar; everything is placed at the current view center.
Drag a body to move it · drag the ○ handle to rotate/aim (hold Shift to snap 15° / 0.25u).
wheel zoom to cursor · right-drag or space+drag pan · dbl-click empty space fits the scene.
Del removes the selection · the control panel edits every property live (wavelength, white/mono, index offset Δn, absorption σ…).
Screens are photometers: they absorb rays and plot a glowing exposure histogram along their length — park one behind a prism to read the spectrum.
Try the presets in the control panel: Prism Rainbow, Focusing Bench, Fiber Light-Pipe, Raindrop Caustic, Periscope.
Keys
H help · M audio · G grid · P save PNG · Esc deselect