Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/Action_GIST.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
#include "Action_GIST.h"
#include "CpptrajStdio.h"
#include "Constants.h"
#include "DataSet_MatrixFlt.h"
#include "DataSet_GridFlt.h"
#include "DataSet_GridDbl.h"
#include "ProgressBar.h"
Expand Down Expand Up @@ -663,7 +664,7 @@ void Action_GIST::NonbondEnergy(Frame const& frameIn, Topology const& topIn)
// Action_GIST::Order()
void Action_GIST::Order(Frame const& frameIn) {
// Loop over all solvent molecules that are on the grid
for (unsigned int gidx = 0; gidx < N_ON_GRID_; gidx += 3)
for (unsigned int gidx = 0; gidx < N_ON_GRID_; gidx += nMolAtoms_)
{
int oidx1 = OnGrid_idxs_[gidx];
int voxel1 = atom_voxel_[oidx1];
Expand Down
4 changes: 2 additions & 2 deletions src/Action_GIST.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
#define INC_ACTION_GIST_H
#include "Action.h"
#include "ImagedAction.h"
#include "DataSet_3D.h"
#include "DataSet_MatrixFlt.h"
#include "Timer.h"
class DataSet_3D;
class DataSet_MatrixFlt;
/// Class for applying Grid Inhomogenous Solvation Theory
/** \author Daniel R. Roe
*/
Expand Down
29 changes: 25 additions & 4 deletions test/Test_GIST_Order/RunTest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,43 @@

. ../MasterTest.sh

CleanFiles gist.in gist-*.dx gistout.dat
CleanFiles gist.in gist-*.dx gistout.dat tip4p.dat tip5p.dat

TESTNAME='GIST tetrahedral water cluster test'
TESTNAME='GIST tetrahedral water cluster tests'
Requires notparallel

INPUT="-i gist.in"

UNITNAME='TIP3P water cluster test'
cat > gist.in <<EOF
parm test_gist.prmtop
trajin test_gist-center.crd
gist doorder gridcntr 0.5 0.5 0.5 griddim 1 1 1 gridspacn 1.0 out gistout.dat refdens 0.0333
EOF
RunCpptraj "$TESTNAME"

RunCpptraj "$UNITNAME"
DoTest gist-order-norm.dx.save gist-order-norm.dx
DoTest gistout.dat.save gistout.dat

UNITNAME='TIP4P water cluster test'
cat > gist.in <<EOF
parm tip4pew.cluster.parm7
trajin tip4pew.cluster.rst7
gist doorder gridcntr 0.5 0.5 0.5 griddim 1 1 1 gridspacn 1.0 out tip4p.dat refdens 0.0333
EOF
RunCpptraj "$UNITNAME"
#DoTest gist-order-norm.dx.save gist-order-norm.dx
DoTest tip4p.dat.save tip4p.dat

UNITNAME='TIP5P water cluster test'
cat > gist.in <<EOF
parm tip5p.cluster.parm7
trajin tip5p.cluster.rst7
gist doorder gridcntr 0.5 0.5 0.5 griddim 1 1 1 gridspacn 1.0 out tip5p.dat refdens 0.0333
EOF
RunCpptraj "$UNITNAME"
#DoTest gist-order-norm.dx.save gist-order-norm.dx
DoTest tip5p.dat.save tip5p.dat


EndTest
exit 0
2 changes: 1 addition & 1 deletion test/Test_GIST_Order/test_gist-center.crd
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ Cpptraj Generated trajectory
0.000 -0.254 0.021 -0.923 0.849 0.441 0.025 -2.691 0.685 0.703
-2.666 0.593 1.656 -1.834 0.375 0.411 2.133 1.334 0.972 1.864
1.133 1.868 2.207 2.288 0.952
32.472 32.489 32.464
32.472 32.489 32.464
3 changes: 3 additions & 0 deletions test/Test_GIST_Order/tip4p.dat.save
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
GIST Output, information printed per voxel
voxel xcoord ycoord zcoord population g_O g_H dTStrans-dens(kcal/mol/A^3) dTStrans-norm(kcal/mol) dTSorient-dens(kcal/mol/A^3) dTSorient-norm(kcal/mol) dTSsix-dens(kcal/mol/A^3) dTSsix-norm (kcal/mol) Esw-dens(kcal/mol/A^3) Esw-norm(kcal/mol) Eww-dens(kcal/mol/A^3) Eww-norm-unref(kcal/mol) Dipole_x-dens(D/A^3) Dipole_y-dens(D/A^3) Dipole_z-dens(D/A^3) Dipole-dens(D/A^3) neighbor-dens(1/A^3) neighbor-norm order-norm
0 0.5 0.5 0.5 1 30.03 15.015 0 0 0 0 0 0 0 0 0 0 1.17821 0.914938 -1.77876 2.32148 4 4 0.958873
163 changes: 163 additions & 0 deletions test/Test_GIST_Order/tip4pew.cluster.parm7
Original file line number Diff line number Diff line change
@@ -0,0 +1,163 @@
%VERSION VERSION_STAMP = V0001.000 DATE = 11/02/16 10:09:38
%FLAG TITLE
%FORMAT(20a4)
default_name
%FLAG POINTERS
%FORMAT(10I8)
20 3 15 5 0 0 0 0 0 0
35 5 5 0 0 3 0 0 3 1
0 0 0 0 0 0 0 1 4 0
5
%FLAG ATOM_NAME
%FORMAT(20a4)
O H1 H2 EPW O H1 H2 EPW O H1 H2 EPW O H1 H2 EPW O H1 H2 EPW
%FLAG CHARGE
%FORMAT(5E16.8)
0.00000000E+00 9.55249411E+00 9.55249411E+00 -1.91049882E+01 0.00000000E+00
9.55249411E+00 9.55249411E+00 -1.91049882E+01 0.00000000E+00 9.55249411E+00
9.55249411E+00 -1.91049882E+01 0.00000000E+00 9.55249411E+00 9.55249411E+00
-1.91049882E+01 0.00000000E+00 9.55249411E+00 9.55249411E+00 -1.91049882E+01
%FLAG ATOMIC_NUMBER
%FORMAT(10I8)
8 1 1 0 8 1 1 0 8 1
1 0 8 1 1 0 8 1 1 0
%FLAG MASS
%FORMAT(5E16.8)
1.60000000E+01 1.00800000E+00 1.00800000E+00 0.00000000E+00 1.60000000E+01
1.00800000E+00 1.00800000E+00 0.00000000E+00 1.60000000E+01 1.00800000E+00
1.00800000E+00 0.00000000E+00 1.60000000E+01 1.00800000E+00 1.00800000E+00
0.00000000E+00 1.60000000E+01 1.00800000E+00 1.00800000E+00 0.00000000E+00
%FLAG ATOM_TYPE_INDEX
%FORMAT(10I8)
1 2 2 3 1 2 2 3 1 2
2 3 1 2 2 3 1 2 2 3
%FLAG NUMBER_EXCLUDED_ATOMS
%FORMAT(10I8)
3 2 1 1 3 2 1 1 3 2
1 1 3 2 1 1 3 2 1 1
%FLAG NONBONDED_PARM_INDEX
%FORMAT(10I8)
1 -1 4 -1 3 5 4 5 6
%FLAG RESIDUE_LABEL
%FORMAT(20a4)
WAT WAT WAT WAT WAT
%FLAG RESIDUE_POINTER
%FORMAT(10I8)
1 5 9 13 17
%FLAG BOND_FORCE_CONSTANT
%FORMAT(5E16.8)
5.53000000E+02 5.53000000E+02 5.53000000E+02
%FLAG BOND_EQUIL_VALUE
%FORMAT(5E16.8)
1.51360000E+00 1.25000000E-01 9.57200000E-01
%FLAG ANGLE_FORCE_CONSTANT
%FORMAT(5E16.8)

%FLAG ANGLE_EQUIL_VALUE
%FORMAT(5E16.8)

%FLAG DIHEDRAL_FORCE_CONSTANT
%FORMAT(5E16.8)

%FLAG DIHEDRAL_PERIODICITY
%FORMAT(5E16.8)

%FLAG DIHEDRAL_PHASE
%FORMAT(5E16.8)

%FLAG SCEE_SCALE_FACTOR
%FORMAT(5E16.8)

%FLAG SCNB_SCALE_FACTOR
%FORMAT(5E16.8)

%FLAG SOLTY
%FORMAT(5E16.8)
0.00000000E+00 0.00000000E+00 0.00000000E+00
%FLAG LENNARD_JONES_ACOEF
%FORMAT(5E16.8)
6.56136207E+05 0.00000000E+00 0.00000000E+00 0.00000000E+00 0.00000000E+00
0.00000000E+00
%FLAG LENNARD_JONES_BCOEF
%FORMAT(5E16.8)
6.53563058E+02 0.00000000E+00 0.00000000E+00 0.00000000E+00 0.00000000E+00
0.00000000E+00
%FLAG BONDS_INC_HYDROGEN
%FORMAT(10I8)
3 6 1 0 3 3 0 6 3 15
18 1 12 15 3 12 18 3 27 30
1 24 27 3 24 30 3 39 42 1
36 39 3 36 42 3 51 54 1 48
51 3 48 54 3
%FLAG BONDS_WITHOUT_HYDROGEN
%FORMAT(10I8)
0 9 2 12 21 2 24 33 2 36
45 2 48 57 2
%FLAG ANGLES_INC_HYDROGEN
%FORMAT(10I8)

%FLAG ANGLES_WITHOUT_HYDROGEN
%FORMAT(10I8)

%FLAG DIHEDRALS_INC_HYDROGEN
%FORMAT(10I8)

%FLAG DIHEDRALS_WITHOUT_HYDROGEN
%FORMAT(10I8)

%FLAG EXCLUDED_ATOMS_LIST
%FORMAT(10I8)
2 3 4 3 4 4 0 6 7 8
7 8 8 0 10 11 12 11 12 12
0 14 15 16 15 16 16 0 18 19
20 19 20 20 0
%FLAG HBOND_ACOEF
%FORMAT(5E16.8)
0.00000000E+00
%FLAG HBOND_BCOEF
%FORMAT(5E16.8)
0.00000000E+00
%FLAG HBCUT
%FORMAT(5E16.8)
0.00000000E+00
%FLAG AMBER_ATOM_TYPE
%FORMAT(20a4)
OW HW HW EP OW HW HW EP OW HW HW EP OW HW HW EP OW HW HW EP
%FLAG TREE_CHAIN_CLASSIFICATION
%FORMAT(20a4)
BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA BLA
%FLAG JOIN_ARRAY
%FORMAT(10I8)
0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0
%FLAG IROTAT
%FORMAT(10I8)
0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0
%FLAG SOLVENT_POINTERS
%FORMAT(3I8)
0 5 1
%FLAG ATOMS_PER_MOLECULE
%FORMAT(10I8)
4 4 4 4 4
%FLAG BOX_DIMENSIONS
%FORMAT(5E16.8)
9.00000000E+01 4.89800000E+00 5.27200000E+00 5.13200000E+00
%FLAG RADIUS_SET
%FORMAT(1a80)
modified Bondi radii (mbondi)
%FLAG RADII
%FORMAT(5E16.8)
1.50000000E+00 8.00000000E-01 8.00000000E-01 1.50000000E+00 1.50000000E+00
8.00000000E-01 8.00000000E-01 1.50000000E+00 1.50000000E+00 8.00000000E-01
8.00000000E-01 1.50000000E+00 1.50000000E+00 8.00000000E-01 8.00000000E-01
1.50000000E+00 1.50000000E+00 8.00000000E-01 8.00000000E-01 1.50000000E+00
%FLAG SCREEN
%FORMAT(5E16.8)
8.50000000E-01 8.50000000E-01 8.50000000E-01 8.00000000E-01 8.50000000E-01
8.50000000E-01 8.50000000E-01 8.00000000E-01 8.50000000E-01 8.50000000E-01
8.50000000E-01 8.00000000E-01 8.50000000E-01 8.50000000E-01 8.50000000E-01
8.00000000E-01 8.50000000E-01 8.50000000E-01 8.50000000E-01 8.00000000E-01
%FLAG IPOL
%FORMAT(1I8)
0
13 changes: 13 additions & 0 deletions test/Test_GIST_Order/tip4pew.cluster.rst7
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Cpptraj Generated Restart
20
-0.3000000 0.3200000 -2.7880000 -1.0730000 0.6270000 -3.2640000
-0.2420000 -0.6110000 -3.0000000 -0.3761656 0.2533315 -2.8613431
0.1770000 -2.6280000 0.8000000 -0.6900000 -2.9840000 0.6050000
0.0700000 -1.6790000 0.7220000 0.0731324 -2.5648390 0.7708914
-0.0000000 0.0000000 0.0000000 -0.2540000 0.0210000 -0.9230000
0.8490000 0.4410000 0.0250000 0.0635003 0.0492875 -0.0957264
-2.6910000 0.6850000 0.7030000 -2.6660000 0.5930000 1.6560000
-1.8340000 0.3750000 0.4110000 -2.5969349 0.6421447 0.7732872
2.1330000 1.3340000 0.9720000 1.8640000 1.1330000 1.8680000
2.2070000 2.2880000 0.9520000 2.1121896 1.4143335 1.0654802
32.4720000 32.4890000 32.4640000 90.0000000 90.0000000 90.0000000
Loading