I’m currently attempting to reset the values of atom IDs using the “reset_atoms id” command after executing “delete_atoms.” Unfortunately, I encounter the error message: “ERROR: Unknown command: reset_atoms.” Please note that I am using the 23jun , 2022 version of LAMMPS.
variable zmax_del equal ${zmax}-2
variable zmin_del equal ${zmin}+2
region rdel block INF INF INF INF {zmin_del} {zmax_del}
group rdel region rdel
delete_atoms random fraction 0.02 no rdel NULL 482793 bond yes
#delete_atoms 命令随机删除 rdel 组中2%的原子(即约 10 个原子)。
#在使用速度命令之前,必须重置原子 ID,这通过 reset_atoms 命令完成。
reset_atoms id sort yes
velocity carbon_mid create ${T} 48455 mom yes rot yes
fix mynve all nve
compute Tmid carbon_mid temp
fix myber carbon_mid temp/berendsen {T} {T} 100 #对碳_mid 组中的原子应用 Berendsen 恒温器
fix_modify myber temp Tmid