Hi LAMMPS Users,

I am trying to construct a dislocation by positioning the atomic planes such that a dislocation will be generated after the minimization at the centre of the box. I can create the geometry which looks good in visualization as well. I need to minimize the energy while allowing the box to expand.

I am using box/relax along with minimize. I intend to impart strain in successive quasistatic steps after the minimization. I am also fixing the top and bottom slab of few atoms each and constraining them by fix setforce 0 0 0.

When I run the minimization, the temperature and pressure in thermodynamic output doesnot corrrespond to 0 K and 0 pressure. I was wondering whether it is a consequence of constraining by setforce, or it is something else? I doubt it as a consequence of setforce. If it is, does it make sense to use different compute id of temperature and pressure corresponding to nonfrozen atoms? What does that signify physically? And while straining it, temperature and pressure corresponding to which group of atoms would be more sensible.

Attaching the input file for your perusal

variable TEMP equal 0.0

variable LATSCALE equal 1.0

variable NINIT equal 9

variable XTOP1 equal 1

variable XTOP2 equal 1

variable XTOP3 equal 1

variable YTOP1 equal 1

variable YTOP2 equal -1

variable YTOP3 equal 0

variable ZTOP1 equal 1

variable ZTOP2 equal 1

variable ZTOP3 equal -2

variable unitX equal 1.73205*0.5

variable unitY equal 1.41421

variable unitZ equal 2.44950

variable SIZEX equal 80

variable SIZEY equal 80

variable SIZEZ equal 12

variable HALFX equal {SIZEX}*0.5
variable HALFY equal {SIZEY}*0.5

variable LENGTHX equal ${SIZEX}*1.0001

variable LENGTHY equal {SIZEY}*1.00
variable LENGTHZ equal {SIZEZ}*1.0001

variable UPPERX equal ${SIZEX}*1.000001

variable LOWERX equal ({SIZEX}-1)*1.0001 variable FINALX equal ({SIZEX}-0.5)*1.000001

variable sclUPP equal {FINALX}/{UPPERX}

variable sclLOW equal {FINALX}/{LOWERX}

variable HALFLX equal 0.5*{LENGTHX} variable HALFLY equal 0.5*{LENGTHY}*1.0000001

variable frozenslab equal 10

variable latparam equal 2.85531344*${LATSCALE}

variable cutoffpctg equal 0.7

variable delcutoff equal 0.5*sqrt(3)*{latparam}*{cutoffpctg}

variable NCLUST equal 1

variable DISTY equal 0.0

variable DISTX equal 30.0

variable helrad equal 0.5

variable SIZECLUST equal 3

log LOG.create.CLUSTER.EDGE.dislocation.SHEAR.INIT.{NINIT}.{SIZEX}.{SIZEY}.{SIZEZ}.txt

clear

units metal

dimension 3

boundary p p p

atom_style atomic

box tilt large

lattice bcc {latparam} spacing {unitX} {unitY} {unitZ} orient x {XTOP1} {XTOP2} {XTOP3} orient y {YTOP1} {YTOP2} {YTOP3} orient z {ZTOP1} {ZTOP2} ${ZTOP3}

region box prism 0 {LENGTHX} 0 {LENGTHY} 0 ${LENGTHZ} 0 0 0 units lattice

create_box 2 box

region uppbox prism 0 {UPPERX} 0 {HALFLY} 0 {LENGTHZ} 0 0 0 units lattice region lowbox prism 0 {LOWERX} {HALFLY} {LENGTHY} 0 ${LENGTHZ} 0 0 0 units lattice

create_atoms 1 region uppbox

create_atoms 1 region lowbox

group upper region uppbox

group lower region lowbox

pair_style eam/fs

pair_coeff * * FeHe-with_radcrit_0.50.eam.fs Fe He

neighbor 2.0 bin

neigh_modify delay 10 check yes

delete_atoms overlap ${delcutoff} all all

compute poteng all pe/atom

thermo 1000

thermo_style custom step pe ke etotal temp pxx pyy pzz press vol lx ly lz

#dump dump2 all xyz 1 XYZ.create.EDGE.dislocation.*.xyz

variable xupp atom x*({sclUPP}-1) variable xlow atom x*({sclLOW}-1)

fix 1 upper move variable v_xupp NULL NULL NULL NULL NULL

fix 2 lower move variable v_xlow NULL NULL NULL NULL NULL

run 1

unfix 1

unfix 2

change_box all x final 0 {FINALX} units lattice delete_atoms overlap {delcutoff} all all

variable LENGTHXX1 equal lx

variable LENGTHYY1 equal ly

variable LENGTHZZ1 equal lz

variable lowery equal ylo

variable uppery equal yhi

variable freezeLO equal {lowery}+{frozenslab}

variable freezeUP equal {uppery}-{frozenslab}

region freeze1 prism EDGE EDGE {lowery} {freezeLO} EDGE EDGE 0 0 0 units box

region freeze2 prism EDGE EDGE {freezeUP} {uppery} EDGE EDGE 0 0 0 units box

group frozenlo region freeze1

group frozenup region freeze2

region freeze union 2 freeze1 freeze2

group frozen region freeze

include adding.clusters.N${NCLUST}.size${SIZECLUST}.init${NINIT}.y[{DISTY}].x[{DISTX}].in

group helium type 2

group nonfrozenhel subtract all frozen

group nonfrozen subtract nonfrozenhel helium

fix freezeatoms frozen setforce 0.0 0.0 0.0

dump dump1 nonfrozenhel cfg 10000 DUMP/CFG.create.CLUSTER.EDGE.INIT${NINIT}.NCLUST${NCLUST}.DISTY${DISTY}.DISTX${DISTX}.*.cfg mass type xs ys zs id

dump_modify dump1 element Fe He

thermo 100

thermo_style custom step pe ke etotal temp pxx pyy pzz press vol lx ly lz

fix 1 all move variable NULL NULL NULL NULL NULL NULL

run 1

unfix 1

fix 1 all box/relax aniso 0.0

min_style cg

minimize 1e-15 1e-15 50000 100000