OEForceField

Attention

This API is currently available in C++ and Python.

class OEForceField : public OEMolFunc1

The OEForceField is an abstract base class. This class defines an interface for the collection of force field components. The OEForceField extends the OEMolFunc1 class to allow this being a collection of multiple components. The collection of components into a force field needs to be done concomitant with one or more OEFFParams derived classes.

../../_images/OEForceField.png
The following methods are publicly inherited from OEFunc0:
The following methods are publicly inherited from OEFunc1:
The following methods are publicly inherited from OEMolFunc:
The OEForceField class defines the following public methods:
The following classes derive from this class:

GetTitle

std::string GetTitle() const

See SetTitle.

HasCoulomb

bool HasCoulomb() const

Returns if coulombic interactions are currently turned on.

HasInternalCharges

bool HasInternalCharges() const

Returns True if associated force field parameters has internal charges.

PrepMol

bool PrepMol(OEChem::OEMolBase &mol, bool sweep=true, bool warnOK=true) const

Defines the interface to prepare a molecule to be used for force field setup (OEMolFunc.Setup). This method internally calls for all contained OEFFParams instances in the OEForceField derived class to perform necessary preparation to enable using those parameters.

The second argument to the method specifies whether a call to OEMolBase.Sweep is allowed during the preparation. By default, sweeping a molecule is allowed by the method. Methods that override OEFFParams.PrepMol may alter the contents of the passed molecule.

Method returns true if preparation is successful, and false otherwise.

Set

bool Set(const OESystem::OEUnaryPredicate<OEChem::OEBondBase> &pred,
         unsigned int functype)
bool Set(const OESystem::OEUnaryPredicate<OEChem::OEAtomBase> &pred,
         unsigned int functype)
bool Set(const OESystem::OEBinaryPredicate<OEChem::OEAtomBase,
         OEChem::OEAtomBase> &pred, unsigned int functype)
bool Set(const OESystem::OEBinaryPredicate<OEChem::OEBondBase,
         OEChem::OEBondBase> &pred, unsigned int functype)

These methods assigns interaction-control predicates. The first argument is the predicate type to be passed to the interaction component. The second argument is a value or a set of binary OR’ed values taken from the OEFuncType namespace which specifies the intended target for the predicate assignment.

The set method passed on the interaction-control predicates to the appropriate force field components contained. Method returns false if predicate was not set to any of the components contained by the force field.

Set must be called before the Setup for it to be effective.

SetNonBondCutoff

bool SetNonBondCutoff(const double)

Sets the non-bonded interactions cutoff, in angstroms.

SetTitle

void SetTitle(const std::string&)

Title for the force field.