I went through Ch.10 of Hjorth-Jensen (2015) and wrote up as many C++ scripts to illustrate all the (serial) PDE solvers: forward, backward Euler, Crank-Nicolson, Jacobi method.
Lid-driven cavity with incompressible, viscous fluid on a 512×512 staggered grid, in CUDA C++11, with finite difference method for 2-dim., unsteady Navier-Stokes equations solver
Compare this with pp. 69 of Ch. 5, Example Applications of Griebel, Dornsheifer, Neunhoeffer.
Michael Griebel, Thomas Dornsheifer, Tilman Neunhoeffer. Numerical Simulation in Fluid Dynamics: A Practical Introduction (Monographs on Mathematical Modeling and Computation). SIAM. 1997.