OpenMD  2.5
Molecular Dynamics in the Open
OpenMD::Inversion Class Reference

#include "primitives/Inversion.hpp"

Inheritance diagram for OpenMD::Inversion:
OpenMD::ShortRangeInteraction

Public Member Functions

 Inversion (Atom *atom1, Atom *atom2, Atom *atom3, Atom *atom4, InversionType *it)
 
virtual ~Inversion ()
 
virtual void calcForce (RealType &angle, bool doParticlePot)
 
RealType getValue (int snapshotNo)
 
RealType getPotential ()
 
AtomgetAtomA ()
 
AtomgetAtomB ()
 
AtomgetAtomC ()
 
AtomgetAtomD ()
 
InversionTypegetInversionType ()
 
virtual std::string getName ()
 
virtual void setName (const std::string &name)
 
void accept (BaseVisitor *v)
 
- Public Member Functions inherited from OpenMD::ShortRangeInteraction
virtual ~ShortRangeInteraction ()
 
int getGlobalIndex ()
 
void setGlobalIndex (int index)
 
int getLocalIndex ()
 
void setLocalIndex (int index)
 
void setSnapshotManager (SnapshotManager *sman)
 
virtual RealType getPrevValue ()
 
virtual RealType getValue ()
 
virtual std::vector< Atom * > getAtoms ()
 
void addProperty (GenericData *genData)
 
void removeProperty (const std::string &propName)
 
void clearProperties ()
 
std::vector< std::string > getPropertyNames ()
 
std::vector< GenericData * > getProperties ()
 
GenericDatagetPropertyByName (const std::string &propName)
 

Protected Attributes

InversionTypeinversionType_
 
InversionKey inversionKey_
 
std::string name_
 
RealType potential_
 
- Protected Attributes inherited from OpenMD::ShortRangeInteraction
SnapshotManagersnapshotMan_
 
std::vector< Atom * > atoms_
 
int globalIndex_
 
int localIndex_
 

Additional Inherited Members

- Protected Member Functions inherited from OpenMD::ShortRangeInteraction
 ShortRangeInteraction ()
 
 ShortRangeInteraction (const ShortRangeInteraction &sri)
 
ShortRangeInteractionoperator= (const ShortRangeInteraction &sri)
 

Detailed Description

Definition at line 72 of file Inversion.hpp.

Constructor & Destructor Documentation

◆ Inversion()

OpenMD::Inversion::Inversion ( Atom atom1,
Atom atom2,
Atom atom3,
Atom atom4,
InversionType it 
)

◆ ~Inversion()

virtual OpenMD::Inversion::~Inversion ( )
inlinevirtual

Definition at line 79 of file Inversion.hpp.

References OpenMD::InversionData::angle.

Member Function Documentation

◆ accept()

void OpenMD::Inversion::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 142 of file Inversion.hpp.

References OpenMD::BaseVisitor::visit().

◆ calcForce()

◆ getAtomA()

◆ getAtomB()

◆ getAtomC()

◆ getAtomD()

◆ getInversionType()

InversionType* OpenMD::Inversion::getInversionType ( )
inline

Definition at line 135 of file Inversion.hpp.

◆ getName()

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

Returns the name of this ShortRangeInteraction

Implements OpenMD::ShortRangeInteraction.

Definition at line 138 of file Inversion.hpp.

Referenced by OpenMD::NameFinder::loadNames().

◆ getPotential()

RealType OpenMD::Inversion::getPotential ( )
inline

◆ getValue()

RealType OpenMD::Inversion::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 82 of file Inversion.hpp.

References OpenMD::cross(), OpenMD::dot(), and OpenMD::Vector< Real, Dim >::normalize().

◆ setName()

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

Sets the name of this inversion for selections

Reimplemented from OpenMD::ShortRangeInteraction.

Definition at line 140 of file Inversion.hpp.

Referenced by OpenMD::MoleculeCreator::createInversion().

Member Data Documentation

◆ inversionKey_

InversionKey OpenMD::Inversion::inversionKey_
protected

Definition at line 148 of file Inversion.hpp.

Referenced by calcForce(), and Inversion().

◆ inversionType_

InversionType* OpenMD::Inversion::inversionType_
protected

Definition at line 147 of file Inversion.hpp.

Referenced by calcForce(), and Inversion().

◆ name_

std::string OpenMD::Inversion::name_
protected

Definition at line 149 of file Inversion.hpp.

◆ potential_

RealType OpenMD::Inversion::potential_
protected

Definition at line 151 of file Inversion.hpp.

Referenced by calcForce().


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