changed reading hint
[gromacs/adressmacs.git] / include / rdgroup.h
blobb16291a73f6487b7ca6b5c9ed36323a1212dc868
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 2.0
12 * Copyright (c) 1991-1999
13 * BIOSON Research Institute, Dept. of Biophysical Chemistry
14 * University of Groningen, The Netherlands
16 * Please refer to:
17 * GROMACS: A message-passing parallel molecular dynamics implementation
18 * H.J.C. Berendsen, D. van der Spoel and R. van Drunen
19 * Comp. Phys. Comm. 91, 43-56 (1995)
21 * Also check out our WWW page:
22 * http://md.chem.rug.nl/~gmx
23 * or e-mail to:
24 * gromacs@chem.rug.nl
26 * And Hey:
27 * Green Red Orange Magenta Azure Cyan Skyblue
30 #ifndef _rdgroup_h
31 #define _rdgroup_h
33 static char *SRCID_rdgroup_h = "$Id$";
35 #ifdef HAVE_IDENT
36 #ident "@(#) rdgroup.h 1.15 2/2/97"
37 #endif /* HAVE_IDENT */
38 #include <typedefs.h>
40 #ifdef CPLUSPLUS
41 extern "C" {
42 #endif
44 t_block *init_index(char *gfile, char ***grpname);
45 /* Lower level routine than the next */
47 void rd_index(char *statfile,int ngrps,int isize[],
48 atom_id *index[],char *grpnames[]);
49 /* Assume the group file is generated, so the
50 * format need not be user-friendly. The format is:
51 * nr of groups, total nr of atoms
52 * for each group: name nr of element, elements
53 * The function opens a file, reads ngrps groups, puts the
54 * sizes in isize, the atom_id s in index and the names of
55 * the groups in grpnames.
57 * It is also assumed, that when ngrps groups are requested
58 * memory has been allocated for ngrps index arrays, and that
59 * the dimension of the isize and grpnames arrays are ngrps.
62 void rd_index_nrs(char *statfile,int ngrps,int isize[],
63 atom_id *index[],char *grpnames[],int grpnr[]);
64 /* the same but also reads the number of the selected group*/
66 void get_index(t_atoms *atoms, char *fnm, int ngrps,
67 int isize[], atom_id *index[],char *grpnames[]);
68 /* Does the same as rd_index, but if the fnm pointer is NULL it
69 * will not read from fnm, but it will make default index groups
70 * for the atoms in *atoms.
71 */
73 #ifdef CPLUSPLUS
75 #endif
77 #endif /* _rdgroup_h */