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 
46  {
47 
48  public:
59  MMFF94AngleBendingInteraction(std::size_t term_atom1_idx, std::size_t ctr_atom_idx, std::size_t term_atom2_idx,
60  unsigned int angle_type_idx, bool linear, double force_const, double ref_angle):
61  termAtom1Idx(term_atom1_idx),
62  ctrAtomIdx(ctr_atom_idx), termAtom2Idx(term_atom2_idx),
63  angleTypeIdx(angle_type_idx), linear(linear), forceConst(force_const), refAngle(ref_angle) {}
64 
69  std::size_t getTerminalAtom1Index() const
70  {
71  return termAtom1Idx;
72  }
73 
78  std::size_t getCenterAtomIndex() const
79  {
80  return ctrAtomIdx;
81  }
82 
87  std::size_t getTerminalAtom2Index() const
88  {
89  return termAtom2Idx;
90  }
91 
96  std::size_t getAtom1Index() const
97  {
98  return termAtom1Idx;
99  }
100 
105  std::size_t getAtom2Index() const
106  {
107  return ctrAtomIdx;
108  }
109 
114  std::size_t getAtom3Index() const
115  {
116  return termAtom2Idx;
117  }
118 
123  unsigned int getAngleTypeIndex() const
124  {
125  return angleTypeIdx;
126  }
127 
132  bool isLinearAngle() const
133  {
134  return linear;
135  }
136 
141  double getForceConstant() const
142  {
143  return forceConst;
144  }
145 
150  double getReferenceAngle() const
151  {
152  return refAngle;
153  }
154 
159  void setReferenceAngle(double angle)
160  {
161  refAngle = angle;
162  }
163 
164  private:
165  std::size_t termAtom1Idx;
166  std::size_t ctrAtomIdx;
167  std::size_t termAtom2Idx;
168  unsigned int angleTypeIdx;
169  bool linear;
170  double forceConst;
171  double refAngle;
172  };
173  } // namespace ForceField
174 } // namespace CDPL
175 
176 #endif // CDPL_FORCEFIELD_MMFF94ANGLEBENDINGINTERACTION_HPP
Stores parameters for a single MMFF94 angle-bending interaction defined over an atom triplet.
Definition: MMFF94AngleBendingInteraction.hpp:46
std::size_t getAtom2Index() const
Returns the zero-based index of the central atom (alias for getCenterAtomIndex()).
Definition: MMFF94AngleBendingInteraction.hpp:105
std::size_t getAtom1Index() const
Returns the zero-based index of the first terminal atom (alias for getTerminalAtom1Index()).
Definition: MMFF94AngleBendingInteraction.hpp:96
std::size_t getCenterAtomIndex() const
Returns the zero-based index of the central (vertex) atom.
Definition: MMFF94AngleBendingInteraction.hpp:78
double getForceConstant() const
Returns the angle-bending force constant.
Definition: MMFF94AngleBendingInteraction.hpp:141
std::size_t getTerminalAtom2Index() const
Returns the zero-based index of the second terminal atom.
Definition: MMFF94AngleBendingInteraction.hpp:87
bool isLinearAngle() const
Tells whether the equilibrium angle is near linear (180°).
Definition: MMFF94AngleBendingInteraction.hpp:132
unsigned int getAngleTypeIndex() const
Returns the MMFF94 angle type index.
Definition: MMFF94AngleBendingInteraction.hpp:123
std::size_t getTerminalAtom1Index() const
Returns the zero-based index of the first terminal atom.
Definition: MMFF94AngleBendingInteraction.hpp:69
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:59
std::size_t getAtom3Index() const
Returns the zero-based index of the second terminal atom (alias for getTerminalAtom2Index()).
Definition: MMFF94AngleBendingInteraction.hpp:114
double getReferenceAngle() const
Returns the reference angle.
Definition: MMFF94AngleBendingInteraction.hpp:150
void setReferenceAngle(double angle)
Sets the reference angle.
Definition: MMFF94AngleBendingInteraction.hpp:159
The namespace of the Chemical Data Processing Library.