changed reading hint
[gromacs/adressmacs.git] / include / random.h
blob5005b360dad844c244b397e079e2b8bd12ab4577
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 _random_h
31 #define _random_h
33 static char *SRCID_random_h = "$Id$";
35 #ifdef HAVE_IDENT
36 #ident "@(#) random.h 1.5 12/16/92"
37 #endif /* HAVE_IDENT */
39 #include <typedefs.h>
41 extern real gauss(real am, real sd, int *ig);
42 /* Generate a gaussian number with:
43 * am = center of the distribution
44 * sd = standard deviation
45 * ig = the random number seed.
48 extern int make_seed(void);
49 /* Make a random seed: (time+getpid) % 65536 */
51 extern real rando(int *ig);
52 /* Generate a random number 0 <= r < 1. ig is the (address of) the
53 * seed variable.
56 extern void grp_maxwell(t_block *grp,real tempi[],int nrdf[],int seed,
57 t_atoms *atoms,rvec v[]);
58 /* Generate for each group in grp a temperature. */
60 extern void maxwell_speed(real tempi,int nrdf,int seed,
61 t_atoms *atoms, rvec v[]);
62 /* Generate velocites according to a maxwellian distribution */
64 extern real calc_cm(FILE *log,int natoms,real mass[],rvec x[],rvec v[],
65 rvec xcm,rvec vcm,rvec acm,matrix L);
66 /* Calculate the c.o.m. position, velocity, acceleration and the
67 * moment of Inertia. Returns the total mass.
70 extern void stop_cm(FILE *log,int natoms,real mass[],rvec x[],rvec v[]);
72 #endif /* _random_h */