Chemical Data Processing Library C++ API - Version 1.4.0
MMFF94AngleBendingInteractionParameterizer.hpp
Go to the documentation of this file.
1 /*
2  * MMFF94AngleBendingInteractionParameterizer.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_MMFF94ANGLEBENDINGINTERACTIONPARAMETERIZER_HPP
30 #define CDPL_FORCEFIELD_MMFF94ANGLEBENDINGINTERACTIONPARAMETERIZER_HPP
31 
32 #include <vector>
33 #include <cstddef>
34 #include <memory>
35 
46 
47 
48 namespace CDPL
49 {
50 
51  namespace Chem
52  {
53 
54  class MolecularGraph;
55  class Atom;
56  class Bond;
57  } // namespace Chem
58 
59  namespace ForceField
60  {
61 
71  {
72 
73  public:
75  typedef std::shared_ptr<MMFF94AngleBendingInteractionParameterizer> SharedPointer;
76 
81 
91  bool strict);
92 
98 
104 
110 
116 
122 
128 
134 
140 
146 
155  void parameterize(const Chem::MolecularGraph& molgraph, MMFF94AngleBendingInteractionList& ia_list, bool strict);
156 
157  private:
158  void getParameters(const Chem::MolecularGraph& molgraph, const Chem::Atom& term_atom1, const Chem::Atom& ctr_atom,
159  const Chem::Atom& term_atom2, const Chem::Bond& term_atom1_bnd, const Chem::Bond& term_atom2_bnd,
160  unsigned int& angle_type_idx, bool& linear, double& force_const, double& ref_angle, bool strict) const;
161 
162  void getParameters(const Chem::MolecularGraph& molgraph, const Chem::Atom& term_atom1, unsigned int term_atom1_type, const Chem::Atom& ctr_atom,
163  unsigned int ctr_atom_type, const Chem::Atom& term_atom2, unsigned int term_atom2_type, const Chem::Bond& term_atom1_bnd,
164  const Chem::Bond& term_atom2_bnd, unsigned int& angle_type_idx, bool& linear, double& force_const, double& ref_angle, bool strict) const;
165 
166  std::size_t getSizeOfContaining3Or4Ring(const Chem::MolecularGraph& molgraph, const Chem::Atom& term_atom1,
167  const Chem::Atom& ctr_atom, const Chem::Atom& term_atom2) const;
168 
192  unsigned int getAngleTypeIndex(const Chem::Bond& bond1, const Chem::Bond& bond2, std::size_t r_size) const;
193 
194  typedef std::vector<const Chem::Atom*> AtomList;
195  typedef std::vector<const Chem::Bond*> BondList;
196 
197  InteractionFilterFunction3 filterFunc;
198  MMFF94NumericAtomTypeFunction atomTypeFunc;
199  MMFF94BondTypeIndexFunction bondTypeIdxFunc;
204  AtomList nbrAtoms;
205  BondList nbrBonds;
206  };
207  } // namespace ForceField
208 } // namespace CDPL
209 
210 #endif // CDPL_FORCEFIELD_MMFF94ANGLEBENDINGINTERACTIONPARAMETERIZER_HPP
Definition of the preprocessor macro CDPL_FORCEFIELD_API.
#define CDPL_FORCEFIELD_API
Tells the compiler/linker which classes, functions and variables are part of the library API.
Type declaration of generic wrapper class types for storing user-defined interaction filtering predic...
Declaration of type CDPL::ForceField::MMFF94AngleBendingInteractionList.
Definition of class CDPL::ForceField::MMFF94AngleBendingParameterTable.
Definition of class CDPL::ForceField::MMFF94AtomTypePropertyTable.
Definition of class CDPL::ForceField::MMFF94BondStretchingInteractionParameterizer.
Definition of class CDPL::ForceField::MMFF94BondStretchingParameterTable.
Definition of class CDPL::ForceField::MMFF94BondStretchingRuleParameterTable.
Definition of class CDPL::ForceField::MMFF94PrimaryToParameterAtomTypeMap.
Type declaration of generic wrapper classes for storing user-defined functions for the retrieval of M...
Abstract base class representing a chemical atom and its bonded neighborhood.
Definition: Atom.hpp:57
Abstract base class representing a chemical bond between two Chem::Atom instances.
Definition: Bond.hpp:54
Abstract base class for representations of a chemical structure as a graph of bonded atoms.
Definition: MolecularGraph.hpp:57
Detects and parameterizes the MMFF94 angle-bending interactions of a molecular graph.
Definition: MMFF94AngleBendingInteractionParameterizer.hpp:71
MMFF94AngleBendingInteractionParameterizer(const Chem::MolecularGraph &molgraph, MMFF94AngleBendingInteractionList &ia_list, bool strict)
Constructs the parameterizer and processes the molecular graph molgraph.
void setAngleBendingParameterTable(const MMFF94AngleBendingParameterTable::SharedPointer &table)
Sets the primary table providing angle type-specific angle-bending parameters.
void setAtomTypePropertyTable(const MMFF94AtomTypePropertyTable::SharedPointer &table)
Sets the table providing MMFF94 numeric atom type property data (used by the empirical rule fallback)...
void setBondStretchingRuleParameterTable(const MMFF94BondStretchingRuleParameterTable::SharedPointer &table)
Sets the fallback bond-stretching rule parameter table (used in the empirical rule fallback).
void setBondStretchingParameterTable(const MMFF94BondStretchingParameterTable::SharedPointer &table)
Sets the primary bond-stretching parameter table (used to retrieve reference bond lengths in the empi...
MMFF94AngleBendingInteractionParameterizer()
Constructs an MMFF94AngleBendingInteractionParameterizer instance using the default MMFF94 parameter ...
void setAromaticRingSetFunction(const MMFF94RingSetFunction &func)
Sets the function used to obtain the set of MMFF94 aromatic rings of the input molecular graph.
std::shared_ptr< MMFF94AngleBendingInteractionParameterizer > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94AngleBendingInteractionPara...
Definition: MMFF94AngleBendingInteractionParameterizer.hpp:75
void parameterize(const Chem::MolecularGraph &molgraph, MMFF94AngleBendingInteractionList &ia_list, bool strict)
Perceives the MMFF94 angle-bending interactions for molgraph and outputs the corresponding parameter ...
void setBondTypeIndexFunction(const MMFF94BondTypeIndexFunction &func)
Sets the function used to look up the MMFF94 bond type index of a bond.
void setAtomTypeFunction(const MMFF94NumericAtomTypeFunction &func)
Sets the function used to look up the MMFF94 numeric atom type of an atom.
void setFilterFunction(const InteractionFilterFunction3 &func)
Sets the filter function used to skip atom triplets during parameterization.
void setParameterAtomTypeMap(const MMFF94PrimaryToParameterAtomTypeMap::SharedPointer &map)
Sets the map used to translate primary atom types into their corresponding parameter atom types.
std::shared_ptr< MMFF94AngleBendingParameterTable > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94AngleBendingParameterTable ...
Definition: MMFF94AngleBendingParameterTable.hpp:64
std::shared_ptr< MMFF94AtomTypePropertyTable > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94AtomTypePropertyTable insta...
Definition: MMFF94AtomTypePropertyTable.hpp:68
Detects and parameterizes the MMFF94 bond-stretching interactions of a molecular graph.
Definition: MMFF94BondStretchingInteractionParameterizer.hpp:64
std::shared_ptr< MMFF94BondStretchingParameterTable > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94BondStretchingParameterTabl...
Definition: MMFF94BondStretchingParameterTable.hpp:64
std::shared_ptr< MMFF94BondStretchingRuleParameterTable > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94BondStretchingRuleParameter...
Definition: MMFF94BondStretchingRuleParameterTable.hpp:65
std::shared_ptr< MMFF94PrimaryToParameterAtomTypeMap > SharedPointer
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94PrimaryToParameterAtomTypeM...
Definition: MMFF94PrimaryToParameterAtomTypeMap.hpp:64
std::function< unsigned int(const Chem::Atom &)> MMFF94NumericAtomTypeFunction
Generic wrapper class used to store a user-defined numeric MMFF94 atom type function.
Definition: MMFF94PropertyFunctions.hpp:56
std::function< const Chem::FragmentList::SharedPointer &(const Chem::MolecularGraph &)> MMFF94RingSetFunction
Generic wrapper class used to store a user-defined MMFF94 ring set function.
Definition: MMFF94PropertyFunctions.hpp:76
std::function< bool(const Chem::Atom &, const Chem::Atom &, const Chem::Atom &)> InteractionFilterFunction3
Generic wrapper for storing user-defined three-atom interaction filtering functions (see [FUNWRP]).
Definition: InteractionFilterFunctions.hpp:63
std::function< unsigned int(const Chem::Bond &)> MMFF94BondTypeIndexFunction
Generic wrapper class used to store a user-defined MMFF94 bond type index function.
Definition: MMFF94PropertyFunctions.hpp:71
The namespace of the Chemical Data Processing Library.