M04 Energy Minimization of Vacancy: Difference between revisions

From Micro and Nano Mechanics Group
Jump to navigation Jump to search
(New page: <H1 ALIGN="CENTER"><FONT SIZE="-1">Manual 04 for MD++ </FONT> <BR> Creating a Vacancy, Relaxing The Imperfect Structure <br>and Calculating Vacancy Formation Energy</H1> <DIV> <P ALIGN="...)
 
Line 10: Line 10:
<BR><HR>
<BR><HR>


== Making a Vacancy ==
== Creating a Vacancy in a Perfect Crystal ==
A vacancy is a common and important type of point defect in solids. It is an
In manual M02, we learned how to create a perfect crystal using MD++. However,
empty site (''i.e.'' a missing atom) in an otherwise prefect crystal structure. Here
most crystal structures are hardly perfect in natural environmet. It is
we discuss how to introduce a vacancy in a perfect crystal using MD++ and how
common to have various kinds of defects such as point, line, planar and volume
to compute the vacancy formation energy. Consider the following MD++ input
defects. Sometimes, we intend to introduce certain kinds of defects to study the
file, '''movacancy.script''', that creates a vacancy in a perfect BCC Molybdenum
property of interest.
crystal.


Vacancy is one of the frequently encountered point defects in solids and can be
considered as a missing atom from the otherwise perfect crystal. In this manual, we will learn
how to create a vacancy inside of the perfect crystal and how to calculate the
vacancy formation energy of the bulk material. Let’s run the following example
script by typing

$ bin/fs gpp scripts/movacancy.script
<pre>
<pre>
# -*-shell-script-*-
# -*-shell-script-*-
Line 69: Line 63:
</pre>
</pre>


We can run this script file by typing
The script above shows how to create a vacancy from the perfect BCC Mo

crystal. First, a 5×5×5 perfect cubic crystal of Mo is created with all the simulation box
$ bin/fs gpp scripts/movacancy.script
edges aligned along <100> directions. Then an atom of ID 0 is fixed by

First, MD++ creates a 5×5×5 perfect cubic crystal of Mo with edges along
<100> directions. Then it fixes atom 0 by


input = [ 1 # number of atoms to be fixed
input = [ 1 # number of atoms to be fixed
0 ] # index of an atom to be fixed
0 ] # index of an atom to be fixed
fixatoms by ID
fixatoms_by_ID


and will be removed by the command '''removefixedatoms''' in the script.
and then removs this atom by the command '''removefixedatoms'''.
The first number in the input array specifies the number of atoms to be removed.
Suppose, if you want to remove two atoms of indices 3 and 8, you can do so by
For example, if you would like to remove two atoms, say 3 and 8, you can do so
by


input = [ 2 # number of atoms to be fixed
input = [ 2 # number of atoms to be fixed
Line 85: Line 84:
removefixedatoms # remove fixed atoms
removefixedatoms # remove fixed atoms


At this moment, you may wonder how we know which atom has which index.
Sometimes, you may want to remove a specific atom you see in the graphic
window. You can obtain the index of this atom by clicking the atom with
If you click an atom in the visualization window with the left button of the
your mouse. Depending on the setting of '''plot_atom_info''', other information is
mouse, it gives the index number and energy of the clicked atom.<ref> This is the case when '''plot_atom_info = 3''' is specified in the script file. If '''plot_atom_info = 1''', the index number and the reduced coordinate of the clicked atom will be given. If '''plot_atom_info = 2''', the index number of the clicked atom and its real coordinate (in &Aring;) will be displayed.</ref>
also displayed when you click on the atom. If '''plot_atom_info = 1''', the atom
In the visualization window, you will see the atoms near the vacant site have different color
index number and its scaled coordinates are printed when the atom is clicked.
than the others. In the script file, two color windows are set by the variable
If '''plot_atom_info = 2''', the atom index and its real coordinate (in &Aring;) will be
'''plot_color_windows''' according to the potential energy of the individual atom. The atoms
printed. If '''plot_atom_info = 3''', the atom index and its local energy (in eV)
whose energies are between -10 and -6.8 (eV) are shown in gray and the atoms
will be printed.
whose energies lie between -6.7 and -6.0 (eV) are shown in orange. It shows

that the atoms near the vacancy have higher energy than the rest. Click the
The script file also sets up two color windows ('''plot_color_windows''') to
atoms and you will see the potential energy of each atom. If you also compare
display the atoms. Atoms with local energy between -10 eV and -6.8 eV are
shown in gray and the atoms whose energies lie between -6.7 eV and -6.0 eV are
shown in orange. This will highlight the atoms near the vacancy because they
usually have a higher local energy. Click the atoms and you will see the actual
local energy of these atoms. If you compare
the potential energy of the perfect structure and the vacancy-formed structure,
the potential energy of the perfect structure and the vacancy-formed structure,
you will know which structure has higher energy.
you will know which structure has higher energy.


''Q.1'' If a single atom, whose index is other than 0, is removed from the same perfect structure,
''Q.1'' If a single atom, whose index is other than 0, is removed from the same perfect structure,
do you still expect the final state has the same amount of
do we expect the system to have a different potential energy?
energy? Explain the reason.


== Relaxation ==
== Relaxation ==

Revision as of 00:46, 28 November 2007

Manual 04 for MD++
Creating a Vacancy, Relaxing The Imperfect Structure
and Calculating Vacancy Formation Energy

Keonwook Kang and Wei Cai

Nov 27 , 2007



Creating a Vacancy in a Perfect Crystal

A vacancy is a common and important type of point defect in solids. It is an empty site (i.e. a missing atom) in an otherwise prefect crystal structure. Here we discuss how to introduce a vacancy in a perfect crystal using MD++ and how to compute the vacancy formation energy. Consider the following MD++ input file, movacancy.script, that creates a vacancy in a perfect BCC Molybdenum crystal.

# -*-shell-script-*-
setnolog
setoverwrite
dirname = runs/movacancy # specify run directory

#--------------------------------------------
# Read in potential file
potfile = ~/Codes/MD++/potentials/mo_pot readpot

#--------------------------------------------
#Create Perfect Lattice Configuration
crystalstructure = body-centered-cubic latticeconst = 3.1472 #(A)
latticesize = [ 1 0 0 5
                0 1 0 5
                0 0 1 5]
makecrystal finalcnfile = perf.cn writecn
eval # evaluate the potential of perfect crystal
#--------------------------------------------
# Create Vacancy
input = [ 1      # number of atoms to be fixed
          0]     # index of an atom to be fixed
fixatoms_by_ID   # fix a set of atoms by their indices
removefixedatoms # remove fixed atoms
finalcnfile = movac.cn writecn
eval # evaluate the vacancy-formed crystal
#---------------------------------------------
# Plot Configuration
atomradius = 1.0 bondradius = 0.3 bondlength = 0
atomcolor = blue highlightcolor = purple backgroundcolor = gray
bondcolor = red   fixatomcolor = yellow
plotfreq = 10 win_width = 600    win_height = 600
plot_atom_info = 3
color00 = "orange" color01 = "purple" color02 = "green"
color03 = "magenta" color04 = "cyan"   color05 = "purple"
color06 = "gray80" color07 = "white"
plot_color_windows = [ 2             # number of color windows
                      -10  -6.8   6  # color06 = gray80
                      -6.7 -6.0   0  # color00 = orange
                     ]
rotateangles = [ 0 0 0 1 ]
openwin alloccolors rotate saverot plot
sleep quit

We can run this script file by typing

$ bin/fs gpp scripts/movacancy.script

First, MD++ creates a 5×5×5 perfect cubic crystal of Mo with edges along <100> directions. Then it fixes atom 0 by

   input = [ 1         # number of atoms to be fixed
             0 ]       # index of an atom to be fixed
   fixatoms_by_ID

and then removs this atom by the command removefixedatoms. The first number in the input array specifies the number of atoms to be removed. For example, if you would like to remove two atoms, say 3 and 8, you can do so by

input = [ 2            #  number of atoms to be fixed
          3 8 ]        #  index of atoms to be fixed
fixatoms_by_ID         #  fix a set of atoms by their index
removefixedatoms       # remove fixed atoms

Sometimes, you may want to remove a specific atom you see in the graphic window. You can obtain the index of this atom by clicking the atom with your mouse. Depending on the setting of plot_atom_info, other information is also displayed when you click on the atom. If plot_atom_info = 1, the atom index number and its scaled coordinates are printed when the atom is clicked. If plot_atom_info = 2, the atom index and its real coordinate (in Å) will be printed. If plot_atom_info = 3, the atom index and its local energy (in eV) will be printed.

The script file also sets up two color windows (plot_color_windows) to display the atoms. Atoms with local energy between -10 eV and -6.8 eV are shown in gray and the atoms whose energies lie between -6.7 eV and -6.0 eV are shown in orange. This will highlight the atoms near the vacancy because they usually have a higher local energy. Click the atoms and you will see the actual local energy of these atoms. If you compare the potential energy of the perfect structure and the vacancy-formed structure, you will know which structure has higher energy.

Q.1 If a single atom, whose index is other than 0, is removed from the same perfect structure, do we expect the system to have a different potential energy?

Relaxation

After creating a vacancy, it is not hard to imagine that the atoms around the vacancy will not stay as they were, for they have less bonds and form a locally unstable structure. We can expect the atoms near the vacancy will move toward the vacant site to some degree and lower the total energy of the system. In other words, the atomistic structure will be relaxed to its locay energy minimum state from the given initial position. MD++ uses a conjugate gradient relaxation (CGR) algorithm[1] for this energy minimization process. for which the script file needs the section given below.

#---------------------------------------------
# Conjugate-Gradient relaxation
conj_ftol = 1e-7          # tolerance on the residual gradient
conj_fevalmax = 1000 # max. number of iterations
conj_fixbox = 1           # fix the simulation box
relax                     # CG relaxation command
finalcnfile = relaxed.cn writecn
eval                      # evaluate relaxed structure

Let’s copy the above script and paste it to the movacancy.script right before the last command, sleep quit. You will watch the potential energy of the simulated system keeps decreasing while the relaxation goes on. There are a coulple of variables related with CG relaxation. conj_ftol is the tolerance of the residual gradient and conj_fevalmax is the maximum number of iterations. The relaxtion will stop if the tolerance becomes smaller than the specified conj_ftol or if the number of iteration reaches its maximum. If conj_fixbox is equal to 1, the shape and size of simulation cell box is fixed so that only the atoms can move during the relaxation. Sometimes you need to relax the simulation box together with atoms. In such a case you can add more degrees of freedom to the system by setting conj_fixbox = 0. For example, you can allow the box to expand or shrink hydrostatically by saying that

conj_fixbox = 0
conj_fixboxvec = [ 0 1 1
                   1 0 1
                   1 1 0]

In this case, only the diagonal components of the box matrix can relax and the other components are fixed as assigned to conj_fixboxvec.

Vacancy Formation Energy

We define the vacancy formation energy Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle E_v} as the energy needed to create a vacancy from the bulk perfect crystal structure. This can be obtained by comparing the energy of the relaxed vacancy-formed structure and the energy of a perfect crystal structure. However, it is not just a simple substraction between two, because we need to make sure we compare two systems of the same number of atoms. In reality, no atom is removed or destroyed when a vacancy forms. Rather, what we can think of is displacement of an inside atom to the free surface of a solid leaving a vacancy inside as shown in Fig. 2(a). Even though there is no free surface in our simulation with the periodic boundary condition. Let Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle N} be the total number of atoms in the original perfect crystal structure. And Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle E_1} is the energy of the perfect crystal and Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle E_2} is the energy of relaxed structure of Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle (N − 1)} atoms. Then the vacancy formation energy Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle E_v} can be expressed as

                                           N −1
                           Ev   ≡ E2 −            · E1 .                      
                                             N

Q.2 Can you tell the different physical meanings between two expres sions Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle E_2 − \frac{N-1}{N}E_1} and Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle E_2 − E_1} ? You can use Fig. 2 for your explanation.

Once you know the vacancy formation energy Failed to parse (SVG (MathML can be enabled via browser plugin): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle E_v} , you can use it to estimate the concentration of vacancy <maht>[n]</math> in the crystal strucutre at given temperature T and atmospheric pressure from Boltzmans distribution relation[2],

                           [n] ∼ exp(−Ev /kB T )                            

where kB = 8.621E-5 eV/K is Boltzman’s constant. For example, the vacancy formation energy of Mo is 2.550 (eV)[3] from the atomistic calculation. Then the fraction of vacancy will be on the order of 1.514E-43 at 300 K.

Q.3 Calculate the vacancy formation energy of Mo with the simulation box of different size. The vacancy formation energy is expected to be the same irrelavant to the box size. However, you will find the energy dramatically changes if the box is smaller than the certain size. Explain the reason.

Notes

  1. Numerical Recipes, http://www.nr.com/
  2. R. J. Stokes and D. F. Evans, Fundamentals of Interfacial Engineering, Wiley-VCH 1997 pp.491-493
  3. With the tight binding model, it is reported to be 2.46 eV. See the referene, M. J. Mehl and D. A. Papaconstantopoulos, “Applications of a tight-binding total-energy method for transition and noble metals: Elastic constants, vacancies, and surfaces of monatomic metals”, Physical Review B 54 4519-4530 1996