Loading...
Searching...
No Matches
DistGeom::DistViolationContribs Class Reference

`#include <DistViolationContribs.h>`

Inheritance diagram for DistGeom::DistViolationContribs:

## Public Member Functions

| DistViolationContribs ()=default
| DistViolationContribs (ForceFields::ForceField *owner)
| Constructor.
double | getEnergy (double *pos) const override
| returns our contribution to the energy of a position
void | getGrad (double *pos, double *grad) const override
| calculates our contribution to the gradients of a position
DistViolationContribs * | copy () const override
| return a copy
void | addContrib (unsigned int idx1, unsigned int idx2, double ub, double lb, double weight=1.0)
bool | empty () const
unsigned int | size () const
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 violations of the upper and lower bounds by distance between two points

Definition at line 33 of file DistViolationContribs.h.

## Constructor & Destructor Documentation

## DistViolationContribs() [1/2]

DistGeom::DistViolationContribs::DistViolationContribs | ( |  | ) |

default

## DistViolationContribs() [2/2]

DistGeom::DistViolationContribs::DistViolationContribs | ( | ForceFields::ForceField * | owner | ) |

Constructor.

Parameters

  owner | pointer to the owning ForceField

## Member Function Documentation

## addContrib()

void DistGeom::DistViolationContribs::addContrib | ( | unsigned int | idx1,
|  | unsigned int | idx2,
|  | double | ub,
|  | double | lb,
|  | double | weight = `1.0`
| ) |  |

inline

Definition at line 51 of file DistViolationContribs.h.

## copy()

DistViolationContribs * DistGeom::DistViolationContribs::copy | ( |  | ) | const

inline override virtual

return a copy

Implements ForceFields::ForceFieldContrib.

Definition at line 47 of file DistViolationContribs.h.

## empty()

bool DistGeom::DistViolationContribs::empty | ( |  | ) | const

inline

Definition at line 55 of file DistViolationContribs.h.

## getEnergy()

double DistGeom::DistViolationContribs::getEnergy | ( | double * | pos | ) | const

override virtual

returns our contribution to the energy of a position

Implements ForceFields::ForceFieldContrib.

## getGrad()

void DistGeom::DistViolationContribs::getGrad | ( | double * | pos,
|  | double * | grad
| ) |  | const

override virtual

calculates our contribution to the gradients of a position

Implements ForceFields::ForceFieldContrib.

## size()

unsigned int DistGeom::DistViolationContribs::size | ( |  | ) | const

inline

Definition at line 56 of file DistViolationContribs.h.

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

- DistViolationContribs.h