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 * GRowing Old MAkes el Chrono Sweat
29 static char *SRCID_calcmu_c
= "$Id$";
41 void calc_mu(t_nsborder
*nsb
,rvec x
[],real q
[],rvec mu
)
46 end
= start
+ HOMENR(nsb
);
49 for(i
=start
; (i
<end
); i
++) {
50 for(m
=0; (m
<DIM
); m
++) {
51 mu
[m
] += q
[i
]*x
[i
][m
];
54 for(m
=0; (m
<DIM
); m
++)
58 bool read_mu(FILE *fp
,rvec mu
,real
*vol
)
60 /* For backward compatibility */
63 if (fread(mmm
,(size_t)(4*sizeof(mmm
)),1,fp
) != 1)