Open Babel
3.0
|
#include <openbabel/rotamer.h>
Public Member Functions | |
OBRotamerList () | |
virtual OBGenericData * | Clone (OBBase *parent) const |
~OBRotamerList () | |
void | Setup (OBMol &, OBRotorList &) |
void | Setup (OBMol &mol, unsigned char *ref, int nrotors) |
unsigned int | NumRotors () const |
unsigned int | NumRotamers () const |
void | AddRotamer (double *) |
void | AddRotamer (int *key) |
void | AddRotamer (std::vector< int > key) |
void | AddRotamer (unsigned char *key) |
void | AddRotamers (unsigned char *arr, int nconf) |
void | GetReferenceArray (unsigned char *) const |
std::vector< double * > | CreateConformerList (OBMol &mol) |
void | ExpandConformerList (OBMol &mol, std::vector< double *> &confs) |
bool | SetCurrentCoordinates (OBMol &mol, std::vector< int > arr) |
void | SetBaseCoordinateSets (OBMol &mol) |
void | SetBaseCoordinateSets (std::vector< double *> bc, unsigned int N) |
unsigned int | NumBaseCoordinateSets () const |
double * | GetBaseCoordinateSet (unsigned int i) const |
unsigned int | NumAtoms () const |
void | SetAttribute (const std::string &v) |
void | SetOrigin (const DataOrigin s) |
virtual const std::string & | GetAttribute () const |
unsigned int | GetDataType () const |
virtual const std::string & | GetValue () const |
virtual DataOrigin | GetOrigin () const |
Iterator methods | |
std::vector< unsigned char * >::iterator | BeginRotamer () |
std::vector< unsigned char * >::iterator | EndRotamer () |
Protected Attributes | |
std::string | _attr |
unsigned int | _type |
DataOrigin | _source |
Supports a set of rotamer coordinate sets for some number of potentially rotatable bonds.
A high-level class for rotamer / conformer generation, intended mainly for use with the related class OBRotorList and the OBRotorRules database
Rotamers represent conformational isomers formed simply by rotation of dihedral angles. On the other hand, conformers may include geometric relaxation (i.e., slight modification of bond lengths, bond angles, etc.)
The following shows an example of generating 2 conformers using different rotor states. Similar code could be used for systematic or Monte Carlo conformer sampling when combined with energy evaluation (molecular mechanics or otherwise).
|
inline |
~OBRotamerList | ( | ) |
|
virtual |
Reimplemented from OBGenericData.
void Setup | ( | OBMol & | mol, |
OBRotorList & | rl | ||
) |
Set up a rotamer list based on an already created OBRotorList.
Referenced by OBRotamerList::Clone(), OBForceField::FastRotorSearch(), OBConformerSearch::GetConformers(), OBForceField::RandomRotorSearchInitialize(), OBConformerSearch::Setup(), OBForceField::SystematicRotorSearchInitialize(), OpenBabel::UpdateConformersFromTree(), and OBForceField::WeightedRotorSearch().
void Setup | ( | OBMol & | mol, |
unsigned char * | ref, | ||
int | nrotors | ||
) |
Set up a rotamer list based on the supplied reference atoms and the number of rotors
mol | The molecule to evaluate |
ref | An array of the 4 dihedral atoms for each rotor |
nrotors | The number of rotors (i.e., the size of ref / 4) |
|
inline |
|
inline |
void AddRotamer | ( | double * | c | ) |
Add a rotamer to the list based on the supplied coordinate set as a double*.
Referenced by OBConformerSearch::GetConformers(), OBForceField::RandomRotorSearchInitialize(), OBConformerSearch::Setup(), and OBForceField::SystematicRotorSearchInitialize().
void AddRotamer | ( | int * | key | ) |
Add a rotamer to the list based on key
as a configuration of the individual rotor bonds.
void AddRotamer | ( | std::vector< int > | key | ) |
Add a rotamer to the list based on key
as a configuration of the individual rotor bonds.
void AddRotamer | ( | unsigned char * | key | ) |
Add a rotamer to the list based on key
as a configuration of the individual rotor bonds.
void AddRotamers | ( | unsigned char * | arr, |
int | nconf | ||
) |
Add nconf
rotamers based on as
an array of configurations much like AddRotamer()
Referenced by OBRotamerList::Clone().
void GetReferenceArray | ( | unsigned char * | ref | ) | const |
|
inline |
|
inline |
vector< double * > CreateConformerList | ( | OBMol & | mol | ) |
Create a conformer list using the internal base set of coordinates.
void ExpandConformerList | ( | OBMol & | mol, |
std::vector< double *> & | confs | ||
) |
Create a conformer list using the internal base set of coordinates.
confs
Referenced by OBConformerSearch::GetConformers(), OBForceField::RandomRotorSearchInitialize(), OBConformerSearch::Setup(), and OBForceField::SystematicRotorSearchInitialize().
bool SetCurrentCoordinates | ( | OBMol & | mol, |
std::vector< int > | arr | ||
) |
Change the current coordinate set
Referenced by OBForceField::FastRotorSearch(), OpenBabel::UpdateConformersFromTree(), and OBForceField::WeightedRotorSearch().
void SetBaseCoordinateSets | ( | OBMol & | mol | ) |
Copies the mol's conformers (the coordinates, NOT the pointers) into the object as base coordinates.
Referenced by OBRotamerList::Clone(), OBForceField::FastRotorSearch(), OBConformerSearch::GetConformers(), OBForceField::RandomRotorSearchInitialize(), OBConformerSearch::Setup(), OBForceField::SystematicRotorSearchInitialize(), OpenBabel::UpdateConformersFromTree(), and OBForceField::WeightedRotorSearch().
void SetBaseCoordinateSets | ( | std::vector< double *> | bc, |
unsigned int | N | ||
) |
Copies the coordinates in bc, NOT the pointers, into this object.
bc | The conformer set for the molecule |
N | The number of atoms in the molecule |
|
inline |
|
inline |
Get a pointer to a specific base pointer (i.e., specific conformer)
|
inline |
|
inlineinherited |
Set the attribute (key), which can be used to retrieve this data.
Referenced by OBGastChrg::AssignPartialCharges(), OpenBabel::ComparePairSecond(), OBMol::DoTransformations(), OBMol::FindLSSR(), OBMol::FindSSSR(), OBForceField::GetAtomTypes(), OBMol::GetFormula(), OBMol::GetLSSR(), OBForceField::GetPartialCharges(), OBMol::GetSSSR(), OBDescriptor::PredictAndSave(), and OBMol::SetFormula().
|
inlineinherited |
Set the origin of this data, which can be used to filter the data.
Referenced by OBGastChrg::AssignPartialCharges(), OpenBabel::ComparePairSecond(), OBMol::DoTransformations(), OBMol::FindAngles(), OBMol::FindLSSR(), OBMol::FindSSSR(), OBMol::FindTorsions(), OBMol::GetFormula(), OBMol::GetLSSR(), OBMol::GetSSSR(), OBDescriptor::PredictAndSave(), and OBMol::SetFormula().
|
inlinevirtualinherited |
Referenced by OpenBabel::extract_thermochemistry(), and OBMoleculeFormat::MakeCombinedMolecule().
|
inlineinherited |
|
inlinevirtualinherited |
Base class returns a default value (the attribute type) but should never be called.
Reimplemented in OBPairData, and OBCommentData.
Referenced by OBDepict::AddAtomLabels(), OBDepict::DrawMolecule(), OBDescriptor::FilterCompare(), and OBDescriptor::GetValues().
|
inlinevirtualinherited |
|
protectedinherited |
attribute tag (e.g., "UnitCell", "Comment" or "Author")
Referenced by OBRotamerList::Clone(), and OBNasaThermoData::OBNasaThermoData().
|
protectedinherited |
attribute type – declared for each subclass
Referenced by OBRotamerList::Clone(), and OBNasaThermoData::OBNasaThermoData().
|
protectedinherited |
source of data for accounting
Referenced by OBConformerData::operator=(), OBSymmetryData::operator=(), OBTorsionData::operator=(), and OBAngleData::operator=().