#---------- units metal boundary s p s atom_style atomic atom_modify map array sort 0 0.0 timestep 0.001 neighbor 2.0 bin neigh_modify delay 0 every 5 check yes #--model region box block 0 300 0 182.519979 0 250 units box #工件 create_box 4 box mass 1 47.867 mass 2 47.867 mass 3 47.867 mass 4 55.845 lattice custom 2.951 origin 0.25 0.0833333 0.25 a1 1 0.0 0.0 a2 0.0 1.732 0.0 a3 0.0 0.0 1.586 & basis 0 0 0 & basis 0.5 0.5 0 & basis 0 0.333333333333333333333333333333 0.5 & basis 0.5 0.83333333333333333333333333333 0.5 region boundary1 block 0 300 0 182.519979 0 10 units box region boundary2 block 0 10 0 182.519979 0 150 units box region boundary3 block 290 300 0 182.519979 0 150 units box region boundary4 union 3 boundary1 boundary2 boundary3 units box #固定? create_atoms 1 region boundary4 group boundary region boundary4 region thermostat1 block 10 290 0 182.519979 10 20 units box region thermostat2 block 10 20 0 182.519979 10 150 units box region thermostat3 block 280 290 0 182.519979 10 150 units box region thermostat4 union 3 thermostat1 thermostat2 thermostat3 units box #恒温? create_atoms 2 region thermostat4 group thermostat region thermostat4 region newton block 20 280 0 182.519979 20 150 units box #牛顿? create_atoms 3 region newton group newton region newton group workpiece subtract all boundary set group boundary type 1 set group thermostat type 2 set group newton type 3 #--------------刀具设? lattice bcc 2.865 #金刚? region tool sphere 70 90 182 30 units box #定义位置 create_atoms 4 region tool #创建原子 group tool region tool set group tool type 4 write_data chushi.file run_style verlet ##################################---Potential pair_style hybrid meam lj/cut 3.0 eam/fs pair_coeff * * meam library.meam Fe Ti FeTi.meam Ti Ti Ti NULL #pair_coeff * * eam/fs Ti2.eam.fs Ti Ti Ti NULL pair_coeff 1 4 lj/cut 0.00064465 2.7115 pair_coeff 2 4 lj/cut 0.00064465 2.7115 pair_coeff 3 4 lj/cut 0.00064465 2.7115 pair_coeff * * eam/fs Fe_2.eam.fs NULL NULL NULL Fe #####################################---Compute compute cna all cna/atom 3.54192936 compute s newton stress/atom NULL compute t workpiece temp variable T equal temp variable P1 equal pxx/10000 variable P2 equal pyy/10000 variable P3 equal pzz/10000 variable P4 equal pxy/10000 variable P5 equal pyz/10000 variable P6 equal pxz/10000 variable Step equal step variable Ener equal etotal variable EnerPot equal pe variable EnerKin equal ke variable press equal press variable f1 equal fcm(tool,x)*1.60217653 variable f2 equal fcm(tool,y)*1.60217653 variable f3 equal fcm(tool,z)*1.60217653 thermo 200 thermo_style custom step temp press lx ly lz pxx pyy pzz etotal pe ke thermo_modify temp t velocity workpiece create 300 123454 temp t #---------------------能量最小化-------------------------- min_style cg minimize 1e-25 1e-25 10000 10000 reset_timestep 0 #---InitialRelaxation fix myfix_tool tool rigid single neigh_modify exclude group tool tool dump mydump1 all cfg 1000 Ti_indent.*.cfg mass type xs ys zs id type c_cna c_s[1] c_s[2] c_s[3] fix chiyu1 workpiece nvt temp 300.0 300.0 0.1 drag 1.0 run 10000 undump mydump1 unfix chiyu1 reset_timestep 0 #####################################---Indent #variable z equal "182-0.1*elapsed*dt" #10m/s thermo 200 thermo_style custom step temp press lx ly lz pxx pyy pzz etotal pe ke thermo_modify temp t dump mydump2 all custom 1000 indent.xyz mass type xs ys zs id type c_cna c_s[1] c_s[2] c_s[3] fix 1 boundary setforce 0.0 0.0 0.0 fix 2 all nve fix 3 thermostat temp/rescale 1 300.0 300.0 0.002 1.0 fix 4 tool move linear 0 0 -0.1 units box #下移速度0.1A/ps,10m/ps fix 5 all print 200 "${Step} ${T} ${Ener} ${P1} ${P2} ${P3} ${press} ${f1} ${f2} ${f3}" file Curve_State_Load_indent.dat title "Step T Ener P1 P2 P3 press f1 f2 f3" screen no variable Dhop equal 29.51 variable check atom "c_dsp[4] > v_Dhop" compute dsp workpiece displace/atom refresh check dump 1 workpiece custom 100 tmp.dump id type x y z dump_modify 1 append yes thresh c_dsp[4] > ${Dhop} & refresh c_dsp delay 100 run 60000 unfix 4 unfix 5 undump mydump2 reset_timestep 0 #####################################---Grinding dump mydump3 all custom 2000 grinding.xyz mass type xs ys zs id type c_cna c_s[1] c_s[2] c_s[3] thermo 200 thermo_style custom step temp press lx ly lz pxx pyy pzz etotal pe ke thermo_modify temp t fix 6 tool move linear 0.2 0 0 units box #速度0.2A/ps fix 7 all print 200 "${Step} ${T} ${Ener} ${P1} ${P2} ${P3} ${press} ${f1} ${f2} ${f3}" file Curve_State_Load_friction.dat title "Step T Ener P1 P2 P3 press f1 f2 f3" screen no run 500000 unfix 6 unfix 7 undump mydump3