RDKit
Open-source cheminformatics and machine learning.
Loading...
Searching...
No Matches
ForceFields::CrystalFF::TorsionAngleContribs Class Reference

#include <TorsionAngleContribs.h>

Inheritance diagram for ForceFields::CrystalFF::TorsionAngleContribs:
ForceFields::ForceFieldContrib

Public Member Functions

 TorsionAngleContribs ()=default
 
 TorsionAngleContribs (ForceField *owner)
 Constructor.
 
 ~TorsionAngleContribs ()=default
 
void addContrib (unsigned int idx1, unsigned int idx2, unsigned int idx3, unsigned int idx4, std::vector< double > forceConstants, std::vector< int > signs)
 Add contribution to this collection.
 
double getEnergy (double *pos) const override
 return the contribution of this contrib to the energy of a given state
 
void getGrad (double *pos, double *grad) const override
 
TorsionAngleContribscopy () const override
 Copy constructor.
 
bool empty () const
 Return true if there are no contributions in this contrib.
 
unsigned int size () const
 Get number of contributions in this contrib.
 
- Public Member Functions inherited from ForceFields::ForceFieldContrib
 ForceFieldContrib ()
 
 ForceFieldContrib (ForceFields::ForceField *owner)
 
virtual ~ForceFieldContrib ()
 

Additional Inherited Members

- Protected Attributes inherited from ForceFields::ForceFieldContrib
ForceFielddp_forceField {nullptr}
 our owning ForceField
 

Detailed Description

Definition at line 50 of file TorsionAngleContribs.h.

Constructor & Destructor Documentation

◆ TorsionAngleContribs() [1/2]

ForceFields::CrystalFF::TorsionAngleContribs::TorsionAngleContribs ( )
default

◆ TorsionAngleContribs() [2/2]

ForceFields::CrystalFF::TorsionAngleContribs::TorsionAngleContribs ( ForceField owner)

Constructor.

Parameters
ownerpointer to the owning ForceField

◆ ~TorsionAngleContribs()

ForceFields::CrystalFF::TorsionAngleContribs::~TorsionAngleContribs ( )
default

Member Function Documentation

◆ addContrib()

void ForceFields::CrystalFF::TorsionAngleContribs::addContrib ( unsigned int  idx1,
unsigned int  idx2,
unsigned int  idx3,
unsigned int  idx4,
std::vector< double >  forceConstants,
std::vector< int >  signs 
)

Add contribution to this collection.

Parameters
idx1index of atom1 in the ForceField's positions
idx2index of atom2 in the ForceField's positions
idx3index of atom3 in the ForceField's positions
idx4index of atom4 in the ForceField's positions
forceConstantsforce constants for the torsion potentials
signsphase for the torsion potentials (-1 or 1)

◆ copy()

TorsionAngleContribs * ForceFields::CrystalFF::TorsionAngleContribs::copy ( ) const
inlineoverridevirtual

Copy constructor.

Implements ForceFields::ForceFieldContrib.

Definition at line 87 of file TorsionAngleContribs.h.

◆ empty()

bool ForceFields::CrystalFF::TorsionAngleContribs::empty ( ) const
inline

Return true if there are no contributions in this contrib.

Definition at line 92 of file TorsionAngleContribs.h.

◆ getEnergy()

double ForceFields::CrystalFF::TorsionAngleContribs::getEnergy ( double *  pos) const
overridevirtual

return the contribution of this contrib to the energy of a given state

Parameters
pospositions of the atoms in the current state

Implements ForceFields::ForceFieldContrib.

◆ getGrad()

void ForceFields::CrystalFF::TorsionAngleContribs::getGrad ( double *  pos,
double *  grad 
) const
overridevirtual

calculate the contribution of this contrib to the gradient at a given state

Parameters
pospositions of the atoms in the current state
gradgradients to be adapted

Implements ForceFields::ForceFieldContrib.

◆ size()

unsigned int ForceFields::CrystalFF::TorsionAngleContribs::size ( ) const
inline

Get number of contributions in this contrib.

Definition at line 95 of file TorsionAngleContribs.h.


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