Class AtomPlacer3D

java.lang.Object
org.openscience.cdk.modeling.builder3d.AtomPlacer3D

public class AtomPlacer3D extends Object
Place aliphatic chains with Z matrix method. Please use ModelBuilder3D to place general molecules.
Author:
chhoppe
See Also:
Source code:
main
Belongs to CDK module:
builder3d
Keywords:
AtomPlacer3D
Created on:
2004-10-8
  • Method Details

    • initilize

      public void initilize(Map parameterSet)
      Initialize the atomPlacer class.
      Parameters:
      parameterSet - Force Field parameter as Hashtable
    • findHeavyAtomsInChain

      public int[] findHeavyAtomsInChain(IAtomContainer molecule, IAtomContainer chain)
      Count and find first heavy atom(s) (non Hydrogens) in a chain.
      Parameters:
      molecule - the reference molecule for searching the chain
      chain - chain to be searched
      Returns:
      the atom number of the first heavy atom the number of heavy atoms in the chain
    • markPlaced

      public IAtomContainer markPlaced(IAtomContainer ac)
      Mark all atoms in chain as placed. (CDKConstant ISPLACED)
      Parameters:
      ac - chain
      Returns:
      chain all atoms marked as placed
    • placeAliphaticHeavyChain

      public void placeAliphaticHeavyChain(IAtomContainer molecule, IAtomContainer chain) throws CDKException
      Method assigns 3D coordinates to the heavy atoms in an aliphatic chain.
      Parameters:
      molecule - the reference molecule for the chain
      chain - the atoms to be assigned, must be connected
      Throws:
      CDKException - the 'chain' was not a chain
    • zmatrixChainToCartesian

      public void zmatrixChainToCartesian(IAtomContainer molecule, boolean flagBranched)
      Takes the given Z Matrix coordinates and converts them to cartesian coordinates. The first Atom end up in the origin, the second on on the x axis, and the third one in the XY plane. The rest is added by applying the Zmatrix distances, angles and dihedrals. Assign coordinates directly to the atoms.
      Parameters:
      molecule - the molecule to be placed in 3D
      flagBranched - marks branched chain author: egonw,cho
    • getBondLengthValue

      public double getBondLengthValue(String id1, String id2)
      Gets the distanceValue attribute of the parameter set.
      Parameters:
      id1 - atom1 id
      id2 - atom2 id
      Returns:
      The distanceValue value from the force field parameter set
    • getAngleValue

      public double getAngleValue(String id1, String id2, String id3)
      Gets the angleKey attribute of the AtomPlacer3D object.
      Parameters:
      id1 - Description of the Parameter
      id2 - Description of the Parameter
      id3 - Description of the Parameter
      Returns:
      The angleKey value
    • getNextUnplacedHeavyAtomWithAliphaticPlacedNeighbour

      public IAtom getNextUnplacedHeavyAtomWithAliphaticPlacedNeighbour(IAtomContainer molecule)
      Gets the nextUnplacedHeavyAtomWithAliphaticPlacedNeighbour from an atom container or molecule.
      Parameters:
      molecule -
      Returns:
      The nextUnplacedHeavyAtomWithAliphaticPlacedNeighbour value author: steinbeck,cho
    • getNextPlacedHeavyAtomWithUnplacedAliphaticNeighbour

      public IAtom getNextPlacedHeavyAtomWithUnplacedAliphaticNeighbour(IAtomContainer molecule)
      Gets the nextPlacedHeavyAtomWithAliphaticPlacedNeigbor from an atom container or molecule.
      Parameters:
      molecule -
      Returns:
      The nextUnplacedHeavyAtomWithUnplacedAliphaticNeigbor author: steinbeck,cho
    • getNextPlacedHeavyAtomWithUnplacedRingNeighbour

      public IAtom getNextPlacedHeavyAtomWithUnplacedRingNeighbour(IAtomContainer molecule)
      Gets the nextPlacedHeavyAtomWithUnplacedRingNeighbour attribute of the AtomPlacer3D object.
      Parameters:
      molecule - The atom container under consideration
      Returns:
      The nextPlacedHeavyAtomWithUnplacedRingNeighbour value
    • getFarthestAtom

      public IAtom getFarthestAtom(javax.vecmath.Point3d refAtomPoint, IAtomContainer ac)
      Gets the farthestAtom attribute of the AtomPlacer3D object.
      Parameters:
      refAtomPoint - Description of the Parameter
      ac - Description of the Parameter
      Returns:
      The farthestAtom value
    • getUnplacedRingHeavyAtom

      public IAtom getUnplacedRingHeavyAtom(IAtomContainer molecule, IAtom atom)
      Gets the unplacedRingHeavyAtom attribute of the AtomPlacer3D object.
      Parameters:
      molecule -
      atom - Description of the Parameter
      Returns:
      The unplacedRingHeavyAtom value
    • geometricCenterAllPlacedAtoms

      public javax.vecmath.Point3d geometricCenterAllPlacedAtoms(IAtomContainer molecule)
      Calculates the geometric center of all placed atoms in the atomcontainer.
      Parameters:
      molecule -
      Returns:
      Point3d the geometric center
    • getPlacedHeavyAtom

      public IAtom getPlacedHeavyAtom(IAtomContainer molecule, IAtom atom)
      Returns a placed atom connected to a given atom.
      Parameters:
      molecule -
      atom - The Atom whose placed bonding partners are to be returned
      Returns:
      a placed heavy atom connected to a given atom author: steinbeck
    • getPlacedHeavyAtom

      public IAtom getPlacedHeavyAtom(IAtomContainer molecule, IAtom atomA, IAtom atomB)
      Gets the first placed Heavy Atom around atomA which is not atomB.
      Parameters:
      molecule -
      atomA - Description of the Parameter
      atomB - Description of the Parameter
      Returns:
      The placedHeavyAtom value
    • getPlacedHeavyAtoms

      public IAtomContainer getPlacedHeavyAtoms(IAtomContainer molecule, IAtom atom)
      Gets the placed Heavy Atoms connected to an atom.
      Parameters:
      molecule -
      atom - The atom the atoms must be connected to.
      Returns:
      The placed heavy atoms.
    • numberOfUnplacedHeavyAtoms

      public int numberOfUnplacedHeavyAtoms(IAtomContainer ac)
      Gets numberOfUnplacedHeavyAtoms (no Flag ISPLACED, no Hydrogens)
      Parameters:
      ac - AtomContainer
      Returns:
      #UnplacedAtoms
    • allHeavyAtomsPlaced

      public boolean allHeavyAtomsPlaced(IAtomContainer ac)
      True is all the atoms in the given AtomContainer have been placed.
      Parameters:
      ac - The AtomContainer to be searched
      Returns:
      True is all the atoms in the given AtomContainer have been placed