clear
units           metal
atom_style      atomic

# --------------------------------------------------
# INPUT CONFIGURATION
# --------------------------------------------------
boundary        p f f
variable        configuration  string  "add"
variable        tempstart  equal  1200.0
variable        tempstop   equal  1200.0

read_data       ${configuration}.data
log             ${configuration}.log
mass            1       28.0855
mass            2       15.9994
group Si type 1
group O  type 2 

# --------------------------------------------------
# INTERACTION
# --------------------------------------------------
pair_style      tersoff
pair_coeff * *  SiO.tersoff Si O  
neighbor        2.0 bin
neigh_modify    every 1 delay 40 check yes

# --------------------------------------------------
# SETTINGS
# --------------------------------------------------
timestep        0.25e-3 # [ps]
thermo          1
thermo_style    custom step time temp ke pe etotal press pxx pyy pzz

# --------------------------------------------------
# MD STAGE 1 -- high friction (30*dt) to damp excess local energy
# --------------------------------------------------
fix         1  all nve
fix         2  all langevin ${tempstart} ${tempstop} 0.0075 260220161

dump        1 all custom 5000 ${configuration}.dump id element x y z vx vy vz 
dump_modify 1 sort id
dump_modify 1 element Si O

run    5000 
# --------------------------------------------------

# --------------------------------------------------
# MD STAGE 2 -- lower friction (100*dt) to equilibrate
# --------------------------------------------------
unfix       2  
fix         2  all langevin ${tempstart} ${tempstop} 0.025 260220162

dump_modify 1 every 20000

run    20000
# --------------------------------------------------

