4 * This source code is part of
8 * GROningen MAchine for Chemical Simulations
12 * Copyright (c) 1991-1999
13 * BIOSON Research Institute, Dept. of Biophysical Chemistry
14 * University of Groningen, The Netherlands
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
27 * Green Red Orange Magenta Azure Cyan Skyblue
33 static char *SRCID_rdgroup_h
= "$Id$";
36 #ident "@(#) rdgroup.h 1.15 2/2/97"
37 #endif /* HAVE_IDENT */
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.
77 #endif /* _rdgroup_h */