Reaction-diffusion · qwen3-235b-a22b-2507
Output generated Cost / run $0.0008 Runtime 59.0s
Prompt for this run
Run a Gray-Scott reaction-diffusion simulation on a canvas that grows organic Turing patterns in real time, with the mouse seeding new growth.
TAKE IT TO CODE
A single self-contained HTML file — copy it and open in any browser, or reuse the prompt with your own pi-agent run.
RUN
METRICS
Transcript · 4 messages
Run a Gray-Scott reaction-diffusion simulation on a canvas that grows organic Turing patterns in real time, with the mouse seeding new growth.
index.html (9691 bytes)Successfully wrote 9691 bytes to index.html
I've created a single-page web application that implements a Gray-Scott reaction-diffusion simulation. The simulation generates organic Turing patterns in real time, and you can interact with it using your mouse to seed new growth. Key features of the implementation: - A canvas-based simulation displaying the concentration of chemical B (which forms the patterns) - Interactive controls to adjust the Gray-Scott parameters (feed rate, kill rate, diffusion rates) - Mouse interaction that allows you to seed new growth by clicking and dragging - Real-time updates showing the evolving patterns The simulation models the reaction-diffusion process where two chemicals A and B interact according to the equations: - A + 2B → 3B (reaction) - Feed A into the system at a constant rate - Remove B from the system at a constant rate - Diffuse both chemicals across the space The result is an emergent system that creates complex, organic-looking patterns reminiscent of biological structures. You can run it by opening the index.html file in any modern browser. Adjust the sliders to see different pattern formations emerge.