rdkit-headers 2022.3.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (320) hide show
  1. rdkit_headers/__init__.py +13 -0
  2. rdkit_headers/include/rdkit/CIPLabeler/CIPLabeler.h +59 -0
  3. rdkit_headers/include/rdkit/CIPLabeler/TooManyNodesException.h +28 -0
  4. rdkit_headers/include/rdkit/Catalogs/Catalog.h +461 -0
  5. rdkit_headers/include/rdkit/Catalogs/CatalogEntry.h +48 -0
  6. rdkit_headers/include/rdkit/Catalogs/CatalogParams.h +42 -0
  7. rdkit_headers/include/rdkit/ChemicalFeatures/ChemicalFeature.h +38 -0
  8. rdkit_headers/include/rdkit/ChemicalFeatures/FreeChemicalFeature.h +97 -0
  9. rdkit_headers/include/rdkit/DataManip/MetricMatrixCalc/MetricFuncs.h +54 -0
  10. rdkit_headers/include/rdkit/DataManip/MetricMatrixCalc/MetricMatrixCalc.h +106 -0
  11. rdkit_headers/include/rdkit/DataStructs/BitOps.h +337 -0
  12. rdkit_headers/include/rdkit/DataStructs/BitVect.h +68 -0
  13. rdkit_headers/include/rdkit/DataStructs/BitVectUtils.h +35 -0
  14. rdkit_headers/include/rdkit/DataStructs/BitVects.h +25 -0
  15. rdkit_headers/include/rdkit/DataStructs/DatastructsException.h +31 -0
  16. rdkit_headers/include/rdkit/DataStructs/DatastructsStreamOps.h +72 -0
  17. rdkit_headers/include/rdkit/DataStructs/DiscreteDistMat.h +30 -0
  18. rdkit_headers/include/rdkit/DataStructs/DiscreteValueVect.h +146 -0
  19. rdkit_headers/include/rdkit/DataStructs/ExplicitBitVect.h +96 -0
  20. rdkit_headers/include/rdkit/DataStructs/FPBReader.h +281 -0
  21. rdkit_headers/include/rdkit/DataStructs/MultiFPBReader.h +213 -0
  22. rdkit_headers/include/rdkit/DataStructs/SparseBitVect.h +101 -0
  23. rdkit_headers/include/rdkit/DataStructs/SparseIntVect.h +571 -0
  24. rdkit_headers/include/rdkit/DataStructs/base64.h +41 -0
  25. rdkit_headers/include/rdkit/DistGeom/BoundsMatrix.h +121 -0
  26. rdkit_headers/include/rdkit/DistGeom/ChiralSet.h +58 -0
  27. rdkit_headers/include/rdkit/DistGeom/ChiralViolationContrib.h +96 -0
  28. rdkit_headers/include/rdkit/DistGeom/DistGeomUtils.h +195 -0
  29. rdkit_headers/include/rdkit/DistGeom/DistViolationContrib.h +54 -0
  30. rdkit_headers/include/rdkit/DistGeom/FourthDimContrib.h +65 -0
  31. rdkit_headers/include/rdkit/DistGeom/TriangleSmooth.h +36 -0
  32. rdkit_headers/include/rdkit/Features/Feature.h +96 -0
  33. rdkit_headers/include/rdkit/ForceField/Contrib.h +40 -0
  34. rdkit_headers/include/rdkit/ForceField/ForceField.h +253 -0
  35. rdkit_headers/include/rdkit/ForceField/MMFF/AngleBend.h +78 -0
  36. rdkit_headers/include/rdkit/ForceField/MMFF/AngleConstraint.h +64 -0
  37. rdkit_headers/include/rdkit/ForceField/MMFF/BondStretch.h +67 -0
  38. rdkit_headers/include/rdkit/ForceField/MMFF/Contribs.h +26 -0
  39. rdkit_headers/include/rdkit/ForceField/MMFF/DistanceConstraint.h +61 -0
  40. rdkit_headers/include/rdkit/ForceField/MMFF/Nonbonded.h +105 -0
  41. rdkit_headers/include/rdkit/ForceField/MMFF/OopBend.h +65 -0
  42. rdkit_headers/include/rdkit/ForceField/MMFF/Params.h +1134 -0
  43. rdkit_headers/include/rdkit/ForceField/MMFF/PositionConstraint.h +55 -0
  44. rdkit_headers/include/rdkit/ForceField/MMFF/StretchBend.h +70 -0
  45. rdkit_headers/include/rdkit/ForceField/MMFF/TorsionAngle.h +79 -0
  46. rdkit_headers/include/rdkit/ForceField/MMFF/TorsionConstraint.h +70 -0
  47. rdkit_headers/include/rdkit/ForceField/UFF/AngleBend.h +92 -0
  48. rdkit_headers/include/rdkit/ForceField/UFF/AngleConstraint.h +64 -0
  49. rdkit_headers/include/rdkit/ForceField/UFF/BondStretch.h +83 -0
  50. rdkit_headers/include/rdkit/ForceField/UFF/Contribs.h +23 -0
  51. rdkit_headers/include/rdkit/ForceField/UFF/DistanceConstraint.h +62 -0
  52. rdkit_headers/include/rdkit/ForceField/UFF/Inversion.h +81 -0
  53. rdkit_headers/include/rdkit/ForceField/UFF/Nonbonded.h +87 -0
  54. rdkit_headers/include/rdkit/ForceField/UFF/Params.h +153 -0
  55. rdkit_headers/include/rdkit/ForceField/UFF/PositionConstraint.h +55 -0
  56. rdkit_headers/include/rdkit/ForceField/UFF/TorsionAngle.h +115 -0
  57. rdkit_headers/include/rdkit/ForceField/UFF/TorsionConstraint.h +70 -0
  58. rdkit_headers/include/rdkit/Geometry/Grid3D.h +55 -0
  59. rdkit_headers/include/rdkit/Geometry/GridUtils.h +64 -0
  60. rdkit_headers/include/rdkit/Geometry/Transform.h +19 -0
  61. rdkit_headers/include/rdkit/Geometry/Transform2D.h +85 -0
  62. rdkit_headers/include/rdkit/Geometry/Transform3D.h +101 -0
  63. rdkit_headers/include/rdkit/Geometry/UniformGrid3D.h +217 -0
  64. rdkit_headers/include/rdkit/Geometry/Utils.h +97 -0
  65. rdkit_headers/include/rdkit/Geometry/point.h +585 -0
  66. rdkit_headers/include/rdkit/GraphMol/Abbreviations/Abbreviations.h +132 -0
  67. rdkit_headers/include/rdkit/GraphMol/Atom.h +449 -0
  68. rdkit_headers/include/rdkit/GraphMol/AtomIterators.h +212 -0
  69. rdkit_headers/include/rdkit/GraphMol/Bond.h +393 -0
  70. rdkit_headers/include/rdkit/GraphMol/BondIterators.h +75 -0
  71. rdkit_headers/include/rdkit/GraphMol/Canon.h +130 -0
  72. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/CartesianProduct.h +147 -0
  73. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/Enumerate.h +187 -0
  74. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/EnumerateBase.h +200 -0
  75. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/EnumerateTypes.h +59 -0
  76. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/EnumerationPickler.h +60 -0
  77. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/EnumerationStrategyBase.h +227 -0
  78. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/RandomSample.h +163 -0
  79. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Enumerate/RandomSampleAllBBs.h +184 -0
  80. rdkit_headers/include/rdkit/GraphMol/ChemReactions/PreprocessRxn.h +64 -0
  81. rdkit_headers/include/rdkit/GraphMol/ChemReactions/Reaction.h +491 -0
  82. rdkit_headers/include/rdkit/GraphMol/ChemReactions/ReactionFingerprints.h +147 -0
  83. rdkit_headers/include/rdkit/GraphMol/ChemReactions/ReactionParser.h +274 -0
  84. rdkit_headers/include/rdkit/GraphMol/ChemReactions/ReactionPickler.h +119 -0
  85. rdkit_headers/include/rdkit/GraphMol/ChemReactions/ReactionRunner.h +116 -0
  86. rdkit_headers/include/rdkit/GraphMol/ChemReactions/ReactionUtils.h +74 -0
  87. rdkit_headers/include/rdkit/GraphMol/ChemReactions/SanitizeRxn.h +169 -0
  88. rdkit_headers/include/rdkit/GraphMol/ChemTransforms/ChemTransforms.h +270 -0
  89. rdkit_headers/include/rdkit/GraphMol/ChemTransforms/MolFragmenter.h +120 -0
  90. rdkit_headers/include/rdkit/GraphMol/Chirality.h +137 -0
  91. rdkit_headers/include/rdkit/GraphMol/Conformer.h +183 -0
  92. rdkit_headers/include/rdkit/GraphMol/CoordGen.h +195 -0
  93. rdkit_headers/include/rdkit/GraphMol/Depictor/DepictUtils.h +366 -0
  94. rdkit_headers/include/rdkit/GraphMol/Depictor/EmbeddedFrag.h +544 -0
  95. rdkit_headers/include/rdkit/GraphMol/Depictor/RDDepictor.h +284 -0
  96. rdkit_headers/include/rdkit/GraphMol/Deprotect/Deprotect.h +105 -0
  97. rdkit_headers/include/rdkit/GraphMol/Descriptors/AUTOCORR2D.h +49 -0
  98. rdkit_headers/include/rdkit/GraphMol/Descriptors/AUTOCORR3D.h +51 -0
  99. rdkit_headers/include/rdkit/GraphMol/Descriptors/AtomFeat.h +39 -0
  100. rdkit_headers/include/rdkit/GraphMol/Descriptors/BCUT.h +66 -0
  101. rdkit_headers/include/rdkit/GraphMol/Descriptors/ConnectivityDescriptors.h +211 -0
  102. rdkit_headers/include/rdkit/GraphMol/Descriptors/CoulombMat.h +42 -0
  103. rdkit_headers/include/rdkit/GraphMol/Descriptors/Crippen.h +137 -0
  104. rdkit_headers/include/rdkit/GraphMol/Descriptors/Data3Ddescriptors.h +55 -0
  105. rdkit_headers/include/rdkit/GraphMol/Descriptors/EEM.h +59 -0
  106. rdkit_headers/include/rdkit/GraphMol/Descriptors/GETAWAY.h +51 -0
  107. rdkit_headers/include/rdkit/GraphMol/Descriptors/Lipinski.h +169 -0
  108. rdkit_headers/include/rdkit/GraphMol/Descriptors/MORSE.h +50 -0
  109. rdkit_headers/include/rdkit/GraphMol/Descriptors/MQN.h +47 -0
  110. rdkit_headers/include/rdkit/GraphMol/Descriptors/MolData3Ddescriptors.h +62 -0
  111. rdkit_headers/include/rdkit/GraphMol/Descriptors/MolDescriptors.h +86 -0
  112. rdkit_headers/include/rdkit/GraphMol/Descriptors/MolDescriptors3D.h +25 -0
  113. rdkit_headers/include/rdkit/GraphMol/Descriptors/MolSurf.h +120 -0
  114. rdkit_headers/include/rdkit/GraphMol/Descriptors/PBF.h +60 -0
  115. rdkit_headers/include/rdkit/GraphMol/Descriptors/PMI.h +128 -0
  116. rdkit_headers/include/rdkit/GraphMol/Descriptors/Property.h +123 -0
  117. rdkit_headers/include/rdkit/GraphMol/Descriptors/RDF.h +52 -0
  118. rdkit_headers/include/rdkit/GraphMol/Descriptors/RegisterDescriptor.h +84 -0
  119. rdkit_headers/include/rdkit/GraphMol/Descriptors/USRDescriptor.h +137 -0
  120. rdkit_headers/include/rdkit/GraphMol/Descriptors/WHIM.h +51 -0
  121. rdkit_headers/include/rdkit/GraphMol/DistGeomHelpers/BoundsMatrixBuilder.h +77 -0
  122. rdkit_headers/include/rdkit/GraphMol/DistGeomHelpers/Embedder.h +437 -0
  123. rdkit_headers/include/rdkit/GraphMol/FMCS/FMCS.h +194 -0
  124. rdkit_headers/include/rdkit/GraphMol/FMCS/Graph.h +43 -0
  125. rdkit_headers/include/rdkit/GraphMol/FileParsers/FileParserUtils.h +231 -0
  126. rdkit_headers/include/rdkit/GraphMol/FileParsers/FileParsers.h +399 -0
  127. rdkit_headers/include/rdkit/GraphMol/FileParsers/GeneralFileReader.h +170 -0
  128. rdkit_headers/include/rdkit/GraphMol/FileParsers/MolFileStereochem.h +60 -0
  129. rdkit_headers/include/rdkit/GraphMol/FileParsers/MolSupplier.h +444 -0
  130. rdkit_headers/include/rdkit/GraphMol/FileParsers/MolWriters.h +338 -0
  131. rdkit_headers/include/rdkit/GraphMol/FileParsers/MultithreadedMolSupplier.h +102 -0
  132. rdkit_headers/include/rdkit/GraphMol/FileParsers/MultithreadedSDMolSupplier.h +65 -0
  133. rdkit_headers/include/rdkit/GraphMol/FileParsers/MultithreadedSmilesMolSupplier.h +66 -0
  134. rdkit_headers/include/rdkit/GraphMol/FileParsers/PNGParser.h +203 -0
  135. rdkit_headers/include/rdkit/GraphMol/FileParsers/SequenceParsers.h +117 -0
  136. rdkit_headers/include/rdkit/GraphMol/FileParsers/SequenceWriters.h +47 -0
  137. rdkit_headers/include/rdkit/GraphMol/FilterCatalog/FilterCatalog.h +260 -0
  138. rdkit_headers/include/rdkit/GraphMol/FilterCatalog/FilterCatalogEntry.h +276 -0
  139. rdkit_headers/include/rdkit/GraphMol/FilterCatalog/FilterMatcherBase.h +152 -0
  140. rdkit_headers/include/rdkit/GraphMol/FilterCatalog/FilterMatchers.h +576 -0
  141. rdkit_headers/include/rdkit/GraphMol/FilterCatalog/FunctionalGroupHierarchy.h +52 -0
  142. rdkit_headers/include/rdkit/GraphMol/Fingerprints/AtomPairGenerator.h +188 -0
  143. rdkit_headers/include/rdkit/GraphMol/Fingerprints/AtomPairs.h +268 -0
  144. rdkit_headers/include/rdkit/GraphMol/Fingerprints/FingerprintGenerator.h +372 -0
  145. rdkit_headers/include/rdkit/GraphMol/Fingerprints/FingerprintUtil.h +160 -0
  146. rdkit_headers/include/rdkit/GraphMol/Fingerprints/Fingerprints.h +167 -0
  147. rdkit_headers/include/rdkit/GraphMol/Fingerprints/MACCS.h +32 -0
  148. rdkit_headers/include/rdkit/GraphMol/Fingerprints/MHFP.h +285 -0
  149. rdkit_headers/include/rdkit/GraphMol/Fingerprints/MorganFingerprints.h +210 -0
  150. rdkit_headers/include/rdkit/GraphMol/Fingerprints/MorganGenerator.h +251 -0
  151. rdkit_headers/include/rdkit/GraphMol/Fingerprints/RDKitFPGenerator.h +162 -0
  152. rdkit_headers/include/rdkit/GraphMol/Fingerprints/TopologicalTorsionGenerator.h +127 -0
  153. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/CrystalFF/TorsionAngleM6.h +72 -0
  154. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/CrystalFF/TorsionPreferences.h +41 -0
  155. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/FFConvenience.h +130 -0
  156. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/MMFF/AtomTyper.h +236 -0
  157. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/MMFF/Builder.h +141 -0
  158. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/MMFF/MMFF.h +105 -0
  159. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/UFF/AtomTyper.h +57 -0
  160. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/UFF/Builder.h +129 -0
  161. rdkit_headers/include/rdkit/GraphMol/ForceFieldHelpers/UFF/UFF.h +82 -0
  162. rdkit_headers/include/rdkit/GraphMol/FragCatalog/FragCatGenerator.h +33 -0
  163. rdkit_headers/include/rdkit/GraphMol/FragCatalog/FragCatParams.h +94 -0
  164. rdkit_headers/include/rdkit/GraphMol/FragCatalog/FragCatalogEntry.h +136 -0
  165. rdkit_headers/include/rdkit/GraphMol/FragCatalog/FragCatalogUtils.h +62 -0
  166. rdkit_headers/include/rdkit/GraphMol/FragCatalog/FragFPGenerator.h +38 -0
  167. rdkit_headers/include/rdkit/GraphMol/GenericGroups/GenericGroups.h +301 -0
  168. rdkit_headers/include/rdkit/GraphMol/GraphMol.h +22 -0
  169. rdkit_headers/include/rdkit/GraphMol/MMPA/MMPA.h +81 -0
  170. rdkit_headers/include/rdkit/GraphMol/MolAlign/AlignMolecules.h +183 -0
  171. rdkit_headers/include/rdkit/GraphMol/MolAlign/O3AAlignMolecules.h +354 -0
  172. rdkit_headers/include/rdkit/GraphMol/MolBundle.h +121 -0
  173. rdkit_headers/include/rdkit/GraphMol/MolCatalog/MolCatalog.h +20 -0
  174. rdkit_headers/include/rdkit/GraphMol/MolCatalog/MolCatalogEntry.h +109 -0
  175. rdkit_headers/include/rdkit/GraphMol/MolCatalog/MolCatalogParams.h +40 -0
  176. rdkit_headers/include/rdkit/GraphMol/MolChemicalFeatures/FeatureParser.h +58 -0
  177. rdkit_headers/include/rdkit/GraphMol/MolChemicalFeatures/MolChemicalFeature.h +98 -0
  178. rdkit_headers/include/rdkit/GraphMol/MolChemicalFeatures/MolChemicalFeatureDef.h +68 -0
  179. rdkit_headers/include/rdkit/GraphMol/MolChemicalFeatures/MolChemicalFeatureFactory.h +78 -0
  180. rdkit_headers/include/rdkit/GraphMol/MolDraw2D/MolDraw2D.h +539 -0
  181. rdkit_headers/include/rdkit/GraphMol/MolDraw2D/MolDraw2DHelpers.h +284 -0
  182. rdkit_headers/include/rdkit/GraphMol/MolDraw2D/MolDraw2DJS.h +62 -0
  183. rdkit_headers/include/rdkit/GraphMol/MolDraw2D/MolDraw2DSVG.h +88 -0
  184. rdkit_headers/include/rdkit/GraphMol/MolDraw2D/MolDraw2DUtils.h +179 -0
  185. rdkit_headers/include/rdkit/GraphMol/MolDraw2D/MolDraw2Dwx.h +107 -0
  186. rdkit_headers/include/rdkit/GraphMol/MolEnumerator/LinkNode.h +159 -0
  187. rdkit_headers/include/rdkit/GraphMol/MolEnumerator/MolEnumerator.h +276 -0
  188. rdkit_headers/include/rdkit/GraphMol/MolHash/MolHash.h +12 -0
  189. rdkit_headers/include/rdkit/GraphMol/MolHash/nmmolhash.h +60 -0
  190. rdkit_headers/include/rdkit/GraphMol/MolInterchange/MolInterchange.h +93 -0
  191. rdkit_headers/include/rdkit/GraphMol/MolInterchange/details.h +49 -0
  192. rdkit_headers/include/rdkit/GraphMol/MolOps.h +1016 -0
  193. rdkit_headers/include/rdkit/GraphMol/MolPickler.h +314 -0
  194. rdkit_headers/include/rdkit/GraphMol/MolStandardize/AcidBaseCatalog/AcidBaseCatalogEntry.h +56 -0
  195. rdkit_headers/include/rdkit/GraphMol/MolStandardize/AcidBaseCatalog/AcidBaseCatalogParams.h +65 -0
  196. rdkit_headers/include/rdkit/GraphMol/MolStandardize/AcidBaseCatalog/AcidBaseCatalogUtils.h +37 -0
  197. rdkit_headers/include/rdkit/GraphMol/MolStandardize/Charge.h +145 -0
  198. rdkit_headers/include/rdkit/GraphMol/MolStandardize/Fragment.h +105 -0
  199. rdkit_headers/include/rdkit/GraphMol/MolStandardize/FragmentCatalog/FragmentCatalogEntry.h +60 -0
  200. rdkit_headers/include/rdkit/GraphMol/MolStandardize/FragmentCatalog/FragmentCatalogParams.h +63 -0
  201. rdkit_headers/include/rdkit/GraphMol/MolStandardize/FragmentCatalog/FragmentCatalogUtils.h +35 -0
  202. rdkit_headers/include/rdkit/GraphMol/MolStandardize/Metal.h +73 -0
  203. rdkit_headers/include/rdkit/GraphMol/MolStandardize/MolStandardize.h +178 -0
  204. rdkit_headers/include/rdkit/GraphMol/MolStandardize/Normalize.h +104 -0
  205. rdkit_headers/include/rdkit/GraphMol/MolStandardize/Tautomer.h +428 -0
  206. rdkit_headers/include/rdkit/GraphMol/MolStandardize/TautomerCatalog/TautomerCatalogEntry.h +59 -0
  207. rdkit_headers/include/rdkit/GraphMol/MolStandardize/TautomerCatalog/TautomerCatalogParams.h +69 -0
  208. rdkit_headers/include/rdkit/GraphMol/MolStandardize/TautomerCatalog/TautomerCatalogUtils.h +81 -0
  209. rdkit_headers/include/rdkit/GraphMol/MolStandardize/TransformCatalog/TransformCatalogEntry.h +57 -0
  210. rdkit_headers/include/rdkit/GraphMol/MolStandardize/TransformCatalog/TransformCatalogParams.h +66 -0
  211. rdkit_headers/include/rdkit/GraphMol/MolStandardize/TransformCatalog/TransformCatalogUtils.h +37 -0
  212. rdkit_headers/include/rdkit/GraphMol/MolStandardize/Validate.h +199 -0
  213. rdkit_headers/include/rdkit/GraphMol/MolTransforms/MolTransforms.h +222 -0
  214. rdkit_headers/include/rdkit/GraphMol/MonomerInfo.h +138 -0
  215. rdkit_headers/include/rdkit/GraphMol/PartialCharges/GasteigerCharges.h +27 -0
  216. rdkit_headers/include/rdkit/GraphMol/PartialCharges/GasteigerParams.h +86 -0
  217. rdkit_headers/include/rdkit/GraphMol/PeriodicTable.h +325 -0
  218. rdkit_headers/include/rdkit/GraphMol/QueryAtom.h +161 -0
  219. rdkit_headers/include/rdkit/GraphMol/QueryBond.h +146 -0
  220. rdkit_headers/include/rdkit/GraphMol/QueryOps.h +1110 -0
  221. rdkit_headers/include/rdkit/GraphMol/RDKitBase.h +35 -0
  222. rdkit_headers/include/rdkit/GraphMol/RDKitQueries.h +25 -0
  223. rdkit_headers/include/rdkit/GraphMol/RGroupDecomposition/RGroupDecomp.h +225 -0
  224. rdkit_headers/include/rdkit/GraphMol/ROMol.h +844 -0
  225. rdkit_headers/include/rdkit/GraphMol/RWMol.h +222 -0
  226. rdkit_headers/include/rdkit/GraphMol/ReducedGraphs/ReducedGraphs.h +85 -0
  227. rdkit_headers/include/rdkit/GraphMol/Resonance.h +236 -0
  228. rdkit_headers/include/rdkit/GraphMol/RingInfo.h +274 -0
  229. rdkit_headers/include/rdkit/GraphMol/Rings.h +90 -0
  230. rdkit_headers/include/rdkit/GraphMol/SLNParse/SLNAttribs.h +93 -0
  231. rdkit_headers/include/rdkit/GraphMol/SLNParse/SLNParse.h +70 -0
  232. rdkit_headers/include/rdkit/GraphMol/SLNParse/SLNParseOps.h +328 -0
  233. rdkit_headers/include/rdkit/GraphMol/SanitException.h +120 -0
  234. rdkit_headers/include/rdkit/GraphMol/ScaffoldNetwork/ScaffoldNetwork.h +195 -0
  235. rdkit_headers/include/rdkit/GraphMol/ShapeHelpers/ShapeEncoder.h +73 -0
  236. rdkit_headers/include/rdkit/GraphMol/ShapeHelpers/ShapeUtils.h +279 -0
  237. rdkit_headers/include/rdkit/GraphMol/SmilesParse/SmartsWrite.h +46 -0
  238. rdkit_headers/include/rdkit/GraphMol/SmilesParse/SmilesParse.h +160 -0
  239. rdkit_headers/include/rdkit/GraphMol/SmilesParse/SmilesParseOps.h +53 -0
  240. rdkit_headers/include/rdkit/GraphMol/SmilesParse/SmilesWrite.h +288 -0
  241. rdkit_headers/include/rdkit/GraphMol/SmilesParse/primes.h +18 -0
  242. rdkit_headers/include/rdkit/GraphMol/StereoGroup.h +74 -0
  243. rdkit_headers/include/rdkit/GraphMol/Subgraphs/SubgraphUtils.h +57 -0
  244. rdkit_headers/include/rdkit/GraphMol/Subgraphs/Subgraphs.h +154 -0
  245. rdkit_headers/include/rdkit/GraphMol/SubstanceGroup.h +297 -0
  246. rdkit_headers/include/rdkit/GraphMol/Substruct/SubstructMatch.h +232 -0
  247. rdkit_headers/include/rdkit/GraphMol/Substruct/SubstructUtils.h +44 -0
  248. rdkit_headers/include/rdkit/GraphMol/SubstructLibrary/PatternFactory.h +40 -0
  249. rdkit_headers/include/rdkit/GraphMol/SubstructLibrary/SubstructLibrary.h +951 -0
  250. rdkit_headers/include/rdkit/GraphMol/SubstructLibrary/SubstructLibrarySerialization.h +231 -0
  251. rdkit_headers/include/rdkit/GraphMol/TautomerQuery/TautomerQuery.h +104 -0
  252. rdkit_headers/include/rdkit/GraphMol/Trajectory/Snapshot.h +69 -0
  253. rdkit_headers/include/rdkit/GraphMol/Trajectory/Trajectory.h +105 -0
  254. rdkit_headers/include/rdkit/GraphMol/atomic_data.h +76 -0
  255. rdkit_headers/include/rdkit/GraphMol/details.h +15 -0
  256. rdkit_headers/include/rdkit/GraphMol/new_canon.h +772 -0
  257. rdkit_headers/include/rdkit/Numerics/Alignment/AlignPoints.h +49 -0
  258. rdkit_headers/include/rdkit/Numerics/Conrec.h +203 -0
  259. rdkit_headers/include/rdkit/Numerics/EigenSolvers/PowerEigenSolver.h +68 -0
  260. rdkit_headers/include/rdkit/Numerics/Matrix.h +347 -0
  261. rdkit_headers/include/rdkit/Numerics/Optimizer/BFGSOpt.h +397 -0
  262. rdkit_headers/include/rdkit/Numerics/SquareMatrix.h +89 -0
  263. rdkit_headers/include/rdkit/Numerics/SymmMatrix.h +361 -0
  264. rdkit_headers/include/rdkit/Numerics/Vector.h +327 -0
  265. rdkit_headers/include/rdkit/Query/AndQuery.h +57 -0
  266. rdkit_headers/include/rdkit/Query/EqualityQuery.h +88 -0
  267. rdkit_headers/include/rdkit/Query/GreaterEqualQuery.h +74 -0
  268. rdkit_headers/include/rdkit/Query/GreaterQuery.h +74 -0
  269. rdkit_headers/include/rdkit/Query/LessEqualQuery.h +75 -0
  270. rdkit_headers/include/rdkit/Query/LessQuery.h +74 -0
  271. rdkit_headers/include/rdkit/Query/NullQueryAlgebra.h +86 -0
  272. rdkit_headers/include/rdkit/Query/OrQuery.h +58 -0
  273. rdkit_headers/include/rdkit/Query/Query.h +210 -0
  274. rdkit_headers/include/rdkit/Query/QueryObjects.h +38 -0
  275. rdkit_headers/include/rdkit/Query/RangeQuery.h +116 -0
  276. rdkit_headers/include/rdkit/Query/SetQuery.h +87 -0
  277. rdkit_headers/include/rdkit/Query/XOrQuery.h +63 -0
  278. rdkit_headers/include/rdkit/RDGeneral/BadFileException.h +39 -0
  279. rdkit_headers/include/rdkit/RDGeneral/BoostEndInclude.h +69 -0
  280. rdkit_headers/include/rdkit/RDGeneral/BoostStartInclude.h +95 -0
  281. rdkit_headers/include/rdkit/RDGeneral/ConcurrentQueue.h +132 -0
  282. rdkit_headers/include/rdkit/RDGeneral/Dict.h +350 -0
  283. rdkit_headers/include/rdkit/RDGeneral/Exceptions.h +73 -0
  284. rdkit_headers/include/rdkit/RDGeneral/FileParseException.h +36 -0
  285. rdkit_headers/include/rdkit/RDGeneral/Invariant.h +198 -0
  286. rdkit_headers/include/rdkit/RDGeneral/LocaleSwitcher.h +54 -0
  287. rdkit_headers/include/rdkit/RDGeneral/RDAny.h +217 -0
  288. rdkit_headers/include/rdkit/RDGeneral/RDConfig.h +49 -0
  289. rdkit_headers/include/rdkit/RDGeneral/RDExportMacros.h +40 -0
  290. rdkit_headers/include/rdkit/RDGeneral/RDLog.h +142 -0
  291. rdkit_headers/include/rdkit/RDGeneral/RDProps.h +172 -0
  292. rdkit_headers/include/rdkit/RDGeneral/RDThreads.h +44 -0
  293. rdkit_headers/include/rdkit/RDGeneral/RDValue-doublemagic.h +478 -0
  294. rdkit_headers/include/rdkit/RDGeneral/RDValue-taggedunion.h +518 -0
  295. rdkit_headers/include/rdkit/RDGeneral/RDValue.h +285 -0
  296. rdkit_headers/include/rdkit/RDGeneral/Ranking.h +87 -0
  297. rdkit_headers/include/rdkit/RDGeneral/StreamOps.h +637 -0
  298. rdkit_headers/include/rdkit/RDGeneral/export.h +559 -0
  299. rdkit_headers/include/rdkit/RDGeneral/hanoiSort.h +167 -0
  300. rdkit_headers/include/rdkit/RDGeneral/hash/detail/float_functions.hpp +156 -0
  301. rdkit_headers/include/rdkit/RDGeneral/hash/detail/hash_float.hpp +179 -0
  302. rdkit_headers/include/rdkit/RDGeneral/hash/extensions.hpp +152 -0
  303. rdkit_headers/include/rdkit/RDGeneral/hash/hash.hpp +463 -0
  304. rdkit_headers/include/rdkit/RDGeneral/hash/hash_fwd.hpp +51 -0
  305. rdkit_headers/include/rdkit/RDGeneral/test.h +274 -0
  306. rdkit_headers/include/rdkit/RDGeneral/types.h +401 -0
  307. rdkit_headers/include/rdkit/RDGeneral/utils.h +106 -0
  308. rdkit_headers/include/rdkit/RDGeneral/versions.h +27 -0
  309. rdkit_headers/include/rdkit/RDStreams/streams.h +19 -0
  310. rdkit_headers/include/rdkit/RingDecomposerLib.h +751 -0
  311. rdkit_headers/include/rdkit/SimDivPickers/DistPicker.h +92 -0
  312. rdkit_headers/include/rdkit/SimDivPickers/HierarchicalClusterPicker.h +107 -0
  313. rdkit_headers/include/rdkit/SimDivPickers/LeaderPicker.h +470 -0
  314. rdkit_headers/include/rdkit/SimDivPickers/MaxMinPicker.h +303 -0
  315. rdkit_headers-2022.3.3.dist-info/METADATA +24 -0
  316. rdkit_headers-2022.3.3.dist-info/RECORD +320 -0
  317. rdkit_headers-2022.3.3.dist-info/WHEEL +4 -0
  318. rdkit_headers-2022.3.3.dist-info/entry_points.txt +4 -0
  319. rdkit_headers-2022.3.3.dist-info/licenses/LICENSE +29 -0
  320. rdkit_headers-2022.3.3.dist-info/licenses/NOTICE +5 -0
@@ -0,0 +1,86 @@
1
+ //
2
+ // Copyright (C) 2003-2015 Rational Discovery LLC
3
+ //
4
+ // @@ All Rights Reserved @@
5
+ // This file is part of the RDKit.
6
+ // The contents are covered by the terms of the BSD license
7
+ // which is included in the file license.txt, found at the root
8
+ // of the RDKit source tree.
9
+ //
10
+ #include <RDGeneral/export.h>
11
+ #ifndef _RD_GASTEIGERPARAMS_H
12
+ #define _RD_GASTEIGERPARAMS_H
13
+
14
+ #include <RDGeneral/types.h>
15
+ #include <RDGeneral/Exceptions.h>
16
+ #include <string>
17
+ #include <map>
18
+
19
+ namespace RDKit {
20
+ extern std::string paramData;
21
+ extern std::string additionalParamData;
22
+
23
+ // this is a constant used during the iteration procedure for the hydrogen atoms
24
+ // for the remaining atoms it is computed on the fly
25
+ const double IONXH = 20.02;
26
+
27
+ const double DAMP_SCALE = 0.5;
28
+ const double DAMP = 0.5;
29
+
30
+ class RDKIT_PARTIALCHARGES_EXPORT GasteigerParams {
31
+ /* \brief Container for all the partial charge parameters
32
+ *
33
+ * It is filled by the paramData string defined in GasteigerParams.cpp
34
+ * The main data member is a STL map that take a pair<std::string,
35
+ *std::string>
36
+ * of element name and mode (hybridization or bonding mode) and return a
37
+ *vector
38
+ * of three parameters, used in the iterative partial charges equalization
39
+ *procedure
40
+ */
41
+
42
+ public:
43
+ static const GasteigerParams *getParams(const std::string &paramData = "");
44
+
45
+ ~GasteigerParams() { d_paramMap.clear(); }
46
+
47
+ DOUBLE_VECT getParams(std::string elem, std::string mode,
48
+ bool throwOnFailure = false) const {
49
+ std::pair<std::string, std::string> query(elem, mode);
50
+ std::map<std::pair<std::string, std::string>, DOUBLE_VECT>::const_iterator
51
+ iter;
52
+ iter = d_paramMap.find(query);
53
+ if (iter != d_paramMap.end()) {
54
+ return iter->second;
55
+ } else {
56
+ if (throwOnFailure) {
57
+ std::string message =
58
+ "ERROR: No Gasteiger Partial Charge parameters for Element: ";
59
+ message += elem;
60
+ message += " Mode: ";
61
+ message += mode;
62
+ throw ValueErrorException(message);
63
+ } else {
64
+ iter =
65
+ d_paramMap.find(std::make_pair(std::string("X"), std::string("*")));
66
+ if (iter != d_paramMap.end()) {
67
+ return iter->second;
68
+ } else {
69
+ std::string message =
70
+ "ERROR: Default Gasteiger Partial Charge parameters are missing";
71
+ throw ValueErrorException(message);
72
+ }
73
+ }
74
+ }
75
+ }
76
+
77
+ GasteigerParams(std::string paramData = "");
78
+
79
+ private:
80
+ std::map<std::pair<std::string, std::string>, DOUBLE_VECT> d_paramMap;
81
+
82
+ static class GasteigerParams *ds_instance;
83
+ };
84
+ }; // namespace RDKit
85
+
86
+ #endif
@@ -0,0 +1,325 @@
1
+ //
2
+ // Copyright (C) 2001-2011 Rational Discovery LLC
3
+ //
4
+ // @@ All Rights Reserved @@
5
+ // This file is part of the RDKit.
6
+ // The contents are covered by the terms of the BSD license
7
+ // which is included in the file license.txt, found at the root
8
+ // of the RDKit source tree.
9
+ //
10
+ #include <RDGeneral/export.h>
11
+ #ifndef _RD_PERIODIC_TABLE_H
12
+ #define _RD_PERIODIC_TABLE_H
13
+
14
+ #include <map>
15
+ #include <vector>
16
+ #include <RDGeneral/types.h>
17
+ #include "atomic_data.h"
18
+
19
+ namespace RDKit {
20
+
21
+ //! singleton class for retrieving information about atoms
22
+ /*!
23
+ Use the singleton like this:
24
+
25
+ \verbatim
26
+ const PeriodicTable *tbl = PeriodicTable::getTable();
27
+ tbl->getAtomicWeight(6); // get atomic weight for Carbon
28
+ tbl->getAtomicWeight("C"); // get atomic weight for Carbon
29
+ \endverbatim
30
+
31
+ */
32
+ class RDKIT_GRAPHMOL_EXPORT PeriodicTable {
33
+ public:
34
+ //! returns a pointer to the singleton PeriodicTable
35
+ /*
36
+ \return a pointer to the singleton ParamCollection
37
+
38
+ <b>Notes:</b>
39
+ - do <b>not</b> delete the pointer returned here
40
+ - if the singleton PeriodicTable has already been instantiated and
41
+ the singleton will be returned, otherwise the singleton will
42
+ be constructed.
43
+
44
+ */
45
+ static PeriodicTable *getTable();
46
+
47
+ ~PeriodicTable() {
48
+ byanum.clear();
49
+ byname.clear();
50
+ }
51
+
52
+ //! returns the atomic weight
53
+ double getAtomicWeight(UINT atomicNumber) const {
54
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
55
+ double mass = byanum[atomicNumber].Mass();
56
+ return mass;
57
+ }
58
+ //! \overload
59
+ double getAtomicWeight(const std::string &elementSymbol) const {
60
+ PRECONDITION(byname.count(elementSymbol), "Element not found");
61
+ int anum = byname.find(elementSymbol)->second;
62
+ double mass = byanum[anum].Mass();
63
+ return mass;
64
+ }
65
+ //! \overload
66
+ double getAtomicWeight(const char *elementSymbol) const {
67
+ return getAtomicWeight(std::string(elementSymbol));
68
+ }
69
+
70
+ //! returns the atomic number
71
+ int getAtomicNumber(const char *elementSymbol) const {
72
+ std::string symb(elementSymbol);
73
+
74
+ return getAtomicNumber(symb);
75
+ }
76
+ //! overload
77
+ int getAtomicNumber(const std::string &elementSymbol) const {
78
+ // this little optimization actually makes a measurable difference
79
+ // in molecule-construction time
80
+ int anum = -1;
81
+ if (elementSymbol == "C") {
82
+ anum = 6;
83
+ } else if (elementSymbol == "N") {
84
+ anum = 7;
85
+ } else if (elementSymbol == "O") {
86
+ anum = 8;
87
+ } else {
88
+ STR_UINT_MAP::const_iterator iter = byname.find(elementSymbol);
89
+ if (iter != byname.end()) {
90
+ anum = iter->second;
91
+ }
92
+ }
93
+ POSTCONDITION(anum > -1, "Element '" + elementSymbol + "' not found");
94
+ return anum;
95
+ }
96
+
97
+ //! returns the atomic symbol
98
+ std::string getElementSymbol(UINT atomicNumber) const {
99
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
100
+ return byanum[atomicNumber].Symbol();
101
+ }
102
+
103
+ //! returns the atom's van der Waals radius
104
+ double getRvdw(UINT atomicNumber) const {
105
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
106
+ return byanum[atomicNumber].Rvdw();
107
+ }
108
+ //! \overload
109
+ double getRvdw(const std::string &elementSymbol) const {
110
+ PRECONDITION(byname.count(elementSymbol),
111
+ "Element '" + elementSymbol + "' not found");
112
+ return getRvdw(byname.find(elementSymbol)->second);
113
+ }
114
+ //! \overload
115
+ double getRvdw(const char *elementSymbol) const {
116
+ return getRvdw(std::string(elementSymbol));
117
+ }
118
+
119
+ //! returns the atom's covalent radius
120
+ double getRcovalent(UINT atomicNumber) const {
121
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
122
+ return byanum[atomicNumber].Rcov();
123
+ }
124
+ //! \overload
125
+ double getRcovalent(const std::string &elementSymbol) const {
126
+ PRECONDITION(byname.count(elementSymbol),
127
+ "Element '" + elementSymbol + "' not found");
128
+ return getRcovalent(byname.find(elementSymbol)->second);
129
+ }
130
+ //! \overload
131
+ double getRcovalent(const char *elementSymbol) const {
132
+ return getRcovalent(std::string(elementSymbol));
133
+ }
134
+
135
+ //! returns the atom's bond radius
136
+ double getRb0(UINT atomicNumber) const {
137
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
138
+ return byanum[atomicNumber].Rb0();
139
+ }
140
+ //! \overload
141
+ double getRb0(const std::string &elementSymbol) const {
142
+ PRECONDITION(byname.count(elementSymbol),
143
+ "Element '" + elementSymbol + "' not found");
144
+ return getRb0(byname.find(elementSymbol)->second);
145
+ }
146
+ //! \overload
147
+ double getRb0(const char *elementSymbol) const {
148
+ return getRb0(std::string(elementSymbol));
149
+ }
150
+
151
+ //! returns the atom's default valence
152
+ int getDefaultValence(UINT atomicNumber) const {
153
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
154
+ return byanum[atomicNumber].DefaultValence();
155
+ }
156
+ //! \overload
157
+ int getDefaultValence(const std::string &elementSymbol) const {
158
+ PRECONDITION(byname.count(elementSymbol),
159
+ "Element '" + elementSymbol + "' not found");
160
+ return getDefaultValence(byname.find(elementSymbol)->second);
161
+ }
162
+ //! \overload
163
+ int getDefaultValence(const char *elementSymbol) const {
164
+ return getDefaultValence(std::string(elementSymbol));
165
+ }
166
+
167
+ //! returns a vector of all stable valences. For atoms where
168
+ //! we really don't have any idea what a reasonable maximum
169
+ //! valence is (like transition metals), the vector ends with -1
170
+ const INT_VECT &getValenceList(UINT atomicNumber) const {
171
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
172
+ return byanum[atomicNumber].ValenceList();
173
+ }
174
+ //! \overload
175
+ const INT_VECT &getValenceList(const std::string &elementSymbol) const {
176
+ PRECONDITION(byname.count(elementSymbol),
177
+ "Element '" + elementSymbol + "' not found");
178
+ return getValenceList(byname.find(elementSymbol)->second);
179
+ }
180
+ //! \overload
181
+ const INT_VECT &getValenceList(const char *elementSymbol) const {
182
+ return getValenceList(std::string(elementSymbol));
183
+ }
184
+
185
+ //! returns the number of outer shell electrons
186
+ int getNouterElecs(UINT atomicNumber) const {
187
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
188
+ return byanum[atomicNumber].NumOuterShellElec();
189
+ }
190
+ //! \overload
191
+ int getNouterElecs(const std::string &elementSymbol) const {
192
+ PRECONDITION(byname.count(elementSymbol),
193
+ "Element '" + elementSymbol + "' not found");
194
+ return getNouterElecs(byname.find(elementSymbol)->second);
195
+ }
196
+ //! \overload
197
+ int getNouterElecs(const char *elementSymbol) const {
198
+ return getNouterElecs(std::string(elementSymbol));
199
+ }
200
+
201
+ //! returns the number of the most common isotope
202
+ int getMostCommonIsotope(UINT atomicNumber) const {
203
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
204
+ return byanum[atomicNumber].MostCommonIsotope();
205
+ }
206
+ //! \overload
207
+ int getMostCommonIsotope(const std::string &elementSymbol) const {
208
+ PRECONDITION(byname.count(elementSymbol),
209
+ "Element '" + elementSymbol + "' not found");
210
+ return getMostCommonIsotope(byname.find(elementSymbol)->second);
211
+ }
212
+ //! \overload
213
+ int getMostCommonIsotope(const char *elementSymbol) const {
214
+ return getMostCommonIsotope(std::string(elementSymbol));
215
+ }
216
+
217
+ //! returns the mass of the most common isotope
218
+ double getMostCommonIsotopeMass(UINT atomicNumber) const {
219
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
220
+ return byanum[atomicNumber].MostCommonIsotopeMass();
221
+ }
222
+ //! \overload
223
+ double getMostCommonIsotopeMass(const std::string &elementSymbol) const {
224
+ PRECONDITION(byname.count(elementSymbol),
225
+ "Element '" + elementSymbol + "' not found");
226
+ return getMostCommonIsotopeMass(byname.find(elementSymbol)->second);
227
+ }
228
+ //! \overload
229
+ double getMostCommonIsotopeMass(const char *elementSymbol) const {
230
+ return getMostCommonIsotopeMass(std::string(elementSymbol));
231
+ }
232
+
233
+ //! returns the mass of a particular isotope; zero if that
234
+ //! isotope is unknown.
235
+ double getMassForIsotope(UINT atomicNumber, UINT isotope) const {
236
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
237
+ const std::map<unsigned int, std::pair<double, double>> &m =
238
+ byanum[atomicNumber].d_isotopeInfoMap;
239
+ std::map<unsigned int, std::pair<double, double>>::const_iterator item =
240
+ m.find(isotope);
241
+ if (item == m.end()) {
242
+ return 0.0;
243
+ } else {
244
+ return item->second.first;
245
+ }
246
+ }
247
+ //! \overload
248
+ double getMassForIsotope(const std::string &elementSymbol,
249
+ UINT isotope) const {
250
+ PRECONDITION(byname.count(elementSymbol),
251
+ "Element '" + elementSymbol + "' not found");
252
+ return getMassForIsotope(byname.find(elementSymbol)->second, isotope);
253
+ }
254
+ //! \overload
255
+ double getMassForIsotope(const char *elementSymbol, UINT isotope) const {
256
+ return getMassForIsotope(std::string(elementSymbol), isotope);
257
+ }
258
+ //! returns the abundance of a particular isotope; zero if that
259
+ //! isotope is unknown.
260
+ double getAbundanceForIsotope(UINT atomicNumber, UINT isotope) const {
261
+ PRECONDITION(atomicNumber < byanum.size(), "Atomic number not found");
262
+ const std::map<unsigned int, std::pair<double, double>> &m =
263
+ byanum[atomicNumber].d_isotopeInfoMap;
264
+ std::map<unsigned int, std::pair<double, double>>::const_iterator item =
265
+ m.find(isotope);
266
+ if (item == m.end()) {
267
+ return 0.0;
268
+ } else {
269
+ return item->second.second;
270
+ }
271
+ }
272
+ //! \overload
273
+ double getAbundanceForIsotope(const std::string &elementSymbol,
274
+ UINT isotope) const {
275
+ PRECONDITION(byname.count(elementSymbol),
276
+ "Element '" + elementSymbol + "' not found");
277
+ return getAbundanceForIsotope(byname.find(elementSymbol)->second, isotope);
278
+ }
279
+ //! \overload
280
+ double getAbundanceForIsotope(const char *elementSymbol, UINT isotope) const {
281
+ return getAbundanceForIsotope(std::string(elementSymbol), isotope);
282
+ }
283
+
284
+ //! convenience function to determine which atom is more electronegative
285
+ /*!
286
+
287
+ check if atom with atomic number \c anum1 is more
288
+ electronegative than the one with \c anum2
289
+ this is rather lame but here is how we do it
290
+ - the atom with the higher number of outer shell electrons
291
+ is considered more electronegative
292
+ - if the # of outer shell elecs are the same
293
+ the atom with the lower atomic weight is more electronegative
294
+
295
+ */
296
+ bool moreElectroNegative(UINT anum1, UINT anum2) const {
297
+ PRECONDITION(anum1 < byanum.size(), "Atomic number not found");
298
+ PRECONDITION(anum2 < byanum.size(), "Atomic number not found");
299
+ // FIX: the atomic_data needs to have real electronegativity values
300
+ UINT ne1 = getNouterElecs(anum1);
301
+ UINT ne2 = getNouterElecs(anum2);
302
+ if (ne1 > ne2) {
303
+ return true;
304
+ }
305
+ if (ne1 == ne2) {
306
+ if (anum1 < anum2) {
307
+ return true;
308
+ }
309
+ }
310
+ return false;
311
+ }
312
+
313
+ private:
314
+ PeriodicTable();
315
+ PeriodicTable &operator=(const PeriodicTable &);
316
+ static void initInstance();
317
+
318
+ static class std::unique_ptr<PeriodicTable> ds_instance;
319
+
320
+ std::vector<atomicData> byanum;
321
+ STR_UINT_MAP byname;
322
+ };
323
+ }; // namespace RDKit
324
+
325
+ #endif
@@ -0,0 +1,161 @@
1
+ //
2
+ // Copyright (C) 2001-2022 Greg Landrum and other RDKit contributors
3
+ //
4
+ // @@ All Rights Reserved @@
5
+ // This file is part of the RDKit.
6
+ // The contents are covered by the terms of the BSD license
7
+ // which is included in the file license.txt, found at the root
8
+ // of the RDKit source tree.
9
+ //
10
+ #include <RDGeneral/export.h>
11
+ #ifndef RD_QUERYATOM_H
12
+ #define RD_QUERYATOM_H
13
+
14
+ #include <utility>
15
+ #include "Atom.h"
16
+ #include <Query/QueryObjects.h>
17
+ #include <GraphMol/QueryOps.h>
18
+
19
+ namespace RDKit {
20
+
21
+ //! Class for storing atomic queries
22
+ /*!
23
+ QueryAtom objects are derived from Atom objects, so they can be
24
+ added to molecules and the like, but they have much fancier
25
+ querying capabilities.
26
+
27
+ */
28
+ class RDKIT_GRAPHMOL_EXPORT QueryAtom : public Atom {
29
+ public:
30
+ typedef Queries::Query<int, Atom const *, true> QUERYATOM_QUERY;
31
+
32
+ QueryAtom() : Atom() {}
33
+ explicit QueryAtom(int num) : Atom(num), dp_query(makeAtomNumQuery(num)) {}
34
+ explicit QueryAtom(const Atom &other)
35
+ : Atom(other), dp_query(makeAtomNumQuery(other.getAtomicNum())) {
36
+ if (other.getIsotope()) {
37
+ this->expandQuery(makeAtomIsotopeQuery(other.getIsotope()),
38
+ Queries::CompositeQueryType::COMPOSITE_AND);
39
+ }
40
+ if (other.getFormalCharge()) {
41
+ this->expandQuery(makeAtomFormalChargeQuery(other.getFormalCharge()),
42
+ Queries::CompositeQueryType::COMPOSITE_AND);
43
+ }
44
+ if (other.getNumRadicalElectrons()) {
45
+ this->expandQuery(
46
+ makeAtomNumRadicalElectronsQuery(other.getNumRadicalElectrons()),
47
+ Queries::CompositeQueryType::COMPOSITE_AND);
48
+ }
49
+ }
50
+ QueryAtom(const QueryAtom &other) : Atom(other) {
51
+ if (other.dp_query) {
52
+ dp_query = other.dp_query->copy();
53
+ } else {
54
+ dp_query = nullptr;
55
+ }
56
+ }
57
+ QueryAtom &operator=(const QueryAtom &other) {
58
+ if (this == &other) {
59
+ return *this;
60
+ }
61
+ Atom::operator=(other);
62
+ delete dp_query;
63
+ if (other.dp_query) {
64
+ dp_query = other.dp_query->copy();
65
+ } else {
66
+ dp_query = nullptr;
67
+ }
68
+ return *this;
69
+ }
70
+
71
+ QueryAtom(QueryAtom &&other) noexcept : Atom(std::move(other)) {
72
+ dp_query = std::exchange(other.dp_query, nullptr);
73
+ }
74
+ QueryAtom &operator=(QueryAtom &&other) noexcept {
75
+ if (this == &other) {
76
+ return *this;
77
+ }
78
+ QueryAtom::operator=(std::move(other));
79
+ dp_query = std::exchange(other.dp_query, nullptr);
80
+ return *this;
81
+ }
82
+
83
+ ~QueryAtom() override;
84
+
85
+ //! returns a copy of this query, owned by the caller
86
+ Atom *copy() const override;
87
+
88
+ // This method can be used to distinguish query atoms from standard atoms:
89
+ bool hasQuery() const override { return dp_query != nullptr; }
90
+
91
+ //! replaces our current query with the value passed in
92
+ std::string getQueryType() const override { return dp_query->getTypeLabel(); }
93
+
94
+ //! replaces our current query with the value passed in
95
+ void setQuery(QUERYATOM_QUERY *what) override {
96
+ delete dp_query;
97
+ dp_query = what;
98
+ }
99
+ //! returns our current query
100
+ QUERYATOM_QUERY *getQuery() const override { return dp_query; }
101
+
102
+ //! expands our current query
103
+ /*!
104
+ \param what the Queries::Query to be added. The ownership of
105
+ the query is passed to the current object, where it
106
+ might be deleted, so that the pointer should not be
107
+ used again in the calling code.
108
+ \param how the operator to be used in the expansion
109
+ \param maintainOrder (optional) flags whether the relative order of
110
+ the queries needs to be maintained, if this is
111
+ false, the order is reversed
112
+ <b>Notes:</b>
113
+ - \c what should probably be constructed using one of the functions
114
+ defined in QueryOps.h
115
+ - the \c maintainOrder option can be useful because the combination
116
+ operators short circuit when possible.
117
+
118
+ */
119
+ void expandQuery(QUERYATOM_QUERY *what,
120
+ Queries::CompositeQueryType how = Queries::COMPOSITE_AND,
121
+ bool maintainOrder = true) override;
122
+
123
+ //! returns true if we match Atom \c what
124
+ bool Match(Atom const *what) const override;
125
+
126
+ //! returns true if our query details match those of QueryAtom \c what
127
+ bool QueryMatch(QueryAtom const *what) const;
128
+
129
+ private:
130
+ QUERYATOM_QUERY *dp_query{nullptr};
131
+
132
+ }; // end o' class
133
+
134
+ namespace detail {
135
+ inline std::string qhelper(Atom::QUERYATOM_QUERY *q, unsigned int depth) {
136
+ std::string res = "";
137
+ if (q) {
138
+ for (unsigned int i = 0; i < depth; ++i) {
139
+ res += " ";
140
+ }
141
+ res += q->getFullDescription() + "\n";
142
+ for (Atom::QUERYATOM_QUERY::CHILD_VECT_CI ci = q->beginChildren();
143
+ ci != q->endChildren(); ++ci) {
144
+ res += qhelper((*ci).get(), depth + 1);
145
+ }
146
+ }
147
+ return res;
148
+ }
149
+ } // namespace detail
150
+ inline std::string describeQuery(const Atom *atom) {
151
+ PRECONDITION(atom, "bad atom");
152
+ std::string res = "";
153
+ if (atom->hasQuery()) {
154
+ res = detail::qhelper(atom->getQuery(), 0);
155
+ }
156
+ return res;
157
+ }
158
+
159
+ }; // namespace RDKit
160
+
161
+ #endif