LAMMPS UF3:BCC Nb短动力学
54原子Nb的完整NVE输入、0.25fs时间步与25fs真实轨迹,提取能量和结构图。
阅读本篇目录
本篇把UF3模型用于54原子BCC Nb,演示从结构、初始速度到NVE轨迹和能量图。轨迹只有25 fs,适合熟悉操作,不能据此判断平衡温度、扩散系数或热导率。
1. 先读取已有结果#
下载完整输入、实际输出、数据与绘图脚本,保存为example.zip:
python3 -m zipfile -e example.zip .
cd lammps-uf3-niobium
module load ase/3.29.0
bash read.sh
bash plot.sh
这两条脚本默认读取资料包已有结果,在analysis-read/生成CSV,在figures/出图。新计算单独写入work-new/,与参考数据分开。

inputs/models/bcc-scale1.0.data为基准BCC,实际数据还包含±2%晶格尺度和小位移构型。点的颜色表示当前模型原子力大小,并不代表原子温度。
2. 动力学输入#
units metal
atom_style atomic
boundary p p p
newton on
read_data ../models/bcc-scale1.0.data
pair_style uf3 3
pair_coeff * * ../potentials/Nb.uf3 Nb
neighbor 1.0 bin
neigh_modify every 1 delay 0 check yes
timestep 0.00025
velocity all create 300 833001 mom yes rot yes dist gaussian
fix integrator all nve
thermo 5
thermo_style custom step atoms temp pe ke etotal press
thermo_modify norm no format float %.16g
variable total equal etotal
fix save all ave/time 1 1 1 c_thermo_temp c_thermo_pe v_total file MD.dat format "%20.16g"
dump trajectory all custom 5 MD.dump id type x y z vx vy vz fx fy fz
dump_modify trajectory sort id format float %.16g
run 100
0.00025 ps=0.25 fs,100步共25 fs。velocity create 300只生成以300 K为目标的初始速度,后面的NVE没有恒温器,瞬时温度会变化。variable total必须先于引用它的fix save定义。
3. 提交、读取和查看轨迹#
bash submit.sh
squeue -u "$USER"
# 作业结束后
bash read.sh work-new analysis-new
bash plot.sh analysis-new figures-new work-new
head -6 analysis-new/UF3-Nb-short-NVE.csv
新计算沿用模型与后端设置。MD.dump含坐标、速度和力,可在OVITO中直接打开;MD.dat记录逐步温度、势能和总能量。
4. 本例得到什么#
P100和V10016G各运行普通主机/KOKKOS两种路径,共四条100步轨迹。25 fs内总能量变化范围最大 1.98×10⁻⁷ eV/atom。图中微小平滑变化并非温控器作用;短NVE中的积分误差需要结合时间步长与模拟时长分析。
扩展到生产模拟前,应根据模型适用范围选择结构和温压条件,先优化/平衡,再做所需时长的采样;增大体系并不能代替模型可靠性检查。这里没有新增DFT数据,也没有重新训练UF3。
需要根据你的体系选择资源?联系讨论计算需求。实际可用软件与权限,以当前账户和运行环境为准。