3
# 1) You must use moltemplate.sh to create 3 files:
4
# system.data system.in.init system.in.settings
5
# (Follow the instructions in README_setup.sh, or run it using ./README_sh.)
6
# 2) You must equilibrate the system beforehand using "run.in.npt".
7
# This will create the file "system_after_npt.data" which this file reads.
8
# (Note: I have not verified that this equilibration protocol works well.)
14
# lmp_g++ -i run.in.nvt
15
# (assuming lmp_g++ is the name of your lammps binary)
17
# -- Prerequisite Input Files: --
18
# systen.data, system.in.init, system.in.settings, system.in.sw
19
# system_after_npt.data
21
# You can generate these files using this procedure
23
# moltemplate.sh -a "@atom:/WatMW/mW 1" system.lt
25
# lmp_linux -i run.in.npt
27
# ---------------------------------
33
include system.in.init
37
# -- atom definition section --
40
# Read the coordinates generated by an earlier NPT simulation
42
read_data system_after_npt.data
44
# (The "write_restart" and "read_restart" commands were buggy in 2012,
45
# but they should work also. I prefer "write_data" and "read_data".)
48
# -- settings section --
51
include system.in.settings
58
dump 1 all custom 1000 traj_nvt.lammpstrj id mol type x y z ix iy iz
59
dump 2 TraPPE custom 1000 traj_alkane_nvt.lammpstrj id mol type x y z ix iy iz
60
fix fxnvt all nvt temp 300.0 300.0 500.0 tchain 1
62
# The following commands are useful if you want to calculate the distribution
63
# of alkane-chain radius-of-gyration at a given temperature & pressure.
64
#compute cRg TraPPE gyration
65
#variable vRg equal c_cRg
67
#variable vPE equal c_cPE
68
#fix FprintPE all print 1000 "${vPE}" file U.dat
69
#fix FprintRg all print 1000 "${vRg}" file Rg.dat
71
thermo_style custom step temp pe etotal press vol epair ebond eangle edihed
72
thermo 1000 # time interval for printing out "thermo" data
73
#thermo_modify flush yes
75
restart 100000 restart_nvt
79
write_data system_after_nvt.data