@@ -38,7 +38,7 @@ The most common examples are D1Q3, D2Q5, D2Q9, D3Q7, D3Q15, D3Q19, and D3Q27.
Not all velocity sets are suitable for accurate resolution of the desired macroscopic equation \cite{kruger:2017lattice,fucik:lbman,fucik:lbmat}.
In this thesis, we aim to use LBM for the solution of the Navier--Stokes equations in $\mathbb R^3$ and thus consider the D3Q27 velocity set consisting of $Q =27$ discrete velocities.
A velocity set for LBM is fully defined by two sets of quantities: lattice velocities $\vec\xi_q$ and the corresponding weights $w_q$ for $q =1, \ldots, Q$.
A velocity set for LBM is fully defined by two sets of quantities: lattice velocities $\vec\xi_q$ and the corresponding weights $w_q$ for $q \in\{1, \ldots, Q\}$.
Another important quantity that can be derived from these two sets is the lattice speed of sound $c_s$.
The aforementioned velocity sets can be derived using the Gauss--Hermite quadrature~\cite[Appendix~A.4]{kruger:2017lattice}.
Another approach explained in \cite[Section~3.4.7.2]{kruger:2017lattice} is to determine the weights by solving the system of equations representing general conditions that ensure rotational isotropy of the lattice.
@@ -56,7 +56,8 @@ The discretization of \cref{eq:lbm:BTE} in velocity space (using a velocity set)
f_q(\vec x + \Delta t \vec\xi_q, t + \Delta t) - f_q(\vec x, t) = \Delta t \left( \mathcal C_q(\vec x, t) + \mathcal S_q(\vec x, t) \right)
%f_q(\vec x + \Delta t \vec \xi_q, t + \Delta t) - f_q(\vec x, t) = \Delta t \mathcal C_q(\vec x, t)
\end{equation}
for all $q =1, \ldots, Q$, $\vec x \in\hat\Omega$, and $t \in\hat I$.
\todo{fix dimensions of the quantities: $\vec x$~\si{\metre}, but $\Delta t \vec\xi_q$~\si{-}}
for all $q \in\{1, \ldots, Q\}$, $\vec x \in\hat\Omega$, and $t \in\hat I$.
In \cref{eq:lbm:LBE}, $f_q = f_q(\vec x, t)$ is the discrete density distribution functions corresponding to the microscopic velocity $\vec\xi_q$, $\mathcal C_q$ is the discrete collision operator and $\mathcal S_q$ is the discrete source term.
Note that the collision operator $\mathcal C_q$ depends on the whole set of $Q$ discrete density distribution functions (i.e., the $Q$ equations written in \eqref{eq:lbm:LBE} are not independent).
@@ -67,7 +68,7 @@ The scheme for the approximation of the Navier--Stokes equations is constructed
\end{equation}
and the macroscopic momentum density $\rho\vec v$, which can be computed in lattice units as
f_q(\vec x + \Delta t \vec\xi_q, t + \Delta t) = f_q^\ast(\vec x, t),
\qquad\forall q \in\{1, \ldots, Q\},
\end{equation}
where the post-collision distribution function $f_q$ is propagated to the neighboring lattice site in the direction of the corresponding velocity $\vec\xi_q$.
\end{enumerate}
@@ -130,11 +133,13 @@ The alternative, yet equivalent can be formulated as:
f_q(\vec x, t) = f_q^\ast(\vec x - \Delta t \vec\xi_q, t - \Delta t),
\qquad\forall q \in\{1, \ldots, Q\},
\end{equation}
where the post-collision distribution function $f_q$ is propagated from the neighboring lattice site in the direction of $-\vec\xi_q$ from the previous time level.
where $f_q^\ast$ denotes the value of the distribution function \emph{after} collision in the given lattice site.
\end{enumerate}
@@ -142,7 +147,7 @@ The alternative, yet equivalent can be formulated as:
This scheme is called the \emph{pull scheme}, since the streaming step propagates the values to the reference lattice site $\vec x \in\hat\Omega$ from its neighbors.
The visualization of the difference between the push and pull streaming schemes is illustrated in \cref{fig:lbm:AB push,fig:lbm:AB pull} for a D2Q9 velocity set.
Note that regardless of the chosen streaming scheme, the collision step is \emph{local} in terms of the lattice sites $\vec x \in\hat\Omega$ (i.e., collisions in different lattice sites are independent of each other), but collective for all $q =1, \ldots, Q$ since collision operator $\mathcal C_q$ depends on the whole set of distribution functions in given lattice site.
Note that regardless of the chosen streaming scheme, the collision step is \emph{local} in terms of the lattice sites $\vec x \in\hat\Omega$ (i.e., collisions in different lattice sites are independent of each other), but collective for all $q \in\{1, \ldots, Q\}$ since collision operator $\mathcal C_q$ depends on the whole set of distribution functions in given lattice site.
On the other hand, the operations in the streaming step are \emph{non-local}, but trivial as they do not require any computation (the post-collision values are merely transferred from one place to another).
Both the push and pull schemes require attention during the implementation to avoid overwriting memory locations containing values that may be needed in the future.
@@ -180,16 +185,19 @@ The time-stepping procedure using the A-A pattern can be formalized as follows:
\texttt{A[}\overline q, \vec x\texttt{]} = f_q^\ast(\vec x, t),
\qquad\forall q \in\{1, \ldots, Q\},
\end{equation}
where the post-collision values are written to the same array \ic{A} at the same lattice site $\vec x$, but the direction $q$ is inverted: $\overline q \in\{1, \ldots, Q\}$ is defined such that $\vec\xi_{\overline q}=-\vec\xi_q$.
\end{enumerate}
@@ -199,16 +207,19 @@ The time-stepping procedure using the A-A pattern can be formalized as follows:
f_q(\vec x, t) = \texttt{A[}\overline q, \vec x - \Delta t \vec\xi_q\texttt{]},
\qquad\forall q \in\{1, \ldots, Q\},
\end{equation}
where the values are read from the array \ic{A} from neighboring lattice sites, but the direction $q$ is inverted for consistency with \cref{eq:lbm:AA-pattern:even post-collision step}.