Tagged files with gromacs 3.0 header and added some license info
[alexxy/gromacs.git] / include / grompp.h
1 /*
2  * $Id$
3  * 
4  *                This source code is part of
5  * 
6  *                 G   R   O   M   A   C   S
7  * 
8  *          GROningen MAchine for Chemical Simulations
9  * 
10  *                        VERSION 3.0
11  * 
12  * Copyright (c) 1991-2001
13  * BIOSON Research Institute, Dept. of Biophysical Chemistry
14  * University of Groningen, The Netherlands
15  * 
16  * This program is free software; you can redistribute it and/or
17  * modify it under the terms of the GNU General Public License
18  * as published by the Free Software Foundation; either version 2
19  * of the License, or (at your option) any later version.
20  * 
21  * If you want to redistribute modifications, please consider that
22  * scientific software is very special. Version control is crucial -
23  * bugs must be traceable. We will be happy to consider code for
24  * inclusion in the official distribution, but derived work must not
25  * be called official GROMACS. Details are found in the README & COPYING
26  * files - if they are missing, get the official version at www.gromacs.org.
27  * 
28  * To help us fund GROMACS development, we humbly ask that you cite
29  * the papers on the package - you can find them in the top README file.
30  * 
31  * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org .
32  * 
33  * And Hey:
34  * GRoups of Organic Molecules in ACtion for Science
35  */
36
37 #ifndef _grompp_h
38 #define _grompp_h
39
40 static char *SRCID_grompp_h = "$Id$";
41 #include <config.h>
42
43 static char *SRCID_grompp_h = "$Id$";
44
45 #ifdef HAVE_IDENT
46 #ident  "@(#) grompp.h 1.37 2/2/97"
47 #endif /* HAVE_IDENT */
48
49 #include <stdio.h>
50 #include "typedefs.h"
51 #include "macros.h"
52
53 #define MAXSLEN 32
54 typedef struct {
55   atom_id a[MAXATOMLIST];       /* The atom list (eg. bonds: particle   */
56                                 /* i = a[0] (AI), j = a[1] (AJ))        */
57   real    c[MAXFORCEPARAM];     /* Force parameters (eg. b0 = c[0])     */
58   char    s[MAXSLEN];           /* A string (instead of parameters),    *
59                                  * read from the .rtp file in pdb2gmx   */
60 } t_param;
61
62 typedef struct {
63   int           nr;             /* The number of bonds in this record   */
64   t_param       *param;         /* Array of parameters (dim: nr)        */
65 } t_params;
66
67 typedef struct {
68   int           nr;             /* The number of exclusions             */
69   atom_id       *e;             /* The excluded atoms                   */
70 } t_excls;
71
72 typedef struct {
73   char          **name;
74   int           nrexcl;         /* Number of exclusions per atom        */
75   bool          excl_set;       /* Have exclusions been generated?      */
76   bool          bProcessed;     /* Has the mol been processed           */
77   t_atoms       atoms;          /* Atoms                                */
78   t_block       cgs;            /* Charge groups                        */
79   t_block       mols;           /* Molecules                            */
80   t_params      plist[F_NRE];   /* Parameters in old style              */
81 } t_molinfo;
82
83 typedef struct {
84   int           nr;             /* The number of atomtypes              */
85   t_atom        *atom;          /* Array of atoms                       */
86   char          ***atomname;    /* Names of the atomtypes               */
87   t_param       *nb;            /* Nonbonded force default params       */
88 } t_atomtype;
89
90 typedef enum {
91   d_defaults,
92   d_atomtypes,
93   d_bondtypes,
94   d_constrainttypes,
95   d_pairtypes,
96   d_angletypes,
97   d_dihedraltypes,
98   d_nonbond_params,
99   d_blocktype,
100   d_moleculetype,
101   d_atoms,
102   d_dum2,
103   d_dum3,
104   d_dum4,
105   d_bonds,
106   d_exclusions,
107   d_pairs,
108   d_angles,
109   d_dihedrals,
110   d_constraints,
111   d_settles,
112   d_system,
113   d_molecules,
114   d_position_restraints,
115   d_angle_restraints,
116   d_angle_restraints_z,
117   d_distance_restraints,
118   d_maxdir,
119   d_invalid,
120   d_none
121 } directive;
122
123 static char *ds[d_maxdir+1] = {
124   "defaults",
125   "atomtypes",
126   "bondtypes",
127   "constrainttypes",
128   "pairtypes",
129   "angletypes",
130   "dihedraltypes",
131   "nonbond_params",
132   "blocktype",
133   "moleculetype",
134   "atoms",
135   "dummies2",
136   "dummies3",
137   "dummies4",
138   "bonds",
139   "exclusions",
140   "pairs",
141   "angles",
142   "dihedrals",
143   "constraints",
144   "settles",
145   "system",
146   "molecules",
147   "position_restraints",
148   "angle_restraints",
149   "angle_restraints_z",
150   "distance_restraints",
151   "invalid"
152   };
153
154 extern void convert_harmonics(int nrmols,t_molinfo mols[],t_atomtype *atype);
155
156 #endif  /* _grompp_h */