<!--                                                              -->
<!-- GROMACS Data type description (DTD). 

                This source code is part of
 
                 G   R   O   M   A   C   S
 
          GROningen MAchine for Chemical Simulations
 
                        VERSION 3.1
 
 Copyright (c) 1991-2002
 BIOSON Research Institute, Dept. of Biophysical Chemistry
 University of Groningen, The Netherlands
 
 This program is free software; you can redistribute it and/or
 modify it under the terms of the GNU General Public License
 as published by the Free Software Foundation; either version 2
 of the License, or (at your option) any later version.
 
 If you want to redistribute modifications, please consider that
 scientific software is very special. Version control is crucial -
 bugs must be traceable. We will be happy to consider code for
 inclusion in the official distribution, but derived work must not
 be called official GROMACS. Details are found in the README & COPYING
 files - if they are missing, get the official version at www.gromacs.org.
 
 To help us fund GROMACS development, we humbly ask that you cite
 the papers on the package - you can find them in the top README file.
 
 Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org .
 
 And Hey:
 GROningen Mixture of Alchemy and Childrens' Stories

                                                            
 David van der Spoel 07/2001, 03/2002                        
 The authorative version of this document can be found at    
 http://www.gromacs.org/gromacs3.1.dtd                       
 and also in the library directory of your local GROMACS     
 installation.                                                
 
 Please use the following formal public identifier to identify it:
     "-//RESIDUES//DTD Residues XML V1.0//EN"

 <!DOCTYPE residues PUBLIC "-//RESIDUES//DTD Gromacs XML V3.1.0//EN"
                    "http://www.gromacs.org/residues.dtd"
                   [...]>
-->

<!-- This file defines the structure of the information necessary make
     a molecule from simple building blocks (called residues). The
     algorithm processing a sequence (or pdb file) should follow these
     steps:
     1. Do all the modification (moddef)
     2. Add all the links between residues
     3. Generate hydrogens
     4. Generate angle and torsion descriptions                     
-->

<!ELEMENT macromolecules (residues,macromolecule*)>

<!ELEMENT residues (residue*,linkdef*,moddef*)>

<!ELEMENT residue (ratom+,rbond*,rangle*,rimproper*,rdihedral*,raddh*)>
<!ATTLIST residue
          restype  ID    #REQUIRED
	  longname CDATA #REQUIRED>
<!-- We can not use ID here for atom names since there is no -->
<!-- hope to make them unique, e.g. all amino acids have the -->
<!-- same name for backbone atoms.                           -->
<!ELEMENT ratom EMPTY>
<!ATTLIST ratom
          name  CDATA #REQUIRED>
<!ELEMENT rbond EMPTY>
<!ATTLIST rbond
          a1 CDATA #REQUIRED
	  a2 CDATA #REQUIRED>	  
<!ELEMENT rangle EMPTY>
<!ATTLIST rangle
          a1 CDATA #REQUIRED
	  a2 CDATA #REQUIRED
	  a3 CDATA #REQUIRED>	  
<!ELEMENT rimproper EMPTY>
<!ATTLIST rimproper
          a1 CDATA #REQUIRED
	  a2 CDATA #REQUIRED
	  a3 CDATA #REQUIRED
	  a4 CDATA #REQUIRED>
<!ELEMENT rdihedral EMPTY>
<!ATTLIST rdihedral
          a1 CDATA #REQUIRED
	  a2 CDATA #REQUIRED
	  a3 CDATA #REQUIRED
	  a4 CDATA #REQUIRED>
<!-- Definition of how to add (hydrogen) atoms to molecules  -->
<!-- using a certain geometry (see GROMACS manual)           -->
<!ELEMENT raddh EMPTY>
<!ATTLIST raddh
          hclass   ( polar | aromatic | aliphatic ) 
	  addgeom  CDATA #REQUIRED
	  addnum   CDATA #REQUIRED
	  addto    CDATA #REQUIRED>
	  
<!-- Define a covalent link between two residues, given in restyp -->
<!-- and the atoms are given as well (atomprev and atomnext)      -->
<!-- A reference distance between the atoms does also have to be  -->
<!-- given in nm (but that does not have to be used).             -->
<!ELEMENT linkdef EMPTY>
<!ATTLIST linkdef
          linktype ID     #REQUIRED
	  restype  IDREFS #REQUIRED
	  atomprev CDATA  #REQUIRED
          atomnext CDATA  #REQUIRED
	  refdist  CDATA  #REQUIRED>

<!-- Description of termini, etc. or maybe other modifications too -->
<!-- It is important that the implementation deletes first, and    -->
<!-- adds atoms afterwards                                         --> 
<!ELEMENT moddef (moddelete*,modadd*,modrepl*)>
<!ATTLIST moddef
          modtype ID    #REQUIRED>
<!ELEMENT moddelete EMPTY>
<!ATTLIST moddelete
          delname CDATA #REQUIRED>
<!ELEMENT modreplace EMPTY>
<!ATTLIST modreplace
          oldname CDATA #REQUIRED
          newname CDATA #REQUIRED>
<!ELEMENT modadd EMPTY>
<!ATTLIST modadd
          addname CDATA #REQUIRED
          addbond CDATA #REQUIRED>

<!-- Generic stuff to define proteins etc. as built up from blocks -->
<!-- such as amino acids and HEME etc.                             -->
<!ELEMENT macromolecule (mblock+,mlink*,mmod*)>
<!ATTLIST macromolecule
          mname ID #REQUIRED>
<!ELEMENT mblock EMPTY>
<!ATTLIST mblock
          resname   ID    #REQUIRED
          restype   IDREF #REQUIRED
          protonated ( no | polar | all ) "polar">
<!ELEMENT mlink EMPTY>
<!ATTLIST mlink
          mlinktype  ( peptide | disulphide | special ) "peptide"
          resname   IDREFS #REQUIRED>
<!ELEMENT mmod EMPTY>
<!ATTLIST mmod
          resname IDREF #REQUIRED
          modtype IDREF #REQUIRED>
	  
<!-- Generic stuff to define proteins etc. as built up from blocks -->
<!-- such as amino acids and HEME etc.                             -->
<!ELEMENT macromolecule (mblock+,mlink*,mmod*)>
<!ATTLIST macromolecule
          mname ID #REQUIRED>
<!ELEMENT mblock EMPTY>
<!ATTLIST mblock
          resname   ID    #REQUIRED
          restype   IDREF #REQUIRED
          protonated ( no | polar | all ) "polar">
<!ELEMENT mlink EMPTY>
<!ATTLIST mlink
          mlinktype  ( peptide | disulphide | special ) "peptide"
          resname   IDREFS #REQUIRED>
<!ELEMENT mmod EMPTY>
<!ATTLIST mmod
          resname IDREF #REQUIRED
          modtype IDREF #REQUIRED>
	  
