Mathematical animations in pure Python — zero dependencies, one file, stdlib only.
No pygame. No numpy. No shaders. Just tkinter, math, and ideas that are older than computers: fiber bundles, chaotic attractors, hyperbolic geometry, n-body gravity. If you have Python, you already have everything this needs.
python spectral_geometry.py # windowed art / ambient display
python spectral_geometry.py --selftest # headless render test, no screen neededControls: Space / → / mouse click — next scene · ← — previous · Esc / Q — quit. Scenes auto-rotate every 7 minutes. Live clock + optional system telemetry (CPU/RAM, if psutil is present) make it a pleasant second-monitor ambient panel.
Because constraints are the art. Every scene here is:
- One file, no installs — runs on any Python ≥ 3.10 with tkinter (the default on Windows/macOS, one package away on Linux)
- A pooled-canvas renderer — pre-allocated line items, style caching, quantized HSV: thousands of segments at 30 fps on an office laptop
- Honest mathematics — real Verlet gravity, real RK4 pendulums, real Möbius maps and stereographic projections; nothing is a pre-baked path
spectral_geometry.py # the current piece: 8 scenes, windowed, selftest
series/ # the evolution: 01→09, fullscreen tkinter experiments
assets/ # GIF/poster previews + the headless renderer that made them
The series/ folder is the archaeology — nine earlier screensavers (sacred geometry, 4D polytopes, walking creatures, wireframe terrain…) that led here. assets/render_previews.py re-renders every preview headlessly (Pillow used only for asset generation, never at runtime).
MIT — take it, remix it, put it on the second monitor of your open-space office.







