RDKit: OopBend.h Source File

| RDKit Open-source cheminformatics and machine learning.

- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

OopBend.h
Go to the documentation of this file.
1 //
2 // Copyright (C) 2013 Paolo Tosco
3 //
4 // Copyright (C) 2004-2006 Rational Discovery LLC
5 //
6 // @@ All Rights Reserved @@
7 // This file is part of the RDKit.
8 // The contents are covered by the terms of the BSD license
9 // which is included in the file license.txt, found at the root
10 // of the RDKit source tree.
11 //
12 #ifndef __RD_MMFFOopBend_H__
13 #define __RD_MMFFOopBend_H__
14
15 #include <ForceField/Contrib.h>
16 #include <Geometry/point.h>
17
18 namespace ForceFields {
19 namespace MMFF {
20 class MMFFOop;
21
22 //! the out-of-plane term for MMFF
23 class OopBendContrib : public ForceFieldContrib {
24 public:
25 OopBendContrib() : d_at1Idx(-1), d_at2Idx(-1), d_at3Idx(-1), d_at4Idx(-1){};
26 //! Constructor
27 /*!
28 The Wilson angle is between the vector formed by atom2-atom4
29 and the angle formed by atom1-atom2-atom3
30
31 \param owner pointer to the owning ForceField
32 \param idx1 index of atom1 in the ForceField's positions
33 \param idx2 index of atom2 in the ForceField's positions
34 \param idx3 index of atom3 in the ForceField's positions
35 \param idx4 index of atom4 in the ForceField's positions
36 */
37 OopBendContrib(ForceField *owner, unsigned int idx1, unsigned int idx2,
38 unsigned int idx3, unsigned int idx4,
39 const MMFFOop *mmffOopParams);
40 double getEnergy(double *pos) const;
41 void getGrad(double *pos, double *grad) const;
42 virtual OopBendContrib *copy() const { return new OopBendContrib(*this); };
43
44 private:
45 int d_at1Idx, d_at2Idx, d_at3Idx, d_at4Idx;
46 double d_koop;
47 };
48
49 namespace Utils {
50 //! calculates and returns the Wilson angle (in degrees)
51 double calcOopChi(const RDGeom::Point3D &iPoint, const RDGeom::Point3D &jPoint,
52 const RDGeom::Point3D &kPoint, const RDGeom::Point3D &lPoint);
53 //! returns the out-of-plane force constant koop
54 double calcOopBendForceConstant(const MMFFOop *mmffOopParams);
55 //! calculates and returns the out-of-plane MMFF energy
56 double calcOopBendEnergy(const double chi, const double koop);
57 }
58 }
59 }
60 #endif
ForceFields::MMFF::Utils::calcOopBendEnergy
double calcOopBendEnergy(const double chi, const double koop)
calculates and returns the out-of-plane MMFF energy
point.h
ForceFields::ForceFieldContrib
abstract base class for contributions to ForceFields
Definition: Contrib.h:17
ForceFields::MMFF::OopBendContrib::getGrad
void getGrad(double *pos, double *grad) const
calculates our contribution to the gradients of a position
ForceFields::MMFF::OopBendContrib::copy
virtual OopBendContrib * copy() const
return a copy
Definition: OopBend.h:42
Contrib.h
ForceFields
Definition: TorsionAngleM6.h:23
ForceFields::MMFF::MMFFOop
class to store MMFF parameters for out-of-plane bending
Definition: MMFF/Params.h:124
ForceFields::MMFF::Utils::calcOopChi
double calcOopChi(const RDGeom::Point3D &iPoint, const RDGeom::Point3D &jPoint, const RDGeom::Point3D &kPoint, const RDGeom::Point3D &lPoint)
calculates and returns the Wilson angle (in degrees)
ForceFields::MMFF::Utils::calcOopBendForceConstant
double calcOopBendForceConstant(const MMFFOop *mmffOopParams)
returns the out-of-plane force constant koop
RDGeom::Point3D
Definition: point.h:45
ForceFields::MMFF::OopBendContrib
the out-of-plane term for MMFF
Definition: OopBend.h:23
ForceFields::MMFF::OopBendContrib::OopBendContrib
OopBendContrib()
Definition: OopBend.h:25
ForceFields::ForceField
A class to store forcefields and handle minimization.
Definition: ForceField.h:57
ForceFields::MMFF::OopBendContrib::getEnergy
double getEnergy(double *pos) const
returns our contribution to the energy of a position