Hi all,
I want to analyze the H-bonds, in simulation of a water-polymer system with class II FF. So, I use pair_style hbond/dreiding/lj and rerun command. My input file is as follows:
boundary p p p
units real
atom_style full
bond_style class2
angle_style class2
dihedral_style class2
improper_style class2
pair_style lj/class2/coul/long 10
pair_modify tail yes table 12
newton on
read_data PP.data
group P type 1 2 3 4 5 6 7 8
kspace_style pppm 1e-4
special_bonds dreiding
neighbor 1 bin
neigh_modify delay 0 every 1 check yes page 1000000
comm_modify mode single cutoff 10
minimize 1.0e-06 1.0e-06 100000 100000
velocity all create 200 492869
reset_timestep 0
fix sh all shake 0.000001 1000 0 b 13 a 28
fix M all npt temp 273 373 100 iso 1 1 1000
dump M P custom 500 dump.lammpstrj id mol type element mass q x y z ix iy iz
thermo 100
thermo_style custom step temp press vol density etotal ke pe time
thermo_modify lost warn flush yes
timestep 1
run 5000
reset_timestep 0
read_dump dump.lammpstrj 500 x y z ix iy iz format native
pair_style hbond/dreiding/lj 4 2.5 3.5 120
pair_coeff 6 9 hbond/dreiding/lj 3 i 9.5 2.75 4
pair_coeff 5 9 hbond/dreiding/lj 3 j 9.5 2.75 4
pair_coeff 5 6 hbond/dreiding/lj 3 j 9.5 2.75 4
pair_coeff 9 9 hbond/dreiding/lj 3 i 9.5 2.75 4
compute hb all pair hbond/dreiding/lj
variable n_hbond equal c_hb[1] #number hbonds
variable E_hbond equal c_hb[2] #hbond energy
thermo_style custom step temp epair v_n_hbond v_E_hbond
rerun dump-productionp.lammpstrj dump x y z box yes
However, I get the following error when it reaches pair_coeff part after rerun. The end lines of the log.lammps file are:
…
…
…
read_dump dump.lammpstrj 500 x y z ix iy iz format native
orthogonal box = (-0.956178 0.403877 -0.85569) to (63.1314 64.4915 63.2319)
27548 atoms before read
572 atoms in snapshot
0 atoms purged
572 atoms replaced
0 atoms trimmed
0 atoms added
27548 atoms after read
pair_style hbond/dreiding/lj 4 2.5 3.5 120
pair_coeff 6 9 hbond/dreiding/lj 3 i 9.5 2.75 4
ERROR: Numeric index is out of bounds (…/force.cpp:690)
If I use the coeffs available as examples in manual for this pair_style, I get this error:
pair_style hbond/dreiding/lj 4 9.0 11.0 90
pair_coeff 6 9 hbond/dreiding/lj 3 i 9.5 2.75 4 9.0 11.0 90.0
ERROR: Incorrect args for pair coefficients (…/pair_hbond_dreiding_lj.cpp:320)
Can someone help me about this error please? BTW, what are the limitations in the pair_style and pair_coeff numeric indexes?
data fiile is also attached.
Thanks
PP.data (3.38 MB)