RDKit
Open-source cheminformatics and machine learning.
MMFF/AngleConstraint.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
#include <
RDGeneral/export.h
>
13
#ifndef __RD_MMFFANGLECONSTRAINT_H__
14
#define __RD_MMFFANGLECONSTRAINT_H__
15
#include <iostream>
16
#include <
ForceField/Contrib.h
>
17
18
namespace
ForceFields
{
19
namespace
MMFF {
20
21
//! An angle range constraint modelled after a AngleBendContrib
22
class
RDKIT_FORCEFIELD_EXPORT
RDKIT_FORCEFIELD_EXPORT
AngleConstraintContrib
23
:
public
ForceFieldContrib
{
24
public
:
25
AngleConstraintContrib
() : d_at1Idx(-1), d_at2Idx(-1), d_at3Idx(-1){};
26
//! Constructor
27
/*!
28
\param owner pointer to the owning ForceField
29
\param idx1 index of atom1 in the ForceField's positions
30
\param idx2 index of atom2 in the ForceField's positions
31
\param idx3 index of atom3 in the ForceField's positions
32
\param minAngle minimum angle
33
\param maxAngle maximum angle
34
\param forceConst force Constant
35
36
*/
37
AngleConstraintContrib
(
ForceField
*owner,
unsigned
int
idx1,
38
unsigned
int
idx2,
unsigned
int
idx3,
39
double
minAngleDeg,
double
maxAngleDeg,
40
double
forceConst);
41
AngleConstraintContrib
(
ForceField
*owner,
unsigned
int
idx1,
42
unsigned
int
idx2,
unsigned
int
idx3,
bool
relative,
43
double
minAngleDeg,
double
maxAngleDeg,
44
double
forceConst);
45
46
~AngleConstraintContrib
() {}
47
double
getEnergy(
double
*pos)
const
;
48
49
void
getGrad(
double
*pos,
double
*grad)
const
;
50
51
virtual
AngleConstraintContrib
*
copy
()
const
{
52
return
new
AngleConstraintContrib
(*
this
);
53
};
54
55
private
:
56
int
d_at1Idx, d_at2Idx, d_at3Idx;
//!< indices of atoms forming the angle
57
double
d_minAngleDeg, d_maxAngleDeg;
//!< rest amplitudes of the angle
58
double
d_forceConstant;
//!< force constant of the angle constraint
59
};
60
}
// namespace MMFF
61
}
// namespace ForceFields
62
#endif
ForceFields::MMFF::AngleConstraintContrib::~AngleConstraintContrib
~AngleConstraintContrib()
Definition:
MMFF/AngleConstraint.h:46
ForceFields::MMFF::AngleConstraintContrib
An angle range constraint modelled after a AngleBendContrib.
Definition:
MMFF/AngleConstraint.h:22
ForceFields::MMFF::AngleConstraintContrib::AngleConstraintContrib
AngleConstraintContrib()
Definition:
MMFF/AngleConstraint.h:25
ForceFields::ForceField
A class to store forcefields and handle minimization.
Definition:
ForceField.h:79
ForceFields::MMFF::AngleConstraintContrib::copy
virtual AngleConstraintContrib * copy() const
return a copy
Definition:
MMFF/AngleConstraint.h:51
ForceFields::ForceFieldContrib
abstract base class for contributions to ForceFields
Definition:
Contrib.h:18
RDKIT_FORCEFIELD_EXPORT
#define RDKIT_FORCEFIELD_EXPORT
Definition:
export.h:255
ForceFields
Definition:
TorsionAngleM6.h:24
Contrib.h
export.h
ForceField
MMFF
AngleConstraint.h
Generated on Fri Jun 12 2020 19:04:45 for RDKit by
1.8.17