Class NamingUtils

java.lang.Object
ffx.potential.bonded.NamingUtils

public class NamingUtils extends Object
Utilities for importing atoms from PDB files and checking their names.
Since:
1.0
Author:
Jacob Litman, Michael Schnieders
  • Constructor Details

    • NamingUtils

      public NamingUtils()
  • Method Details

    • checkHydrogenAtomNames

      public static void checkHydrogenAtomNames(Residue residue, PDBFilter.PDBFileStandard fileStandard)
      Ensures proper naming of hydrogen according to latest PDB format. Presently mostly guesses at which hydrogen to re-assign, which may cause chirality errors for prochiral hydrogen. If necessary, we will implement more specific mapping.
      Parameters:
      residue - Residue to examine.
      fileStandard - PDB File Standard to use.
    • nameAcetylCap

      public static void nameAcetylCap(Residue residue, Atom aceC)
      Names the atoms in an N-terminal acetyl ACE capping group.
      Parameters:
      residue - Residue containing an acetyl cap.
      aceC - The acetyl group's C atom.
    • renameAlkyl

      public static Optional<Atom> renameAlkyl(Atom carbon, Atom priorAtom, int protonOffset, char posName)
      Renames an atom, its bonded hydrogen, and returns the next atom in the chain.

      If applied to an atom that is not a carbon, it will be misnamed as a carbon, so fix that afterwards.

      Parameters:
      carbon - Alkyl carbon to rename.
      priorAtom - Prior atom in the chain.
      protonOffset - Number of the first hydrogen (such as 2 for HB2-3).
      posName - Name of the position (such as B for CB).
      Returns:
      Next atom in the chain if present.
    • renameAminoAcidToPDBStandard

      public static boolean renameAminoAcidToPDBStandard(Residue residue)
      Renames the Atoms in an amino acid to PDB standard.
      Parameters:
      residue - Residue to fix atom names of.
    • renameArginineHydrogen

      public static void renameArginineHydrogen(Residue residue, List<Atom> resAtoms)
      renameArginineHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
    • renameAsparagineHydrogen

      public static void renameAsparagineHydrogen(Residue residue, List<Atom> resAtoms)
      renameAsparagineHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
    • renameAtomsToPDBStandard

      public static void renameAtomsToPDBStandard(MolecularAssembly molecularAssembly)
      Renames Atoms to PDB standard using bonding patterns, atomic numbers, and residue types.

      Will not work if a force field definition botches its atomic numbers.

      Only implemented for amino acids and nucleic acids at this time.

      Parameters:
      molecularAssembly - MolecularAssembly to fix.
    • renameBetaHydrogen

      public static void renameBetaHydrogen(Residue residue, List<Atom> resAtoms, int indexes)
      renameBetaHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
      indexes - The HB indexes to use.
    • renameBranchedAlkyl

      public static Optional<Atom> renameBranchedAlkyl(Atom carbon, Atom priorAtom, int protonOffset, int branchNum, char posName)
      Renames a numbered carbon, its bonded hydrogen, and returns the next atom in the chain.

      If applied to an atom that is not a carbon, it will be misnamed as a carbon, so fix that afterwards.

      This is for carbons like PHE CD1 and CD2.

      Parameters:
      carbon - Alkyl carbon to rename.
      priorAtom - Prior atom in the chain.
      protonOffset - Number of the first hydrogen (such as 2 for HB2-3).
      branchNum - Index of the branch.
      posName - Name of the position (such as B for CB).
      Returns:
      Next atom in the chain if present.
    • renameCommonAminoAcids

      public static void renameCommonAminoAcids(Residue residue, AminoAcidUtils.AminoAcid3 aa3, Atom CA, Atom CB)
      Renames atoms in common amino acids to PDB standard.
      Parameters:
      residue - Residue to perform renaming for.
      aa3 - Its AA3 code.
      CA - Its alpha carbon.
      CB - Its beta carbon.
    • renameCommonNucleicAcid

      public static void renameCommonNucleicAcid(Residue residue, NucleicAcidUtils.NucleicAcid3 na3)
      Renames atoms in common nucleic acids to PDB standard.
      Parameters:
      residue - Residue to perform renaming for.
      na3 - Its NA3 code.
    • renameCommonNucleobase

      public static void renameCommonNucleobase(Atom N19, Atom C1s, NucleicAcidUtils.NucleicAcid3 na3)
      Renames the atoms of the common nucleobases (A, C, G, T, U, and deoxy variants).
      Parameters:
      N19 - N1 of pyrimidines, N9 of purines.
      C1s - C1' of the ribose sugar.
      na3 - Identity of the nucleic acid.
    • renameCommonPurine

      public static Map<String,Atom> renameCommonPurine(Atom N9, Atom C1s)
      Renames atoms common to all standard purines (A, G)
      Parameters:
      N9 - The N9 atom.
      C1s - The C1' atom.
      Returns:
      A Map containing Atoms important to finding and naming base-unique atoms.
    • renameCommonPyrimidine

      public static Map<String,Atom> renameCommonPyrimidine(Atom N1, Atom C1s)
      Renames atoms common to all standard pyrimidines (C, T, U)
      Parameters:
      N1 - The N1 atom.
      C1s - The C1' atom.
      Returns:
      A Map containing Atoms important to finding and naming base-unique atoms.
    • renameDeltaHydrogen

      public static void renameDeltaHydrogen(Residue residue, List<Atom> resAtoms, int indexes)
      renameDeltaHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
      indexes - The HD indexes to use.
    • renameEpsilonHydrogen

      public static void renameEpsilonHydrogen(Residue residue, List<Atom> resAtoms, int indexes)
      renameEpsilonHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
      indexes - The HE indexes to use.
    • renameGammaHydrogen

      public static void renameGammaHydrogen(Residue residue, List<Atom> resAtoms, int indexes)
      renameGammaHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
      indexes - The HG indexes to use.
    • renameGlutamineHydrogen

      public static void renameGlutamineHydrogen(Residue residue, List<Atom> resAtoms)
      renameGlutamineHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
    • renameGlycineAlphaHydrogen

      public static void renameGlycineAlphaHydrogen(Residue residue, List<Atom> resAtoms)
      renameGlycineAlphaHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
    • renameIsoleucineHydrogen

      public static void renameIsoleucineHydrogen(Residue residue, List<Atom> resAtoms)
      renameIsoleucineHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
    • renameNTerminusHydrogen

      public static void renameNTerminusHydrogen(Residue residue)
      renameNTerminusHydrogen.
      Parameters:
      residue - a Residue object.
    • renameNucleicAcidToPDBStandard

      public static void renameNucleicAcidToPDBStandard(Residue residue)
      Renames the Atoms in a nucleic acid to PDB standard.
      Parameters:
      residue - Residue to fix atom names of.
    • renameZetaHydrogen

      public static void renameZetaHydrogen(Residue residue, List<Atom> resAtoms, int indexes)
      renameZetaHydrogen.
      Parameters:
      residue - a Residue object.
      resAtoms - a List object.
      indexes - The HZ atom indices to use.