# -*-shell-script-*-
# MD code of BCC Mo. edge dislocation
#  MD simulations with surface force and Nose-Hoover thermostat
#------------------------------------------------------------
setnolog
setoverwrite
dirname = runs/mo-edge-md-nh
#--------------------------------------------
#Read in potential file
#
potfile = ~/Codes/MD++/potentials/mo_pot readpot
#------------------------------------------------------------
#Read in structure (created by mo-edge-eq.script)
#
incnfile = ../mo-edge/moedge-1.cn readcn
#------------------------------------------------------------
#Define surface atoms
plot_color_axis = 2   eval  #2 means CSD
# select top surface atoms (by both position and CSD parameter)
#  top surface has 720 atoms
input = [ 1 -10 10 0.2 10  -10 10 10 100 ] fixatoms_by_pos_topol
input = 1 setfixedatomsgroup freeallatoms
# select bottom surface atoms
#  bottom surface has 696 atoms
input = [ 1 -10 10 -10 -0.2 -10 10 10 100 ] fixatoms_by_pos_topol
input = 2 setfixedatomsgroup freeallatoms
#
# apply surface force (corresponding to sigma_xy = 300 MPa)
#  make sure the total force is exactly zero (no center of mass motion)
extforce = [ 2    0.0128986111111111 0 0 # force (fx,fy,fz) on group 1
                 -0.0133433908045977 0 0 # force (fx,fy,fz) on group 2
           ]
#------------------------------------------------------------
#Plot Configuration
atomradius = 1.0 bondradius = 0.3 bondlength = 0
atomcolor = cyan highlightcolor = purple backgroundcolor = gray
bondcolor = red fixatomcolor = yellow
color00 = "orange"  color01 = "red"    color02 = "green"
color03 = "magenta" color04 = "cyan"   color05 = "purple"
color06 = "gray80"  color07 = "white"  color08 = "blue"
#------------------------
#Use local energy to plot
#plot_color_axis = 0  #0: use local energy (default)
#plot_color_windows = [ 2
#                       -6.725  -6.0 8 #color08 = blue
#                       -6.0     0   6 #color06 = gray80
#                      ]
#------------------------
#Use CSD to plot
plot_color_axis = 2  #2: use CSD (default 0: use local energy)
NCS = 8 #number of neighboring atoms in CSD analysis (default: 12 - fcc)
plot_color_windows = [ 2
                       1.5  10  4  #color04 = cyan
                       10   20  6  #color06 = gray80
                     ]
plot_atom_info = 1  plotfreq = 10 
rotateangles = [ 0 0 0 1.5 ]
#
win_width = 600 win_height = 600
openwin alloccolors rotate saverot refreshnnlist eval plot
#sleep quit
#-------------------------------------------------------------
#Molecular Dynamics setting (with surface force, no thermostat)
#
T_OBJ = 300 #(in K)
timestep = 0.0005 # (ps)
atommass = 95.94  #Mo (g/mol)
#
integrator_type = 1        #Velocity Verlet Algorithm
#
usenosehoover = 1  vt2 = 1e28 #vt2 = 3Nk_BT/Ms (in s^(-2)) 
#
totalsteps = 100000
saveprop = 1 savepropfreq = 10 openpropfile 
#
savecn = 1 savecnfreq = 1000 openintercnfile
#
run
writeall = 1 finalcnfile = moedge-2.cn writecn
quit
#-------------------------------------------------------------
