Introduction - If you have any usage issues, please Google them yourself
Parallel LBM in C++
In which, as a counterpoint to abstract virtual generic templated meta-programming, we present a concrete code to simulate on precisely two computational nodes using a 1D lattice Boltzmann model with omega = 1 the heating of one end of a 1m copper bar for 0.1ms.
Note that this code is deliberately condensed, contains few comments, and its layout is optimised for printing out and reading. And in order to get it down to one page I ve also cut it down to one dimension so the concept of hydrodynamics, for which LBM is generally used, is rather lost.
Having said that, it s a neat bit of code. The intention in writing it was to demonstrate how to perform simple distributed memory computations using MPI. My main code uses pretty much the same method, rather better structured, and scales well up to 32 processors (maybe more- I haven t tried).