Semiautomatic construction of lattice Boltzmann models

Phys Rev E. 2020 Apr;101(4-1):043310. doi: 10.1103/PhysRevE.101.043310.

Abstract

A crucial step in constructing a lattice Boltzmann model is the definition of a suitable set of lattice velocities and the correct assignment of the associated weights. For high-order models, the solution of this problem requires a nontrivial effort. This paper outlines the functioning of a publicly available Python script which has been written to assist researchers in that task. The speed of sound c_{s} is considered as a parameter, which can, within limits, be chosen at will. Under this premise, the Maxwell-Boltzmann constraint equations are a system of linear equations to determine the weights and hence amenable to numerical solution by standard linear algebra library routines. By suitable contractions, the tensor equations are mapped to a set of equivalent scalar equations, which simplifies the treatment significantly. For a user-supplied set of velocity shells, the software first checks if a solution for the weights exists and returns it if it also happens to be unique. In such a case, the software also calculates the range of c_{s} values that yield positive weights. Standard models like D3Q19 with a well-defined special c_{s} value then result as limiting cases where one of the weights vanishes. In the case of an infinite set of solutions, the user may find one particular solution by supplying a c_{s} value and then minimizing one or several weights within the framework of standard linear programming. Some examples illustrate the feasibility and usefulness of the approach. A number of models that have been discussed in the literature are nicely reproduced, while the software has also been able to find some new models of even higher order.