The Gray-Scott equations originate from the class of reaction-diffusion equations, and depending or their two-dimensional parameter settings they can model a variety of patterns, such as spots, stripes, maze formations, ripples et cetera [1]. The Gray-Scott equations model the following chemical reaction:
This is modelled by the following coupled Partial Differential Equations (PDEs), consisting of a diffusion term, interaction term, negative and feeds and positive U feed [2]:
Here, and are two-dimensional in space (), and denotes their laplacian operator. Here, we numerically solve these equations by approximating the time derivative by finite difference methods. The time derivative and laplacian are approximated by a forward difference and central difference scheme respectively [3].
Without the interaction and feed terms, the PDEs collapse to regular (uncoupled) heat equations. This case is also considered in our code as a test case.
[1] Trefethen, Nick "The (Unfinished) PDE Coffee Table Book". http://people.maths.ox.ac.uk/trefethen/pdectb/reaction2.pdf
[2] Pearson, John E. "Complex patterns in a simple system." Science 261.5118 (1993): 189-192.
[3] Recktenwald, Gerald W. "Finite-difference approximations to the heat equation." Mechanical Engineering 10 (2004): 1-27. Updated in 2011.
Clone repository by opening the terminal and typing
git clone https://github.com/SABS-R3-projects/Gray-Scott-PDE/
Then install the grayscott module and all dependencies with
pip install .
Congratulations! You successfully installed grayscott.
All the code can be run by executing the jupyter notebook Main.ipynb
. The Jupyter interface is initiated by running jupyter notebook
in your terminal.
This project is release under a BSD 3-Clause License.
Enjoy!