Chemical Data Processing Library C++ API - Version 1.4.0
MMFF94AngleBendingInteraction.hpp
Go to the documentation of this file.
1 /*
2  * MMFF94AngleBendingInteraction.hpp
3  *
4  * This file is part of the Chemical Data Processing Toolkit
5  *
6  * Copyright (C) 2003 Thomas Seidel <thomas.seidel@univie.ac.at>
7  *
8  * This library is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU Lesser General Public
10  * License as published by the Free Software Foundation; either
11  * version 2 of the License, or (at your option) any later version.
12  *
13  * This library is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16  * Lesser General Public License for more details.
17  *
18  * You should have received a copy of the GNU Lesser General Public License
19  * along with this library; see the file COPYING. If not, write to
20  * the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21  * Boston, MA 02111-1307, USA.
22  */
23 
29 #ifndef CDPL_FORCEFIELD_MMFF94ANGLEBENDINGINTERACTION_HPP
30 #define CDPL_FORCEFIELD_MMFF94ANGLEBENDINGINTERACTION_HPP
31 
32 #include <cstddef>
33 
34 
35 namespace CDPL
36 {
37 
38  namespace ForceField
39  {
40 
45  {
46 
47  public:
58  MMFF94AngleBendingInteraction(std::size_t term_atom1_idx, std::size_t ctr_atom_idx, std::size_t term_atom2_idx,
59  unsigned int angle_type_idx, bool linear, double force_const, double ref_angle):
60  termAtom1Idx(term_atom1_idx),
61  ctrAtomIdx(ctr_atom_idx), termAtom2Idx(term_atom2_idx),
62  angleTypeIdx(angle_type_idx), linear(linear), forceConst(force_const), refAngle(ref_angle) {}
63 
68  std::size_t getTerminalAtom1Index() const
69  {
70  return termAtom1Idx;
71  }
72 
77  std::size_t getCenterAtomIndex() const
78  {
79  return ctrAtomIdx;
80  }
81 
86  std::size_t getTerminalAtom2Index() const
87  {
88  return termAtom2Idx;
89  }
90 
95  std::size_t getAtom1Index() const
96  {
97  return termAtom1Idx;
98  }
99 
104  std::size_t getAtom2Index() const
105  {
106  return ctrAtomIdx;
107  }
108 
113  std::size_t getAtom3Index() const
114  {
115  return termAtom2Idx;
116  }
117 
122  unsigned int getAngleTypeIndex() const
123  {
124  return angleTypeIdx;
125  }
126 
131  bool isLinearAngle() const
132  {
133  return linear;
134  }
135 
140  double getForceConstant() const
141  {
142  return forceConst;
143  }
144 
149  double getReferenceAngle() const
150  {
151  return refAngle;
152  }
153 
158  void setReferenceAngle(double angle)
159  {
160  refAngle = angle;
161  }
162 
163  private:
164  std::size_t termAtom1Idx;
165  std::size_t ctrAtomIdx;
166  std::size_t termAtom2Idx;
167  unsigned int angleTypeIdx;
168  bool linear;
169  double forceConst;
170  double refAngle;
171  };
172  } // namespace ForceField
173 } // namespace CDPL
174 
175 #endif // CDPL_FORCEFIELD_MMFF94ANGLEBENDINGINTERACTION_HPP
Stores parameters for a single MMFF94 angle-bending interaction defined over an atom triplet.
Definition: MMFF94AngleBendingInteraction.hpp:45
std::size_t getAtom2Index() const
Returns the zero-based index of the central atom (alias for getCenterAtomIndex()).
Definition: MMFF94AngleBendingInteraction.hpp:104
std::size_t getAtom1Index() const
Returns the zero-based index of the first terminal atom (alias for getTerminalAtom1Index()).
Definition: MMFF94AngleBendingInteraction.hpp:95
std::size_t getCenterAtomIndex() const
Returns the zero-based index of the central (vertex) atom.
Definition: MMFF94AngleBendingInteraction.hpp:77
double getForceConstant() const
Returns the angle-bending force constant.
Definition: MMFF94AngleBendingInteraction.hpp:140
std::size_t getTerminalAtom2Index() const
Returns the zero-based index of the second terminal atom.
Definition: MMFF94AngleBendingInteraction.hpp:86
bool isLinearAngle() const
Tells whether the equilibrium angle is near linear (180°).
Definition: MMFF94AngleBendingInteraction.hpp:131
unsigned int getAngleTypeIndex() const
Returns the MMFF94 angle type index.
Definition: MMFF94AngleBendingInteraction.hpp:122
std::size_t getTerminalAtom1Index() const
Returns the zero-based index of the first terminal atom.
Definition: MMFF94AngleBendingInteraction.hpp:68
MMFF94AngleBendingInteraction(std::size_t term_atom1_idx, std::size_t ctr_atom_idx, std::size_t term_atom2_idx, unsigned int angle_type_idx, bool linear, double force_const, double ref_angle)
Constructs the angle-bending interaction parameter set.
Definition: MMFF94AngleBendingInteraction.hpp:58
std::size_t getAtom3Index() const
Returns the zero-based index of the second terminal atom (alias for getTerminalAtom2Index()).
Definition: MMFF94AngleBendingInteraction.hpp:113
double getReferenceAngle() const
Returns the reference angle.
Definition: MMFF94AngleBendingInteraction.hpp:149
void setReferenceAngle(double angle)
Sets the reference angle.
Definition: MMFF94AngleBendingInteraction.hpp:158
The namespace of the Chemical Data Processing Library.