Skip to content
Andrew Voirol
Work → BuckyBounce: Molecular Physics Lab → BuckyBounce: Molecular Physics & Euler Topology Lab
ThreadComplete

BuckyBounce: Molecular Physics & Euler Topology Lab

An interactive Three.js structural mechanics playground exploring nanoscale allotropes, spring-mass lattice dynamics, harmonic resonance sweeps, and Euler face extraction.

Code
Started Jul 29, 2026·Latest Aug 13, 2026·6 entries

C₆₀ Buckminsterfullerene in Arcade mode with cyan atoms, magenta bonds, neon holographic rings, real-time telemetry panel showing Euler formula V(60)−E(90)+F(32)=2, and Arcade Rebound scoring panel

Arcade mode — fire energy probes through holographic pentagonal target rings on the C₆₀ fullerene

Carbon nanotube (SWCNT) rendered as a cylindrical lattice of cyan atoms and magenta bonds, with Euler topology V(60)−E(110)+F(25)=−25 and science insight about 100 GPa tensile strength
C₆₀ fullerene in Stress Lab mode with harmonic driver at 4.5Hz, thermal Brownian agitation at 50K active, and controls for heatmap, bond snapping, shatter, and Hoberman breathing

What started as an impulse to explore mechanical physics through expanding Hoberman breathing spheres quickly evolved into building a real-time molecular physics laboratory in Three.js. A spring-mass network based on the 60-vertex C60C_{60}C60​ truncated icosahedron provided the ideal playground: 90 covalent bonds modeled as damped Hooke's law springs (F=−kΔx−cvF = -k \Delta x - c vF=−kΔx−cv) and solved with sub-stepped numerical integration, paired with Web Audio FM synthesis for tactile collision clacks.

To turn the simulation into an interactive structural mechanics testbed, the engine needed topological awareness. A chordless minimal cycle traversal algorithm parses raw node-link graphs to extract 2-manifold faces dynamically, locating the exact 12 pentagons and 20 hexagons predicted by Euler's polyhedral formula (V−E+F=2V - E + F = 2V−E+F=2). Those 12 pentagonal topological defects became holographic arcade target rings for high-speed probe ricochets with pentatonic chime sweeps and combo scoring.

The project expanded across six distinct allotropes and structural architectures—from (5,5)(5,5)(5,5) armchair carbon nanotubes and graphene sheets to floating tensegrity icosahedrons with isolated compression struts suspended in continuous tension networks. A harmonic driving oscillator sweeps excitation frequencies to reveal natural eigenmode resonances in real time, accompanied by thermal strain heatmaps, yield-stress covalent bond snapping, and laser-weld lattice repair.

Latest Update

Six floating struts and an interactive molecular codex

Thu, Aug 13, 2026

Timeline

Dropped into a dark room — a BuckyBounce AI export straight from Google AI Studio — and found 60 physics bodies bouncing correctly but leaking AudioContexts on every collision. Found a Vite + React + Three.js codebase with a working Hoberman breathing sphere, gravity gun, shatter/reform mechanics, and FM-synthesized impact audio. The core physics loop was solid: damped Hooke's law springs (F=−kΔx−cvF = -k \Delta x - c vF=−kΔx−cv) with elastic boundary collisions. But every node collision spawned a fresh AudioContext instead of reusing a shared one — 6,598 console errors in a 3-minute session. A geometry rotation TS error broke the initial render path. Both were 15-minute fixes once diagnosed: lazy-init a single AudioContext, cast the rotation properly. The initial cleanup — import map removal, Tailwind CDN→npm migration, API key migration to import.meta.env — had already run. Two hours of recon, two surgical fixes, and the export went from "crashes with a wall of red" to "60-body spring-mass sim running clean at 60fps."

ReactDebugging
Permalink →

What started as an impulse to explore mechanical physics through expanding Hoberman breathing spheres quickly evolved into building a real-time C60C_{60}C60​ fullerene spring-mass simulator in Three.js. Generating the 60-vertex truncated icosahedron required deriving 12 golden-ratio (ϕ=(1+5)/2\phi = (1 + \sqrt{5})/2ϕ=(1+5​)/2) vertices of an icosahedron dual, normalizing them to a sphere, dividing each connecting edge into thirds, and wiring the nearest triples to produce 90 covalent spring links. Each bond acts as a damped Hooke's law spring (F=−kΔx−cvF = -k \Delta x - c vF=−kΔx−cv), solved with sub-stepped Euler integration to prevent explosive instability under high restitution. Added an interactive impulse punch system that deforms the molecular cage on click and bounces elastically off canvas boundaries, paired with Web Audio API frequency-modulation (FM) synthesis that produces a crisp metallic clack on every collision.

ReactAnimationVisualization
Permalink →

Taking BuckyBounce from prototype to shipped repo required taming two very different physics engines: in-browser audio concurrency and macOS window focus. Eliminating the 6,536 audio console errors took a lazy singleton AudioContext paired with a 50ms cooldown and a strict 5-sound concurrency limiter in utils.ts. But the real friction hit during asset capture, burning nearly 60% of the launch session's effort on screen recording and demo GIF generation. The Antigravity IDE stole window focus between every automated tool call, while 60fps shatter physics hurled atoms offscreen in under 300ms—consistently leaving screencapture with an empty viewport. Solved both by scripting AppleScript window hiding and extracting discrete frames from a 125-second screencast using ffmpeg timestamps. Shipped 24 files and 5,399 insertions in commit 7866c8d, then turned the bruised session into a lasting rule for our capture skills: lessons are earned, not learned.

WorkflowDebuggingAutomation
Permalink →

To turn an elastic bouncing buckyball into an arcade physics challenge, the engine needed to recognize molecular faces rather than just raw vertices and edges. Implemented a chordless minimal cycle traversal algorithm that parses the raw node-link graph to automatically detect 2-manifold faces, extracting exactly the 12 pentagons and 20 hexagons governed by Euler's polyhedral formula (V−E+F=2V - E + F = 2V−E+F=2). Transformed the 12 pentagonal topological defects into glowing holographic target rings oriented along their outward surface normals. Built a high-speed projectile slingshot mechanic that lets you fire particle probes through the molecular cage, rewarding precision ring threading with procedural pentatonic chime sweeps and exponential combo multipliers when ricocheting off interior nodes.

VisualizationAnimationDesign
Permalink →

Upgraded BuckyBounce into a structural mechanics laboratory featuring 6 allotropes, harmonic resonance sweeps, and catastrophic bond fracture. Expanded the geometry engine beyond C60C_{60}C60​ to generate C70C_{70}C70​ fullerenes, (5,5)(5,5)(5,5) armchair carbon nanotubes, graphene honeycomb sheets, geodesic domes, and 6-strut tensegrity icosahedrons with isolated compression bars suspended in continuous tension networks. Implemented a harmonic driving oscillator to sweep excitation frequencies (ω\omegaω) and reveal natural eigenmode vibrations in real time. Dynamic vertex shaders map Hooke's strain tensors into thermal heatmaps (cyan →\to→ yellow →\to→ red), triggering covalent bond snapping when local strain exceeds yield strength—complete with a laser-weld synthesis tool to reconstruct shattered lattices atom by atom.

VisualizationAnimationReact
Permalink →

Rebuilding BuckyBounce into a full structural laboratory meant expanding far beyond fullerenes to simulate true tensegrity dynamics in Three.js. Constructed a 6-strut tensegrity icosahedron where 6 rigid compression bars remain completely isolated from one another, suspended purely in dynamic equilibrium by 24 continuous elastic tension tendons. To transform the toy into an educational engine, built 666 lines of pedagogical interfaces spanning an interactive 3D Codex modal, structural puzzle challenges, and an AI Architect prompt interface that uses structured Gemini JSON schemas to generate custom spring constants and gravity vectors on the fly. Handled 6 distinct structural allotropes across 670 lines in geometry/structures.ts, wiring real-time Euler polyhedral validation into the HUD. Shipped 3,530 insertions across 21 files in commit 519aa35 after 513 agent steps, turning a simple bouncing sphere into a deep material science playground.

Three.jsPhysicsReact
Permalink →

Andrew Voirol

Builder, hacker, shipper. Currently leaving localhost.

Navigate

WorkThreadsBuilder's LogAboutContactRSS Feed

Connect

X / TwitterGitHubLinkedIn

© 2026 Andrew Voirol·Back to top ↑
✦Just one prompt away from figuring it all out.