OpenLB 1.7
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
olb::momenta::InnerEdgeStress3D< plane, normal1, normal2 > Struct Template Reference

Computation of the stress tensor in an inner edge. More...

#include <elements.h>

+ Collaboration diagram for olb::momenta::InnerEdgeStress3D< plane, normal1, normal2 >:

Public Member Functions

template<typename TYPE , typename CELL , typename RHO , typename U , typename PI , typename V = typename CELL::value_t, typename DESCRIPTOR = typename CELL::descriptor_t>
void compute (CELL &cell, const RHO &rho, const U &u, PI &pi) any_platform
 

Static Public Member Functions

static std::string getName ()
 

Detailed Description

template<int plane, int normal1, int normal2>
struct olb::momenta::InnerEdgeStress3D< plane, normal1, normal2 >

Computation of the stress tensor in an inner edge.

Definition at line 1317 of file elements.h.

Member Function Documentation

◆ compute()

template<int plane, int normal1, int normal2>
template<typename TYPE , typename CELL , typename RHO , typename U , typename PI , typename V = typename CELL::value_t, typename DESCRIPTOR = typename CELL::descriptor_t>
void olb::momenta::InnerEdgeStress3D< plane, normal1, normal2 >::compute ( CELL & cell,
const RHO & rho,
const U & u,
PI & pi )
inline

Definition at line 1319 of file elements.h.

1320 {
1321 V uSqr = util::normSqr<V,DESCRIPTOR::d>(u);
1322 auto newCell = cell.template getField<descriptors::POPULATION>();
1323 for (int iPop=0; iPop<DESCRIPTOR::q; ++iPop) {
1324 if ( (descriptors::c<DESCRIPTOR>(iPop,(plane+1)%3) == -normal1) &&
1325 (descriptors::c<DESCRIPTOR>(iPop,(plane+2)%3) == -normal2) ) {
1326 int opp = descriptors::opposite<DESCRIPTOR>(iPop);
1327 newCell[iPop] = newCell[opp]
1328 - equilibrium<DESCRIPTOR>::secondOrder(opp, rho, u, uSqr)
1329 + equilibrium<DESCRIPTOR>::secondOrder(iPop, rho, u, uSqr);
1330 }
1331 }
1332 lbm<DESCRIPTOR>::computeStress(newCell, rho, u, pi);
1333 }
static V secondOrder(int iPop, const RHO &rho, const U &u, const USQR &uSqr) any_platform
Computation of equilibrium distribution, second order in u.
Definition lbm.h:51
static void computeStress(CELL &cell, const RHO &rho, const U &u, PI &pi) any_platform
Computation of stress tensor.
Definition lbm.h:229

References olb::lbm< DESCRIPTOR >::computeStress(), and olb::equilibrium< DESCRIPTOR >::secondOrder().

+ Here is the call graph for this function:

◆ getName()

template<int plane, int normal1, int normal2>
static std::string olb::momenta::InnerEdgeStress3D< plane, normal1, normal2 >::getName ( )
inlinestatic

Definition at line 1335 of file elements.h.

1335 {
1336 return "InnerEdgeStress3D";
1337 }

The documentation for this struct was generated from the following file: