phonopy workshop

Upload: hantarto5844

Post on 25-Feb-2018

225 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/25/2019 Phonopy Workshop

    1/52

    Introduction to phonopy

  • 7/25/2019 Phonopy Workshop

    2/52

    Run examples

    Suppose phonopy's /binis in the list of the execution path.Examples are found at

    http://phonopy.sourceforge.net/examples.html

    % cd example/NaCl% phonopy -p -nac band.conf

    % cd example/Si% phonopy -p mesh.conf

  • 7/25/2019 Phonopy Workshop

    3/52

    Installation

    Download phonopy http://sourceforge.net/projects/phonopy/

    Install phonopy

    dd the phonopy li!rary directory"e.g.# ~/phonopy-1.1/lib/python) to PY!"NP#!#may!e in .bash$c# .shen etc.

    % s'do apt-(et install python-de& python-n'mpy

    python-matplotlib python-t* python-lxml python-yaml

    % ta$ x&f phonopy-1.1.ta$.(% cd phonopy-1.1% python set'p.py install home+.

    expo$t PY!"NP#!+,PY!"NP#!~/phonopy-1.1/lib/python

  • 7/25/2019 Phonopy Workshop

    4/52

    $honopy is

    phonon calculation tool!ox Easily installed on recent systems

    $honopy re%uires force calculators# e.g.# it wor&togather with firstprinciples calculations# or anycalculation that can calculate forces on atoms.

    $rocesses of phonopy and force calculations are

    completely separated. (herefore phonopy can !eapplied to any force calculator with small effort. )ritten mainly in $ython

    $honopy $ython module is prepared.

  • 7/25/2019 Phonopy Workshop

    5/52

    *alculation steps

    +orces

    Displacement

    supercell with a displacement,. $repare a unit cell

    -. Relax the structure

    . uild a set of supercells with

    displacements

    0. *alculate forces on atoms ofthe set of supercells

    1. *ollect sets of forces

    2. *alculate phonon fre%uencies

  • 7/25/2019 Phonopy Workshop

    6/52

    )or& flow of phonopy

    $repare a crystal structure at e%uili!rium in 3S$P"SC#format

    *reate supercells with displacements

    +orce calculation !y a force calculator# e.g. 3S$ +orce collection

    *ollect sets of forces on atoms of the supercells

    $honon analysis

    Density of states# and structure# (hermal properties# etc. +urther analysis from a set of phonon calculations

    (hermal expansion# etc.

  • 7/25/2019 Phonopy Workshop

    7/52

    $reprocess 4 +orce collection

    Input structure "P"SC#5

    Supercell si6e "--dim5

    7utput files- Supercell with

    displacements"P"SC#-5

    - Displacement directions"disp.yaml5

    0isp.yaml

    &asp$'n.xml's

    7utput file Sets of forces 2"C34S3S)

    used in the postprocess.

    $reprocess

    % phonopy -d -dim+56 6 65

    "supercell si6e 8 -x-x-5

    +orce collection

    % phonopy -f #774&aps$'n.xml

  • 7/25/2019 Phonopy Workshop

    8/52

    P"SC#

    SP"SC#8 P"SC#-

    disp.yaml

    $honopyprocess

    09:tag

    3S$ calculations3S$ D+$( calculations

  • 7/25/2019 Phonopy Workshop

    9/52

    $ost process

    file containing sets of forces and atomicdisplacements "2"C34S3S5 is transformed tosupercell force constants.

    Dynamical matrices at ar!itrary qpoint are !uilt from

    the supercell force constants. Dynamical matrices are sol9ed# and phonon fre%uency

    and polari6ation 9ectors are o!tained. D7S# $D7S# !and structure# and thermal properties at

    constant 9olume are o!tained following a setting file"xxx.conf5 and commandline options.

    % cat mesh.conf09: + 6 6 6:P + 6; 6; 6;% phonopy -p -t mesh.conf

    (hermal properties are calculated and plotted.

  • 7/25/2019 Phonopy Workshop

    10/52

    $honopy postprocess

    the$mal4p$ope$ties.yaml total4dos.dat pa$tial4dos.dat

    mesh.yamlband.yaml

    P"SC#09: tag or--dimoption P9:99

  • 7/25/2019 Phonopy Workshop

    11/52

    *omputing system

    $* *lusters& force calculation

    )or& station

    s& phonon analysis"9ia ; forwarding5

    Recent $*s are enough strong that usually $* can !e )or& station.

    $lot

  • 7/25/2019 Phonopy Workshop

    12/52

    (ips of force calculation in 3S$

    + -1.;e-;?Set

    and relax as much as possi!le watching the recidual forces

    Recidual forces of =,e0 e3/> may !e accepta!le# !ut depends on systems.

    +orce calculations of supercells9@9"N + -1Set

    P3C + #cc'$ate73#7 + .2#7S3.#00>90 + .A3.30922 + 1.;e-;?

    9NC#of phonon calculation

    i.e. no relaxation is allowed.

    9@9"N + 6B 9S92 + ?ay!e

  • 7/25/2019 Phonopy Workshop

    13/52

    n example set of 9NC#s

    P3C + #cc'$ate 3NCA + D;; 9@9"N + 6

    9S92 + NSE + 6; N37:9N + D 30922 + 1.;e-;? 30922> + -1.;e-;? 9#7>" + ? 9S:3# + ;B S9>:# + ;.1

    73#7 + .2#7S3.#00>90 + .A3. 7E# + .2#7S3.

    P3C + #cc'$ate 3NCA + D;; 9@9"N + -1

    N37:9N + D 30922 + 1.;e-;? 9#7>" + ? 9S:3# + ;B S9>:# + ;.1 73#7 + .2#7S3.#00>90 + .A3. 7E# + .2#7S3.

  • 7/25/2019 Phonopy Workshop

    14/52

    (ips of kpoint sampling mesh inelectronic structure calculations

    Real space Reciprocal space

    -A-supercell

    Bnit

    cell

    CAC

  • 7/25/2019 Phonopy Workshop

    15/52

    rief introduction to phonon theory

  • 7/25/2019 Phonopy Workshop

    16/52

    armonic oscillator

    armonic potential wellV

    m

    k

    fre%uency

    ?ass

    Spring constant

    F8ma8-kx

    x

    x

    E%uation of motion

    solution is

  • 7/25/2019 Phonopy Workshop

    17/52

    ,Dlattice connected with ..

    n nF, nF-n,

    earest neigh!or

    un, un unF, unF-

    a?ass m

    Get displacement !e superposition of tra9eling wa9es

  • 7/25/2019 Phonopy Workshop

    18/52

    Dispersion relation

    Sol9ing e%uation of motion# fre%uency is

  • 7/25/2019 Phonopy Workshop

    19/52

    (rans9erse wa9e

    q

    tomic modulation is orthogonal to wa9e 9ector.

  • 7/25/2019 Phonopy Workshop

    20/52

    Gongitudinal wa9e

    tomic modulation is parallel to wa9e 9ector.

    q

  • 7/25/2019 Phonopy Workshop

    21/52

    Interaction among atoms

    H H

    H

    H

    )e don't &now how far it reaches and how strong it is.

    +urthermore interaction is not only in pairs.

  • 7/25/2019 Phonopy Workshop

    22/52

    $otential energy expansion

    amiltonian 8 &inetic F potential

    $otential energy is expaned with respect to

    atomic displacements "U5.

    i#j# k# H : *artesian components

    ?# # $# H : Gattice points

    "?onatomic unit cell5

    : +orce constants

    "+*s5

  • 7/25/2019 Phonopy Workshop

    23/52

    $honon from classical mechanics

    7mit higher terms than ndorder armonic approximation

    Diagonali6ation is needed.

    $honon is found to diagonali6e harmonic amiltonian:

    (his is reduced to eigen9alue pro!lem of dynamical matrix.

    JM: mass#NK: num!er of atoms# R: positon 9ector

    ?ultiple atoms in a unit cell are considered.Indices LMN... are used for internal atomic la!eling.

    $honon fre%uencies are o!tained as s%uare roots of

    eigen9alues of the dynamical matrix.

  • 7/25/2019 Phonopy Workshop

    24/52

    It is con9enient for sol9ing eigen9alue pro!lem using computer toconstruct a matrix of in the form li&e "two atom in unit cell5:

    Diagonali6ation using computer

    eigvals, eigvecs = numpy.linalg.eigh( dynmat )

    D: dynamical matrix# w: eigen9ector# s: !and index

  • 7/25/2019 Phonopy Workshop

    25/52

    Eigen9ector w

    Jere indices i#jrun o9er the *atesian components and atom indices.

    w"qs5 are eigen9ectors in the output files of phonopy.

    7rthonormality

    *ompleteness

  • 7/25/2019 Phonopy Workshop

    26/52

    Imaginary mode

    "aOK# bPK5

    Sometimes it relates to phase transition# or may !eused to chec& if 9irtual crystal structure is sta!le or not.

    ormal mode coordinate

    Imaginary fre%uency appears when crystal structureis dynamically unsta!le through the imaginary mode.

    JIn phonopy output# imaginary fre%uency is gi9en as negati9e fre%uency.

  • 7/25/2019 Phonopy Workshop

    27/52

    Supercell approach

    H H

    H

    H

    ssume interaction range is confined in supercell si6e.

    E.g.# -x- supercell is used to calculate force constans.

  • 7/25/2019 Phonopy Workshop

    28/52

    +inite difference method

    +orce on an atom "Fi5

    tomic displacement "Qrj5

    Displace one atom# and measure forces on all atoms

  • 7/25/2019 Phonopy Workshop

    29/52

    (hermal properties

    elmholt6 free energy

    (hermal properties are calculated from fre%uencies.

    Entropy

    eat capacity at constant 9olume

    uantum mechanics is necessary to deri9e them.

  • 7/25/2019 Phonopy Workshop

    30/52

    *rystal symmetry

  • 7/25/2019 Phonopy Workshop

    31/52

    *rystal symmetry

    *I+ data!ase may ha9e small num!er of decimalse.g. ,/ K.

    3S$ geometry optimi6ation may result in !rea&ing symmetryin hexagonal case# etc.

    *rystal symmetry gi9es high %uality results and reducescomputational demands.

    % phonopy -symmetry --tolerance=1e-8

    Detailed crystal symmetry is chec&ed !y

    *rystal structure has to !e correctly symmetri6edaccording to the space group type.

  • 7/25/2019 Phonopy Workshop

    32/52

    *entrings of crystals

    In space group type names in international ta!le#

    starting withF#I# C#A# andBmeans thatcrystal has centring.

    F: face centreI: !ody centreC#A#B: !ase centre

    In these cases# the con9entional unit cell is ,# -# or0fold larger than the primiti9e cell.

    Gattice parameters of the con9entional and primiti9ecells are related !y transformation matrix."I(-KK- Sec. 1.,5 JI(: International ta!le 9olume

  • 7/25/2019 Phonopy Workshop

    33/52

    Fmm"e.g. Silicon5

    *on9entional unit cell to

    primiti9e cell

    PRIMITIVE_AXIS = 1!" 1!" 1!" 1!" 1!" 1!"

  • 7/25/2019 Phonopy Workshop

    34/52

    rillouin 6ones for space groups

  • 7/25/2019 Phonopy Workshop

    35/52

    rillouin 6one ofFmm

    *oordinates wrt. reciprocalprimiti9e lattice 9ectors

    (his is to !e written in #Iand #$tags.

  • 7/25/2019 Phonopy Workshop

    36/52

    ?ore on phonopy

  • 7/25/2019 Phonopy Workshop

    37/52

    Running modes of phonopy

    and structure

    ?esh sampling

    Gist of qpoints

    Sample qpoints along specified paths

    Sample qpoints on a uniform mesh

    Sample %points listed in FP"9NSfile

    *alculations of D7S# $D7S# thermal properties !elong to this mode.

  • 7/25/2019 Phonopy Workshop

    38/52

    and structure mode

    qpoint sampling paths:

    um!er of sampling points in a path:

    @#N0 + ; ; ; 1/6 ; ; 1/6 1/6 ;

    @#N04P"9NS + D1 JEnd points are counted.

    ",5 "-5 "5

    (he output file is band.yaml.

  • 7/25/2019 Phonopy Workshop

    39/52

    bandplot

    Replot !and structure from !and.yaml !y

    % bandplot

    *ommand options can !e shown !y

    % bandplot -h

    (o print out fre%uencies in gnuplot data format

    % bandplot --(n'plot

    If you want to cut !elow K#

    % bandplot --fmin+;

  • 7/25/2019 Phonopy Workshop

    40/52

    ?esh sampling mode

    Reciprocal lattice are sampled !y a uniform mesh.:P + 1; 1; 1;

    In phonopy# a mesh point samples the point when the

    num!er is odd. 7ptionally# the sampling mesh can !eshifted with respect to grid space.

    :P4shift + ;.D ;.D ;.D

    )hen MP_SI$Tis K or K.1# the symmetri6ation of thegrid points is fast# which may !e important when themesh is %uite dense.

    (he output file is mesh.yaml.

  • 7/25/2019 Phonopy Workshop

    41/52

    ?esh sampling/D7S

    n: num!er of calculated qpoints# g: function used for !roadening

    % phonopy --dos % phonopy -por

    "without plot5 "with plot5

    (he output file is totalTdos.dat.

    (he !roadening function is the

  • 7/25/2019 Phonopy Workshop

    42/52

    ?esh sampling/$D7S

    $artial D7S is o!tained !y

    P0"S + 1 68 G D H

    s well as total D7S# smearing is controlled !y --si(ma.

    % phonopy

    )ith -poption# $D7S is plotted.

    (he output files is pa$tial4dos.dat# and reploted !y

    % pdosplot -i I1 6 G D8 H5

    )here num!ers for -ioption correspond to,x# ,y# ,6# -x# -y# -6# H "num!ers are atom indices.5

    and

  • 7/25/2019 Phonopy Workshop

    43/52

    D7S/(hermal properties

    elmholt6 free energy# entropy# heat capacity at constant9olume are calculated from phonon fre%uencies !y

    % phonopy -t

    )ith -poption# the resutls are plotted.7ptions --tmax8--tmin8--tstepmay !e used together.

    (he output file is the$mal4p$ope$ties.yaml.

    (hermal properties are replotted !y

    % p$opplot c& "or-fe8 --ent$opy5

    --(n'plotoption is dummy....5

  • 7/25/2019 Phonopy Workshop

    44/52

    onanalytical term correction

    Dynamical matrix at q K are corrected !y nonanalytical term correction. R. ?. $ic& et al.# $R ,# U,K# ",UVK5

    t general qpoints# force constants are corrected !yinterpolation scheme of )ang et al. (W. $hys.: *ondens.?atter. --# -K--K, "-K,K55

    % phonopy --nac

    orn effecti9e charge and dielectric tensors arenecessary to use this option and those aresummari6ed in @"Nfile.

    JZ: orn effecti9e charge tensor# X: dielectric tensor

  • 7/25/2019 Phonopy Workshop

    45/52

    @"Nfile

    73PS97"N + .A3.

    @"N 3223C93S in e8 c'mm'lati&e o'tp't)

    :#C"SC"P9C S#9C 09373C9C 3NS" incl'din( local fieldeffects in 02)

    3S$ results are found in "AC#around:

    1G.G;;6.;; ;.;; ;.;; ;.;; 6.;; ;.;; ;.;; ;.;; 6.;;1.J? ;.;; ;.;; ;.;; 1.J? ;.;; ;.;; ;.;; 1.J?-;.JJ ;.;; ;.;; ;.;; -;.JJ ;.;; ;.;; ;.;; -;.JJ...

    Bnit con9ersion factor X

    Z

    (hese 9alues may !e o!tained !y 3S$ 1 !y setting

    J7nly Y for independent atoms ha9e to !e written. Independent

    atoms are found atom4mappin(of output of % phonopy --symmet$y

  • 7/25/2019 Phonopy Workshop

    46/52

    uasiharmonic approximation"5

    : +re%uencies at 9olumes

    Z phonopy%ha p s e9.dat [thermalTpropertiesTyamlTofT9olume, [thermalTpropertiesTyamlTofT9olume- [thermalTpropertiesTyamlTofT9olume ...

    (he file e-&.datcontains 9olumes andelectronic total energies U"V5 of unit cells.

    1G;.;;;;; -G6.166GH1GG.D;;;;; -G6.H;;JKG1GJ.;H;;;; -G6.JGJ1G6...

    3 B

  • 7/25/2019 Phonopy Workshop

    47/52

    (hermal expansion of Silicon !y

    7rigin of thermal expansion is9olume dependence of fre%uency.

    Supercell si6es

    l d d f f

  • 7/25/2019 Phonopy Workshop

    48/52

    3olume dependence of fre%uencyof Silicon

    (his point

  • 7/25/2019 Phonopy Workshop

    49/52

    nimation for 9Tsim and else

    #N9:3 + ;.D ;.D ;.D

    #N9:3 + G D 6; ;.6D ;.6D ;.6D

    +or 9Tsim

    +or gdis# etc# at only point

    and index "from the !ottom5

    qpoint

    mplitude

    um!er of pictures

    tomic position shift

  • 7/25/2019 Phonopy Workshop

    50/52

    Eigen9ector to displacement

    :"0A7#9"N + ; ; ; 1 1 18 G 1

    Displaced structure along an eigen9ector is created !y

    :P"SC#-;;1is the structure that we want.

  • 7/25/2019 Phonopy Workshop

    51/52

    +inite displacements

    mplitudeDefault 9alue is K.K, >.

    (oo small 9alue enhances error of forces.

    (oo large 9alue induces anharmonic contri!ution.

    $lusminus displacement

    (a&e plusminus as default

    7nly plus when symmetric "automatically searched from crystal symmetry5

    (his often also compensates residual forces.

    *om!ination of these defaults and high enoughenergy con9ergence criteria in force calculation isexpected to gi9e uniform results.

  • 7/25/2019 Phonopy Workshop

    52/52

    oo&s and a reference

    Introduction to Gattice Dynamics "?artin (. Do9e5 $hysical $roperties of *rystals "W. +. ye5 (hermodynamics of *rystals "Duane *. )allace5 (hermodynamics and an Introduction to

    (hermostatistics "er!ert . *allen5 Electrons and $honons "W. ?. Yiman5 $rinciples of uantum ?echanics "R. Shan&ar5

    +rom ultrasoft pseudopotentials to the projectoraugmentedwa9e method#