The figure below represents how the basic classes of chemfiles are organized and
how they interact together. Chemfiles is organized around a handful of public
Selection, all of which are presented here.
trajectory is the main entry point of
chemfiles. It reads one or many
frames from a
file on the disk using a specific format. The file type and the format are
automatically determined from the extension.
topology describes the organization of
the particles in the system. It contains a list of
atoms in the system, and information about which atoms are bonded
residue is a group of atoms bonded
together, which may or may not corresponds to molecules. When working with
bio-molecules and specifically proteins from the PDB data bank, the residues
should correspond to amino-acids in the protein.
Atom class contains basic information about
the atoms in the system: the name (if it is available), mass, kind of atom and
so on. Atoms are not limited to plain chemical elements.
UnitCell class describes the boundary
conditions of the system: where are the boundaries, and what is the periodicity
of theses boundaries. An unit cell can be of three types: Infinite,
Orthorhombic or Triclinic. Infinite cells do not have any boundaries.
Orthorhombic cells are defined by three orthogonal vectors, and triclinic cells
are defined by three vectors without any constrain.
Chemfiles also provides a selection language,
implemented in the
Selection class. This
selection language allows the users to select a group of atoms from a
frame using a selection string such as
45 and name O) or name C".