OpenMD 3.1
Molecular Dynamics in the Open
Loading...
Searching...
No Matches
OpenMD::Bond Class Reference
+ Inheritance diagram for OpenMD::Bond:

Public Member Functions

 Bond (Atom *atom1, Atom *atom2, BondType *bt)
 
void calcForce (bool doParticlePot)
 
RealType getValue (int snap)
 Returns the value of this ShortRangeInteraction in specified snapshot.
 
RealType getPotential ()
 
AtomgetAtomA ()
 
AtomgetAtomB ()
 
BondTypegetBondType ()
 
virtual std::string getName ()
 Returns the name of this ShortRangeInteraction.
 
virtual void setName (const std::string &name)
 Sets the name of this bond for selections.
 
void accept (BaseVisitor *v)
 
virtual RealType getPrevValue ()
 Returns the previous value of this ShortRangeInteraction.
 
virtual RealType getValue ()
 Returns the current value of this ShortRangeInteraction.
 
- Public Member Functions inherited from OpenMD::ShortRangeInteraction
int getGlobalIndex ()
 Returns the global index of this ShortRangeInteraction.
 
void setGlobalIndex (int index)
 Sets the global index of this ShortRangeInteraction.
 
int getLocalIndex ()
 Returns the local index of this ShortRangeInteraction.
 
void setLocalIndex (int index)
 Sets the local index of this ShortRangeInteraction.
 
void setSnapshotManager (SnapshotManager *sman)
 Sets the Snapshot Manager of this ShortRangeInteraction.
 
virtual std::vector< Atom * > getAtoms ()
 
void addProperty (std::shared_ptr< GenericData > genData)
 Adds property into property map.
 
void removeProperty (const std::string &propName)
 Removes property from PropertyMap by name.
 
std::vector< std::string > getPropertyNames ()
 Returns all names of properties.
 
std::vector< std::shared_ptr< GenericData > > getProperties ()
 Returns all of the properties in PropertyMap.
 
std::shared_ptr< GenericDatagetPropertyByName (const std::string &propName)
 Returns property.
 

Additional Inherited Members

- Protected Member Functions inherited from OpenMD::ShortRangeInteraction
 ShortRangeInteraction (const ShortRangeInteraction &sri)
 
ShortRangeInteractionoperator= (const ShortRangeInteraction &sri)
 
- Protected Attributes inherited from OpenMD::ShortRangeInteraction
SnapshotManagersnapshotMan_
 
std::vector< Atom * > atoms_
 
int globalIndex_
 
int localIndex_
 

Detailed Description

Definition at line 61 of file Bond.hpp.

Constructor & Destructor Documentation

◆ Bond()

OpenMD::Bond::Bond ( Atom * atom1,
Atom * atom2,
BondType * bt )
inline

Definition at line 65 of file Bond.hpp.

◆ ~Bond()

virtual OpenMD::Bond::~Bond ( )
inlinevirtual

Definition at line 71 of file Bond.hpp.

Member Function Documentation

◆ accept()

void OpenMD::Bond::accept ( BaseVisitor * v)
inlinevirtual

The purpose of the Visitor Pattern is to encapsulate an operation that you want to perform on the elements of a data structure. In this way, you can change the operation being performed on a structure without the need of changing the classes of the elements that you are operating on. Using a Visitor pattern allows you to decouple the classes for the data structure and the algorithms used upon them

Parameters
vvisitor

Implements OpenMD::ShortRangeInteraction.

Definition at line 111 of file Bond.hpp.

◆ calcForce()

void OpenMD::Bond::calcForce ( bool doParticlePot)
inline

Definition at line 72 of file Bond.hpp.

◆ getAtomA()

Atom * OpenMD::Bond::getAtomA ( )
inline

Definition at line 101 of file Bond.hpp.

◆ getAtomB()

Atom * OpenMD::Bond::getAtomB ( )
inline

Definition at line 103 of file Bond.hpp.

◆ getBondType()

BondType * OpenMD::Bond::getBondType ( )
inline

Definition at line 105 of file Bond.hpp.

◆ getName()

virtual std::string OpenMD::Bond::getName ( )
inlinevirtual

Returns the name of this ShortRangeInteraction.

Implements OpenMD::ShortRangeInteraction.

Definition at line 107 of file Bond.hpp.

◆ getPotential()

RealType OpenMD::Bond::getPotential ( )
inline

Definition at line 99 of file Bond.hpp.

◆ getPrevValue()

RealType OpenMD::ShortRangeInteraction::getPrevValue ( )
virtual

Returns the previous value of this ShortRangeInteraction.

Returns
the value of this ShortRangeInteraction

Reimplemented from OpenMD::ShortRangeInteraction.

Definition at line 123 of file ShortRangeInteraction.cpp.

◆ getValue() [1/2]

RealType OpenMD::ShortRangeInteraction::getValue ( )
virtual

Returns the current value of this ShortRangeInteraction.

Returns
the current value of this ShortRangeInteraction

Reimplemented from OpenMD::ShortRangeInteraction.

Definition at line 129 of file ShortRangeInteraction.cpp.

◆ getValue() [2/2]

RealType OpenMD::Bond::getValue ( int snapshotNo)
inlinevirtual

Returns the value of this ShortRangeInteraction in specified snapshot.

Returns
the value of this ShortRangeInteraction
Parameters
snapshotNo

Implements OpenMD::ShortRangeInteraction.

Definition at line 93 of file Bond.hpp.

References OpenMD::Vector< Real, Dim >::length(), and OpenMD::Snapshot::wrapVector().

◆ setName()

virtual void OpenMD::Bond::setName ( const std::string & name)
inlinevirtual

Sets the name of this bond for selections.

Reimplemented from OpenMD::ShortRangeInteraction.

Definition at line 109 of file Bond.hpp.


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