ls1-MarDyn
ls1-MarDyn molecular dynamics code
Public Member Functions | List of all members
VirialProfile Class Reference
Inheritance diagram for VirialProfile:
ProfileBase

Public Member Functions

 VirialProfile (DensityProfile *densProf)
 
void record (Molecule &mol, unsigned long uID) final
 The recording step defines what kind of data needs to be recorded for a single molecule with a corresponding uID. More...
 
void collectAppend (DomainDecompBase *domainDecomp, unsigned long uID) final
 Append all necessary communication per bin to the DomainDecomposition. Append from e.g. _localProfile. More...
 
void collectRetrieve (DomainDecompBase *domainDecomp, unsigned long uID) final
 Get global values after AllReduceSum per bin. Write to e.g. _globalProfile. More...
 
void output (string prefix, long unsigned accumulatedDatasets) final
 
void reset (unsigned long uID) final
 Used to reset all array contents for a specific uID in order to start the next recording timeframe. More...
 
int comms () final
 1D profiles like a number density profile should return 1 here. 3D profiles that have 3 entries per bin that need to be communicated would need to return 3. Adjust as needed. Same number as commAppends in collectAppend. More...
 
- Public Member Functions inherited from ProfileBase
virtual void init (SamplingInformation &samplingInformation)
 Init function is given a pointer to the KartesianProfile object handling this profile. Same for all profiles. More...
 

Additional Inherited Members

- Protected Member Functions inherited from ProfileBase
void writeMatrix (ofstream &outfile)
 Matrix writing routine to avoid code duplication. More...
 
void writeKartMatrix (ofstream &outfile)
 
void writeSimpleMatrix (ofstream &outfile)
 STUB for simple Matrix output without headers. More...
 
void writeCylMatrix (ofstream &outfile)
 cylinder Matrix output More...
 
- Protected Attributes inherited from ProfileBase
string _profilePrefix
 
SamplingInformation _samplInfo
 
long _accumulatedDatasets = -1
 

Member Function Documentation

◆ collectAppend()

void VirialProfile::collectAppend ( DomainDecompBase domainDecomp,
unsigned long  uID 
)
inlinefinalvirtual

Append all necessary communication per bin to the DomainDecomposition. Append from e.g. _localProfile.

Parameters
domainDecompDomainDecomposition handling the communication.
uIDuID of molecule in sampling grid, needed to put data in right spot in the profile arrays.

Implements ProfileBase.

◆ collectRetrieve()

void VirialProfile::collectRetrieve ( DomainDecompBase domainDecomp,
unsigned long  uID 
)
inlinefinalvirtual

Get global values after AllReduceSum per bin. Write to e.g. _globalProfile.

Parameters
domainDecompDomainDecomposition handling the communication.
uIDuID of molecule in sampling grid, needed to put data in right spot in the profile arrays.

Implements ProfileBase.

◆ comms()

int VirialProfile::comms ( )
inlinefinalvirtual

1D profiles like a number density profile should return 1 here. 3D profiles that have 3 entries per bin that need to be communicated would need to return 3. Adjust as needed. Same number as commAppends in collectAppend.

Returns
Number of nedded communications per bin so the communicator can be setup correctly.

Implements ProfileBase.

◆ output()

void VirialProfile::output ( string  prefix,
long unsigned  accumulatedDatasets 
)
finalvirtual

Special 1D output

Parameters
prefix
accumulatedDatasets

Implements ProfileBase.

◆ record()

void VirialProfile::record ( Molecule mol,
unsigned long  uID 
)
inlinefinalvirtual

The recording step defines what kind of data needs to be recorded for a single molecule with a corresponding uID.

Parameters
molReference to Molecule, needed to extract info such as velocity or Virial.
uIDuID of molecule in sampling grid, needed to put data in right spot in the profile arrays.

Implements ProfileBase.

◆ reset()

void VirialProfile::reset ( unsigned long  uID)
inlinefinalvirtual

Used to reset all array contents for a specific uID in order to start the next recording timeframe.

Parameters
uIDuID of molecule in sampling grid, needed to put data in right spot in the profile arrays.

Implements ProfileBase.


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