RDKit: ForceFields::AngleConstraintContribs Class Reference

| RDKit Open-source cheminformatics and machine learning.

Loading...
Searching...
No Matches
Public Member Functions | List of all members
ForceFields::AngleConstraintContribs Class Reference

A term to capture all flat bottom angle constraint potentials. More...

`#include <AngleConstraints.h>`

Inheritance diagram for ForceFields::AngleConstraintContribs:

## Public Member Functions
| AngleConstraintContribs ()=default
| AngleConstraintContribs (ForceField *owner)
| Constructor.
| ~AngleConstraintContribs () override=default
void | addContrib (unsigned int idx1, unsigned int idx2, unsigned int idx3, double minAngleDeg, double maxAngleDeg, double forceConst)
| Add a contribution to this contrib collection.
void | addContrib (unsigned int idx1, unsigned int idx2, unsigned int idx3, bool relative, double minAngleDeg, double maxAngleDeg, double forceConst)
| Add a contribution to this contrib 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
AngleConstraintContribs * | copy () 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
ForceField * | dp_forceField {nullptr}
| our owning ForceField

## Detailed Description

A term to capture all flat bottom angle constraint potentials.

Definition at line 39 of file AngleConstraints.h.

## Constructor & Destructor Documentation

## ◆ AngleConstraintContribs() [1/2]

ForceFields::AngleConstraintContribs::AngleConstraintContribs | ( |  | ) |
| default

Referenced by copy().

## ◆ AngleConstraintContribs() [2/2]

ForceFields::AngleConstraintContribs::AngleConstraintContribs | ( | ForceField * | owner | ) |

Constructor.

Parameters

  owner | pointer to the owning ForceField

References ForceFields::ForceFieldContrib::ForceField.

## ◆ ~AngleConstraintContribs()

ForceFields::AngleConstraintContribs::~AngleConstraintContribs | ( |  | ) |
| overridedefault

## Member Function Documentation

## ◆ addContrib() [1/2]

void ForceFields::AngleConstraintContribs::addContrib | ( | unsigned int | idx1,
|  | unsigned int | idx2,
|  | unsigned int | idx3,
|  | bool | relative,
|  | double | minAngleDeg,
|  | double | maxAngleDeg,
|  | double | forceConst )

Add a contribution to this contrib collection.

Parameters

  idx1 | index of atom1 in the ForceField's positions
  idx2 | index of atom2 in the ForceField's positions
  idx3 | index of atom3 in the ForceField's positions
  relative | whether to add the provided angle to the current angle
  minAngle | minimum angle
  maxAngle | maximum angle
  forceConst | force Constant

## ◆ addContrib() [2/2]

void ForceFields::AngleConstraintContribs::addContrib | ( | unsigned int | idx1,
|  | unsigned int | idx2,
|  | unsigned int | idx3,
|  | double | minAngleDeg,
|  | double | maxAngleDeg,
|  | double | forceConst )

Add a contribution to this contrib collection.

Parameters

  idx1 | index of atom1 in the ForceField's positions
  idx2 | index of atom2 in the ForceField's positions
  idx3 | index of atom3 in the ForceField's positions
  minAngle | minimum angle
  maxAngle | maximum angle
  forceConst | force Constant

## ◆ copy()

AngleConstraintContribs * ForceFields::AngleConstraintContribs::copy | ( |  | ) | const
| inlineoverridevirtual

Copy constructor.

Implements ForceFields::ForceFieldContrib.

Definition at line 90 of file AngleConstraints.h.

References AngleConstraintContribs().

## ◆ empty()

bool ForceFields::AngleConstraintContribs::empty | ( |  | ) | const
| inline

Return true if there are no contributions in this contrib.

Definition at line 95 of file AngleConstraints.h.

## ◆ getEnergy()

double ForceFields::AngleConstraintContribs::getEnergy | ( | double * | pos | ) | const
| overridevirtual

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

Parameters

  pos | positions of the atoms in the current state

Implements ForceFields::ForceFieldContrib.

## ◆ getGrad()

void ForceFields::AngleConstraintContribs::getGrad | ( | double * | pos,
|  | double * | grad ) const
| overridevirtual

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

Parameters

  pos | positions of the atoms in the current state
  grad | gradients to be adapted

Implements ForceFields::ForceFieldContrib.

## ◆ size()

unsigned int ForceFields::AngleConstraintContribs::size | ( |  | ) | const
| inline

Get number of contributions in this contrib.

Definition at line 98 of file AngleConstraints.h.

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

- AngleConstraints.h