30#ifndef DUAL_LB_HELPERS_H
31#define DUAL_LB_HELPERS_H
41template<
typename T,
typename DESCRIPTOR>
44 static T
equilibrium(
int iPop,
int jPop, T rho,
const T u[DESCRIPTOR::d])
48 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
54 static T
equilibrium2(
int iPop,
int jPop, T rho,
const T u[DESCRIPTOR::d])
57 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
61 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
72 static void computeRhoU(T
const* cell, T& rho, T u[DESCRIPTOR::d])
76 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
79 for (
int iPop=0; iPop < DESCRIPTOR::q; ++iPop) {
81 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
85 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
97template <
typename DESCRIPTOR>
101 template <concepts::MinimalCell CELL,
typename V=
typename CELL::value_t>
108 template <concepts::MinimalCell CELL,
typename DJDF,
typename V=
typename CELL::value_t>
111 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
117 template <concepts::MinimalCell CELL,
typename DUDF,
typename V=
typename CELL::value_t>
120 V rho, u[DESCRIPTOR::d];
122 for (
int iD=0; iD < DESCRIPTOR::d; ++iD) {
128 template <concepts::MinimalCell CELL,
typename DPIDF,
typename V=
typename CELL::value_t>
131 V rho, u[DESCRIPTOR::d];
135 for (
int iAlpha=0; iAlpha < DESCRIPTOR::d; ++iAlpha) {
136 for (
int iBeta=iAlpha; iBeta < DESCRIPTOR::d; ++iBeta) {
Highest-level interface to read-only Cell data.
constexpr T invCs2() any_platform
constexpr T t(unsigned iPop, tag::CUM) any_platform
constexpr int c(unsigned iPop, unsigned iDim) any_platform
Top level namespace for all of OpenLB.
static V secondOrder(int iPop, const RHO &rho, const U &u, const USQR &uSqr) any_platform
Computation of equilibrium distribution, second order in u.
static void computeRhoU(CELL &cell, RHO &rho, U &u) any_platform
Computation of hydrodynamic variables.
Derivative of Objective functional regarding populations.
This structure forwards the calls to the appropriate helper class.
static T equilibrium2(int iPop, int jPop, T rho, const T u[DESCRIPTOR::d])
static void computeRhoU(T const *cell, T &rho, T u[DESCRIPTOR::d])
Computation of hydrodynamic variables.
static T equilibrium(int iPop, int jPop, T rho, const T u[DESCRIPTOR::d])
static void computeRhoU(ConstCell< T, DESCRIPTOR > &cell, T &rho, T u[DESCRIPTOR::d])
static void dUDf(CELL &cell, DUDF &dudf, int jPop) any_platform
derive velocity u by population component
static V dRhoDf(CELL &cell, int jPop) any_platform
derive rho by population component
static void dPiDf(CELL &cell, DPIDF &dpidf, int jPop) any_platform
derive stress pi by population component
static void dJDf(CELL &cell, DJDF &djdf, int jPop) any_platform
derive momentum j by population component