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

#include <HarmonicBondType.hpp>

Inheritance diagram for OpenMD::HarmonicBondType:

Public Member Functions

 HarmonicBondType (RealType myR0, RealType myK)
void setForceConstant (RealType myK)
RealType getForceConstant ()
virtual void calcForce (RealType r, RealType &V, RealType &dVdr)
- Public Member Functions inherited from OpenMD::BondType
 BondType (RealType myR0)
virtual ~BondType ()
RealType getEquilibriumBondLength ()
void setEquilibriumBondLength (RealType myR0)

Private Attributes

RealType k

Additional Inherited Members

- Protected Attributes inherited from OpenMD::BondType
RealType r0

Detailed Description

HarmonicBondType is the basic OpenMD bond type.

\[ V = 0.5* k(r -r_0)^2 \]

Definition at line 55 of file HarmonicBondType.hpp.

Constructor & Destructor Documentation

◆ HarmonicBondType()

OpenMD::HarmonicBondType::HarmonicBondType ( RealType  myR0,
RealType  myK 

Definition at line 59 of file HarmonicBondType.hpp.

References k.

Member Function Documentation

◆ calcForce()

virtual void OpenMD::HarmonicBondType::calcForce ( RealType  r,
RealType &  V,
RealType &  dVdr 

Implements OpenMD::BondType.

Definition at line 67 of file HarmonicBondType.hpp.

References k, and OpenMD::BondType::r0.

◆ getForceConstant()

RealType OpenMD::HarmonicBondType::getForceConstant ( )

Definition at line 65 of file HarmonicBondType.hpp.

References k.

Referenced by OpenMD::UreyBradleyBendType::getUBForceConstant().

◆ setForceConstant()

void OpenMD::HarmonicBondType::setForceConstant ( RealType  myK)

Definition at line 63 of file HarmonicBondType.hpp.

References k.

Referenced by OpenMD::UreyBradleyBendType::setUBForceConstant().

Member Data Documentation

◆ k

RealType OpenMD::HarmonicBondType::k

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