calculateMDFields.H
Go to the documentation of this file.
1 const List<DynamicList<molecule*> >& cellOccupancy = molecules.cellOccupancy();
2 
3 forAll(cellOccupancy, cell)
4 {
5  const List<molecule*>& molsInCell = cellOccupancy[cell];
6 
7  forAll(molsInCell, mIC)
8  {
9  molecule* mol = molsInCell[mIC];
10 
11  const label molId = mol->id();
12 
13  const vector& molU = mol->U();
14 
15  allSpeciesN_RU[molId][cell]++;
16 
17  allSpeciesM_RU[molId][cell] += mol->mass();
18 
19  allSpeciesVelocitySum_RU[molId][cell] += molU;
20 
21  allSpeciesVelocityMagSquaredSum_RU[molId][cell] += molU & molU;
22  }
23 }
List< scalarField > allSpeciesM_RU(molecules.potential().nIds(), scalarField(mesh.nCells(), 0.0))
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59
List< scalarField > allSpeciesN_RU(molecules.potential().nIds(), scalarField(mesh.nCells(), 0.0))
forAll(cellOccupancy, cell)
List< vectorField > allSpeciesVelocitySum_RU(molecules.potential().nIds(), vectorField(mesh.nCells(), vector::zero))
const List< DynamicList< molecule * > > & cellOccupancy
List< scalarField > allSpeciesVelocityMagSquaredSum_RU(molecules.potential().nIds(), scalarField(mesh.nCells(), 0.0))
Vector< scalar > vector
A scalar version of the templated Vector.
Definition: vector.H:49