Chemical Data Processing Library C++ API - Version 1.4.0
MMFF94StretchBendInteraction.hpp
Go to the documentation of this file.
1 /*
2  * MMFF94StretchBendInteraction.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_MMFF94STRETCHBENDINTERACTION_HPP
30 #define CDPL_FORCEFIELD_MMFF94STRETCHBENDINTERACTION_HPP
31 
32 #include <cstddef>
33 
34 
35 namespace CDPL
36 {
37 
38  namespace ForceField
39  {
40 
46  {
47 
48  public:
61  MMFF94StretchBendInteraction(std::size_t term_atom1_idx, std::size_t ctr_atom_idx, std::size_t term_atom2_idx,
62  unsigned int sb_type_idx, double ref_angle, double ref_length1, double ref_length2,
63  double ijk_force_const, double kji_force_const):
64  termAtom1Idx(term_atom1_idx),
65  ctrAtomIdx(ctr_atom_idx), termAtom2Idx(term_atom2_idx),
66  sbTypeIdx(sb_type_idx), refAngle(ref_angle), refLength1(ref_length1), refLength2(ref_length2),
67  ijkForceConst(ijk_force_const), kjiForceConst(kji_force_const) {}
68 
73  std::size_t getTerminalAtom1Index() const
74  {
75  return termAtom1Idx;
76  }
77 
82  std::size_t getCenterAtomIndex() const
83  {
84  return ctrAtomIdx;
85  }
86 
91  std::size_t getTerminalAtom2Index() const
92  {
93  return termAtom2Idx;
94  }
95 
100  std::size_t getAtom1Index() const
101  {
102  return termAtom1Idx;
103  }
104 
109  std::size_t getAtom2Index() const
110  {
111  return ctrAtomIdx;
112  }
113 
118  std::size_t getAtom3Index() const
119  {
120  return termAtom2Idx;
121  }
122 
127  unsigned int getStretchBendTypeIndex() const
128  {
129  return sbTypeIdx;
130  }
131 
136  double getIJKForceConstant() const
137  {
138  return ijkForceConst;
139  }
140 
145  double getKJIForceConstant() const
146  {
147  return kjiForceConst;
148  }
149 
154  double getReferenceAngle() const
155  {
156  return refAngle;
157  }
158 
163  void setReferenceAngle(double angle)
164  {
165  refAngle = angle;
166  }
167 
172  double getReferenceLength1() const
173  {
174  return refLength1;
175  }
176 
182  {
183  refLength1 = length;
184  }
185 
190  double getReferenceLength2() const
191  {
192  return refLength2;
193  }
194 
200  {
201  refLength2 = length;
202  }
203 
204  private:
205  std::size_t termAtom1Idx;
206  std::size_t ctrAtomIdx;
207  std::size_t termAtom2Idx;
208  unsigned int sbTypeIdx;
209  double refAngle;
210  double refLength1;
211  double refLength2;
212  double ijkForceConst;
213  double kjiForceConst;
214  };
215  } // namespace ForceField
216 } // namespace CDPL
217 
218 #endif // CDPL_FORCEFIELD_MMFF94STRETCHBENDINTERACTION_HPP
Stores paramters for a single MMFF94 stretch-bend coupling interaction.
Definition: MMFF94StretchBendInteraction.hpp:46
std::size_t getTerminalAtom2Index() const
Returns the zero-based index of the second terminal atom k.
Definition: MMFF94StretchBendInteraction.hpp:91
MMFF94StretchBendInteraction(std::size_t term_atom1_idx, std::size_t ctr_atom_idx, std::size_t term_atom2_idx, unsigned int sb_type_idx, double ref_angle, double ref_length1, double ref_length2, double ijk_force_const, double kji_force_const)
Constructs the stretch-bend interaction parameter set.
Definition: MMFF94StretchBendInteraction.hpp:61
double getKJIForceConstant() const
Returns the force constant coupling j-k bond stretching with the central angle.
Definition: MMFF94StretchBendInteraction.hpp:145
std::size_t getCenterAtomIndex() const
Returns the zero-based index of the central atom j.
Definition: MMFF94StretchBendInteraction.hpp:82
double getReferenceLength1() const
Returns the reference length of bond i-j.
Definition: MMFF94StretchBendInteraction.hpp:172
std::size_t getTerminalAtom1Index() const
Returns the zero-based index of the first terminal atom i.
Definition: MMFF94StretchBendInteraction.hpp:73
double getReferenceAngle() const
Returns the reference angle.
Definition: MMFF94StretchBendInteraction.hpp:154
std::size_t getAtom1Index() const
Returns the zero-based index of the first terminal atom (alias for getTerminalAtom1Index()).
Definition: MMFF94StretchBendInteraction.hpp:100
std::size_t getAtom2Index() const
Returns the zero-based index of the central atom (alias for getCenterAtomIndex()).
Definition: MMFF94StretchBendInteraction.hpp:109
double getReferenceLength2() const
Returns the reference length of bond j-k.
Definition: MMFF94StretchBendInteraction.hpp:190
void setReferenceAngle(double angle)
Sets the reference angle.
Definition: MMFF94StretchBendInteraction.hpp:163
unsigned int getStretchBendTypeIndex() const
Returns the MMFF94 stretch-bend type index.
Definition: MMFF94StretchBendInteraction.hpp:127
void setReferenceLength1(double length)
Sets the reference length of bond i-j.
Definition: MMFF94StretchBendInteraction.hpp:181
std::size_t getAtom3Index() const
Returns the zero-based index of the second terminal atom (alias for getTerminalAtom2Index()).
Definition: MMFF94StretchBendInteraction.hpp:118
void setReferenceLength2(double length)
Sets the reference length of bond j-k.
Definition: MMFF94StretchBendInteraction.hpp:199
double getIJKForceConstant() const
Returns the force constant coupling i-j bond stretching with the central angle.
Definition: MMFF94StretchBendInteraction.hpp:136
VectorNorm2< E >::ResultType length(const VectorExpression< E > &e)
Returns the length (L2 norm) of the vector expression e (alias of norm2()).
Definition: VectorExpression.hpp:1129
The namespace of the Chemical Data Processing Library.