Class CIPTool
java.lang.Object
org.openscience.cdk.geometry.cip.CIPTool
Tool to help determine the R,S and stereochemistry definitions of a subset of the
CIP rules [Cahn, R.S. et. al.. Angew. Chem. Int. Ed.. 1966. 5]. The used set up sub rules are specified in the
CIPLigandRule class.
Basic use starts from a ITetrahedralChirality and therefore
assumes atoms with four neighbours:
IAtom[] ligandAtoms = mol.getConnectedAtomsList(centralAtom).toArray(new IAtom[4]); ITetrahedralChirality tetraStereo = new TetrahedralChirality( centralAtom, ligandAtoms, Stereo.ANTI_CLOCKWISE ); CIP_CHIRALITY cipChirality = CIPTool.getCIPChirality(mol, tetraStereo);The
IBond.Stereo value can be
reconstructed from 3D coordinates with the StereoTool.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumEnumeration with the two tetrahedral chiralities defined by the CIP schema. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intIAtom index to indicate an implicit hydrogen, not present in the chemical graph. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleancheckIfAllLigandsAreDifferent(ILigand[] ligands) Checks if each nextILigandis different from the previous one according to theCIPLigandRule.static org.openscience.cdk.geometry.cip.LigancyFourChiralitydefineLigancyFourChirality(IAtomContainer container, int chiralAtom, int ligand1, int ligand2, int ligand3, int ligand4, ITetrahedralChirality.Stereo stereo) Creates a ligancy for chirality around a single chiral atom, where the involved atoms are identified by there index in theIAtomContainer.static ILiganddefineLigand(IAtomContainer container, VisitedAtoms visitedAtoms, int chiralAtom, int ligandAtom) Creates a ligand attached to a single chiral atom, where the involved atoms are identified by there index in theIAtomContainer.static CIPTool.CIP_CHIRALITYgetCIPChirality(org.openscience.cdk.geometry.cip.LigancyFourChirality stereoCenter) Returns the R or S chirality according to the CIP rules, based on the given chirality information.static CIPTool.CIP_CHIRALITYgetCIPChirality(IAtomContainer container, IDoubleBondStereochemistry stereoCenter) static CIPTool.CIP_CHIRALITYgetCIPChirality(IAtomContainer container, ITetrahedralChirality stereoCenter) Returns the R or S chirality according to the CIP rules, based on the given chirality information.static ILigand[]getLigandLigands(ILigand ligand) Returns a CIP-expanded array of side chains of a ligand.static voidlabel(IAtomContainer container) Convenience method for labelling all stereo elements.static ILigand[]Reorders theILigandobjects in the array according to the CIP rules.
-
Field Details
-
HYDROGEN
public static final int HYDROGENIAtom index to indicate an implicit hydrogen, not present in the chemical graph.- See Also:
-
-
Constructor Details
-
CIPTool
public CIPTool()
-
-
Method Details
-
getCIPChirality
public static CIPTool.CIP_CHIRALITY getCIPChirality(org.openscience.cdk.geometry.cip.LigancyFourChirality stereoCenter) Returns the R or S chirality according to the CIP rules, based on the given chirality information.- Parameters:
stereoCenter- Chiral center for which the CIP chirality is to be determined asLigancyFourChiralityobject.- Returns:
- A
CIPTool.CIP_CHIRALITYvalue.
-
label
Convenience method for labelling all stereo elements. TheCIPTool.CIP_CHIRALITYis determined for each element and stored as asStringon theCDKConstants.CIP_DESCRIPTORproperty key. Atoms/bonds that are not stereocenters have no label assigned and the property will be null.- Parameters:
container- structure to label
-
getCIPChirality
public static CIPTool.CIP_CHIRALITY getCIPChirality(IAtomContainer container, ITetrahedralChirality stereoCenter) Returns the R or S chirality according to the CIP rules, based on the given chirality information.- Parameters:
container-IAtomContainerto which thestereoCenterbelongs.stereoCenter- Chiral center for which the CIP chirality is to be determined asITetrahedralChiralityobject.- Returns:
- A
CIPTool.CIP_CHIRALITYvalue.
-
getCIPChirality
public static CIPTool.CIP_CHIRALITY getCIPChirality(IAtomContainer container, IDoubleBondStereochemistry stereoCenter) -
checkIfAllLigandsAreDifferent
Checks if each nextILigandis different from the previous one according to theCIPLigandRule. It assumes that the input is sorted based on that rule.- Parameters:
ligands- array ofILigandto check- Returns:
- true, if all ligands are different
-
order
-
defineLigancyFourChirality
public static org.openscience.cdk.geometry.cip.LigancyFourChirality defineLigancyFourChirality(IAtomContainer container, int chiralAtom, int ligand1, int ligand2, int ligand3, int ligand4, ITetrahedralChirality.Stereo stereo) Creates a ligancy for chirality around a single chiral atom, where the involved atoms are identified by there index in theIAtomContainer. For the four ligand atoms,HYDROGENcan be passed as index, which will indicate the presence of an implicit hydrogen, not explicitly present in the chemical graph of the givencontainer.- Parameters:
container-IAtomContainerfor which the returnedILigands are definedchiralAtom- int pointing to theIAtomindex of the chiral atomligand1- int pointing to theIAtomindex of the firstILigandligand2- int pointing to theIAtomindex of the secondILigandligand3- int pointing to theIAtomindex of the thirdILigandligand4- int pointing to theIAtomindex of the fourthILigandstereo-ITetrahedralChirality.Stereofor the chirality- Returns:
- the created
LigancyFourChirality
-
defineLigand
public static ILigand defineLigand(IAtomContainer container, VisitedAtoms visitedAtoms, int chiralAtom, int ligandAtom) Creates a ligand attached to a single chiral atom, where the involved atoms are identified by there index in theIAtomContainer. For ligand atom,HYDROGENcan be passed as index, which will indicate the presence of an implicit hydrogen, not explicitly present in the chemical graph of the givencontainer.- Parameters:
container-IAtomContainerfor which the returnedILigands are definedvisitedAtoms- a list of atoms already visited in the analysischiralAtom- an integer pointing to theIAtomindex of the chiral atomligandAtom- an integer pointing to theIAtomindex of theILigand- Returns:
- the created
ILigand
-
getLigandLigands
Returns a CIP-expanded array of side chains of a ligand. If the ligand atom is only connected to the chiral atom, the method will return an empty list. The expansion involves the CIP rules, so that a double bonded oxygen will be represented twice in the list.
-