-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b09d522
commit 232d8f3
Showing
2 changed files
with
1,070 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
############################# | ||
### Configure system type ### | ||
############################# | ||
|
||
units metal | ||
boundary p p p | ||
atom_style charge | ||
|
||
################################ | ||
### Define system parameters ### | ||
################################ | ||
|
||
region myRegion block 0.0 32.65 0.0 32.65 0.0 32.65 | ||
create_box 2 myRegion | ||
|
||
############################################################## | ||
### Read input file and assign types and elementary groups ### | ||
############################################################## | ||
|
||
# We start from a xyz file | ||
|
||
read_dump NaCl.xyz 0 x y z box no add yes format xyz | ||
set atom 1*500 type 1 | ||
set atom 501*1000 type 2 | ||
mass 1 22.989 | ||
mass 2 35.453 | ||
set atom 1*500 charge 1 | ||
set atom 501*1000 charge -1 | ||
group Na type 1 | ||
group Cl type 2 | ||
|
||
velocity all create 1100 132465 | ||
|
||
######################################## | ||
### Define forcefield for simulation ### | ||
######################################## | ||
|
||
kspace_style pppm 1.0e-4 | ||
|
||
# order: A, rho, sigma, C, D | ||
pair_style born/coul/long 10.0 | ||
pair_style born/coul/long 10.0 8. | ||
pair_coeff 1 1 0.26370336 0.31699740062 2.340 1.048573120 0.49932058 | ||
pair_coeff 1 2 0.21096269 0.31699740062 2.755 6.990487130 8.67580800 | ||
pair_coeff 2 2 0.15822202 0.31699740062 3.170 72.40147522 145.42710039 | ||
|
||
# ***************************************** # | ||
# *********** Run NPT Simulation ********** # | ||
# ***************************************** # | ||
|
||
timestep 0.001 | ||
fix myBarostat all npt temp 1100 1100 $(50*dt) iso 1.0 1.0 $(500*dt) | ||
|
||
# Compute the pressure. | ||
compute myTemp all temp | ||
|
||
# Set the dump file to dump every 1000 time steps. | ||
dump myDump1 all custom 1000 NPT.lammpstraj id type element x y z | ||
dump_modify myDump1 element Na Cl | ||
dump_modify myDump1 sort id | ||
dump_modify myDump1 append yes | ||
|
||
log NPT.log append | ||
|
||
# Define the output and run. | ||
thermo 1000 | ||
thermo_style custom step time temp density press | ||
run 200000 |
Oops, something went wrong.