Avogadro::Calc::LennardJones#

class LennardJones : public EnergyCalculator#

Public Functions

LennardJones()#
~LennardJones() override = default#
inline virtual LennardJones *newInstance() const override#

Create a new instance of the model. Ownership passes to the caller.

inline virtual std::string identifier() const override#
Returns:

a unique identifier for this calculator.

inline virtual std::string name() const override#
Returns:

A short translatable name for this method (e.g., MMFF94, UFF, etc.)

inline virtual std::string description() const override#
Returns:

a description of the method

inline virtual bool acceptsIons() const override#

Indicate if your method can handle ions Many methods only treat neutral systems, either a neutral molecule or a neutral unit cell.

Returns:

true if ions are supported

inline virtual bool acceptsRadicals() const override#

Indicate if your method can handle radicals Most methods only treat closed-shell molecules.

Returns:

true if radicals are supported

inline virtual bool acceptsUnitCell() const override#

Indicate if your method can handle unit cells.

Returns:

true if unit cells are supported

inline virtual Core::Molecule::ElementMask elements() const override#

Indicate if your method only treats a subset of elements.

Returns:

an element mask corresponding to the defined subset

Real value(const Eigen::VectorXd &x) override#
void gradient(const Eigen::VectorXd &x, Eigen::VectorXd &grad) override#
virtual void setMolecule(Core::Molecule *mol) override#

Called when the current molecule changes.

Protected Attributes

Core::Molecule *m_molecule#
Core::UnitCell *m_cell#
Eigen::MatrixXd m_radii#
bool m_vdw#
Real m_depth#
int m_exponent#
Core::Molecule::ElementMask m_elements#