Implementing DFT in PlaneWave basis - molgw

Apr 14, 2008 - (r)∣. 2 depends on the density non linear equations. Energy, Forces, Band structure, Electronic ..... We need to calculate the Hartree potential:.
1MB taille 1 téléchargements 334 vues
Implementing DFT in Plane­Wave basis Fabien Bruneval Service de Recherches de Métallurgie Physique CEA Saclay France

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

DFT for periodic systems

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Outline A DFT code adapted to periodic systems:



Self­consistency in KS equations



Crystal structure



k­points



Plane­Waves



Supercells

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Solving KS equations depends on the density  non linear equations 2

∇ h r =− v ion r v H [] r v xc []r  2 h r  i r =i  i r 

 r =∑ ∣ i r ∣

2

i occ

Energy, Forces, Band structure, Electronic density F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Solving KS equations depends on the density  non linear equations 2

−∇ h r = v ion  r v H [ ]r v xc [] r  2 h  i=i  i

 r =∑ ∣ i r ∣

2

i occ

Energy, Forces, Band structure, Electronic density F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Solving KS equations depends on the density  non linear equations

 0

 r  First guess for              2

∇ h r =− v ion r v H [] r v xc []r  2

h  i=i  i if

 n

n−1

 ≠

Diagonalization

2

 r =∑ ∣i r ∣ i occ

Energy, Forces, Band structure, Electronic density F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Outline A DFT code adapted to periodic systems:



Self­consistency in KS equations



Crystal structure



k­points



Plane­Waves



Supercells

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Crystal structure Crystal axis: a1, a2, a3 Direct lattice vector:

Periodic potential:

Reciprocal lattice axis:

R=n1 a 1n 2 a2 n3 a 3 V  r R=V r  2 b 1= a 2×a3  2 b 2= a 3×a 1  2 b 3= a 1×a2 

G=n1 b 1n 2 b2n3 b 3 Reciprocal lattice: F. Bruneval

iG. R

e

=1

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Bloch theorem and k­points Bloch theorem:

 k i  r =e where 

i k .r

u k i r 

k is in the first Brillouin zone uki(r) is a periodic function with crystal periodicity

Any periodic operator and, in particular, the Hamiltonian, is diagonal in k.

〈 k i∣h∣k ' j〉=∫ d r e

i  k ' −k  . r

∗ ki

h r  u r  u k ' j  r 

V

=∑ ∫ d r e R

i k ' − k  . r R



∗ ki

×h r R u r Ru k ' j r R F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

k­points allow to split the calculations

〈 k i∣h∣k ' j〉= k k ' 〈 k i∣h∣k j〉 The Hamiltonian has blocks of non interacting k­points:

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Solving KS equations with k­points depends on the density  non linear equations

 0

 r  First guess for              2

∇ h r =− v ion r v H [] r v xc []r  2 Diagonalizations

h k  k i=k i k 1

if

1

n

 ≠

1

 n−1 

1

i

h k k i =k i  k 2

2

2

2

i

h k  k i =k i  k 3

3

3

1 2  r = ∣ k i  r ∣ ∑ N k k ,i occ

Energy, Forces, Band structure, Electronic density F. Bruneval

     Coimbra, 14/04/08

3

i

Implementing DFT in Plane­Wave Basis

 

Brillouin Zone integration Many quantities of the scheme require averaging in the BZ, e.g. kinetic term, electronic density:

 r =

to be exact, it should be

 r =

1 ∑ N k k ∈BZ

∑∣k i r ∣

2

i occ

1 dk ∫ V BZ V BZ

2

∣k i  r ∣ ∑ i occ

We have to find a set of points in the BZ, which makes the limit as fast as possible:

1 ∑ N k k ∈BZ F. Bruneval



1 V BZ

∫dk V BZ

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Brillouin Zone integration 1 ∑ Nk k



1 dk ∫ V BZ V BZ

Monkhorst­Pack technique, Phys. Rev. B 13, 5188 (1976)

2x2 with shift 0.5 0.5 F. Bruneval

2x2 with shift 0.  0.      Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Equivalence k­points/larger cells 1 unit cell

F. Bruneval

2 unit cells

4 unit cells

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Outline A DFT code adapted to periodic systems:



Self­consistency in KS equations



Crystal structure



k­points



Plane­Waves



Supercells

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Bloch theorem again

k i  r =e where 

i k .r

u k i r 

k is in the first Brillouin zone uki(r) is a periodic function with crystal periodicity

uki(r) is periodic and can be expanded in a Fourier series

1 iG. r u k i  r = c k i G e ∑  G where  G is on the reciprocal lattice:

G=n1 b 1n 2 b2n3 b 3

1 i k G  .r  k i  r = c k i G e ∑  G F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Potentials in plane­waves Example of the ionic potential:

R­space: V(r)

Z V ion r = ∣r∣ Z  V ion G=4  2 ∣G∣ G­space: V(G)

|G| F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Plane Waves Reciprocal lattice:

G=n1 b 1n 2 b2n3 b 3

Volume of the sphere containing all PW:

4 3 V sphere= G max 3

Volume of occupied by 1 single PW: 3

2  V PW = 

2 max

G E cutoff = 2 N G ∝ E F. Bruneval

3 /2 cutoff

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Cutoff for the density 1 ∗  r =  k i r  k i r  ∑ N k k i occ 1 ∗ i G −G '  . r = c k i G c k i G ' e ∑ ∑ ∑ N k  k i occ G G G ' G max

=



G0 2G max

F. Bruneval

max

i G 0. r

G  0 e

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

PW: an orthogonal basis set The wavefunctions are a linear combination of orthogonal basis functions:

∣k i 〉 = and



c k i G ∣kG 〉

∣G∣Gmax

1 i G ' −G  .r ∣ 〈 kG k G ' 〉= ∫ d r e =G G '  Variational principle:

E ground state E  Ecutoff = x Ha

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

PW: an orthogonal basis set Adding more PW or increasing the cutoff energy makes ALWAYS the result more accurate

Silicon

Eexact

F. Bruneval

EPW(Ecutoff)

Gaussian basis sets of quantum­chemisrty: STO­3G STO­6G 3­21G 6­31G 6­31+G* 6­311+G* 6­311++G** cc­pVDZ cc­pVTZ cc­pVQZ aug­cc­pVDZ aug­cc­pVTZ aug­cc­pVQZ Dünning SVP Dünning DVP Dünning TVP Dünning TVPP      Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

PW makes life easier thanks to the FFTs iG. r f r =∑ f G e G

f G= 1 ∫ d r e−i G . r f r   1 −i G . r = e f r i  ∑ N r r ∈ i

Discrete Fourier Transform

i

It is exact as long as NG = Nr This means that

f G=DFT −1 [ DFT [ f G ] ] The fast version of DFT is the famous Fast FT with scales as O( N log N ) instead of N2. This enforces the use of regular grid in real space. F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Illustration of the use FFTs We need to calculate the Hartree potential:

c k i G

FFT

r '  v H r =∫ d r ' ∣r −r '∣ uki  r   r =

 G vH G=4 

 r 

 G  ∣G∣2

vH  G F. Bruneval

FFT

1 ∣u k i  r ∣2 ∑ N k ki

FFT

vHr      Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Supercell technique How to simulate a finite system with periodic boundary conditions? The cost of the calculation can be problematic, since 

N G ∝ E

3 /2 cutoff

Still useful for slabs, wires, etc.

L

F. Bruneval

     Coimbra, 14/04/08

Implementing DFT in Plane­Wave Basis

 

Recap ●

Self­consistent loop



k­points:





Monkhorst­Pack grid (like 4x4x4 shift 0.5 0.5 0.5)



Equivalence between k­points and larger cells

Plane­Waves

F. Bruneval



PW are an orthogonal basis set



Cutoff energy for wavefunctions



Intensive use of FFT's to increase efficiency      Coimbra, 14/04/08