132 {
133 V rho, u[DESCRIPTOR::d];
134 MomentaF().computeRhoU(cell, rho, u);
135
137
138 V velDenominator = cell.template getFieldComponent<descriptors::VELOCITY_DENOMINATOR>(0);
139
140
141 V uPlus[DESCRIPTOR::d]{ };
142 V diff[DESCRIPTOR::q]{ };
143
144 if (velDenominator > std::numeric_limits<V>::epsilon()) {
145 for (int iDim=0; iDim<DESCRIPTOR::d; ++iDim) {
146 uPlus[iDim] = u[iDim];
147 }
149 if constexpr (!isStatic) {
150 particles::resetParticleRelatedFields<DESCRIPTOR,CELL,V>(cell);
151 }
152
153 for (int tmp_iPop=0; tmp_iPop < DESCRIPTOR::q; tmp_iPop++) {
154 diff[tmp_iPop] +=
EquilibriumF().compute(tmp_iPop, rho, uPlus)
156 cell[tmp_iPop] += diff[tmp_iPop];
157 }
158 }
159
160 particles::resetParticleContactRelatedFields<DESCRIPTOR,CELL,V>(cell);
161
162 return statistic;
163 }
typename MOMENTA::template type< DESCRIPTOR > MomentaF
void calculate(CELL &cell, pVELOCITY &pVelocity)
typename EQUILIBRIUM::template type< DESCRIPTOR, MOMENTA > EquilibriumF
typename COLLISION::template type< DESCRIPTOR, MOMENTA, EQUILIBRIUM > CollisionO
typename meta::list< descriptors::OMEGA > parameters