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

carries out velocity relaxation (similar to the SetMomentumMapping procedure). More...

#include <VelocityGradientRelaxation.h>

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

Public Member Functions

 VelocityGradientRelaxationTopOnly (double relaxationParam, coupling::interface::MDSolverInterface< LinkedCell, dim > *const mdSolverInterface, const coupling::datastructures::CouplingCellWithLinkedCells< LinkedCell, dim > *const couplingCells)
 a simple constructor
 
virtual ~VelocityGradientRelaxationTopOnly ()
 a dummy destructor
 
void insertMomentum (coupling::datastructures::CouplingCellWithLinkedCells< LinkedCell, dim > &cell, I02 idx) const override
 insertes the momentum to the cells according to the params and velocity gradient relaxation method
 
- Public Member Functions inherited from coupling::VelocityGradientRelaxation< LinkedCell, dim >
 VelocityGradientRelaxation (double relaxationParam, coupling::interface::MDSolverInterface< LinkedCell, dim > *const mdSolverInterface, const coupling::datastructures::CouplingCellWithLinkedCells< LinkedCell, dim > *const couplingCells)
 a simple constructor
 
virtual ~VelocityGradientRelaxation ()
 a dummy destructor
 
unsigned int getTimeIntervalPerMomentumInsertion () const override
 returns the time step interval for the momentum insertion, always one for this method
 
- 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
 

Additional Inherited Members

- Protected Attributes inherited from coupling::VelocityGradientRelaxation< LinkedCell, dim >
const coupling::datastructures::CouplingCellWithLinkedCells< LinkedCell, dim > *const _couplingCells
 
const double _relaxationParam
 
- 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::VelocityGradientRelaxationTopOnly< LinkedCell, dim >

carries out velocity relaxation (similar to the SetMomentumMapping procedure).

In this particular case, however, the velocity is relaxed within a one cell-wide strip around the molecular domain. For this purpose, the velocity that shall be imposed in average in the cells that are within a three cell-wide strip need to be known and stored in the microscopicMomentum-buffers (2 cells overlap with the MD simulation, and 1 more (ghost) cell layer surrounding the MD domain). The procedure then only considers molecules that are located between the midpoints of the cells which are in the two cell-wide boundary strip. For all these molecules, a second-order interpolation of the average velocity at their respective position is carried out and the molecules are then relaxed towards this particular velocity.

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
Todo
Don't know what this does, just copied the comments from above

Member Function Documentation

◆ insertMomentum()

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

insertes the momentum to the cells according to the params and velocity gradient relaxation method

This method does not conserve the kinetic energy of the respective coupling cell. To conserve the energy as well, see the description of MomentumController on details how to do that.

Parameters
cellthe coupling cell to insert momentum to
idxthe coupling cell's index

Reimplemented from coupling::VelocityGradientRelaxation< LinkedCell, dim >.


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