MSD curve of Ni-Al

In order to calculate the diffusions, I want to calculated the MSD curve of Ni and Al in FCC Ni-1at%Al。

The code was set as follows:

#================== Start=================
units metal
boundary p p p
timestep 0.001

#----- Al content
variable x_Al equal 0.01
#----- Diffusion Temperature
variable T_init equal 1200

lattice fcc 3.58
region box block 0 5 0 5 0 5
create_box 2 box
create_atoms 1 box

#-----------------replace Ni with Al------------
set type 1 type/ratio 2 ${x_Al} 666

mass 1 58.6934
mass 2 26.981538

group Ni type 1
group Al type 2

pair_style meam/c
pair_coeff * * library.meam Al Ni AlNi.meam Ni Al

min_style cg
minimize 1e-15 1e-15 5000 5000

velocity all create ${T_init} 876848 dist gaussian

fix 1 all npt temp ${T_init} ${T_init} $(100*dt) iso 0.0 0.0 1.0 drag 0.2
thermo 2000
run 20000
unfix 1

reset_timestep 0

#------------------ MSD calculation ---------
fix 1 all nvt temp ${T_init} ${T_init} $(100*dt)
compute 1 Ni msd com yes
variable twopoint_Ni equal c_1[4]/(6 * step * dt+1e-6)
fix 8 all vector 10 c_1[4]
variable fitslope_Ni equal slope(f_8)/(6 * 10 * dt)

compute 2 Al msd com yes
variable twopoint_Al equal c_2[4]/(6 * step * dt+1e-6)
fix 9 all vector 10 c_2[4]
variable fitslope_Al equal slope(f_9)/(6 * 10 * dt)

thermo_style custom step temp press vol c_1[4] c_2[4] v_twopoint_Ni v_fitslope_Ni v_twopoint_Al v_fitslope_Al

dump 2 all custom 1000 MSD_${T_init}.xyz id type x y z

variable t equal temp
variable st equal step
variable MSD_Single_Ni equal c_1[4]
variable MSD_Single_Al equal c_2[4]

fix 3 all print 100 “${st} ${t} ${MSD_Single_Ni} ${twopoint_Ni} ${fitslope_Ni}” file MSD_${T_init}_Ni.result screen no
fix 4 all print 100 “${st} ${t} ${MSD_Single_Al} ${twopoint_Al} ${fitslope_Al}” file MSD_${T_init}_Al.result screen no

run 100000

#================== END =================

The potential was obtained from DOI:10.1016/j.calphad.2006.02.006

However, the calculated MSD values kept around a certain values, not increased with increasing step.


What should I do to correct the code and get a single increasing curve?


Zhenbang Wei

What is the melting point of your material? And is the potential you have chosen representing it well?

The melting temperature of Ni-1at%Al is over 1727 K, much higher than 1200 K which I set in the code.
There are 5 potentials of Ni-Al obtained from Interatomic Potentials Repository (, I have run the code with various potentials, the results are as following:

(1) DOI: 10.1088/0953-8984/27/33/336302

(2) DOI: 10.1080/14786430903258184

(3) DOI: 10.1016/j.calphad.2006.02.006

(4) DOI: 10.1016/j.actamat.2003.11.026

(5) DOI: 10.1103/physrevb.65.224114

These results are similar, so I think there is no problem with potentials.

Since your system is significantly below melting point, why should there be a significant diffusion?

Thanks, problems have been solved by add certain amount of vacancies in the models.

Please start a new thread. See Please Read This First: Guidelines and Suggestions for posting LAMMPS questions :