![]() |
Chemical Data Processing Library C++ API - Version 1.4.0
|
Calculator for the MMFF94 partial atomic charges of a molecular graph. More...
#include <MMFF94ChargeCalculator.hpp>
Public Types | |
| typedef std::shared_ptr< MMFF94ChargeCalculator > | SharedPointer |
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94ChargeCalculator instances. More... | |
Public Member Functions | |
| MMFF94ChargeCalculator () | |
Constructs the MMFF94ChargeCalculator instance. More... | |
| MMFF94ChargeCalculator (const Chem::MolecularGraph &molgraph, Util::DArray &charges, bool strict) | |
Constructs the MMFF94ChargeCalculator instance and immediately calculates partial charges for the atoms of molgraph. More... | |
| void | setBondChargeIncrementTable (const MMFF94BondChargeIncrementTable::SharedPointer &table) |
| Sets the bond charge increment table to use. More... | |
| void | setPartialBondChargeIncrementTable (const MMFF94PartialBondChargeIncrementTable::SharedPointer &table) |
| Sets the partial bond charge increment table to use. More... | |
| void | setAtomTypePropertyTable (const MMFF94AtomTypePropertyTable::SharedPointer &table) |
| Sets the MMFF94 atom type property table to use. More... | |
| void | setFormalChargeDefinitionTable (const MMFF94FormalAtomChargeDefinitionTable::SharedPointer &table) |
| Sets the formal charge definition table to use. More... | |
| void | setAromaticRingSetFunction (const MMFF94RingSetFunction &func) |
| Specifies the function used to retrieve the aromatic ring set of a molecular graph. More... | |
| void | setNumericAtomTypeFunction (const MMFF94NumericAtomTypeFunction &func) |
| Specifies the function used to retrieve the numeric MMFF94 atom type of an atom. More... | |
| void | setSymbolicAtomTypeFunction (const MMFF94SymbolicAtomTypeFunction &func) |
| Specifies the function used to retrieve the symbolic MMFF94 atom type of an atom. More... | |
| void | setBondTypeIndexFunction (const MMFF94BondTypeIndexFunction &func) |
| Specifies the function used to retrieve the MMFF94 bond type index of a bond. More... | |
| void | calculate (const Chem::MolecularGraph &molgraph, Util::DArray &charges, bool strict) |
| Calculates MMFF94 partial charges for the atoms of a molecular graph. More... | |
| const Util::DArray & | getFormalCharges () const |
| Returns the formal atomic charges assigned during the last calculation. More... | |
Calculator for the MMFF94 partial atomic charges of a molecular graph.
Partial atomic charges are constructed from full or fractional formal atomic charges and per-bond charge-increment contributions according to the MMFF94 parameterization. Parameter tables and atom-/bond-typing functions can be customized via the corresponding setter methods; default tables and typing functions match the standard MMFF94 reference.
| typedef std::shared_ptr<MMFF94ChargeCalculator> CDPL::ForceField::MMFF94ChargeCalculator::SharedPointer |
A reference-counted smart pointer [SHPTR] for dynamically allocated MMFF94ChargeCalculator instances.
| CDPL::ForceField::MMFF94ChargeCalculator::MMFF94ChargeCalculator | ( | ) |
Constructs the MMFF94ChargeCalculator instance.
| CDPL::ForceField::MMFF94ChargeCalculator::MMFF94ChargeCalculator | ( | const Chem::MolecularGraph & | molgraph, |
| Util::DArray & | charges, | ||
| bool | strict | ||
| ) |
Constructs the MMFF94ChargeCalculator instance and immediately calculates partial charges for the atoms of molgraph.
| molgraph | The molecular graph for which to calculate partial atomic charges. |
| charges | The output array storing the calculated partial charges. |
| strict | If true, strict parameterization is performed (and may fail). Otherwise, in case of parameterization problems, fallback strategies take effect. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setBondChargeIncrementTable | ( | const MMFF94BondChargeIncrementTable::SharedPointer & | table | ) |
Sets the bond charge increment table to use.
| table | The table providing bond charge increments. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setPartialBondChargeIncrementTable | ( | const MMFF94PartialBondChargeIncrementTable::SharedPointer & | table | ) |
Sets the partial bond charge increment table to use.
| table | The table providing partial bond charge increments. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setAtomTypePropertyTable | ( | const MMFF94AtomTypePropertyTable::SharedPointer & | table | ) |
Sets the MMFF94 atom type property table to use.
| table | The table providing atom type properties. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setFormalChargeDefinitionTable | ( | const MMFF94FormalAtomChargeDefinitionTable::SharedPointer & | table | ) |
Sets the formal charge definition table to use.
| table | The table providing formal charge definitions. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setAromaticRingSetFunction | ( | const MMFF94RingSetFunction & | func | ) |
Specifies the function used to retrieve the aromatic ring set of a molecular graph.
| func | The aromatic ring set function. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setNumericAtomTypeFunction | ( | const MMFF94NumericAtomTypeFunction & | func | ) |
Specifies the function used to retrieve the numeric MMFF94 atom type of an atom.
| func | The numeric atom type function. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setSymbolicAtomTypeFunction | ( | const MMFF94SymbolicAtomTypeFunction & | func | ) |
Specifies the function used to retrieve the symbolic MMFF94 atom type of an atom.
| func | The symbolic atom type function. |
| void CDPL::ForceField::MMFF94ChargeCalculator::setBondTypeIndexFunction | ( | const MMFF94BondTypeIndexFunction & | func | ) |
Specifies the function used to retrieve the MMFF94 bond type index of a bond.
| func | The bond type index function. |
| void CDPL::ForceField::MMFF94ChargeCalculator::calculate | ( | const Chem::MolecularGraph & | molgraph, |
| Util::DArray & | charges, | ||
| bool | strict | ||
| ) |
Calculates MMFF94 partial charges for the atoms of a molecular graph.
The partial atomic charges are constructed from initial full or fractional formal atomic charges \( q_I^0 \) (usually zero, but, e.g., +1/3 for guanidinium nitrogens) by adding contributions from bond charge increments \( w_{KI} \) which describe the polarity of the bonds to atom i from attached atoms k. Thus, \( w_{KI} \) is the contribution to the total charge on atom i of atom type I accumulated from, and at the expense of, its bonded neighbor k of atom type K. Specifically, MMFF computes \( q_i \) as
\( q_i = (1 - M_I \: u_I) \:q_I^0 + \sum (u_K \: q_K^0) + \sum w_{KI} \)
where \( w_{KI} = -w_{IK} \) and where the sums on the right hand side run over the \( M_I = crd(I) \) atoms k of MMFF atom type K directly attached to atom i ( \( crd(I) \) comes from "MMFFPROP.PAR"). In this equation, \( q_I^0 \) and \( q_K^0 \) are the formal charges assigned in the atom typing procedure (usually, by subroutine XTYPE), and the sum of the first two terms gives the "effective" fractional formal atomic charge residing on atom i. This approach allows a formal atomic charge initially affixed by the atom-typing procedure (e.g., \( q_I^0 \)) to be shared in a prescribed manner with the neighbors bonded to the atom in question. For example, for the series PO4(-3), HPO4(-2), H2PO4-, H3P04, it allows allows the partial charges on the terminal oxygens (each represented by the same numerical atom type, "32") to vary in a way which properly reflects the partial charges obtained from fits to the 6-31G* electrostatic potential. In particular, the difference between the resultant charges \( q_i \) calculated for the single terminal oxygen in H3PO4 and for the four equivalent terminal oxygens in PO4(-3) comes to -0.375, half (because \( u_{32} = -0.5 \)) the difference of -0.75 in the \( q_K^0 \) charges (i.e., 0.00 and -0.75, respectively) and reasonably in accord with the difference of -0.42 found by fitting the electrostatic potential.
| molgraph | The molecular graph for which to calculate partial atomic charges. |
| charges | The output array storing the calculated partial charges. |
| strict | If true, strict parameterization will be peformed that might fail. Otherwise, in case of parameterization problems, fallback strategies take effect. |
| const Util::DArray& CDPL::ForceField::MMFF94ChargeCalculator::getFormalCharges | ( | ) | const |
Returns the formal atomic charges assigned during the last calculation.
const reference to the array of formal charges.