Previous versions of Gromacs never wrote broken molecules, but
this is no longer true for domain decomposition. Box dimensions
are set from the trajectory, but the molecular connectivity
from the structure file.
Fixes #834.
Change-Id: I61ecb4957ef11e03bfeef10095a406cbddd23a34
int gmx_bond(int argc, char *argv[])
{
const char *desc[] = {
int gmx_bond(int argc, char *argv[])
{
const char *desc[] = {
- "[TT]g_bond[tt] makes a distribution of bond lengths. If all is well a",
+ "[TT]g_bond[tt] makes a distribution of bond lengths by using the",
+ "connectivity information in the structure file. If all is well a",
"Gaussian distribution should be made when using a harmonic potential.",
"Bonds are read from a single group in the index file in order i1-j1",
"i2-j2 through in-jn.[PAR]",
"Gaussian distribution should be made when using a harmonic potential.",
"Bonds are read from a single group in the index file in order i1-j1",
"i2-j2 through in-jn.[PAR]",
"of the bondlength ([TT]-blen[tt]). That means, for a bond of 0.2",
"a tol of 0.1 gives a distribution from 0.18 to 0.22.[PAR]",
"Option [TT]-d[tt] plots all the distances as a function of time.",
"of the bondlength ([TT]-blen[tt]). That means, for a bond of 0.2",
"a tol of 0.1 gives a distribution from 0.18 to 0.22.[PAR]",
"Option [TT]-d[tt] plots all the distances as a function of time.",
- "This requires a structure file for the atom and residue names in",
- "the output. If however the option [TT]-averdist[tt] is given (as well",
+ "If however the option [TT]-averdist[tt] is given (as well",
"or separately) the average bond length is plotted instead."
};
const char *bugs[] = {
"or separately) the average bond length is plotted instead."
};
const char *bugs[] = {
- "It should be possible to get bond information from the topology."
+ "It should be possible to get information about specific bonds from the topology."
};
static real blen = -1.0, tol = 0.1;
static gmx_bool bAver = TRUE, bAverDist = TRUE;
};
static real blen = -1.0, tol = 0.1;
static gmx_bool bAver = TRUE, bAverDist = TRUE;
t_filenm fnm[] = {
{ efTRX, "-f", NULL, ffREAD },
{ efNDX, NULL, NULL, ffREAD },
t_filenm fnm[] = {
{ efTRX, "-f", NULL, ffREAD },
{ efNDX, NULL, NULL, ffREAD },
- { efTPS, NULL, NULL, ffOPTRD },
+ { efTPS, NULL, NULL, ffREAD },
{ efXVG, "-o", "bonds", ffWRITE },
{ efLOG, NULL, "bonds", ffOPTWR },
{ efXVG, "-d", "distance", ffOPTWR }
{ efXVG, "-o", "bonds", ffWRITE },
{ efLOG, NULL, "bonds", ffOPTWR },
{ efXVG, "-d", "distance", ffOPTWR }
NFILE, fnm, asize(pa), pa, asize(desc), desc, asize(bugs), bugs,
&oenv);
NFILE, fnm, asize(pa), pa, asize(desc), desc, asize(bugs), bugs,
&oenv);
+ read_tps_conf(ftp2fn(efTPS, NFILE, fnm), title, &top, &ePBC, &x, NULL, box, FALSE);
+
if (bAverDist)
{
fdist = opt2fn("-d", NFILE, fnm);
if (bAverDist)
{
fdist = opt2fn("-d", NFILE, fnm);
else
{
fdist = opt2fn_null("-d", NFILE, fnm);
else
{
fdist = opt2fn_null("-d", NFILE, fnm);
- if (fdist)
- {
- read_tps_conf(ftp2fn(efTPS, NFILE, fnm), title, &top, &ePBC, &x, NULL, box,
- FALSE);
- }
}
rd_index(ftp2fn(efNDX, NFILE, fnm), 1, &gnx, &index, &grpname);
}
rd_index(ftp2fn(efNDX, NFILE, fnm), 1, &gnx, &index, &grpname);