| 1 |
# PREREQUISITES: |
| 2 |
# |
| 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, |
| 6 |
# or run the file as a script using ./README_setup.sh) |
| 7 |
# 2) You must equilibrate the system beforehand using "run.in.npt". |
| 8 |
# This will create the file "system_after_npt.data" which this file reads. |
| 9 |
# (Note: I have not verified that this equilibration protocol works well.) |
| 10 |
|
| 11 |
# ------------------------------- Initialization Section -------------------- |
| 12 |
|
| 13 |
include "system.in.init" # specify the style of force field used |
| 14 |
|
| 15 |
# Weird LAMMPS issue: |
| 16 |
# The "system.in.init" file contains definitions for bond, angle, dihedral, |
| 17 |
# and improper interactions that were defined in the AMBER/GAFF2 force-field. |
| 18 |
# But since the molecules in this example do not have any improper interactions, |
| 19 |
# LAMMPS will crash. To get around this, tell LAMMPS to disable all |
| 20 |
# improper interactions: |
| 21 |
|
| 22 |
improper_style none |
| 23 |
|
| 24 |
# ------------------------------- Atom Definition Section ------------------- |
| 25 |
|
| 26 |
# Read the coordinates generated by an earlier NPT simulation |
| 27 |
|
| 28 |
read_data "system_after_npt.data" |
| 29 |
|
| 30 |
# (The "write_restart" and "read_restart" commands were buggy in 2012, |
| 31 |
# but they should work also. I prefer "write_data" and "read_data".) |
| 32 |
|
| 33 |
# ------------------------------- Settings Section -------------------------- |
| 34 |
|
| 35 |
include "system.in.settings" # load the force field parameters |
| 36 |
|
| 37 |
# ------------------------------- Run Section ------------------------------- |
| 38 |
|
| 39 |
# -- simulation protocol -- |
| 40 |
|
| 41 |
|
| 42 |
timestep 2.0 |
| 43 |
|
| 44 |
thermo 500 |
| 45 |
#thermo_modify flush yes |
| 46 |
|
| 47 |
dump 1 all custom 2000 traj_nvt.lammpstrj id mol type x y z ix iy iz |
| 48 |
|
| 49 |
fix fxnvt all nvt temp 300.0 300.0 500.0 tchain 1 |
| 50 |
|
| 51 |
run 1000000 |
| 52 |
|
| 53 |
write_data "system_after_nvt.data" |