OpenLB 1.7
Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
olb::collision::TrackAverageVelocity< COLLISION >::type< DESCRIPTOR, MOMENTA, EQUILIBRIUM > Struct Template Reference

#include <collisionModifiers.h>

+ Collaboration diagram for olb::collision::TrackAverageVelocity< COLLISION >::type< DESCRIPTOR, MOMENTA, EQUILIBRIUM >:

Public Types

using MomentaF = typename MOMENTA::template type<DESCRIPTOR>
 
using CollisionO = typename COLLISION::template type<DESCRIPTOR, MOMENTA, EQUILIBRIUM>
 

Public Member Functions

template<CONCEPT(MinimalCell) CELL, typename PARAMETERS , typename V = typename CELL::value_t>
CellStatistic< V > apply (CELL &cell, PARAMETERS &parameters) any_platform
 

Detailed Description

template<typename COLLISION>
template<typename DESCRIPTOR, typename MOMENTA, typename EQUILIBRIUM>
struct olb::collision::TrackAverageVelocity< COLLISION >::type< DESCRIPTOR, MOMENTA, EQUILIBRIUM >

Definition at line 94 of file collisionModifiers.h.

Member Typedef Documentation

◆ CollisionO

template<typename COLLISION >
template<typename DESCRIPTOR , typename MOMENTA , typename EQUILIBRIUM >
using olb::collision::TrackAverageVelocity< COLLISION >::type< DESCRIPTOR, MOMENTA, EQUILIBRIUM >::CollisionO = typename COLLISION::template type<DESCRIPTOR, MOMENTA, EQUILIBRIUM>

Definition at line 96 of file collisionModifiers.h.

◆ MomentaF

template<typename COLLISION >
template<typename DESCRIPTOR , typename MOMENTA , typename EQUILIBRIUM >
using olb::collision::TrackAverageVelocity< COLLISION >::type< DESCRIPTOR, MOMENTA, EQUILIBRIUM >::MomentaF = typename MOMENTA::template type<DESCRIPTOR>

Definition at line 95 of file collisionModifiers.h.

Member Function Documentation

◆ apply()

template<typename COLLISION >
template<typename DESCRIPTOR , typename MOMENTA , typename EQUILIBRIUM >
template<CONCEPT(MinimalCell) CELL, typename PARAMETERS , typename V = typename CELL::value_t>
CellStatistic< V > olb::collision::TrackAverageVelocity< COLLISION >::type< DESCRIPTOR, MOMENTA, EQUILIBRIUM >::apply ( CELL & cell,
PARAMETERS & parameters )
inline

Definition at line 99 of file collisionModifiers.h.

99 {
100 auto statistics = CollisionO().apply(cell, parameters);
101
102 Vector<V,DESCRIPTOR::d> u;
103 MomentaF().computeU(cell, u);
104
105 std::size_t iT = parameters.template get<descriptors::LATTICE_TIME>();
106 auto uAvg = cell.template getField<descriptors::AVERAGE_VELOCITY>();
107 cell.template setField<descriptors::AVERAGE_VELOCITY>((uAvg * (iT-1) + u) / iT);
108
109 return statistics;
110 }
typename COLLISION::template type< DESCRIPTOR, MOMENTA, EQUILIBRIUM > CollisionO
typename MOMENTA::template type< DESCRIPTOR > MomentaF
typename COLLISION::parameters::template include< descriptors::LATTICE_TIME > parameters

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