Assignment
PDEs in 1D: Reaction-Diffusion
Implement a full 1D reaction-diffusion workflow for the Gierer-Meinhardt model. Your submission should include code and figures that demonstrate pattern formation.
Required
- Implement the PDE solver using an explicit Euler time step.
- Enforce Neumann boundary conditions at each step.
- Use \(L=40\), \(dx=0.5\), \(dt=0.001\), \(a=0.40\), \(b=1.00\), \(d=20\), \(\gamma=1\).
- Create an animation of \(v(x)\) that updates in time.
Turing Instability
- Implement
is_turing_instability(a, b, d)and plot the Turing space diagram. - Mark the point \((a, d)\) you are using on the diagram.
Extra Mile (Optional)
- Compute unstable spatial modes and display the leading mode on the animation.
- Make the diagram interactive: clicking on \((a, d)\) updates the simulation.
- Try other boundary conditions and compare.
Tips for Success
- Start simple: Verify your Laplacian and boundary conditions first.
- Test incrementally: Plot intermediate results to detect instability early.
- Be careful with dt: If the simulation explodes, reduce \(dt\) or increase \(dx\).
- Document choices: Report the parameters you used and the patterns you observed.
Good luck and enjoy your coding!