variable R equal 24.6 variable T equal 300 variable L equal 200 variable dt equal 60 variable Thot equal $T+${dt}/2.0 variable Tcold equal $T-${dt}/2.0 log log.lammpsT$TR$R echo both units metal atom_style atomic boundary s s s read_data data25.txt ######################################## MASS mass 1 72.64 mass 2 12.001 ######################################## VELOCITY velocity all create $T 87287 mom yes rot yes dist uniform ######################################## POTENTIAL pair_style tersoff pair_coeff * * CGe.tersoff Ge C neighbor 2 bin neigh_modify every 50 delay 0 region right block INF INF INF INF 200 INF units box group right region right delete_atoms group right ######################################## REGIONS region fl block INF INF INF INF INF 5 units box group fl region fl region 0 block INF INF INF INF 10 15 units box region hot block INF INF INF INF 15 30 units box group hot region hot region 1 block INF INF INF INF 30 40 units box region 2 block INF INF INF INF 40 50 units box region 3 block INF INF INF INF 50 60 units box region 4 block INF INF INF INF 60 70 units box region 5 block INF INF INF INF 70 80 units box region 6 block INF INF INF INF 80 90 units box region 7 block INF INF INF INF 90 100 units box region 8 block INF INF INF INF 100 110 units box region 9 block INF INF INF INF 110 120 units box region 10 block INF INF INF INF 120 130 units box region 11 block INF INF INF INF 130 140 units box region 12 block INF INF INF INF 140 150 units box region 13 block INF INF INF INF 150 160 units box region 14 block INF INF INF INF 160 170 units box region cold block INF INF INF INF 170 185 units box group cold region cold region 15 block INF INF INF INF 185 190 units box region fr block INF INF INF INF 190 INF units box group fr region fr group 1 region 1 group 2 region 2 group 3 region 3 group 4 region 4 group 5 region 5 group 6 region 6 group 7 region 7 group 8 region 8 group 9 region 9 group 10 region 10 group 11 region 11 group 12 region 12 group 13 region 13 group 14 region 14 group middle subtract all fl fr hot cold ######################################## HOT & COLD fix 1 hot nvt temp ${Thot} ${Thot} 0.1 fix 2 cold nvt temp ${Tcold} ${Tcold} 0.1 fix 5 middle nve ######################################## SETFORCE fix 3 fl setforce 0 0 0 fix 4 fr setforce 0 0 0 velocity fl set 0 0 0 units box velocity fr set 0 0 0 units box ######################################## compute hot hot temp compute 1 1 temp compute 2 2 temp compute 3 3 temp compute 4 4 temp compute 5 5 temp compute 6 6 temp compute 7 7 temp compute 8 8 temp compute 9 9 temp compute 10 10 temp compute 11 11 temp compute 12 12 temp compute 13 13 temp compute 14 14 temp compute cold cold temp ######################################## compute ke middle ke/atom compute pe middle pe/atom compute stress middle stress/atom NULL virial ######################################## compute J middle heat/flux ke pe stress variable Jz equal c_J[3]/(3.14*$R*$R*140) ######################################## thermo 1000 thermo_style custom step fix ave all ave/time 1 500000 500000 v_Jz c_hot c_1 c_2 c_3 c_4 c_5 c_6 c_7 c_8 c_9 c_10 & c_11 c_12 c_13 c_14 c_cold file ave-r${R}-T$T-dt${dt}.txt dump 1 all atom 500000 dump-r${R}-T$T-dt${dt}.lammpstrj timestep 0.001 run 2000000 group 9000 id 9000 dump 7 9000 custom 1 dump.txt vx vy vz run 10000