# -*-shell-script-*-
# Create screw dislocation in BCC Ta with kinks under PBC
#------------------------------------------------------------
setnolog
setoverwrite
dirname = runs/mo-junction
#--------------------------------------------
#Read in potential file
#
potfile = ~/Codes/MD++/potentials/mo_pot readpot
#------------------------------------------------------------
#Read in structure
#incnfile = relaxed.cn readcn
#------------------------------------------------------------
#Create Perfect Lattice Configuration
#
latticestructure = body-centered-cubic latticeconst = 3.1472 #(A) for Mo
latticesize = [  1   1  -2   16
                 1  -1   0   19
                 1   1   2   16
              ]
makecn finalcnfile = perf.cn writecn                
#-------------------------------------------------------------
#Create Dislocation Dipole
# cross screw and screw junction on [112]x[112] lattice
mkdipole = [ 3 2             # z, y
             0.0078125 0 0.0234375 #1/8/16,0,3/8/16, [11-2]*1/8+[112]*3/8=[111]/2
             0.0001 -0.25 0.25
             0.305           # nu
             -10 10 -10 10 1 # number of images
             0 0 0 1         # store displacement, do not commit
           ] 
makedipole finalcnfile = makedp.cn writecn
mkdipole = [ 1 2             # x, y
             0.0234375 0 0.0078125 #3/8/16,0,1/8/16, [11-2]*3/8+[112]*1/8=[11-1]/2
             0.0001 0.25 0.75
             0.305            # nu
             -10 10  -10 10 1 # number of images
             0 0 0 0          # commit displacement field
           ] 
makedipole finalcnfile = makedp.cn writecn
#-------------------------------------------------------------
#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
                      ]
#------------------------
plot_atom_info = 1  plotfreq = 10 
rotateangles = [ 0 0 0 1.5 ]
#
win_width = 600 win_height = 600
#win_width = 200 win_height = 200
openwin alloccolors rotate saverot refreshnnlist eval plot
#sleep quit
#------------------------------------------------------------
#Conjugate-Gradient relaxation
#
conj_ftol = 1e-7 conj_itmax = 1000 conj_fevalmax = 1000
conj_fixbox = 1
relax eval  finalcnfile = relaxed.cn writecn
sleep quit
#-------------------------------------------------------------
