/* P.J. van Maaren, November 2005 Added tetrahedral stuff */
/****************************************************************************/
-static void find_nearest_neighbours(int ePBC,
+static void find_nearest_neighbours(PbcType pbcType,
int natoms,
matrix box,
rvec x[],
snew(skmol, maxidx);
/* Must init pbc every step because of pressure coupling */
- set_pbc(&pbc, ePBC, box);
+ set_pbc(&pbc, pbcType, box);
gmx_rmpbc(gpbc, natoms, box, x);
{
FILE * fpsg = nullptr, *fpsk = nullptr;
t_topology top;
- int ePBC;
+ PbcType pbcType;
t_trxstatus* status;
int natoms;
real t;
gmx_rmpbc_t gpbc = nullptr;
- read_tps_conf(fnTPS, &top, &ePBC, &xtop, nullptr, box, FALSE);
+ read_tps_conf(fnTPS, &top, &pbcType, &xtop, nullptr, box, FALSE);
snew(sg_slice, nslice);
snew(sk_slice, nslice);
fpsk = xvgropen(skfn, "S\\sk\\N Distance Order Parameter", "Time (ps)", "S\\sk\\N", oenv);
/* loop over frames */
- gpbc = gmx_rmpbc_init(&top.idef, ePBC, natoms);
+ gpbc = gmx_rmpbc_init(&top.idef, pbcType, natoms);
nframes = 0;
do
{
- find_nearest_neighbours(ePBC, natoms, box, x, isize[0], index[0], &sg, &sk, nslice,
+ find_nearest_neighbours(pbcType, natoms, box, x, isize[0], index[0], &sg, &sk, nslice,
slice_dim, sg_slice, sk_slice, gpbc);
for (i = 0; (i < nslice); i++)
{
gmx_bool bSliced,
gmx_bool bUnsat,
const t_topology* top,
- int ePBC,
+ PbcType pbcType,
int ngrps,
int axis,
gmx_bool permolecule,
teller = 0;
- gpbc = gmx_rmpbc_init(&top->idef, ePBC, natoms);
+ gpbc = gmx_rmpbc_init(&top->idef, pbcType, natoms);
/*********** Start processing trajectory ***********/
do
{
}
teller++;
- set_pbc(&pbc, ePBC, box);
+ set_pbc(&pbc, pbcType, box);
gmx_rmpbc_copy(gpbc, natoms, box, x0, x1);
/* Now loop over all groups. There are ngrps groups, the order parameter can
}
write_sto_conf(opt2fn("-ob", nfile, fnm), "Order parameters", &useatoms, frout.x, nullptr,
- frout.ePBC, frout.box);
+ frout.pbcType, frout.box);
sfree(frout.x);
done_atom(&useatoms);
char** grpname; /* groupnames */
int ngrps, /* nr. of groups */
i, axis = 0; /* normal axis */
- t_topology* top; /* topology */
- int ePBC;
- int * index, /* indices for a */
- *a; /* atom numbers in each group */
- t_blocka* block; /* data from index file */
+ t_topology* top; /* topology */
+ PbcType pbcType; /* type of periodic boundary conditions */
+ int * index, /* indices for a */
+ *a; /* atom numbers in each group */
+ t_blocka* block; /* data from index file */
t_filenm fnm[] = {
/* files for g_order */
{ efTRX, "-f", nullptr, ffREAD }, /* trajectory file */
fprintf(stderr, "Taking carbons as unsaturated!\n");
}
- top = read_top(ftp2fn(efTPR, NFILE, fnm), &ePBC); /* read topology file */
+ top = read_top(ftp2fn(efTPR, NFILE, fnm), &pbcType); /* read topology file */
block = init_index(ftp2fn(efNDX, NFILE, fnm), &grpname);
index = block->index; /* get indices from t_block block */
print_types(index, a, ngrps, grpname, top);
calc_order(ftp2fn(efTRX, NFILE, fnm), index, a, &order, &slOrder, &slWidth, nslices,
- bSliced, bUnsat, top, ePBC, ngrps, axis, permolecule, radial, distcalc,
+ bSliced, bUnsat, top, pbcType, ngrps, axis, permolecule, radial, distcalc,
opt2fn_null("-nr", NFILE, fnm), &distvals, oenv);
if (radial)