4 * This source code is part of
8 * GROningen MAchine for Chemical Simulations
11 * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others.
12 * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
13 * Copyright (c) 2001-2004, The GROMACS development team,
14 * check out http://www.gromacs.org for more information.
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.
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.
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.
31 * For more info, check our website at http://www.gromacs.org
34 * Gromacs Runs On Most of All Computer Systems
61 extern void check_nnodes_top(char *fn
,t_topology
*top
,int nnodes
);
62 /* Verify whether this tpr file is for nnodes nodes, and quit if not */
64 extern void init_single(FILE *log
,
65 t_parm
*parm
, char *tpbfile
, t_topology
*top
,
66 rvec
**x
,rvec
**v
,t_mdatoms
**mdatoms
,
69 * Allocates space for the topology (top), the coordinates x, the
70 * velocities v, masses mass. Reads the parameters, topology,
71 * coordinates and velocities from the file specified in tpbfile
74 extern void distribute_parts(int left
,int right
,int pid
,int nprocs
,
75 t_parm
*parm
,char *tpbfile
,int nstDlb
);
77 * Reads the parameters, topology, coordinates and velocities for the
78 * multi processor version of the program from the file specified in
79 * parm->files[STATUS_NM]. This file should also contain a so called
80 * split descriptor which describes how to distribute particles over
81 * the system. It then selects for all subsystems the appropriate data
82 * and sends this to the processor using the left and right channels.
83 * At last it sends its own subsystem down the ring where it is buffered.
84 * Its own buffers for reading the data from the file are freed, and it
85 * is now possible to reload this processor from the ring by using the
86 * init_parts() routine.
87 * The routine also creates a renum array which can be used for writing
88 * out the x,v and f for analysis purpose.
91 extern void init_parts(FILE *log
,t_commrec
*cr
,
92 t_parm
*parm
,t_topology
*top
,
93 rvec
**x
,rvec
**v
,t_mdatoms
**mdatoms
,
94 t_nsborder
*nsb
,int list
,
95 bool *bParallelDummies
,
96 t_comm_dummies
*dummycomm
);
98 * Loads the data for a simulation from the ring. Parameters, topology
99 * coordinates, velocities, and masses are initialised equal to using
100 * init_single() in the single processor version. The extra argument
101 * f_add is allocated to use for the update of the forces, the load
102 * array specifies in which part of the x and f array the subsystems
103 * of the other processors are located. Homenr0, homenr1, nparts0 and
104 * nparts1 are necessary to calculate the non bonded interaction using
105 * the symmetry and thus calculating every force only once. List is a facility
106 * for logging (and debugging). One can decide to print none or a set of
107 * selected parameters to the file specified by log. Parameters are
108 * printed by or-ing the corresponding items from t_listitem. A 0 (zero)
109 * specifies that nothing is to be printed on the file. The function
110 * returns the number of shifts over the ring to perform to calculate
114 extern void write_parm(FILE *log
,char *title
,int pid
,t_parm
*parm
);
115 /* Write parm for debugging */