MaMiCo 1.2
Loading...
Searching...
No Matches
coupling::NieVelocityImposition< LinkedCell, dim > Class Template Reference

Velocity imposition scheme following the respective paper by Nie et al., J. Fluid. Mech. 500, 2004. More...

#include <NieVelocityImposition.h>

Inheritance diagram for coupling::NieVelocityImposition< LinkedCell, dim >:
Collaboration diagram for coupling::NieVelocityImposition< LinkedCell, dim >:

Public Member Functions

 NieVelocityImposition (coupling::interface::MDSolverInterface< LinkedCell, dim > *const mdSolverInterface, const unsigned int &outermostLayer, const unsigned int &innermostLayer)
 a simple constructor
 
virtual ~NieVelocityImposition ()
 a simple destructor
 
unsigned int getTimeIntervalPerMomentumInsertion () const override
 momentum shall be inserted in every md time step, so this returns 1
 
void insertMomentum (coupling::datastructures::CouplingCellWithLinkedCells< LinkedCell, dim > &cell, I02 idx) const override
 inserts momentum to a cell
 
- Public Member Functions inherited from coupling::MomentumInsertion< LinkedCell, dim >
 MomentumInsertion (coupling::interface::MDSolverInterface< LinkedCell, dim > *const mdSolverInterface)
 a simple constructor
 
virtual ~MomentumInsertion ()
 a simple destructor
 

Private Member Functions

bool isInsideImpositionLayer (I01 globalCellIndex) const
 based on the cell index, the function tells if the cell is inside the imposition layer
 

Private Attributes

const unsigned int _outermostLayer
 the index of the outermost cell layer
 
const unsigned int _innermostLayer
 the index of the innermost cell layer
 

Additional Inherited Members

- Protected Attributes inherited from coupling::MomentumInsertion< LinkedCell, dim >
coupling::interface::MDSolverInterface< LinkedCell, dim > *const _mdSolverInterface
 

Detailed Description

template<class LinkedCell, unsigned int dim>
class coupling::NieVelocityImposition< LinkedCell, dim >

Velocity imposition scheme following the respective paper by Nie et al., J. Fluid. Mech. 500, 2004.

Author
Philipp Neumann
Template Parameters
LinkedCellthe LinkedCell class is given by the implementation of linked cells in the molecular dynamics simulation
dimrefers to the spacial dimension of the simulation, can be 1, 2, or 3

Constructor & Destructor Documentation

◆ NieVelocityImposition()

template<class LinkedCell, unsigned int dim>
coupling::NieVelocityImposition< LinkedCell, dim >::NieVelocityImposition ( coupling::interface::MDSolverInterface< LinkedCell, dim > *const mdSolverInterface,
const unsigned int & outermostLayer,
const unsigned int & innermostLayer )
inline

a simple constructor

Parameters
mdSolverInterfaceinterface to the md solver
outermostLayerthe index of the outermost cell layer
innermostLayerthe index of the innermost cell layer

Member Function Documentation

◆ getTimeIntervalPerMomentumInsertion()

template<class LinkedCell, unsigned int dim>
unsigned int coupling::NieVelocityImposition< LinkedCell, dim >::getTimeIntervalPerMomentumInsertion ( ) const
inlineoverridevirtual

momentum shall be inserted in every md time step, so this returns 1

Returns
the time step interval for momentum insertion, always 1

Implements coupling::MomentumInsertion< LinkedCell, dim >.

◆ insertMomentum()

template<class LinkedCell, unsigned int dim>
void coupling::NieVelocityImposition< LinkedCell, dim >::insertMomentum ( coupling::datastructures::CouplingCellWithLinkedCells< LinkedCell, dim > & cell,
I02 idx ) const
inlineoverridevirtual

inserts momentum to a cell

Parameters
cellto the coupling cell will the momentum be inserted
idxlocal linearised index for the coupling cell

Implements coupling::MomentumInsertion< LinkedCell, dim >.

◆ isInsideImpositionLayer()

template<class LinkedCell, unsigned int dim>
bool coupling::NieVelocityImposition< LinkedCell, dim >::isInsideImpositionLayer ( I01 globalCellIndex) const
inlineprivate

based on the cell index, the function tells if the cell is inside the imposition layer

returns true if the local cell at index currentLocalCouplingCellIndex is inside the layer of imposition cells, given by outermostLayer and innermostLayer. For, e.g., outermostLayer=2 and innermostLayer=3, the layers for imposition are located in the 3rd and 4th strip of cells (we start counting from cell layer=0 which corresponds to the outermost, actually ghost-layer of cells which surrounds the MD domain).

Parameters
globalCellIndexglobal linearised index of a coupling cell to check
Returns
a bool, that indicates if the given cell index is located in the imposition layer (true) or not (false)

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