Chemical Data Processing Library C++ API - Version 1.2.0
MolProp/AtomFunctions.hpp
Go to the documentation of this file.
1 /*
2  * AtomFunctions.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_ATOMFUNCTIONS_HPP
30 #define CDPL_MOLPROP_ATOMFUNCTIONS_HPP
31 
32 #include <cstddef>
33 #include <string>
34 
37 
38 
39 namespace CDPL
40 {
41 
42  namespace Chem
43  {
44 
45  class Atom;
46  class MolecularGraph;
47  } // namespace Chem
48 
49  namespace MolProp
50  {
51 
53 
55 
57 
59 
60 
62 
63  CDPL_MOLPROP_API void setPEOESigmaCharge(Chem::Atom& atom, double charge);
64 
66 
68 
69 
71 
73 
75 
77 
78 
80 
81  CDPL_MOLPROP_API void setMHMOPiCharge(Chem::Atom& atom, double charge);
82 
84 
86 
87 
88  CDPL_MOLPROP_API unsigned int getHBondDonorType(const Chem::Atom& atom);
89 
90  CDPL_MOLPROP_API void setHBondDonorType(Chem::Atom& atom, unsigned int type);
91 
93 
95 
96 
98 
99  CDPL_MOLPROP_API void setHBondAcceptorType(Chem::Atom& atom, unsigned int type);
100 
102 
104 
105 
106  CDPL_MOLPROP_API bool isInRing(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
107 
108  CDPL_MOLPROP_API bool isInRingOfSize(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, std::size_t size);
109 
111 
112 
114 
115  CDPL_MOLPROP_API std::size_t getIUPACGroup(const Chem::Atom& atom);
116 
117  CDPL_MOLPROP_API std::size_t getPeriod(const Chem::Atom& atom);
118 
120 
121  CDPL_MOLPROP_API double getCovalentRadius(const Chem::Atom& atom, std::size_t order);
122 
124 
125  CDPL_MOLPROP_API const std::string& getElementName(const Chem::Atom& atom);
126 
128 
130 
132 
134 
136 
138 
140 
142 
144 
145 
147  unsigned int flags = Chem::AtomPropertyFlag::DEFAULT);
148 
150 
151  CDPL_MOLPROP_API bool isUnsaturated(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
152 
154 
155  CDPL_MOLPROP_API bool isHBondDonor(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
156 
160  CDPL_MOLPROP_API bool isCarbonylLike(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, bool c_only = false, bool db_o_only = false);
161 
165  CDPL_MOLPROP_API bool isAmideCenter(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, bool c_only = false, bool db_o_only = false);
166 
167  CDPL_MOLPROP_API bool isAmideNitrogen(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, bool c_only = false, bool db_o_only = false);
168 
170 
172 
176  CDPL_MOLPROP_API bool isBridgehead(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, bool bridged_only);
177 
181  CDPL_MOLPROP_API bool isSpiroCenter(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
182 
183 
185  unsigned int flags = Chem::AtomPropertyFlag::DEFAULT);
186 
187  CDPL_MOLPROP_API std::size_t getExplicitAtomCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, unsigned int type, bool strict = true);
188 
189  CDPL_MOLPROP_API std::size_t getAtomCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, unsigned int type, bool strict = true);
190 
192 
193  CDPL_MOLPROP_API std::size_t getChainAtomCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
194 
195  CDPL_MOLPROP_API std::size_t getRingAtomCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
196 
197  CDPL_MOLPROP_API std::size_t getAromaticAtomCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
198 
199  CDPL_MOLPROP_API std::size_t getHeavyAtomCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
200 
201 
202  CDPL_MOLPROP_API std::size_t getExplicitBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
203 
204  CDPL_MOLPROP_API std::size_t getExplicitBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, std::size_t order);
205 
206  CDPL_MOLPROP_API std::size_t getExplicitBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, std::size_t order, unsigned int type, bool strict = true);
207 
208  CDPL_MOLPROP_API std::size_t getBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
209 
210  CDPL_MOLPROP_API std::size_t getBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, std::size_t order);
211 
212  CDPL_MOLPROP_API std::size_t getBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, std::size_t order, unsigned int type, bool strict = true);
213 
215 
216  CDPL_MOLPROP_API std::size_t getChainBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
217 
218  CDPL_MOLPROP_API std::size_t getRingBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
219 
220  CDPL_MOLPROP_API std::size_t getAromaticBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
221 
222  CDPL_MOLPROP_API std::size_t getHeavyBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
223 
224  CDPL_MOLPROP_API std::size_t getRotatableBondCount(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, bool h_rotors = false, bool ring_bonds = false, bool amide_bonds = false);
225 
226 
227  CDPL_MOLPROP_API std::size_t calcExplicitValence(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
228 
229  CDPL_MOLPROP_API std::size_t calcValence(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
230 
231 
233 
235 
236 
237  CDPL_MOLPROP_API std::size_t calcStericNumber(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph);
238 
239  CDPL_MOLPROP_API unsigned int getVSEPRCoordinationGeometry(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, std::size_t steric_num);
240 
242 
243 
245 
246  CDPL_MOLPROP_API double calcEffectivePolarizability(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, double damping = 0.75);
247 
249 
251 
253 
254  CDPL_MOLPROP_API double calcInductiveEffect(const Chem::Atom& atom, const Chem::MolecularGraph& molgraph, std::size_t num_bonds = 10);
255  } // namespace MolProp
256 } // namespace CDPL
257 
258 #endif // CDPL_MOLPROP_ATOMFUNCTIONS_HPP
Definition of constants in namespace CDPL::Chem::AtomPropertyFlag.
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.
Atom.
Definition: Atom.hpp:52
MolecularGraph.
Definition: MolecularGraph.hpp:52
constexpr unsigned int DEFAULT
Represents the default set of atom properties.
Definition: Chem/AtomPropertyFlag.hpp:53
CDPL_MOLPROP_API std::size_t getElementValenceElectronCount(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t getAromaticAtomCount(const Chem::AtomContainer &cntnr)
CDPL_MOLPROP_API std::size_t getExplicitChainBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API bool isHeavy(const Chem::Atom &atom)
CDPL_MOLPROP_API void setPEOESigmaCharge(Chem::Atom &atom, double charge)
CDPL_MOLPROP_API std::size_t getHeavyBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API void clearHBondAcceptorType(Chem::Atom &atom)
CDPL_MOLPROP_API double calcInductiveEffect(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, std::size_t num_bonds=10)
CDPL_MOLPROP_API void setHBondAcceptorType(Chem::Atom &atom, unsigned int type)
CDPL_MOLPROP_API double calcPiElectronegativity(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API void clearMHMOPiCharge(Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t calcStericNumber(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t calcExplicitValence(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API bool isSemiMetal(const Chem::Atom &atom)
CDPL_MOLPROP_API void setHydrophobicity(Chem::Atom &atom, double hyd)
CDPL_MOLPROP_API std::size_t getChainAtomCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API double getAllredRochowElectronegativity(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t getHeavyAtomCount(const Chem::AtomContainer &cntnr)
CDPL_MOLPROP_API std::size_t getExplicitChainAtomCount(const Chem::AtomContainer &cntnr)
CDPL_MOLPROP_API bool isMainGroupElement(const Chem::Atom &atom)
CDPL_MOLPROP_API void setPEOESigmaElectronegativity(Chem::Atom &atom, double e_neg)
CDPL_MOLPROP_API bool isOrdinaryHydrogen(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, unsigned int flags=Chem::AtomPropertyFlag::DEFAULT)
CDPL_MOLPROP_API double getCovalentRadius(const Chem::Atom &atom, std::size_t order)
CDPL_MOLPROP_API bool hasHBondAcceptorType(const Chem::Atom &atom)
CDPL_MOLPROP_API void clearHBondDonorType(Chem::Atom &atom)
CDPL_MOLPROP_API bool hasMHMOPiCharge(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t getChainBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API bool isNobleGas(const Chem::Atom &atom)
CDPL_MOLPROP_API bool hasPEOESigmaElectronegativity(const Chem::Atom &atom)
CDPL_MOLPROP_API void clearPEOESigmaElectronegativity(Chem::Atom &atom)
CDPL_MOLPROP_API bool isUnsaturated(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API unsigned int getVSEPRCoordinationGeometry(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, std::size_t steric_num)
CDPL_MOLPROP_API bool isChemicalElement(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t calcValenceElectronCount(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t getOrdinaryHydrogenCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, unsigned int flags=Chem::AtomPropertyFlag::DEFAULT)
CDPL_MOLPROP_API bool isCarbonylLike(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, bool c_only=false, bool db_o_only=false)
CDPL_MOLPROP_API std::size_t getExplicitBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t calcFreeValenceElectronCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API bool isBridgehead(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, bool bridged_only)
CDPL_MOLPROP_API double calcEffectivePolarizability(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, double damping=0.75)
CDPL_MOLPROP_API void setHBondDonorType(Chem::Atom &atom, unsigned int type)
CDPL_MOLPROP_API bool hasHydrophobicity(const Chem::Atom &atom)
CDPL_MOLPROP_API double calcTotalPartialCharge(const Chem::Atom &atom)
CDPL_MOLPROP_API bool isAmideCenter(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, bool c_only=false, bool db_o_only=false)
CDPL_MOLPROP_API bool isHBondAcceptor(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getAromaticBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getIUPACGroup(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t calcValence(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getPeriod(const Chem::Atom &atom)
CDPL_MOLPROP_API double getPEOESigmaCharge(const Chem::Atom &atom)
CDPL_MOLPROP_API double getVdWRadius(const Chem::Atom &atom)
CDPL_MOLPROP_API bool isPlanarNitrogen(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API bool isInvertibleNitrogen(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getAtomCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, unsigned int type, bool strict=true)
CDPL_MOLPROP_API void clearHydrophobicity(Chem::Atom &atom)
CDPL_MOLPROP_API unsigned int getHBondAcceptorType(const Chem::Atom &atom)
CDPL_MOLPROP_API void setMHMOPiCharge(Chem::Atom &atom, double charge)
CDPL_MOLPROP_API bool isInRingOfSize(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, std::size_t size)
CDPL_MOLPROP_API bool isMetal(const Chem::Atom &atom)
CDPL_MOLPROP_API double calcLonePairElectronegativity(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API double getHydrophobicity(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t getExplicitAtomCount(const Chem::AtomContainer &cntnr)
CDPL_MOLPROP_API bool hasPEOESigmaCharge(const Chem::Atom &atom)
CDPL_MOLPROP_API std::size_t getRotatableBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, bool h_rotors=false, bool ring_bonds=false, bool amide_bonds=false)
CDPL_MOLPROP_API unsigned int getHBondDonorType(const Chem::Atom &atom)
CDPL_MOLPROP_API bool isNonMetal(const Chem::Atom &atom)
CDPL_MOLPROP_API bool isHBondDonor(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getRingAtomCount(const Chem::AtomContainer &cntnr)
CDPL_MOLPROP_API void clearPEOESigmaCharge(Chem::Atom &atom)
CDPL_MOLPROP_API bool isSpiroCenter(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API bool isAmideNitrogen(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph, bool c_only=false, bool db_o_only=false)
CDPL_MOLPROP_API bool isInRing(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getNumContainingSSSRRings(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API double getAtomicWeight(const Chem::Atom &atom)
CDPL_MOLPROP_API double getMHMOPiCharge(const Chem::Atom &atom)
CDPL_MOLPROP_API bool isHalogen(const Chem::Atom &atom)
CDPL_MOLPROP_API bool hasHBondDonorType(const Chem::Atom &atom)
CDPL_MOLPROP_API double getPEOESigmaElectronegativity(const Chem::Atom &atom)
CDPL_MOLPROP_API bool isTransitionMetal(const Chem::Atom &atom)
CDPL_MOLPROP_API const std::string & getElementName(const Chem::Atom &atom)
CDPL_MOLPROP_API double getHybridPolarizability(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
CDPL_MOLPROP_API std::size_t getRingBondCount(const Chem::Atom &atom, const Chem::MolecularGraph &molgraph)
The namespace of the Chemical Data Processing Library.