Open Babel
3.0
|
#include <openbabel/atom.h>
Public Types | |
enum | StereoFlag |
Public Member Functions | |
OBAtom () | |
virtual | ~OBAtom () |
OBAtom & | operator= (OBAtom &) |
bool | operator== (const OBAtom *other) const |
void | Duplicate (OBAtom *) |
bool | Clear () |
double | GetDistance (int index) |
double | GetDistance (OBAtom *) |
double | GetDistance (vector3 *v) |
double | GetAngle (int b, int c) |
double | GetAngle (OBAtom *b, OBAtom *c) |
virtual OBBase * | DoTransformations (const std::map< std::string, std::string > *, OBConversion *) |
template<class T > | |
T * | CastAndClear (bool clear=true) |
virtual const char * | GetTitle (bool replaceNewlines=true) const |
virtual void | SetTitle (const char *) |
Methods to set atomic information | |
void | SetIdx (int idx) |
void | SetId (unsigned long id) |
void | SetHyb (int hyb) |
void | SetAtomicNum (int atomicnum) |
void | SetIsotope (unsigned int iso) |
void | SetImplicitHCount (unsigned int val) |
void | SetFormalCharge (int fcharge) |
void | SetSpinMultiplicity (short spin) |
void | SetType (const char *type) |
void | SetType (const std::string &type) |
void | SetPartialCharge (double pcharge) |
void | SetVector (const vector3 &v) |
void | SetVector (const double x, const double y, const double z) |
void | SetCoordPtr (double **c) |
void | SetVector () |
void | SetResidue (OBResidue *res) |
void | SetParent (OBMol *ptr) |
void | SetAromatic (bool value=true) |
void | SetInRing (bool value=true) |
void | ClearCoordPtr () |
Methods to retrieve atomic information | |
int | GetFormalCharge () const |
unsigned int | GetAtomicNum () const |
unsigned short int | GetIsotope () const |
int | GetSpinMultiplicity () const |
double | GetAtomicMass () const |
double | GetExactMass () const |
unsigned int | GetIdx () const |
unsigned int | GetIndex () const |
unsigned long | GetId () const |
unsigned int | GetCoordinateIdx () const |
unsigned int | GetExplicitDegree () const |
unsigned int | GetTotalDegree () const |
unsigned int | GetExplicitValence () const |
unsigned int | GetTotalValence () const |
unsigned int | GetHyb () const |
unsigned char | GetImplicitHCount () const |
unsigned int | GetHvyDegree () const |
unsigned int | GetHeteroDegree () const |
char * | GetType () |
double | GetX () const |
double | GetY () const |
double | GetZ () const |
double | x () const |
double | y () const |
double | z () const |
double * | GetCoordinate () |
vector3 & | GetVector () |
const vector3 & | GetVector () const |
double | GetPartialCharge () |
OBResidue * | GetResidue () |
OBMol * | GetParent () |
bool | GetNewBondVector (vector3 &v, double length) |
OBBond * | GetBond (OBAtom *) |
Iterator methods | |
OBBondIterator | BeginBonds () |
OBBondIterator | EndBonds () |
OBBond * | BeginBond (OBBondIterator &i) |
OBBond * | NextBond (OBBondIterator &i) |
OBAtom * | BeginNbrAtom (OBBondIterator &i) |
OBAtom * | NextNbrAtom (OBBondIterator &i) |
Addition of residue/bond info. for an atom | |
void | NewResidue () |
void | AddResidue (OBResidue *res) |
void | DeleteResidue () |
void | AddBond (OBBond *bond) |
void | InsertBond (OBBondIterator &i, OBBond *bond) |
bool | DeleteBond (OBBond *bond) |
void | ClearBond () |
Builder utilities | |
bool | HtoMethyl () |
bool | SetHybAndGeom (int) |
Property information | |
unsigned int | CountFreeOxygens () const |
unsigned int | CountFreeSulfurs () const |
unsigned int | ExplicitHydrogenCount (bool ExcludeIsotopes=false) const |
unsigned int | MemberOfRingCount () const |
unsigned int | MemberOfRingSize () const |
unsigned int | CountRingBonds () const |
double | SmallestBondAngle () |
double | AverageBondAngle () |
std::pair< int, int > | LewisAcidBaseCounts () const |
bool | HasResidue () |
bool | IsHetAtom () |
bool | IsAromatic () const |
bool | IsInRing () const |
bool | IsInRingSize (int) const |
bool | IsHeteroatom () |
bool | IsConnected (OBAtom *) |
bool | IsOneThree (OBAtom *) |
bool | IsOneFour (OBAtom *) |
bool | IsCarboxylOxygen () |
bool | IsPhosphateOxygen () |
bool | IsSulfateOxygen () |
bool | IsNitroOxygen () |
bool | IsAmideNitrogen () |
bool | IsPolarHydrogen () |
bool | IsNonPolarHydrogen () |
bool | IsAromaticNOxide () |
bool | IsChiral () |
bool | IsAxial () |
bool | IsHbondAcceptor () |
bool | IsHbondAcceptorSimple () |
bool | IsHbondDonor () |
bool | IsHbondDonorH () |
bool | IsMetal () |
bool | HasAlphaBetaUnsat (bool includePandS=true) |
bool | HasBondOfOrder (unsigned int bo) |
int | CountBondsOfOrder (unsigned int bo) |
int | HighestBondOrder () |
bool | HasNonSingleBond () |
bool | HasSingleBond () |
bool | HasDoubleBond () |
bool | HasAromaticBond () |
bool | MatchesSMARTS (const char *) |
Generic data handling methods (via OBGenericData) | |
bool | HasData (const std::string &) |
bool | HasData (const char *) |
bool | HasData (const unsigned int type) |
void | DeleteData (unsigned int type) |
void | DeleteData (OBGenericData *) |
void | DeleteData (std::vector< OBGenericData *> &) |
bool | DeleteData (const std::string &s) |
void | SetData (OBGenericData *d) |
void | CloneData (OBGenericData *d) |
size_t | DataSize () const |
OBGenericData * | GetData (const unsigned int type) |
OBGenericData * | GetData (const std::string &) |
OBGenericData * | GetData (const char *) |
std::vector< OBGenericData * > & | GetData () |
std::vector< OBGenericData * > | GetData (DataOrigin source) |
std::vector< OBGenericData * > | GetAllData (const unsigned int type) |
OBDataIterator | BeginData () |
OBDataIterator | EndData () |
Static Public Member Functions | |
static const char * | ClassDescription () |
Public Attributes | |
bool | Visit |
Protected Member Functions | |
int | GetFlag () const |
void | SetFlag (int flag) |
void | UnsetFlag (int flag) |
bool | HasFlag (int flag) |
Protected Attributes | |
unsigned char | _ele |
unsigned char | _imph |
char | _type [OBATOM_TYPE_LEN] |
short | _fcharge |
unsigned short | _isotope |
short | _spinmultiplicity |
unsigned int | _idx |
OBMol * | _parent |
std::vector< OBBond * > | _vbond |
unsigned int | _cidx |
unsigned short | _hyb |
unsigned short | _flags |
double | _pcharge |
double ** | _c |
vector3 | _v |
OBResidue * | _residue |
unsigned long | _id |
std::vector< OBGenericData * > | _vdata |
Atom class.
To understand the OBAtom class it is important to state a key decision on which the design was based. The OBAtom class not only holds data, but facilitates extraction of data perceived from both the atom and the molecule. This prevents the OBMol class from becoming overly large and complicated.
A number of data extraction methods perform what is called `Lazy Evaluation,' which is essentially on-the-fly evaluation. For example, when an atom is queried as to whether it is cyclic or what it's hybridization state is the information is perceived automatically. The perception of a particular trait is actually performed on the entire molecule the first time it is requested of an atom or bond, and stored for subsequent requests for the same trait of additional atoms or bonds.The OBAtom class is similar to OBMol and the whole of Open Babel in that data access and modification is done through Get and Set methods.
The following code demonstrates how to print out the atom numbers, element numbers, and coordinates of a molecule:
A number of the property member functions indicate that atoms have some knowledge of their covalently attached neighbor atoms. Bonding information is partly redundant within a molecule in that an OBMol has a complete list of bonds in a molecule, and an OBAtom has a list bonds of which it is a member. The following code demonstrates how an OBAtom uses its bond information to loop over atoms attached to itself:
should produce an output like
enum StereoFlag |
OBAtom | ( | ) |
Constructor.
|
virtual |
Destructor.
|
inlineprotected |
|
inlineprotected |
Sets the bitwise flag
.
|
inlineprotected |
Unsets the bitwise flag
.
|
inlineprotected |
flag
|
inline |
Equivalence.
void Duplicate | ( | OBAtom * | src | ) |
Duplicate another atom. Copies all information with the exception of index
Referenced by OBUnitCell::FillUnitCell().
|
virtual |
Clear all data. Calls OBBase::Clear() to handle any generic data.
Reimplemented from OBBase.
Referenced by OpenBabel::addFragment().
|
inline |
Set atom index (i.e., in an OBMol)
Referenced by OBMol::AddAtom(), OBMol::DeleteAtom(), OBMol::DeleteHydrogen(), OBMol::EndModify(), and OBMol::NewAtom().
|
inline |
Referenced by OBMol::AddAtom(), and OBMol::NewAtom().
|
inline |
Set atom hybridization (i.e., 1 = sp, 2 = sp2, 3 = sp3 ...)
Referenced by OBResidueData::AssignBonds(), OBAtomTyper::AssignHyb(), OBBuilder::GetNewBondVector(), and OBMol::PerceiveBondOrders().
|
inline |
Set atomic number.
Referenced by OpenBabel::addFragment(), OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OBChemTsfm::Apply(), AliasData::Expand(), OBAtom::HtoMethyl(), and OBAtom::SetHybAndGeom().
void SetIsotope | ( | unsigned int | iso | ) |
Set isotope number (actual atomic weight is tabulated automatically, 0 = most abundant)
Referenced by AliasData::Expand().
|
inline |
Set the implicit hydrogen count to val
.
Referenced by OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OBChemTsfm::Apply(), OBMol::DeleteHydrogens(), and OpenBabel::OBAtomAssignTypicalImplicitHydrogens().
|
inline |
Set the formal charge of the atom to fcharge
.
Referenced by OpenBabel::addFragment(), OBChemTsfm::Apply(), OBBondTyper::AssignFunctionalGroupBonds(), OBMol::ConvertDativeBonds(), OBMol::ConvertZeroBonds(), AliasData::Expand(), OBMol::MakeDativeBonds(), and OBMol::PerceiveBondOrders().
|
inline |
Set the atomic spin to spin
. See _spinmultiplicity.
Referenced by OpenBabel::addFragment(), and AliasData::Expand().
void SetType | ( | const char * | type | ) |
Set the atomic type symbol (see OBTypeTable and OBAtomTyper for more)
Referenced by OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OBResidueData::AssignBonds(), OBAtomTyper::AssignTypes(), OBForceField::GetGrid(), OBAtom::HtoMethyl(), and OBAtom::SetHybAndGeom().
void SetType | ( | const std::string & | type | ) |
Set the atomic type symbol (see OBTypeTable and OBAtomTyper for more)
|
inline |
Set the partial charge to pcharge
.
Referenced by OBGastChrg::AssignPartialCharges(), OBPhModel::AssignSeedPartialCharge(), OBForceField::GetGrid(), and OBAtom::GetPartialCharge().
void SetVector | ( | const vector3 & | v | ) |
Set the coordinate vector for this atom to v
as a vector3.
Referenced by OpenBabel::addFragment(), OBMol::AddNewHydrogens(), OBMol::Align(), OpenBabel::ApplyRotMatToBond(), OBMol::BeginModify(), OBBuilder::Build(), OBMol::Center(), OBBuilder::Connect(), OBDepict::DrawMolecule(), AliasData::Expand(), OBUnitCell::FillUnitCell(), OpenBabel::generateDiagram(), OBForceField::GetCoordinates(), OpenBabel::groupRedraw(), OBAtom::HtoMethyl(), OpenBabel::InternalToCartesian(), OBBuilder::IsSpiroAtom(), OBForceField::LineSearch(), OBForceField::NumericalDerivative(), OBForceField::NumericalSecondDerivative(), OBForceField::SetConformers(), OBForceField::SetCoordinates(), OBAtom::SetHybAndGeom(), OBBond::SetLength(), OBPointGroup::Symmetrize(), OBForceField::ValidateConjugateGradients(), OBForceField::ValidateLineSearch(), and OBForceField::ValidateSteepestDescent().
void SetVector | ( | const double | x, |
const double | y, | ||
const double | z | ||
) |
Set the coordinate vector for this atom based on x
y
& z
.
|
inline |
Set the position of this atom from a pointer-driven array of coordinates.
Referenced by OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OBMol::ConnectTheDots(), OBMol::EndModify(), and OBMol::SetCoordinates().
void SetVector | ( | ) |
Set the position of this atom based on the internal pointer array (i.e. from SetCoordPtr() )
|
inline |
Attach an OBResidue res
as containing this atom.
Referenced by OBResidue::AddAtom(), and OBResidue::RemoveAtom().
|
inline |
Attach an OBMol ptr
as the parent container for this atom.
Referenced by OBMol::AddAtom(), and OBMol::NewAtom().
|
inline |
Mark atom as being aromatic.
Referenced by OBAromaticTyper::AssignAromaticFlags(), and OpenBabel::AssignOBAromaticityModel().
|
inline |
Mark an atom as belonging to at least one ring.
Referenced by OpenBabel::FindRings().
|
inline |
Clear the internal coordinate pointer.
Referenced by OBMol::BeginModify(), and OBMol::ConnectTheDots().
|
inline |
Referenced by OpenBabel::alternate(), OBChemTsfm::Apply(), OpenBabel::AssignOBAromaticityModel(), OBGastChrg::AssignPartialCharges(), OpenBabel::AssignRadicalDots(), OpenBabel::ComparePairSecond(), OBMol::ConnectTheDots(), OBMol::ConvertDativeBonds(), OBMol::ConvertZeroBonds(), OBDepict::DrawMolecule(), OBSmartsMatcher::EvalAtomExpr(), OBChargeModel::FillChargeVectors(), OpenBabel::findMetalloceneBonds(), OBMol::GetTotalCharge(), OpenBabel::HasExocyclicBondToOxygenMinus(), OpenBabel::intToStr(), OpenBabel::IsSpecialCase(), OpenBabel::IsSuppressibleHydrogen(), OBMol::MakeDativeBonds(), OpenBabel::NeedsDoubleBond(), OpenBabel::OBAtomAssignTypicalImplicitHydrogens(), and OBMol::PerceiveBondOrders().
|
inline |
Referenced by OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OpenBabel::alternate(), OBAromaticTyper::AssignAromaticFlags(), OBResidueData::AssignBonds(), OBBondTyper::AssignFunctionalGroupBonds(), OpenBabel::AssignOBAromaticityModel(), OBGastChrg::AssignPartialCharges(), OpenBabel::AssignRadicalDots(), OpenBabel::AtomIsNSOP(), OpenBabel::ComparePairSecond(), OBBuilder::Connect(), OBMol::ConnectTheDots(), OBMol::ConvertZeroBonds(), OBAtom::CountFreeOxygens(), OBAtom::CountFreeSulfurs(), OBMol::DeleteAtom(), OBMol::DeleteHydrogen(), OBMol::DeleteHydrogens(), OBDepict::DrawMolecule(), OBSmartsMatcher::EvalAtomExpr(), OBAtom::ExplicitHydrogenCount(), OpenBabel::findMetalloceneBonds(), OBMol::FindTorsions(), OpenBabel::GetCorrectedBondVector(), OpenBabel::GetDFFVector(), OBBond::GetEquibLength(), OBMol::GetGIVector(), OBMol::GetGTDVector(), OpenBabel::GetHeavyAtomCoords(), OBAtom::GetHvyDegree(), OBRing::GetRootAtom(), OBRotorRules::GetRotorIncrements(), OBMol::GetTotalSpinMultiplicity(), OBAtom::HasAlphaBetaUnsat(), OpenBabel::HasExocyclicBondToOxygenMinus(), OBAtom::HtoMethyl(), OpenBabel::intToStr(), OBAtom::IsAromaticNOxide(), OpenBabel::isFerroceneBond(), OBStericConformerFilter::IsGood(), OBAtom::IsHbondDonor(), OBAtom::IsNonPolarHydrogen(), OpenBabel::IsNotCorH(), OBAtom::IsPolarHydrogen(), OpenBabel::IsSpecialCase(), OpenBabel::IsSulfoneOxygen(), OBMol::MakeDativeBonds(), OBQueryAtom::Matches(), OpenBabel::NeedsDoubleBond(), OBMol::NumHvyAtoms(), OpenBabel::OBAtomAssignTypicalImplicitHydrogens(), OBMol::PerceiveBondOrders(), OBChainsParser::PerceiveChains(), OBRotorList::RemoveSymVals(), OBAtom::SetHybAndGeom(), OBAlign::SetRefMol(), OBAlign::SetTargetMol(), OpenBabel::validAdditionalBond(), and OBChainsParser::~OBChainsParser().
|
inline |
Referenced by OBDepict::DrawMolecule(), OBSmartsMatcher::EvalAtomExpr(), OBAtom::ExplicitHydrogenCount(), OpenBabel::findMetalloceneBonds(), and OpenBabel::IsSuppressibleHydrogen().
|
inline |
Referenced by OpenBabel::alternate(), OpenBabel::AssignRadicalDots(), OpenBabel::findMetalloceneBonds(), OBMol::GetTotalSpinMultiplicity(), and OpenBabel::intToStr().
double GetAtomicMass | ( | ) | const |
Referenced by OBMol::GetMolWt(), and OBMol::ToInertialFrame().
double GetExactMass | ( | ) | const |
Referenced by OBMol::GetExactMass().
|
inline |
Referenced by OBMol::AddAtom(), OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OBMol::Align(), OpenBabel::ApplyRotMatToBond(), OBMol::AreInSameRing(), OBAromaticTyper::AssignAromaticFlags(), OBResidueData::AssignBonds(), OpenBabel::AssignOBAromaticityModel(), OBGastChrg::AssignPartialCharges(), OBBuilder::Build(), OpenBabel::BuildOBRTreeVector(), OpenBabel::CanonicalLabels(), OpenBabel::CartesianToInternal(), OpenBabel::ComparePairSecond(), OBBuilder::Connect(), OBMol::ConnectTheDots(), OBMol::ContigFragList(), OBMol::CopySubstructure(), OBBuilder::CorrectStereoAtoms(), OpenBabel::CreateNewClassVector(), OBMolAtomBFSIter::CurrentDepth(), OBMol::DeleteAtom(), OBMol::DeleteHydrogen(), OBSmartsMatcher::EvalAtomExpr(), AliasData::Expand(), OBSmartsMatcher::FastSingleMatch(), OBMol::FindChildren(), OBMol::FindLargestFragment(), OpenBabel::FindRings(), OBBond::GetBeginAtomIdx(), OpenBabel::GetDFFVector(), OBBond::GetEndAtomIdx(), OpenBabel::getFragment(), OBBuilder::GetFragment(), OBForceField::GetGradient(), OBForceField::GetGrid(), OBMol::GetGTDVector(), OBBond::GetNbrAtomIdx(), OBMol::GetNextFragment(), OBRotorRules::GetRotorIncrements(), OBGraphSym::GetSymmetry(), OBGrid::Init(), OpenBabel::InternalToCartesian(), OBRotorList::IsFixedBond(), OBForceField::IsInSameRing(), OBRing::IsMember(), OBBuilder::IsSpiroAtom(), OBSSMatch::Match(), OBAtom::MatchesSMARTS(), OpenBabel::NeedsDoubleBond(), OBMol::NewAtom(), OpenBabel::OBBondGetSmallestRingSize(), OBMolAtomBFSIter::OBMolAtomBFSIter(), OBMolAtomDFSIter::OBMolAtomDFSIter(), OBMolPairIter::OBMolPairIter(), OBMolAtomDFSIter::operator++(), OBMolAtomBFSIter::operator++(), OBMolPairIter::operator++(), OBAtom::operator=(), OBMol::operator=(), OBAtom::operator==(), OBChainsParser::PerceiveChains(), OBRotorList::RemoveSymVals(), OBMol::RenumberAtoms(), OBRotorList::SetEvalAtoms(), OBAtom::SetHybAndGeom(), OBBond::SetLength(), OBMol::SetTorsion(), OBProxGrid::Setup(), OBSmartsMatcher::SetupAtomMatchTable(), OBFFCalculation2::SetupPointers(), OBFFCalculation3::SetupPointers(), OBFFCalculation4::SetupPointers(), and OBForceField::UpdatePairsSimple().
|
inline |
|
inline |
|
inline |
Referenced by OBMol::DeleteHydrogen(), OpenBabel::SetRotorToAngle(), and OBMol::SetTorsion().
|
inline |
Referenced by OBMol::AddBond(), OBResidueData::AssignBonds(), OBAtomTyper::AssignHyb(), OpenBabel::AssignOBAromaticityModel(), OBGastChrg::AssignPartialCharges(), OBMol::ConnectTheDots(), OBDepict::DrawMolecule(), OBSmartsMatcher::EvalAtomExpr(), OpenBabel::GetLabelAlignment(), OBBuilder::GetNewBondVector(), OBRing::GetRootAtom(), OpenBabel::isFerroceneBond(), OBMol::PerceiveBondOrders(), and OBRotorList::RemoveSymVals().
|
inline |
Referenced by OpenBabel::ComparePairSecond(), OBSmartsMatcher::EvalAtomExpr(), OBBond::IsAmide(), OBBond::IsPrimaryAmide(), OBBond::IsSecondaryAmide(), OpenBabel::IsSpecialCase(), OBBond::IsTertiaryAmide(), and OpenBabel::NeedsDoubleBond().
unsigned int GetExplicitValence | ( | ) | const |
Referenced by OpenBabel::AssignOBAromaticityModel(), OBMol::ConnectTheDots(), OBRing::GetRootAtom(), OBMol::MakeDativeBonds(), OpenBabel::OBAtomAssignTypicalImplicitHydrogens(), OBMol::PerceiveBondOrders(), and OpenBabel::validAdditionalBond().
unsigned int GetTotalValence | ( | ) | const |
Referenced by OpenBabel::AssignRadicalDots(), and OBSmartsMatcher::EvalAtomExpr().
unsigned int GetHyb | ( | ) | const |
Referenced by OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OBAtomTyper::AssignHyb(), OBGastChrg::AssignPartialCharges(), OBBuilder::Build(), OBBuilder::Connect(), OBSmartsMatcher::EvalAtomExpr(), OBBond::GetEquibLength(), OBBuilder::GetNewBondVector(), OBRotorRules::GetRotorIncrements(), OBAtom::HtoMethyl(), OBAtom::IsAxial(), OBMol::PerceiveBondOrders(), OBRotorList::RemoveSymVals(), and OBAtom::SetHybAndGeom().
|
inline |
Referenced by OBMol::AddHydrogens(), OBMol::AddNewHydrogens(), OBChemTsfm::Apply(), OpenBabel::AssignOBAromaticityModel(), OBMol::ConvertZeroBonds(), OBMol::DeleteHydrogens(), OBDepict::DrawMolecule(), OBSmartsMatcher::EvalAtomExpr(), OBMol::GetExactMass(), OBMol::GetGIVector(), OBMol::GetMolWt(), and OpenBabel::TotalHydrogenCount().
unsigned int GetHvyDegree | ( | ) | const |
Referenced by OBGastChrg::AssignPartialCharges(), OBAtom::CountFreeOxygens(), OBAtom::CountFreeSulfurs(), OBMol::GetGIVector(), OBBond::IsPrimaryAmide(), OBBond::IsSecondaryAmide(), OBBuilder::IsSpiroAtom(), OpenBabel::IsSulfoneOxygen(), OpenBabel::IsSuppressibleHydrogen(), OBBond::IsTertiaryAmide(), and OBChainsParser::PerceiveChains().
unsigned int GetHeteroDegree | ( | ) | const |
char * GetType | ( | ) |
Referenced by OBGastChrg::AssignPartialCharges(), and OBAtomTyper::AssignTypes().
|
inline |
Referenced by OBDepict::DrawMolecule(), OBBond::GetLength(), OBGrid::Init(), and OpenBabel::intToStr().
|
inline |
Referenced by OBDepict::DrawMolecule(), OBBond::GetLength(), OBGrid::Init(), and OpenBabel::intToStr().
|
inline |
Referenced by OBDepict::DrawMolecule(), OBBond::GetLength(), and OBGrid::Init().
|
inline |
Referenced by OBMol::Center(), OBMol::Has2D(), OBMol::Has3D(), OBMol::ToInertialFrame(), OBForceField::ValidateConjugateGradients(), OBForceField::ValidateLineSearch(), and OBForceField::ValidateSteepestDescent().
|
inline |
Referenced by OBMol::Center(), OBMol::Has2D(), OBMol::Has3D(), OBMol::ToInertialFrame(), OBForceField::ValidateConjugateGradients(), OBForceField::ValidateLineSearch(), and OBForceField::ValidateSteepestDescent().
|
inline |
Referenced by OBMol::Center(), OBMol::Has2D(), OBMol::Has3D(), OBMol::ToInertialFrame(), and OBForceField::ValidateConjugateGradients().
|
inline |
See SetCoordPtr() for more. If no coordinate pointer is used (e.g., only vector3), NULL will be returned.
Referenced by OBForceField::GetGrid(), OBFFCalculation2::SetupPointers(), OBFFCalculation3::SetupPointers(), OBFFCalculation4::SetupPointers(), and OBForceField::UpdatePairsSimple().
vector3 & GetVector | ( | ) |
Referenced by OBMol::Align(), OpenBabel::ApplyRotMatToBond(), OBAtom::AverageBondAngle(), OBBuilder::Build(), OpenBabel::CartesianToInternal(), OBMol::Center(), OBBuilder::Connect(), OBMol::ConnectTheDots(), OBDepict::DrawMolecule(), OBAtom::Duplicate(), OBMol::EndModify(), AliasData::Expand(), OBAlign::GetAlignment(), OBAtom::GetAngle(), OBAtom::GetDistance(), OpenBabel::GetLabelAlignment(), OBBuilder::GetNewBondVector(), OBMol::GetTorsion(), OBMol::HasNonZeroCoords(), OBBond::IsDoubleBondGeometry(), OBBuilder::IsSpiroAtom(), OBForceField::LineSearch(), OBForceField::NumericalDerivative(), OBForceField::NumericalSecondDerivative(), OBAtom::SetHybAndGeom(), OBBond::SetLength(), OBAlign::SetRefMol(), OBAlign::SetTargetMol(), OBMol::SetTorsion(), OBAtom::SmallestBondAngle(), OBBuilder::Swap(), and OBForceField::ValidateLineSearch().
double GetPartialCharge | ( | ) |
Referenced by OBGastChrg::AssignPartialCharges(), OBChargeModel::FillChargeVectors(), and OBForceField::GetPartialCharges().
OBResidue * GetResidue | ( | ) |
Referenced by OBMol::AddNewHydrogens(), OBResidueData::AssignBonds(), OBMol::CopySubstructure(), and OBResidue::GetBonds().
|
inline |
Referenced by OpenBabel::addNbrs(), OpenBabel::BuildOBRTreeVector(), OBSmartsMatcher::EvalAtomExpr(), OpenBabel::findMetalloceneBonds(), OpenBabel::GetAtomSymClass(), OBBuilder::GetNewBondVector(), and OBBond::SetLength().
bool GetNewBondVector | ( | vector3 & | v, |
double | length | ||
) |
Create a vector for a new bond from this atom, with length given by the supplied parameter
Referenced by OBBondTyper::AssignFunctionalGroupBonds(), OBBuilder::Build(), OBBuilder::GetNewBondVector(), and OBMol::PerceiveBondOrders().
|
inline |
Referenced by OBResidueData::AssignBonds().
|
inline |
OBBond * BeginBond | ( | OBBondIterator & | i | ) |
Set the iterator i
to the beginning of the bonds
Referenced by OpenBabel::ComparePairSecond(), OBMol::ConnectTheDots(), OBMol::ContigFragList(), OBMol::ConvertDativeBonds(), OBMol::FindLargestFragment(), OpenBabel::FindRings(), OBResidue::GetBonds(), OpenBabel::GetDFFVector(), OBMol::GetGTDVector(), OBBond::IsAmide(), OBAtom::IsAmideNitrogen(), OBBond::IsEster(), OBAtom::IsOneFour(), OBAtom::IsOneThree(), OBBond::IsPrimaryAmide(), OBBond::IsSecondaryAmide(), OpenBabel::IsSulfoneOxygen(), OBBond::IsTertiaryAmide(), and OBMol::MakeDativeBonds().
OBBond * NextBond | ( | OBBondIterator & | i | ) |
Increment the iterator i
Referenced by OpenBabel::ComparePairSecond(), OBMol::ConnectTheDots(), OBMol::ContigFragList(), OBMol::ConvertDativeBonds(), OBMol::FindLargestFragment(), OpenBabel::FindRings(), OBResidue::GetBonds(), OpenBabel::GetDFFVector(), OBMol::GetGTDVector(), OBBond::IsAmide(), OBAtom::IsAmideNitrogen(), OBBond::IsEster(), OBAtom::IsOneFour(), OBAtom::IsOneThree(), OBBond::IsPrimaryAmide(), OBBond::IsSecondaryAmide(), OpenBabel::IsSulfoneOxygen(), OBBond::IsTertiaryAmide(), and OBMol::MakeDativeBonds().
OBAtom * BeginNbrAtom | ( | OBBondIterator & | i | ) |
Set the iterator i
to the beginning of the bonds
Referenced by OBMol::AddBond(), OBAromaticTyper::AssignAromaticFlags(), OBAtomTyper::AssignTypes(), OpenBabel::BuildOBRTreeVector(), OpenBabel::ComparePairSecond(), OBMol::DeleteAtom(), OBMol::DeleteHydrogen(), OBMol::DeleteHydrogens(), AliasData::Expand(), OBSmartsMatcher::FastSingleMatch(), OBMol::FindChildren(), OBMol::FindTorsions(), OBMol::GetBond(), OpenBabel::GetLabelAlignment(), OBBuilder::GetNewBondVector(), OBRotorRules::GetRotorIncrements(), OBAtom::HasAlphaBetaUnsat(), OBAtom::IsAxial(), OBBond::IsDoubleBondGeometry(), OBRotorList::IsFixedBond(), OBSSMatch::Match(), OBMolAtomBFSIter::OBMolAtomBFSIter(), OBMolAtomDFSIter::OBMolAtomDFSIter(), OBMolAtomDFSIter::operator++(), OBMolAtomBFSIter::operator++(), OBMol::PerceiveBondOrders(), OBChainsParser::PerceiveChains(), and OBRotorList::SetEvalAtoms().
OBAtom * NextNbrAtom | ( | OBBondIterator & | i | ) |
Increment the iterator i
Referenced by OBAromaticTyper::AssignAromaticFlags(), OBAtomTyper::AssignTypes(), OpenBabel::BuildOBRTreeVector(), OpenBabel::ComparePairSecond(), OBMol::DeleteAtom(), OBMol::DeleteHydrogen(), OBMol::DeleteHydrogens(), AliasData::Expand(), OBAtom::ExplicitHydrogenCount(), OBSmartsMatcher::FastSingleMatch(), OBMol::FindChildren(), OBMol::FindTorsions(), OBMol::GetBond(), OpenBabel::GetLabelAlignment(), OBBuilder::GetNewBondVector(), OBRotorRules::GetRotorIncrements(), OBAtom::HasAlphaBetaUnsat(), OBAtom::IsAxial(), OBRotorList::IsFixedBond(), OBSSMatch::Match(), OBMolAtomBFSIter::OBMolAtomBFSIter(), OBMolAtomDFSIter::OBMolAtomDFSIter(), OBMolAtomDFSIter::operator++(), OBMolAtomBFSIter::operator++(), OBMol::PerceiveBondOrders(), OBChainsParser::PerceiveChains(), and OBRotorList::SetEvalAtoms().
double GetDistance | ( | int | index | ) |
Referenced by OBBondTyper::AssignFunctionalGroupBonds().
double GetDistance | ( | vector3 * | v | ) |
double GetAngle | ( | int | b, |
int | c | ||
) |
Referenced by OBMol::GetAngle().
|
inline |
If no residue has been set for this atom, create a new one.
|
inline |
Add (set) the residue for this atom.
|
inline |
Delete any residue associated with this atom.
|
inline |
Add a bond to the internal list. Does not update the bond.
Referenced by OBMol::AddBond(), and OBBuilder::Connect().
|
inline |
Insert bond
into the internal list at the position from i
Does not modify the bond.
Referenced by OBMol::AddBond().
bool DeleteBond | ( | OBBond * | bond | ) |
Find bond
and remove it from the internal list. Does not update the bond.
|
inline |
Clear all bonding information in this atom (does not delete them)
bool HtoMethyl | ( | ) |
If this is a hydrogen atom, transform into a methyl group.
bool SetHybAndGeom | ( | int | hyb | ) |
Change the hybridization of this atom and modify the geometry accordingly
unsigned int CountFreeOxygens | ( | ) | const |
Referenced by OBGastChrg::AssignPartialCharges(), OBAtom::IsCarboxylOxygen(), OBAtom::IsNitroOxygen(), OBAtom::IsPhosphateOxygen(), OBAtom::IsSulfateOxygen(), and OpenBabel::IsSulfoneOxygen().
unsigned int CountFreeSulfurs | ( | ) | const |
Referenced by OBAtom::IsCarboxylOxygen().
unsigned int ExplicitHydrogenCount | ( | bool | ExcludeIsotopes = false | ) | const |
Referenced by OBSmartsMatcher::EvalAtomExpr(), OBMol::PerceiveBondOrders(), and OpenBabel::TotalHydrogenCount().
unsigned int MemberOfRingCount | ( | ) | const |
Referenced by OBSmartsMatcher::EvalAtomExpr().
unsigned int MemberOfRingSize | ( | ) | const |
unsigned int CountRingBonds | ( | ) | const |
Referenced by OBSmartsMatcher::EvalAtomExpr().
double SmallestBondAngle | ( | ) |
Referenced by OBMol::ConnectTheDots().
double AverageBondAngle | ( | ) |
Referenced by OBBondTyper::AssignFunctionalGroupBonds(), and OBMol::PerceiveBondOrders().
pair< int, int > LewisAcidBaseCounts | ( | ) | const |
Lewis acid/base vacancies for this atom
The returned values count whole lone pairs, so the acid count is the number of electron pairs desired and the base count is the number of electron pairs available.
Algorithm from: Clark, A. M. Accurate Specification of Molecular Structures: The Case for Zero-Order Bonds and Explicit Hydrogen Counting. Journal of Chemical Information and Modeling, 51, 3149-3157 (2011). http://pubs.acs.org/doi/abs/10.1021/ci200488k
Referenced by OBMol::ConvertZeroBonds().
|
inline |
Referenced by OBMol::AddNewHydrogens().
|
inline |
bool IsAromatic | ( | ) | const |
Referenced by OpenBabel::ComparePairSecond(), OBSmartsMatcher::EvalAtomExpr(), OBMol::GetGIVector(), OBQueryAtom::Matches(), and OpenBabel::NeedsDoubleBond().
bool IsInRing | ( | ) | const |
Referenced by OBAromaticTyper::AssignAromaticFlags(), OpenBabel::AssignOBAromaticityModel(), OBBuilder::Connect(), OBSmartsMatcher::EvalAtomExpr(), OpenBabel::findMetalloceneBonds(), OBMol::GetGIVector(), OBAtom::IsAxial(), OBQueryAtom::Matches(), and OBMol::PerceiveBondOrders().
bool IsInRingSize | ( | int | size | ) | const |
Referenced by OBSmartsMatcher::EvalAtomExpr(), and OpenBabel::findMetalloceneBonds().
bool IsHeteroatom | ( | ) |
Referenced by OpenBabel::alternate(), and OBAtom::GetHeteroDegree().
bool IsConnected | ( | OBAtom * | a1 | ) |
Referenced by OBAromaticTyper::AssignAromaticFlags(), OBMol::ConnectTheDots(), OBStericConformerFilter::IsGood(), OBMolPairIter::OBMolPairIter(), and OBMolPairIter::operator++().
bool IsOneThree | ( | OBAtom * | a1 | ) |
Referenced by OBMolPairIter::OBMolPairIter(), and OBMolPairIter::operator++().
bool IsOneFour | ( | OBAtom * | a1 | ) |
bool IsCarboxylOxygen | ( | ) |
Referenced by OBGastChrg::AssignPartialCharges(), and OBBuilder::GetNewBondVector().
bool IsPhosphateOxygen | ( | ) |
Referenced by OBGastChrg::AssignPartialCharges().
bool IsSulfateOxygen | ( | ) |
Referenced by OBGastChrg::AssignPartialCharges().
bool IsNitroOxygen | ( | ) |
bool IsAmideNitrogen | ( | ) |
Returns true if nitrogen is part of an amide.
bool IsPolarHydrogen | ( | ) |
Referenced by OBMol::DeletePolarHydrogens().
bool IsNonPolarHydrogen | ( | ) |
Referenced by OBMol::DeleteNonPolarHydrogens().
bool IsAromaticNOxide | ( | ) |
bool IsChiral | ( | ) |
bool IsAxial | ( | ) |
bool IsHbondAcceptor | ( | ) |
bool IsHbondAcceptorSimple | ( | ) |
bool IsHbondDonor | ( | ) |
Referenced by OBAtom::IsHbondDonorH().
bool IsHbondDonorH | ( | ) |
bool IsMetal | ( | ) |
bool HasAlphaBetaUnsat | ( | bool | includePandS = true | ) |
includePandS | Whether to include phosphorus and sulfur neighbors in this determination (or to exclude them) |
This can be sketched as follows
where a and b are the 'apha' and 'beta' atoms, respectively and '*' indicates the current atom.
bool HasBondOfOrder | ( | unsigned int | bo | ) |
bo
Referenced by OBMol::PerceiveBondOrders().
int CountBondsOfOrder | ( | unsigned int | bo | ) |
bo
int HighestBondOrder | ( | ) |
bool HasNonSingleBond | ( | ) |
Referenced by OBMol::PerceiveBondOrders().
|
inline |
|
inline |
Referenced by OBBondTyper::AssignFunctionalGroupBonds().
|
inline |
bool MatchesSMARTS | ( | const char * | pattern | ) |
|
inlinevirtualinherited |
Perform a set of transformations specified by the user
Typically these are program options to filter or modify an object For example, see OBMol::DoTransformations() and OBMol::ClassDescription() Base type does nothing
Reimplemented in OBMol.
|
inlinestaticinherited |
|
inlineinherited |
By default clears the object. Called from ReadMolecule of most format classes.
|
inlinevirtualinherited |
Base type does nothing Made virtual around r3535 to simplify code which passes around OBBase*.
Reimplemented in OBMol.
Referenced by OBMoleculeFormat::DoOutputOptions().
|
inlinevirtualinherited |
Reimplemented in OBMol.
Referenced by OBMoleculeFormat::DoOutputOptions().
|
inherited |
Referenced by OBDepict::AddAtomLabels(), OBDepict::DrawMolecule(), AliasData::Expand(), OBForceField::GetAtomTypes(), OBForceField::GetConformers(), OBForceField::GetCoordinates(), OBMol::GetEnergies(), OBMol::GetEnergy(), OBForceField::GetPartialCharges(), OBDescriptor::MatchPairData(), OBMoleculeFormat::ReadChemObjectImpl(), and OBMol::SetEnergies().
|
inherited |
|
inherited |
|
inherited |
Delete any data matching the given OBGenericDataType.
Referenced by OpenBabel::CanonicalLabels(), OBDescriptor::DeleteProperties(), OpenBabel::DeleteStereoOnAtom(), and OBMol::RenumberAtoms().
|
inherited |
Delete the given generic data from this object.
|
inherited |
Delete all of the given generic data from this object.
|
inherited |
Deletes the generic data with the specified attribute, returning false if not found.
|
inlineinherited |
Adds a data object; does nothing if d==NULL.
Referenced by OBGastChrg::AssignPartialCharges(), OBMol::CopySubstructure(), AliasData::Expand(), OBForceField::GetAtomTypes(), OBForceField::GetConformers(), OBForceField::GetCoordinates(), OBMol::GetEnergies(), OBMol::GetEnergy(), OBForceField::GetPartialCharges(), OBMoleculeFormat::MakeCombinedMolecule(), OBDescriptor::PredictAndSave(), AliasData::RevertToAliasForm(), and OBMol::SetEnergies().
|
inherited |
Adds a copy of a data object; does nothing if d == NULL
Referenced by AliasData::Expand().
|
inlineinherited |
|
inherited |
Referenced by OBDepict::AddAtomLabels(), OBDepict::DrawMolecule(), OpenBabel::extract_thermochemistry(), OBDescriptor::FilterCompare(), OpenBabel::GetAtomSymClass(), OBForceField::GetAtomTypes(), OBForceField::GetConformers(), OBForceField::GetCoordinates(), OBForceField::GetPartialCharges(), OBDescriptor::GetValues(), OpenBabel::IsSuppressibleHydrogen(), OBMoleculeFormat::MakeCombinedMolecule(), OBMolAngleIter::OBMolAngleIter(), OBMolRingIter::OBMolRingIter(), OBMolTorsionIter::OBMolTorsionIter(), and OBDescriptor::PredictAndSave().
|
inherited |
|
inherited |
|
inlineinherited |
Referenced by OBMol::GetEnergies(), OBMol::GetEnergy(), and OBMol::SetEnergies().
|
inherited |
|
inherited |
Referenced by OpenBabel::CanonicalLabels(), OBMol::CopySubstructure(), OBBuilder::CorrectStereoAtoms(), OBBuilder::CorrectStereoBonds(), OpenBabel::DeleteStereoOnAtom(), and OBMol::operator+=().
|
inlineinherited |
Referenced by OBMol::AddBond(), OBAtom::Duplicate(), OBMoleculeFormat::MakeCombinedMolecule(), and OBMol::operator=().
|
inlineinherited |
Referenced by OBMol::AddBond(), OBAtom::Duplicate(), OBMoleculeFormat::MakeCombinedMolecule(), and OBMol::operator=().
|
protected |
atomic number (type unsigned char to minimize space – allows for 0..255 elements)
Referenced by OBAtom::Duplicate().
|
protected |
number of implicit hydrogens
Referenced by OBAtom::Duplicate().
|
protected |
atomic type
Referenced by OBAtom::Duplicate().
|
protected |
formal charge
Referenced by OBAtom::Duplicate().
|
protected |
isotope (0 = most abundant)
Referenced by OBAtom::Duplicate().
|
protected |
atomic spin, e.g., 2 for radical 1 or 3 for carbene
Referenced by OBAtom::Duplicate().
|
protected |
parent molecule (if any)
|
protected |
bonds to this atom – assumed to be one of the endpoints
|
protected |
index into coordinate array
|
protected |
hybridization
Referenced by OBAtom::Duplicate().
|
protected |
bitwise flags (e.g. aromaticity)
Referenced by OBAtom::Duplicate().
|
protected |
partial charge
Referenced by OBAtom::Duplicate().
|
protected |
coordinate array in double*
|
mutableprotected |
coordinate vector
|
protected |
parent residue (if applicable)
|
protected |
unique id
Referenced by OBAtom::Duplicate().
bool Visit |
Used internally by graph traversal algorithms.
|
protectedinherited |
Custom data.
Referenced by OBMol::OBMol().