Sie sind auf Seite 1von 38

South China University of Technology

Structural Relaxation
Xiaobao Yang
Department of Physics

http://www.compphys.cn/~xbyang/lectures.html

www.compphys.cn

www.compphys.cn

Schrdinger Equation

www.compphys.cn

www.compphys.cn

www.compphys.cn

www.compphys.cn

INCAR
KPOINTS
INCAR
ENCUT = 700
ISMEAR = 0
SIGMA =0.2
NSW = 0
EDIFF = 0.001

POTCAR
POSCAR

KPOINTS
Automatic mesh
0
! number of k-points = 0 ->automatic generation scheme
Monkhorst-Pack ! select Monkhorst-Pack (first letter is significant)
1 1 1
! size of mesh (4x4x4 points along b1, b2, b3)
0. 0. 0.
! shift of the k-mesh
POSCAR

POTCAR
PAW_PBE H 15Jun2001
1.00000000000000000
parameters from PSCTR are:
VRHFIN =H: ultrasoft test
LEXCH = PE
EATOM = 12.4884 eV, .9179 Ry

H2
1.0
12 0 0
0 12 0
0 0 12
2
Cart
000
0 0 0.75

www.compphys.cn

running on 2 nodes
distr: one band on 1 nodes, 2 groups
vasp.4.6.31 08Feb07 complex
POSCAR found : 1 types and 2 ions
LDA part: xc-table for Pade appr. of Perdew
POSCAR, INCAR and KPOINTS ok, starting setup
WARNING: wrap around errors must be expected
FFT: planning ...
1
reading WAVECAR
WARNING: random wavefunctions but no delay for mixing, default for NELMDL
entering main loop
N
E
dE
d eps
ncg
rms
rms(c)
DAV: 1 -0.469211785182E+01 -0.46921E+01 -0.23142E+02 12 0.981E+01
DAV: 2 -0.738346878115E+01 -0.26914E+01 -0.26914E+01 12 0.252E+01
DAV: 3 -0.741841946701E+01 -0.34951E-01 -0.34951E-01 18 0.423E+00
DAV: 4 -0.741843794358E+01 -0.18477E-04 -0.18477E-04 12 0.955E-02
DAV: 5 -0.741843809963E+01 -0.15606E-06 -0.15606E-06 18 0.878E-03
0.436E+00
DAV: 6 -0.698113710837E+01 0.43730E+00 -0.22006E-01 12 0.179E+00
0.237E+00
DAV: 7 -0.674222335613E+01 0.23891E+00 -0.52473E-01 24 0.281E+00
0.269E-01
DAV: 8 -0.674568380323E+01 -0.34604E-02 -0.54198E-03 12 0.257E-01 0.257E-01
DAV: 9 -0.674122836271E+01 0.44554E-02 -0.74399E-03 12 0.325E-01 0.324E-02
DAV: 10 -0.674397109933E+01 -0.27427E-02 -0.55758E-04 12 0.997E-02 0.187E-02
DAV: 11 -0.674418356913E+01 -0.21247E-03 -0.58782E-05 18 0.303E-02
1 F= -.67441836E+01 E0= -.67441836E+01 d E =-.241108E-10
writing wavefunctions

www.compphys.cn

Test everything to ensure convergence


cluster, nanowire, thin film

www.compphys.cn

for i in 250 350 450 500


do
for j in 8 10 12 15 20
do
cat >INCAR<<!
ENCUT = $i
ISMEAR = 0
SIGMA =0.2
NSW = 0
EDIFF = 0.001
!
cat >POSCAR<<!
H2
1.0
$j 0 0
0 $j 0
0 0 $j
2
Cart
000
0 0 0.8
!

for j in 250 300 350 400 450 500 600 700


do
cat >INCAR<<!
ENCUT = $j
ISMEAR = 0
SIGMA =0.2
NSW = 0
EDIFF = 0.001
!
for i in 60 65 70 75 80 85 90
do
cat >POSCAR<<!
H2
1.0
12 0 0
0 12 0
0 0 12
2
Cart
000
0 0 0.$i
!
mpiexec /home/VASP/vasp > "$PBS_JOBID".out.$j.$i
rm WAVECAR CHG CHGCAR
done
done

mpiexec /home/VASP/vasp > "$PBS_JOBID".out.$i.$j


rm WAVECAR CHG CHGCAR
done
done

www.compphys.cn

How to move atoms?


Energy is minimum.
The gradient is zero.

www.compphys.cn

Optimization and Curse of Dimensionality

www.compphys.cn

Quasi-Newton method

www.compphys.cn

Quasi-Newton method in VASP

www.compphys.cn

Quasi-Newton method in VASP

www.compphys.cn

Steepest descent method

www.compphys.cn

Searching direction

Optimized step

New start point

www.compphys.cn

Searching direction

Optimized step

New start point

New start point

Stop searching

www.compphys.cn

f(x) = 1/2 (x - x*)TA(x - x*) , A nn x*


f(x) 1/2 (x - x*)TA(x - x*) = c x*
.
f(x*) = A(x - x*) = 0 A x* f(x) x(1)
x(1) f(x(1)) = A(x(1) - x*)
d(1) x(1) , d(1) f(x(1))
d(1)Tf(x(1)) = 0; , d(2) = x* - x(1), d(1)TAd(2) = 0

A
www.compphys.cn

Conjugate Gradient method


Steepest descent method

Conjugate Gradient

www.compphys.cn

www.compphys.cn

Structural relaxation
To obtain the ground state relaxed geometry of the system.
the equilibrium lattice constants
a given ionic configuration
the forces obtained
these forces are greater
than some minimum tolerance
the ions are moved in the direction of the forces

www.compphys.cn

IBRION-tag in VASP
0 Standard ab-initio molecular dynamics
A Verlet algorithm is used to integrate Newton's equations of
motion. POTIM supplies the timestep in femto seconds.
1 A quasi-Newton algorithm is used to relax the ions into
their instantaneous ground state.
2 A conjugate-gradient algorithm
i)In the first step ions :the direction of the steepest descent.
The energy and the forces are recalculated. ii) Interpolation of
the change of the total energy and of the forces, then a
corrector step. iii) After the corrector step the forces and
energy are recalculated and it is checked whether the forces
contain a significant component parallel to the previous search
direction.
1 initial position 2 trial step 3 corrector step, i.e. positions
www.compphys.cn
corresponding to anticipated minimum 4 trial step

ISIF-tag in VASP

www.compphys.cn

Relaxation with VASP

www.compphys.cn

Energies vs. Forces


H2 molecular

C6H6 molecular

C
C
C
C
C
C
H
H
H
H
H
H

-2.629
-1.415
-1.493
-2.618
-3.851
-3.904
-2.682
-0.585
-0.544
-2.613
-4.764
-4.683

3.681
2.939
1.580
0.818
1.541
2.981
4.664
3.486
1.065
-0.192
1.084
3.483

0.018
0.026
0.024
-0.011
0.016
-0.033
0.020
-0.047
-0.022
-0.045
-0.040
0.032

www.compphys.cn

www.compphys.cn

AWK and VASP


aa=`awk '$2 == "TOTAL-FORCE" {print NR}' OUTCAR`
a=`expr $aa + 1`
bb=`expr $aa + $num + 2`
awk 'NR > a && NR < bb {print $4,$5,$6}' a=$a bb=$bb OUTCAR >force.1
paste site.1 velocity.1 force.1 >all.1
awk '{print $1+$4*h+$7*h*h/2/m*0.0096,$2+$5*h+$8*h*h/2/m*0.0096,
$3+$6*h+$9*h*h/2/m*0.0096}' h=$dt m=$mass all.1>site.2
paste velocity.1 force.1 force.2 >all.2
awk '{print $1+$4*h/2/m*0.0096+$7*h/2/m*0.0096,
$2+$5*h/2/m*0.0096+$8*h/2/m*0.0096,
$3+$6*h/2/m*0.0096+$9*h/2/m*0.0096}' h=$dt m=$mass all.2>velocity.2

www.compphys.cn

Review of QN,SD and CG

Conjugate Gradient
Steepest descent method

www.compphys.cn

Periodical structures

three lines the three lattice vectors defining the unit cell of the system are given
(first line corresponding to the first lattice vector, second to the second, and third to the third

Latticeofgraphene & latticeofgrapheneD

www.compphys.cn

K-mesh -- Monkhorst-Pack

k-sampling to define the Fermi surface precisely

q
q
Special points for Brillonin-zone integrations,www.compphys.cn
PRB, 13,5188(1976)

KPOINTS test
KPOINTS & IBZKPT

Automatic mesh
0
! number of k-points = 0 ->automat
ic generation scheme
Monkhorst-Pack ! select Monkhorst-Pack (first l
etter is significant)
Gamma
5 5 1
! size of mesh (4x4x4 points along
b1, b2, b3)
441
0. 0. 0.
! shift of the k-mesh

www.compphys.cn

LREAL
.FALSE. projection done in reciprocal space
.TRUE. projection done in real space,

This expression can be evaluated in reciprocal or real space:


In reciprocal space the number of operations scales with the size of the basis set (i.e. number
of plane-waves).
In real space, the projection-operators are confined to spheres around each atom. Therefore
the number of operations necessary to evaluate one does not increase with the system size
(usually the number of grid points within the cut-off-sphere is between 500 and 2000).
The number of atom <20 .FALSE. Otherwise, .TRUE.

www.compphys.cn

Strain stabilized nanostructures

PRL 100, 175503 (2008) ; 107, 236101 (2011) www.compphys.cn

Stabilities for various coverage

www.compphys.cn

Effect of temperature and pressure

www.compphys.cn

Li on GaN surface
clear
%Li
a=[
0 -.18783519E+03
1 -.76238692E+03/4
1.5 -.76726294E+03/4
2 -.77302221E+03/4
3 -.78305476E+03/4
%4 -.19702575E+03
4 -.19801252E+03
8 -.20551497E+03
];

mu=[-3 -2];
for ii=1:size(a,1)
plot(mu,a(ii,2)-a(ii,1)*mu,'r')
hold on
end

www.compphys.cn

Defect formation energies

NELECT @ INCAR
Default (number of valence electrons)
NELECT = number of electrons

www.compphys.cn

Homework

Review for the phase diagram.

Sending to 17273799@qq.com when ready

For lecture notes, refer to


http://www.compphys.cn/~xbyang/
www.compphys.cn

Das könnte Ihnen auch gefallen