Inspiration
What it does
It simulates a Gray Scott model of Reaction-Diffusion into a LED board controlled by an arduino. (Simulates a chemical interaction on a 2D grid)
How we built it
We started with a proof of concept by implementing the mathematical model with Python, using a basic inbeed plotting function to visualize the results.
We built the final product using a given arduino simulation (P4LAB sandbox) with a connected virtual 16x16.
We also tried various other implementations with different languages and graphical technologies;
- Python implementation with PyGame
- C++ implementation with OpenGL and Qt
- Web implementation with p5.js and Vue.js
- Java implementation with JOGL and Swing
Challenges we ran into
In order to scale up the reaction-diffusion experiment to larger discretized spaces, we aimed at performing the computations on the GPU using two image buffers, one for the previous state and the other for the current state to display. To do this, we wanted to leverage OpenGL in C++ with an added Qt interface for interactivity. We ran into issues in setting up OpenGL for cross-platform compatibility. To make a demo accessible to the judges, we also tried to implement this as a small web application using Vue.js for the GUI and p5.js for the graphics processing. We ran into memory leakage issues when accessing the rendered image to use as previous state in the simulation. Finally, we tried to use Java Swing for the GUI and JOGL for the shading, but we ran out of time in debugging due to obscure error messages.
Accomplishments that we're proud of
Figuring out how to cast the problem into using unsigned chart to fit the code memory into the arduino board.
What we learned
Learned how to deal with the memory constraints and also understood the impact in the changes of the different mathematical model variables.
What's next for Reaction Diffusion Simulation
An implementation on a bigger LED board (a grid of drones / drone light show).
Log in or sign up for Devpost to join the conversation.