I'm trying to implement a Reaction Diffusion Simulation by following this article: https://www.karlsims.com/rd.html. Where I'm running into trouble is the implementation of the 2D Laplacian function mentioned in this diagram:
The article later says: "The Laplacian is performed with a 3x3 convolution with center weight -1, adjacent neighbors .2, and diagonals .05." From what I've gathered from a little research, I think the convolution would look something like this:
a b c
d e f
g h i
Convolution = 0.2(b + f + h + d) + 0.05(a + c + i + g) - e
What is a 2D Laplacian, and how would I implement it to work on the result of my convolution? Pseudo-code would be much appreciated.