Next: BaseMolecule
Up: Molecule objects
Previous: Animation
  Contents
Subsections
Atom
Files: |
Atom.h |
Derived from: |
none |
Global instance (if any): |
none |
Used in optional component: |
Part of main VMD code |
An Atom object stores the data for a single atom in a molecule. Each
atom has the following information:
- Mass
- Charge
- Atom name
- Atom type
- Residue name
- Residue ID number
- Chain identifier
- Segment name
- List of bonds
Each BaseMolecule contains a list of these Atom objects.
- Atom::Atom(int, float *, float *, char *, char *, char *,
char *, char *, char *)
The first argument is the index of the atom; the rest are the names used
to distinguish this atom (as mentioned in the list above).
Each atom has a set of `extra' data values, other than it's position. The
codes used as indices for these extra data values are:
- ATOMCHARGE
- ATOMMASS
- ATOMBETA
- ATOMOCCUP
- ATOMRAD
- ATOMEXTRA - the number of `extra' data items.
The BackboneType enumeration lists the different types of backbone
bonds which may exist:
- NORMAL - used if nothing else special about the backbone
bond can be determined.
- PROTEINBACK - used for protein backbone bonds.
- NUCLEICBACK - used for nucleic acid backbone bonds.
The ResidueType enumeration lists the different classes of residues
which this atom may be a part of:
- NOTHING - not in a residue of any noted special group.
- PROTEIN - a standard protein residue, i.e. an amino acid.
- NUCLEIC - a standard nucleic acid resiude, i.e. A,T,G,C, or U.
- WATERS - a solvent residue, most likely water.
- int index - the index of this atom, as provided in the
constructor.
- int bonds - the total number of bonds which this atoms
participates in. Note that a bond will be stored twice, once for each of
the atoms it connects.
- int uniq_resid - a unique integer indicating which residue
this atom is in. This is not the same as te residue ID, since that is not
necessarily unique in a given structure (particularly if the structure
contains more than one segment or chain).
- int fragment - which fragment this atom belongs in.
- int bondTo[MAXATOMBONDS] - the indices of the other atoms to
which this atom is bonded. An atom can bond to a maximum number of other
atoms before an error occurs, this maximum is currently 8.
- BackboneType bondType[MAXATOMBONDS] - lists what type of bond
each to the bonds to this atom are.
- BackboneType atomType - indicates if this atom is part of the
backbone, and if so what kind of backbone.
- ResidueType residueType - what type of residue this atom is
a part of.
- float pos[], extra[] - position and `extra' data values for
this atom. These are initial, or `default', values for the atom when no
other coordinates or extra values are known.
- char namestr[], int nameindex - the atom name, and the index
of that name in the unique atom name array in the BaseMolecule which
created the Atom object.
- char typestr[], int typeindex - the atom type name, and the
index of that name in the unique atomtype name array in the BaseMolecule
which created the Atom object.
- char resnamestr[], int resnameindex - the residue name, and the
index of that name in the unique residue name array in the BaseMolecule
which created the Atom object.
- char residstr[], int residindex - the residue ID, and the
index of that name in the unique residue ID array in the BaseMolecule
which created the Atom object.
- char segnamestr[], int segnameindex - the segment name,
and the index
of that name in the unique segment name array in the BaseMolecule which
created the Atom object.
- char chainstr[], int chainindex - the chain ID,
and the index
of that ID in the unique chain ID array in the BaseMolecule which
created the Atom object.
- float radius() - return the atom radius.
- float mass() - return the atom mass.
- float charge() - return the atom charge.
- float beta() - return the atom beta value.
- float occup() - return the atom occupancy value.
- void add_bond(int, BackboneType) - add a new bond to this
atom, which connects this atom and the specified atom, of the given
bond type.
- int bonded(int a) - return TRUE if this atom is bonded
to the specified atom.
To create a new Atom, you specify all the names in the constructor,
and then add the bonds to the atom one at a time using the add_bond
routine. Later, when the molecular structure has been analyzed, the
flags indicating the residue type, fragment index, etc. must be set (they
are currently public members, so they can be accessed directly).
Next: BaseMolecule
Up: Molecule objects
Previous: Animation
  Contents
vmd@ks.uiuc.edu