Chemical Data Processing Library C++ API - Version 1.4.0
MolProp/BondFunctions.hpp
Go to the documentation of this file.
1 /*
2  * BondFunctions.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_MOLPROP_BONDFUNCTIONS_HPP
30 #define CDPL_MOLPROP_BONDFUNCTIONS_HPP
31 
32 #include <cstddef>
33 
35 
36 
37 namespace CDPL
38 {
39 
40  namespace Chem
41  {
42 
43  class Bond;
44  class MolecularGraph;
45  } // namespace Chem
46 
47  namespace MolProp
48  {
49 
56 
62  CDPL_MOLPROP_API void setMHMOPiOrder(Chem::Bond& bond, double order);
63 
69 
76 
77 
85  CDPL_MOLPROP_API double calcPolarizability(const Chem::Bond& bond, const Chem::MolecularGraph& molgraph, double damping = 0.75);
86 
87 
94  CDPL_MOLPROP_API bool isInRing(const Chem::Bond& Bond, const Chem::MolecularGraph& molgraph);
95 
103  CDPL_MOLPROP_API bool isInRingOfSize(const Chem::Bond& bond, const Chem::MolecularGraph& molgraph, std::size_t size);
104 
112 
113 
121 
129 
139  CDPL_MOLPROP_API bool isRotatable(const Chem::Bond& bond, const Chem::MolecularGraph& molgraph, bool h_rotors = false, bool ring_bonds = false, bool amide_bonds = false);
140 
147 
156  CDPL_MOLPROP_API bool isAmideBond(const Chem::Bond& bond, const Chem::MolecularGraph& molgraph, bool c_only = false, bool db_o_only = false);
157  } // namespace MolProp
158 } // namespace CDPL
159 
160 #endif // CDPL_MOLPROP_BONDFUNCTIONS_HPP
Definition of the preprocessor macro CDPL_MOLPROP_API.
#define CDPL_MOLPROP_API
Tells the compiler/linker which classes, functions and variables are part of the library API.
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
CDPL_MOLPROP_API bool hasMHMOPiOrder(const Chem::Bond &atom)
Tells whether bond carries an explicit MolProp::BondProperty::MHMO_PI_ORDER property.
CDPL_MOLPROP_API bool isHydrogenRotor(const Chem::Bond &bond, const Chem::MolecularGraph &molgraph)
Tells whether bond is a rotatable bond whose rotation only moves hydrogen atoms.
CDPL_MOLPROP_API void setMHMOPiOrder(Chem::Bond &bond, double order)
Sets the value of the MolProp::BondProperty::MHMO_PI_ORDER property of bond.
CDPL_MOLPROP_API bool isAmideBond(const Chem::Bond &bond, const Chem::MolecularGraph &molgraph, bool c_only=false, bool db_o_only=false)
Tells whether bond is an amide bond in molgraph.
CDPL_MOLPROP_API double getMHMOPiOrder(const Chem::Bond &bond)
Returns the value of the MolProp::BondProperty::MHMO_PI_ORDER property of bond.
CDPL_MOLPROP_API bool isHydrogenBond(const Chem::Bond &bond)
Tells whether bond is a hydrogen bond (one of the bonded atoms is a hydrogen).
CDPL_MOLPROP_API bool isHeteroAtomHydrogenRotor(const Chem::Bond &bond, const Chem::MolecularGraph &molgraph)
Tells whether bond is a hydrogen-only rotor where the rotating end is a heteroatom-bound hydrogen.
CDPL_MOLPROP_API bool isRotatable(const Chem::Bond &bond, const Chem::MolecularGraph &molgraph, bool h_rotors=false, bool ring_bonds=false, bool amide_bonds=false)
Tells whether bond is rotatable.
CDPL_MOLPROP_API bool isInRingOfSize(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, std::size_t size)
Tells whether atom is a member of a ring of size size in molgraph.
CDPL_MOLPROP_API void clearMHMOPiOrder(Chem::Bond &bond)
Removes the MolProp::BondProperty::MHMO_PI_ORDER property from bond.
CDPL_MOLPROP_API bool isInRing(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
Tells whether atom is a member of any ring in molgraph.
CDPL_MOLPROP_API std::size_t getNumContainingSSSRRings(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
Returns the number of SSSR rings of molgraph that contain atom.
CDPL_MOLPROP_API double calcPolarizability(const Chem::Bond &bond, const Chem::MolecularGraph &molgraph, double damping=0.75)
Calculates the bond polarizability of bond within molgraph.
The namespace of the Chemical Data Processing Library.