Sei sulla pagina 1di 96

phonopy manual

Release 1.7.4

Atsushi Togo

December 04, 2013

CONTENTS

.
.
.
.
.

1
1
3
7
9
9

Tutorial using VASP as calculator


2.1 Pre-process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2.2 Calculation of sets of forces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2.3 Post-process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

11
11
11
12

Work flow

15

Download and install

17

Special cases on installation


5.1 Using phonopy on Mac OS X . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5.2 Set up Ubuntu linux on VirtualBox . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

19
19
20

Features
6.1 Band structure . . . . . . . . . . . . . . .
6.2 Density of states . . . . . . . . . . . . . .
6.3 Thermal properties . . . . . . . . . . . . .
6.4 Animation . . . . . . . . . . . . . . . . .
6.5 Plot and output . . . . . . . . . . . . . . .
6.6 Calculation of mode Grneisen parameters

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

23
23
23
23
23
23
23

Input files
7.1 Setting file . . . . . . . .
7.2 Structure file (POSCAR) .
7.3 Force file (FORCE_SETS)
7.4 FORCE_CONSTANTS . .
7.5 QPOINTS (optional) . . .
7.6 BORN (optional) . . . . .

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

25
25
25
26
27
27
28

Output files
8.1 List of files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
8.2 How to read phonopy YAML files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

29
29
30

Examples
1.1 Si . . . . . . . . . . . . . . . . . . . . . . . .
1.2 NaCl . . . . . . . . . . . . . . . . . . . . . .
1.3 MgB2 characters of ireducible representations
1.4 Al-QHA . . . . . . . . . . . . . . . . . . . .
1.5 Si-gruneisen . . . . . . . . . . . . . . . . . .

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

Setting tags
9.1 Basic tags . . . . . . . . . . . . . . . . . . . . . . . . . .
9.2 Displacement creation tags . . . . . . . . . . . . . . . . .
9.3 Band structure related tags . . . . . . . . . . . . . . . . .
9.4 DOS related tags . . . . . . . . . . . . . . . . . . . . . .
9.5 Thermal properties related tags . . . . . . . . . . . . . .
9.6 Thermal displacements . . . . . . . . . . . . . . . . . . .
9.7 Specific q-points . . . . . . . . . . . . . . . . . . . . . .
9.8 Non-analytical term correction . . . . . . . . . . . . . . .
9.9 Group velocity . . . . . . . . . . . . . . . . . . . . . . .
9.10 Symmetry . . . . . . . . . . . . . . . . . . . . . . . . .
9.11 Force constants . . . . . . . . . . . . . . . . . . . . . . .
9.12 Create animation file . . . . . . . . . . . . . . . . . . . .
9.13 Create modulated structure . . . . . . . . . . . . . . . . .
9.14 Characters of irreducible representations of phonon modes

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.

33
33
34
35
36
38
38
39
40
40
40
41
41
43
43

10 Command options
10.1 Help (-h or --help) . . . .
10.2 Create FORCE_SETS . . . .
10.3 Create FORCE_CONSTANTS
10.4 Graph plotting . . . . . . . .
10.5 Calculate DOS . . . . . . . .
10.6 Unit conversion factor . . . .
10.7 Log level . . . . . . . . . . .
10.8 Crystal symmetry . . . . . . .
10.9 Input cell . . . . . . . . . . .

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.

45
46
46
47
47
47
47
48
48
48

11 Auxiliary tools
11.1 bandplot . . .
11.2 pdosplot . . .
11.3 propplot . . .
11.4 dispmanager
11.5 outcar-born

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

51
51
51
51
52
52

12 Quasi harmonic approximation


12.1 Usage of phonopy-qha . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
12.2 Theory of quasi-harmonic approximation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

53
53
55

13 Calculation of mode Grneisen parameters


13.1 Usage of gruneisen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
13.2 Method to calculate mode Grneisen parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . .

57
57
59

14 Interfaces
14.1 VASP & phonopy calculation . . . .
14.2 VASP-DFPT & phonopy calculation .
14.3 Wien2k & phonopy calculation . . .
14.4 FHI-aims & phonopy calculations . .
14.5 Using phonopy as a python module .

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

61
61
61
63
63
64

15 Formulations
15.1 Second-order force constants . . . . .
15.2 Modified Parlinski-Li-Kawazoe method
15.3 Dynamical matrix . . . . . . . . . . .
15.4 Non-analytical term correction . . . . .
15.5 Thermodynamic properties . . . . . . .

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

71
71
71
72
73
73

ii

15.6 Thermal displacement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .


15.7 Group velocity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

74
75

16 How to cite phonopy


16.1 Citation of phonopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

77
77

17 References
17.1 Method used in phonopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
17.2 Other methods for calculating force constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
17.3 For the study of basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

79
79
79
80

18 Change Log
18.1 Oct-3-2013: Version 1.7.4 . .
18.2 Sep-17-2013: Version 1.7.3 .
18.3 Aug-4-2013: Version 1.7.2 . .
18.4 July-14-2013: Version 1.7.1 .
18.5 Jun-21-2013: Version 1.7 . .
18.6 Apr-13-2013: Version 1.6.4 .
18.7 Feb-7-2013: Version 1.6.3 . .
18.8 Nov-13-2012: Version 1.6.2 .
18.9 Nov-4-2012: Version 1.6.1 . .
18.10 Oct-22-2012: Version 1.6 . .
18.11 June-29-2012: Version 1.5 . .
18.12 May-22-2012: Version 1.4.2 .
18.13 May-21-2012: Version 1.4.1 .
18.14 May-13-2012: Version 1.4 . .
18.15 Mar-20-2012: Version 1.3 . .
18.16 Oct-13-2011: Version 1.2.1 .
18.17 Oct-12-2011: Version 1.2 . .
18.18 Sep-19-2011: Version 1.1 . .
18.19 Sep-5-2011: Version 1.0 . . .
18.20 Aug-8-2011: Version 0.9.6 . .
18.21 Jun-7-2011: Version 0.9.5.1 .
18.22 Errata of document . . . . . .
18.23 Jun-3-2011: Version 0.9.5 . .
18.24 Errata of document . . . . . .
18.25 Apr-18-2011: Version 0.9.4.2
18.26 Feb-26-2011: Version 0.9.4.1
18.27 Feb-20-2011: Version 0.9.4 .
18.28 Jan-21-2011: Version 0.9.3.3 .
18.29 Jan-12-2011: Version 0.9.3.2 .
18.30 Errata of document . . . . . .
18.31 Dec-30-2010: Version 0.9.3.1
18.32 Dec-5-2010: Version 0.9.3 . .
18.33 Nov-26-2010: Version 0.9.2 .
18.34 Sep-22-2010: Version 0.9.1.4
18.35 Aug-24-2010: Version 0.9.1.3
18.36 June-10-2010: Version 0.9.1.2
18.37 May-11-2010: Version 0.9.1.1
18.38 May-10-2010: Version 0.9.1 .
18.39 Apr-12-2010: Version 0.9.0.2
18.40 Apr-12-2010: Version 0.9.0.1
18.41 Apr-10-2010: Version 0.9.0 .
18.42 Mar-10-2010: Version 0.7.4 .

81
81
81
81
82
82
82
82
82
83
83
83
83
83
83
84
84
84
85
85
85
85
85
85
86
86
86
86
87
87
87
87
87
87
88
88
88
89
89
89
89
89
89

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

iii

18.43
18.44
18.45
18.46
18.47

iv

Feb-10-2010: Version 0.7.3 . . . . .


Jan-12-2010: Version 0.7.2 . . . . . .
Dec-8-2009: Version 0.7.1 released .
Nov-24-2009: Version 0.7.0 released
Oct-14-2009: Version 0.6.2 released .

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

.
.
.
.
.

89
89
90
90
90

CHAPTER

ONE

EXAMPLES
Example files are stored in the example directory of distributed package.

1.1 Si
1.1.1 FORCE_SETS file creation for VASP
% phonopy -f vasprun.xml
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
0.9.4
counter (file index): 1 (1)
FORCE_SETS has been created.
_
___ _ __
__| |
/ _ \ _ \ / _ |
| __/ | | | (_| |
\___|_| |_|\__,_|

where vasprun.xml is the VASP output.

1.1.2 DOS
% phonopy -p mesh.conf
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
0.9.4
Mesh sampling mode
Settings:

phonopy manual, Release 1.7.4

Sampling mesh: [31 31 31]


Supercell: [2 2 2]
Spacegroup: Fd -3 m (227)
Number of irreducible q-points:
...

816

1.1.3 Thermal properties


% phonopy -t -p mesh.conf
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
0.9.4
Mesh sampling mode
Settings:
Sampling mesh: [31 31 31]
Supercell: [2 2 2]
Spacegroup: Fd -3 m (227)
Number of irreducible q-points: 816
#
T [K]
F [kJ/mol]
S [J/K/mol]
0.000
11.7110491
0.0000000
10.000
11.7110005
0.0207133
20.000
11.7101707
0.1826665
30.000
11.7063149
0.6494417
40.000
11.6959681
1.4755146
50.000
11.6758627
2.5838025
60.000
11.6436850
3.8753235
70.000
11.5979859
5.2789839
80.000
11.5378707
6.7536680
90.000
11.4627491
8.2777066
100.000
11.3721917
9.8393077
...

C_v [J/K/mol]
0.0000000
0.0652014
0.5801980
1.9566658
3.9391312
6.0729958
8.1398560
10.1081936
12.0151390
13.8988294
15.7763729

Chapter 1. Examples

phonopy manual, Release 1.7.4

1.2 NaCl
1.2.1 Band structure
% phonopy -p band.conf
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
0.9.1.4
Band structure mode
Settings:
Supercell: [2 2 2]
Primitive axis:
[ 0.
0.5 0.5]
[ 0.5 0.
0.5]
[ 0.5 0.5 0. ]
Spacegroup: Fm -3 m (225)
Paths in reciprocal reduced coordinates:
[ 0.00 0.00 0.00] --> [ 0.50 0.00 0.00]
[ 0.50 0.00 0.00] --> [ 0.50 0.50 0.00]
[ 0.50 0.50 0.00] --> [-0.00 -0.00 0.00]
[ 0.00 0.00 0.00] --> [ 0.50 0.50 0.50]
...

1.2. NaCl

phonopy manual, Release 1.7.4

1.2.2 Band structure with non-analytical term correction


This requires to prepare BORN file.
% phonopy -p --nac band.conf
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
1.4
Band structure mode
Settings:
Non-analytical term correction: on
Supercell: [2 2 2]
Primitive axis:
[ 0.
0.5 0.5]
[ 0.5 0.
0.5]
[ 0.5 0.5 0. ]
Spacegroup: Fm-3m (225)
Calculating force constants...
Paths in reciprocal reduced coordinates:
[ 0.00 0.00 0.00] --> [ 0.50 0.00 0.00]
[ 0.50 0.00 0.00] --> [ 0.50 0.50 0.00]
[ 0.50 0.50 0.00] --> [-0.00 -0.00 0.00]
[ 0.00 0.00 0.00] --> [ 0.50 0.50 0.50]
...

Chapter 1. Examples

phonopy manual, Release 1.7.4

1.2.3 PDOS
% phonopy -p pdos.conf
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
1.6.2
Mesh sampling mode
Settings:
Sampling mesh: [41 41 41]
Supercell: [2 2 2]
Primitive axis:
[ 0.
0.5 0.5]
[ 0.5 0.
0.5]
[ 0.5 0.5 0. ]
Spacegroup: Fm-3m (225)
Calculating force constants...
Number of irreducible q-points:
_
___ _ __
__| |
/ _ \ _ \ / _ |
| __/ | | | (_| |
\___|_| |_|\__,_|

1.2. NaCl

1771

phonopy manual, Release 1.7.4

With non-analytical term correction, the PDOS may not change very much because it mainly affects to the density of
states only around point.
% phonopy --nac -p pdos.conf
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
1.6.2
Mesh sampling mode
Settings:
Non-analytical term correction: on
Sampling mesh: [41 41 41]
Supercell: [2 2 2]
Primitive axis:
[ 0.
0.5 0.5]
[ 0.5 0.
0.5]
[ 0.5 0.5 0. ]
Spacegroup: Fm-3m (225)
Calculating force constants...
Number of irreducible q-points: 1771
_
___ _ __
__| |
/ _ \ _ \ / _ |
| __/ | | | (_| |
\___|_| |_|\__,_|

Chapter 1. Examples

phonopy manual, Release 1.7.4

1.3 MgB2 characters of ireducible representations


% phonopy -f vasprun.xml-{001,002}
% phonopy --dim="3 3 2" --ct="0 0 0"
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
1.6.2
Character table mode
Settings:
Supercell: [3 3 2]
Spacegroup: P6/mmm (191)
Calculating force constants...
----------------Character table
----------------q-point: [ 0. 0. 0.]
Point group: 6/mmm
Original rotation matrices:
1
-------1 0 0
0 1 0
0 0 1

2
--------1 0 0
0 -1 0
0 0 -1

3
-------1 -1 0
1 0 0
0 0 1

4
--------1 1 0
-1 0 0
0 0 -1

5
-------0 -1 0
1 -1 0
0 0 1

6
-------0 1 0
-1 1 0
0 0 -1

7
--------1 0 0
0 -1 0
0 0 1

8
-------1 0 0
0 1 0
0 0 -1

9
--------1 1 0
-1 0 0
0 0 1

10
-------1 -1 0
1 0 0
0 0 -1

11
-------0 1 0
-1 1 0
0 0 1

12
-------0 -1 0
1 -1 0
0 0 -1

1.3. MgB2 characters of ireducible representations

phonopy manual, Release 1.7.4

13
-------0 -1 0
-1 0 0
0 0 -1

14
-------0 1 0
1 0 0
0 0 1

15
--------1 0 0
-1 1 0
0 0 -1

16
-------1 0 0
1 -1 0
0 0 1

17
--------1 1 0
0 1 0
0 0 -1

18
-------1 -1 0
0 -1 0
0 0 1

19
-------0 1 0
1 0 0
0 0 -1

20
-------0 -1 0
-1 0 0
0 0 1

21
-------1 0 0
1 -1 0
0 0 -1

22
--------1 0 0
-1 1 0
0 0 1

23
-------1 -1 0
0 -1 0
0 0 -1

24
--------1 1 0
0 1 0
0 0 1

Transformation matrix:
1.000
0.000
0.000

0.000
1.000
0.000

0.000
0.000
1.000

Rotation matrices by transformation matrix:


E
-------1 0 0
0 1 0
0 0 1

i
--------1 0 0
0 -1 0
0 0 -1

C6
-------1 -1 0
1 0 0
0 0 1

S3
--------1 1 0
-1 0 0
0 0 -1

C3
-------0 -1 0
1 -1 0
0 0 1

S6
-------0 1 0
-1 1 0
0 0 -1

C2
--------1 0 0
0 -1 0
0 0 1

sgh
-------1 0 0
0 1 0
0 0 -1

C3
--------1 1 0
-1 0 0
0 0 1

S6
-------1 -1 0
1 0 0
0 0 -1

C6
-------0 1 0
-1 1 0
0 0 1

S3
-------0 -1 0
1 -1 0
0 0 -1

C2
-------0 -1 0
-1 0 0
0 0 -1

sgd
-------0 1 0
1 0 0
0 0 1

C2
--------1 0 0
-1 1 0
0 0 -1

sgv
-------1 0 0
1 -1 0
0 0 1

C2
--------1 1 0
0 1 0
0 0 -1

sgd
-------1 -1 0
0 -1 0
0 0 1

C2
-------0 1 0
1 0 0
0 0 -1

sgv
-------0 -1 0
-1 0 0
0 0 1

C2
-------1 0 0
1 -1 0
0 0 -1

sgd
--------1 0 0
-1 1 0
0 0 1

C2
-------1 -1 0
0 -1 0
0 0 -1

sgv
--------1 1 0
0 1 0
0 0 1

Character table:
1 ( -0.019): A2u
1.000 -1.000 1.000 -1.000 1.000 -1.000 1.000 -1.000
1.000 -1.000 1.000 -1.000 -1.000 1.000 -1.000 1.000
-1.000 1.000 -1.000 1.000 -1.000 1.000 -1.000 1.000

2 (
0.004): E1u
2.000 -2.000 1.000 -1.000 -1.000
-1.000 1.000 1.000 -1.000 -0.000
0.000 -0.000 0.000 -0.000 -0.000

1.000 -2.000 2.000


0.000 0.000 -0.000
0.000 -0.000 0.000

4 (
9.953): E1u
2.000 -2.000 1.000 -1.000 -1.000

1.000 -2.000

2.000

Chapter 1. Examples

phonopy manual, Release 1.7.4

-1.000
-0.000

1.000 1.000 -1.000


0.000 -0.000 0.000

0.000 -0.000 -0.000 0.000


0.000 -0.000 0.000 -0.000

6 ( 11.982): A2u
1.000 -1.000 1.000 -1.000 1.000 -1.000 1.000 -1.000
1.000 -1.000 1.000 -1.000 -1.000 1.000 -1.000 1.000
-1.000 1.000 -1.000 1.000 -1.000 1.000 -1.000 1.000
7 ( 17.269): E2g
2.000 2.000 -1.000 -1.000 -1.000 -1.000 2.000 2.000
-1.000 -1.000 -1.000 -1.000 0.000 0.000 0.000 0.000
-0.000 -0.000 0.000 0.000 0.000 0.000 -0.000 -0.000
9 ( 20.565): B2g
1.000 1.000 -1.000 -1.000 1.000 1.000 -1.000 -1.000
1.000 1.000 -1.000 -1.000 -1.000 -1.000 1.000 1.000
-1.000 -1.000 1.000 1.000 -1.000 -1.000 1.000 1.000
_
___ _ __
__| |
/ _ \ _ \ / _ |
| __/ | | | (_| |
\___|_| |_|\__,_|

1.4 Al-QHA
% phonopy-qha e-v.dat thermal_properties.yaml-{-{5..1},{0..5}} --sparse=50
# Vinet EOS
#
T
E_0
B_0
B_0
V_0
0.000000
-14.796263
75.231724
4.758283
66.697923
2.000000
-14.796263
75.231723
4.758283
66.697923
4.000000
-14.796263
75.231718
4.758284
66.697923
6.000000
-14.796263
75.231695
4.758286
66.697924
8.000000
-14.796263
75.231634
4.758294
66.697928
10.000000
-14.796264
75.231510
4.758308
66.697934
...

1.5 Si-gruneisen
See Calculation of mode Grneisen parameters.

1.4. Al-QHA

phonopy manual, Release 1.7.4

10

Chapter 1. Examples

CHAPTER

TWO

TUTORIAL USING VASP AS


CALCULATOR
2.1 Pre-process
The input stureture of POSCAR is supposed to be this.
In the pre-process, supercell structures with (or without) displacements are created from a unit cell fully consiering
crystal symmetry.
To obtain supercells (2 2 3) with displacements, run phonopy:
phonopy -d --dim="2 2 3"

You should find the files, SPOSCAR, disp.yaml, and POSCAR-{number} as follows:
% ls
disp.yaml

POSCAR

POSCAR-001

POSCAR-002

POSCAR-003

SPOSCAR

SPOSCAR is the perfect supercell structure, disp.yaml contains the information on displacements, and
POSCAR-{number} are the supercells with atomic displacements. POSCAR-{number} corresponds to the different atomic displacements written in disp.yaml.

2.2 Calculation of sets of forces


Force constants are calculated using the structure files POSCAR-{number} (from forces on atoms) or using the
SPOSCAR file (direct calculation of force constants) by your favorite calculator. See the details.
In the case of VASP, the calculations for the finite displacement method can be proceeded just using the
POSCAR-{number} files as POSCAR of VASP calculations. An example of the INCAR is as follows:
PREC
IBRION
ENCUT
EDIFF
ISMEAR
IALGO
LREAL
ADDGRID
LWAVE
LCHARG

=
=
=
=
=
=
=
=
=
=

Accurate
-1
500
1.0e-08
0; SIGMA = 0.01
38
.FALSE.
.TRUE.
.FALSE.
.FALSE.

11

phonopy manual, Release 1.7.4

Be careful not to relax the structures. Then create FORCE_SETS file using VASP interface:
% phonopy -f disp-001/vasprun.xml disp-002/vasprun.xml disp-003/vasprun.xml

or
% phonopy -f disp-{001..003}/vasprun.xml

If you want to calculate force constants by VASP-DFPT directory, see VASP-DFPT & phonopy calculation.

2.3 Post-process
In the post-process,
1. Force constants are calculated from the sets of forces
2. A part of dynamical matrix is built from the force constants
3. Phonon frequencies and eigenvectors are calculated from the dynamical matrices with the specified q-points.
For mesh sampling calculation, prepare the following setting file named, e.g., mesh.conf:
ATOM_NAME = Si O
DIM = 2 2 3
MP = 8 8 8

The density of states (DOS) is plotted by:


% phonopy -p mesh.conf

Thermal properties are calculated with the sampling mesh by:


% phonopy -t mesh.conf

You should check the convergence with respect to the mesh numbers. Thermal properties can be plotted by:
% phonopy -t -p mesh.conf

Projected DOS is calculated by the following setting file named, e.g., pdos.conf:
ATOM_NAME = Si O
DIM = 2 2 3
MP = 8 8 8
PDOS = 1 2, 3 4 5 6

and plotted by:


% phonopy -p pdos.conf

Band structure is calculated with the following setting file named, e.g., band.conf by:
ATOM_NAME = Si O
DIM = 2 2 3
BAND = 0.5 0.5 0.5

0.0 0.0 0.0

0.5 0.5 0.0

0.0 0.5 0.0

The band structure is plotted by:


% phonopy -p band.conf

In either case, by setting the -s option, the plot is going to be saved in the PDF format. If you dont need to plot DOS,
the (partial) DOS is just calculated using the --dos option.

12

Chapter 2. Tutorial using VASP as calculator

phonopy manual, Release 1.7.4

2.3.1 Details
Following files are required in your working directory.
POSCAR, and FORCE_SETS or FORCE_CONSTANTS
disp.yaml is required to create FORCE_SETS.
In the case of finite difference approach, there are three steps.
1. Create supercells and introduce atomic displacements. Each supercell contains one atomic displacement. It is
done by using -d option with --dim option that specifies supercell dimension. The files of supercells with
atomic displacements like as POSCAR-001, POSCAR-002, ..., are created in current directory (the file format
and names are different in WIEN2k mode.) by running phonopy. The files disp.yaml and SPOSCAR are also
created. The file SPOSCAR is the perfect supercell that contains no atomic displacement. This file is not usually
used.
2. Calculate forces on atoms of the supercells with atomic displacements. Currently phonopy has VASP and
WIEN2k interfaces to create FORCE_SETS. After obtaining forces on atoms that calculated by some calculator (its out of phonopy), the forces are summarized in FORCE_SETS file following the format.
3. Calculate phonon related properties. See Features.
If you already have force constants, the first and second steps can be omitted. However your force constants have to be
converted to the format that phonopy can read. The VASP interface to convert force constants is prepared in phonopy.

2.3. Post-process

13

phonopy manual, Release 1.7.4

14

Chapter 2. Tutorial using VASP as calculator

CHAPTER

THREE

WORK FLOW
Work flow of phonopy is shown schematically. There are two ways to calculate, (1) atomic forces from finite displacements and (2) given force constants. You can choose one of them. Forces on atoms or force constants are calculated
by your favorite calculator (shown by the diamonds in the work flow). The boxes are jobs being done by phonopy, and
the circles are input and intermediate output data structures.

Figure 3.1: Work flow of phonon calculation

15

phonopy manual, Release 1.7.4

16

Chapter 3. Work flow

CHAPTER

FOUR

DOWNLOAD AND INSTALL


The procedure of setup phonopy is explained in this section. It is supposed that phonopy is installed on the recent
linux distribution like Ubuntu or Fedora. Mac OS X users may find some more information on Using phonopy on Mac
OS X. If you met installation problems, it is recommended to prepare a system with Ubuntu linux as a virtual machine.
See Set up Ubuntu linux on VirtualBox
1. Prepare the following Python libraries:
Python and its header files
numpy
matplotlib
python-lxml
python-yaml
In Ubuntu linux, they are installed by:
% sudo apt-get install python-dev python-numpy \
python-matplotlib python-tk python-lxml python-yaml

python-scipy is also required to use phonopy-qha.


The texlive-fonts-recommended package may be required, if you see the following message in ploting
results:
! I cant find file pncr7t.

2. Download the source code from:


https://sourceforge.net/projects/phonopy/ .
and extract it:
% tar xvfz phonopy-1.3.tar.gz

3. Put your phonopy directory into your PYTHONPATH in .bashrc etc, e.g.:
export PYTHONPATH=~/phonopy-1.3/lib/python

4. Set up C-libraries for python C-API and python codes. This can be done as follows:
Run setup.py script:
% python setup.py install --home=.

The command phonopy is located in the bin directory. The install location can be specified by the option
--home.
17

phonopy manual, Release 1.7.4

18

Chapter 4. Download and install

CHAPTER

FIVE

SPECIAL CASES ON INSTALLATION


5.1 Using phonopy on Mac OS X
5.1.1 Installation using MacPorts
1. Install MacPorts. Download MacPorts from http://www.macports.org/ and follow the installation instruction.
2. Install the following packages
py27-matplotlib
py27-lxml
py27-yaml
py27-scipy

MacPorts command can be used as follows:


% sudo port install py27-matplotlib

At the same time, many dependent packages are also installed.


3. Add the following line to ~/.matplotlib/matplotlibrc
backend : MacOSX

4. Set /opt/local/bin/python to be prior than the Mac OS X default python, e.g.,:


export PATH=/opt/local/bin:$PATH
in .bashrc or .zshrc.
5. Set python27 as the default python command by:
% port select python python27

6. Add the path below to PYTHONPATH.


/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/

This path can be system dependent. PYTHONPATH setting in step 3 of Download and install is also necessary.
7. Install phonopy following Download and install (step 1 can be omitted.)
Make sure that step 6 is done after step 5.

19

phonopy manual, Release 1.7.4

5.2 Set up Ubuntu linux on VirtualBox


The following the steps to install Ubuntu linux on VirtualBox. This document is prepared for the user who failed to
install phonopy for some reason. Basically the questions on this procedure are not accepted in the phonopy mailing
list.
The setup of Ubuntu linux on VirtualBox is quite easy. Ubuntu (server) linux on VMware player can be set up similarly.
1. Install VirtualBox
VirtualBox is an open source virtualization system. VirtualBox runs on Windows, Mac, Linux, etc. On Windows
and Mac, the explanation of how to install is unnecessary. On Ubuntu linux, it can be installed using apt-get:
% sudo apt-get install virtualbox

2. Download Ubuntu Server image


The Ubuntu Server image is found at http://www.ubuntu.com/download/server/download. Alternatively
it may be downloaded from the mirror sites near your location.
For example, the file name is
ubuntu-11.10-desktop-i386.iso.
3. Create a new virtual machine
You can specify parameters, but it is also OK just clicking next, next, ...

Then you can create an empty virtual machine image.

To install ubuntu server, set the install image as the virtual CD device from Settings -> Storage, and click OK.

20

Chapter 5. Special cases on installation

phonopy manual, Release 1.7.4

Start the virtual machine, then the installation of Ubuntu linux will start.

In the install process, you may just click continue, ..., install, etc. The computers name and user name are
set as you like.
4. System setting of the virtual machine
Boot the virtual machine and login to the ubuntu linux with the user name and password.
The terminal emulator is opened by Alt + Ctrl + T or from the top-left corner seraching terminal. What
has to do first is update the system by:
% sudo apt-get update
% sudo apt-get upgrade

Some packages are to be installed for convenience:


% sudo apt-get install openssh-server

vim, zsh, screen, aptitude may be also useful. Then install phonopy following Download and install.
5. Using phonopy from the host computer of the virtual machine
Phonopy can be used from the host computer (the machine where VirtualBox was installed).
First, the network device of the virtual machine has to be modified. If NAT is used, the port-forwarding setting
is required, Settings -> Network -> Port forwarding, right click, Insert new rule, Host port -> 2222, Guest port
-> 22. You can login to the virtual machine, e.g., by terminal:

5.2. Set up Ubuntu linux on VirtualBox

21

phonopy manual, Release 1.7.4

% ssh -l username -p 2222 localhost

(scp can be used with -P 2222 option.)


If Bridged adapter is used, you have to know the IP address of the virtual machine. Login to the virtual machine
and in the terminal:
% ifconfig

The IP-address is found after inet addr of (probably) eth0. Then you can login to the virtual machine by the
usual manner with the IP address.
If the host computer is a usual linux or Mac (with the terminal in X11), X-forwarding is easily used by:
% ssh -X -l username -p 2222 localhost

or:
% ssh -X IPADDRESS_OF_VIRTUALMACHINE

This is very useful because the plot can be forwarded to the host computer.

22

Chapter 5. Special cases on installation

CHAPTER

SIX

FEATURES
6.1 Band structure
Phonon band structure is calculated for the specified band paths (Band structure related tags).

6.2 Density of states


Total and partial density of states are calculated based on the q-point sampling mesh (DOS related tags). Smearing
parameter is set by SIGMA tag or --sigma option.

6.3 Thermal properties


Helmholtz free energy, heat capacity at constant volume, and entropy at temperatures are calculated from the phonon
frequencies on the q-point sampling mesh (Thermal properties related tags).

6.4 Animation
Phonon mode is visualized by animation. See Create animation file.

6.5 Plot and output


The results of DOS, PDOS, band structure, and thermal properties are immediately plotted by specifying -p option
(Graph plotting). When -s option is set together with the -p option, the plot is stored in the PDF file (-p -s). In
addition those results are saved in output text files (Output files), too.

6.6 Calculation of mode Grneisen parameters


A script gruneisen is used for calculating mode Grneisen parameters in band structure style and mesh sampling
style. See the details at Calculation of mode Grneisen parameters.

23

phonopy manual, Release 1.7.4

24

Chapter 6. Features

CHAPTER

SEVEN

INPUT FILES
7.1 Setting file
A setting file contains phonopy settings which are summarized at Setting tags. This file is passed to phonopy as an
argument, e.g.,
% phonopy phonopy.conf

where the filename is arbitrary.

7.2 Structure file (POSCAR)


Crystal structure is written in VASPs manner (for Wien2k interface, see WIEN2k mode). The format is simple.
The first line is for your comment, where you can write anything you want. The second line is the ratio for lattice
parameters. You can multiply by this number. The third to fifth lines give the lattice parameters, a, b, and c for the
respective lines. The sixth line contains the number of atoms for each atomic species, which have to correspond to the
atomic positions in the order. The seventh line should be written as Direct. This means that the atomic positions are
represented in fractional (reduced) coordinates. When you write chemical symbols in the first line, they are read and
those defined by the ATOM_NAME tag are overwritten.

7.2.1 Example of rutile-type silicon oxide crystal structure (1)


Si O
1.00000000000000
4.2266540199664249
0.0000000000000000
0.0000000000000000
0.0000000000000000
4.2266540199664249
0.0000000000000000
0.0000000000000000
0.0000000000000000
2.6888359272289208
2
4
Direct
0.0000000000000000 0.0000000000000000 0.0000000000000000
0.5000000000000000 0.5000000000000000 0.5000000000000000
0.3067891334429594 0.3067891334429594 0.0000000000000000
0.6932108665570406 0.6932108665570406 0.0000000000000000
0.1932108665570406 0.8067891334429594 0.5000000000000000
0.8067891334429594 0.1932108665570406 0.5000000000000000

The VASP 5.x style is also supported. Chemical symbols are inserted just before the line of the numbers of atoms.
The chemical symbols in this line overwrite those defined by the ATOM_NAME tag and those defined by the first line
of POSCAR.

25

phonopy manual, Release 1.7.4

7.2.2 Example of rutile-type silicon oxide crystal structure (2)


Stishovite
1.00000000000000
4.2266540199664249
0.0000000000000000
0.0000000000000000
0.0000000000000000
4.2266540199664249
0.0000000000000000
0.0000000000000000
0.0000000000000000
2.6888359272289208
Si
O
2
4
Direct
0.0000000000000000 0.0000000000000000 0.0000000000000000
0.5000000000000000 0.5000000000000000 0.5000000000000000
0.3067891334429594 0.3067891334429594 0.0000000000000000
0.6932108665570406 0.6932108665570406 0.0000000000000000
0.1932108665570406 0.8067891334429594 0.5000000000000000
0.8067891334429594 0.1932108665570406 0.5000000000000000

7.3 Force file (FORCE_SETS)


This file gives sets of forces in supercells with finite atomic displacements. Each supercell involves one displaced
atom. The first line is the number of atoms in supercell. The second line gives number of calculated supercells with
displacements. Below the lines, sets of forces with displacements are written. In each set, firstly the atom number in
supercell is written. Secondary, the atomic displacement in Cartesian coordinates is written. Below the displacement
line, atomic forces in Cartesian coordinates are successively written. This is repeated for the set of displacements.
Blank likes are simply ignored.
In the following example, the third line is the displaced atom number that corresponds to the atom number in the
supercell created by phonopy. The fourth line gives the displacements in Cartesian coordinates. The lines below,
the atomic forces in Cartesian coordinates are written. Once all the forces for a supercell are written, the next set of
forces are written. This routine is repeated until the forces of all the displacements have been written.
See also VASP interface and WIEN2k interface for VASP and Wien2k users.

7.3.1 Example
48
2
1
0.0050650623043761
0.0000000000000000
0.0086223630086415
-0.0347116200
-0.0000026500
-0.0679795200
0.0050392400
-0.0015711700
-0.0079514600
0.0027380900
-0.0017851900
-0.0069206400
... (continue until all the forces for this displacement have written)
25
0.0050650623043761
0.0000000000000000
0.0086223630086415
-0.0017134500
-0.0001539800
0.0017333400
0.0013248100
0.0001984300
-0.0001203700
-0.0001310200
-0.0007955600
0.0003889300
... (continue until all the forces for this displacement have written)

26

Chapter 7. Input files

phonopy manual, Release 1.7.4

7.4 FORCE_CONSTANTS
If the force constants of a supercell are known, it is not necessary to prepared FORCES. Phonopy has an interface to
read and write FORCE_CONSTANTS. To read and write FORCE_CONSTANTS are controlled by Force constants.
VASP users can use VASP DFPT interface to create FORCE_CONSTANTS from vasprun.xml.

7.4.1 Format
First line is for the number of atoms in supercell. Below second line, force constants between atoms are written by
every four lines. In first line of the four lines, anything can be written, i.e., just ignored. Second to fourth lines of the
four lines are for the second rank tensor of force constant in Cartesian coordinates, i.e.::
xx xy xz
yx yy yz
zx zy zz

7.4.2 Example
32
1

1
4.635786969900131
-0.000000000000000
-0.000000000000000
1
2
-0.246720998398056
-0.000000000000000
-0.000000000000000
...
1 32
0.002646999982813
0.018011999883049
-0.000000000000000
2
1
-0.246720998398056
0.000000000000000
0.000000000000000
...
32 32
4.635786969900131
0.000000000000000
0.000000000000000

-0.000000000000000
4.635786969900130
-0.000000000000000

-0.000000000000000
-0.000000000000000
4.635786969900130

-0.000000000000000
0.018256999881458
-0.000000000000000

-0.000000000000000
-0.000000000000000
0.018256999881458

0.018011999883049
0.002646999982813
-0.000000000000000

-0.000000000000000
-0.000000000000000
0.035303999770773

0.000000000000000
0.018256999881458
0.000000000000000

0.000000000000000
0.000000000000000
0.018256999881458

0.000000000000000
4.635786969900130
0.000000000000000

0.000000000000000
0.000000000000000
4.635786969900130

7.5 QPOINTS (optional)


Specific q-points are calculated using QPOINTS = .TRUE. tag and QPOINTS file. The file format of QPOINTS is
as follows. The first line gives the number of q-points. Then the successive lines give q-points in reduced coordinate
of reciprocal space of the input unit cell.

7.4. FORCE_CONSTANTS

27

phonopy manual, Release 1.7.4

7.5.1 Example
512
-0.437500000000000
-0.312500000000000
-0.187500000000000
...

-0.437500000000000
-0.437500000000000
-0.437500000000000

-0.437500000000000
-0.437500000000000
-0.437500000000000

7.6 BORN (optional)


This file is used with the --nac option or NAC tag.

7.6.1 Format
In the first line, the first value is the unit conversion factor. For VASP, it may be 27.2116 0.52918.
In the second line, dielectric constant  is specifed in Cartesian coordinates. The nine values correspond to the tensor
elements of xx, xy, xz, yx, yy, yz, zx, zy, and zz.
From the third line, Born effective charges Z for the independent atoms in the primitive cell have to be written in Cartesian coordinates. The independent atoms can be found using the --symmetry option. If PRIMITIVE_AXIS is supposed to be used to calculate phonons, the option --primitive_axis has to be set together with the --symmetry
option.

7.6.2 Example
14.400
2.00 0.00
1.98 0.00
-0.99 0.00
...

28

0.00
0.00
0.00

0.00 2.00
0.00 1.98
0.00 -0.99

0.00
0.00
0.00

0.00
0.00
0.00

0.00 2.00
0.00 1.98
0.00 -0.99

Chapter 7. Input files

CHAPTER

EIGHT

OUTPUT FILES
The output data are stored in the following files on the current directory.

8.1 List of files


8.1.1 band.yaml
Sets of phonon frequencies on band paths calculated by the band-structure mode (e.g. BAND tag) are stored in the
YAML format.
band.yaml is viewed using the tool bandplot (bandplot). bandplot can convert the data in the YAML format
to that in the gnuplot-style format using the --gnuplot option.

8.1.2 mesh.yaml
A set of frequencies on irreducible q-points of a q-point mesh by the mesh-sampling mode (MP tag) is stored in the
YAML format.

8.1.3 qpoints.yaml
A set of frequencies calculated by the q-points mode (QPOINTS tag) is stored in the YAML format.

8.1.4 thermal_properties.yaml
The thermal properties calculated with -t option are stored in the YAML format.
thermal_properties.yaml is plot using the tool propplot (propplot).

8.1.5 total_dos.dat and partial_dos.dat


Total DOS and partial dos are stored in the simple format, respectively.
total_dos.dat and partial_dos.dat are viewed using the tool pdosplot (pdosplot).

29

phonopy manual, Release 1.7.4

File format of partial_dos.dat


The first column is the phonon frequency. The following colums are the projected density of states for atoms in the
primitive cell. In the NaCl example, there are two atoms in the primitive cell, which are one Na and one Cl atoms. The
order of atoms in the primitive cell is confirmed running phonopy with the -v option. The partial_dos.dat of
this example is starting with the following lines:
# Sigma = 0.063253
-0.6695362607
-0.6379098952
-0.6062835296
-0.5746571641
-0.5430307986
-0.5114044331
-0.4797780675
-0.4481517020
-0.4165253365
-0.3848989710
-0.3532726054
-0.3216462399
-0.2900198744
-0.2583935089
-0.2267671433
...

0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000004
0.0000000044
0.0000000370
0.0000002410
0.0000012239

0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000000
0.0000000006
0.0000000066
0.0000000551
0.0000003596
0.0000018260

where from the left to right in each line, frequency, PDOS of Na and PDOS of Cl. The first line is just a comment to
remember the sigma value used.

8.1.6 disp.yaml
This file contains information to create supercells with displacements. The format is hopefully understood just looking
into it. displacement is written in Cartesian coordinates. The displacement and direction are related by
u=A

(a, b, c)d
,
|(a, b, c)d|

where u is the displacement in Cartesian coordinates, A is the amplitude, (a, b, c) is the matrix representing supercell
lattice vectors (three column vectors), and d is the direction along the supercell axes.

8.2 How to read phonopy YAML files


Most phonopy results are written in the YAML format. YAML files are easily translated to the combination of lists
and dictionaries in the python case. For each computer language, e.g., Ruby, each YAML parser is prepared and you
can use those libraries to parse YAML files and analyze the data easily in conjunction with your favorite language. See
http://www.yaml.org/. The basic of the YAML format is found easily on the web.

30

Chapter 8. Output files

phonopy manual, Release 1.7.4

8.2.1 mesh.yaml, band.yaml, qpoints.yaml


General

nqpoint
natom
phonon
qposition
band
frequency
eigenvector

Number of q-points calculated.


Number of atoms in the primitive cell.
Key name of list for q-points.
Position of q-vector in reduced coordinates.
Key name of list for bands.
Phonon frequency in a specified unit at each band
Eigenvectors at each band. Each eigenvector e of dynamical matrix is shown as sets of three complex
values of each atom along the Cartesian axes in the primitive cell. The real and imaginary values
correspond to the left and right, respectively.

Mesh sampling mode

mesh Numbers of mesh sampling points along axes of the primitive cell.
weight In the mesh sampling mode, only phonons at irreducible q-points are calculated in the default behavior.
This value means the multiplicity of a q-point in the reciprocal space of the primitive cell.
Band structure mode

distance

In the band structure mode, this value means the distance from the origin in the reciprocal space of the
primitive cell. The unit is the reciprocal of length unit used in the real space.

8.2.2 thermal_properties.yaml
The physical units of the thermal properties are given in the unit section of this YAML file. However the physical units
are only correct when phonopy ran with proper physical units. See Thermal properties related tags.

8.2.3 disp.yaml
direction
displacement

A displacement in the reduced coordinates.


A displacement in the Cartesian coordinates.

8.2. How to read phonopy YAML files

31

phonopy manual, Release 1.7.4

32

Chapter 8. Output files

CHAPTER

NINE

SETTING TAGS
Most of the setting tags have corresponding command-line options (Command options).
For specifying real and reciprocal points, fractional values (e.g. 1/3) are accepted. However fractional values must
not have space among characters (e.g. 1 / 3) are not allowed.

9.1 Basic tags


9.1.1 ATOM_NAME
Chemical symbols
ATOM_NAME = Si O

The number of chemical symbols have to be same as that of the numbers in the sixth line of POSCAR.
Chemical symbols read by phonopy are overwritten by those written in POSCAR. See POSCAR examples. In WIEN2k
mode, you dont need to set this tag, i.e., chemical symbols are read from the structure file.

9.1.2 EIGENVECTORS
When this tag is .TRUE., eigenvectors are calculated. With -p option, partial density of states are calculated.

9.1.3 MASS
This tag is not necessary to use usually, because atomic masses are automatically set from the chemical symbols.
Atomic masses of a primitive cell are overwritten by the values specified. This tag does not affect to the symmetry
findings. For example, when there are six atoms in a primitive cell, MASS is set as follows
MASS =

28.085 28.085 16.000 16.000 16.000 16.000

9.1.4 DIM
The supercell is created from the input unit cell. When three integers are specified, a supercell elongated along axes
of unit cell is created.
DIM = 2 2 3

33

phonopy manual, Release 1.7.4

In this case, a 2x2x3 supercell is created.


When nine integers are specified, the supercell is created by multiplying the supercell matrix Ms with the unit cell.
For example,
DIM = 0 1 1

1 0 1

1 1 0

the supercell matrix is

0
Ms = 1
1

1
0
1

1
1
0

where the rows correspond to the first three, second three, and third three sets of numbers, respectively. When lattice
parameters of unit cell are the column vectors of au , bu , and cu , those of supercell, as , bs , cs , are determined by,
(as bs cs ) = (au bu cu )Ms
Be careful that the axes in POSCAR is defined by three row vectors, i.e., (au bu cu )T .

9.1.5 PRIMITIVE_AXIS
PRIMITIVE_AXIS = 0.0 0.5 0.5

0.5 0.0 0.5

0.5 0.5 0.0

Likewise,
PRIMITIVE_AXIS = 0 1/2 1/2

1/2 0 1/2

1/2 1/2 0

The primitive cell for building the dynamical matrix is created by multiplying primitive-axis matrix Mp . Let the matrix
as,

0.0 0.5 0.5


Mp = 0.5 0.0 0.5
0.5 0.5 0.0
where the rows correspond to the first three, second three, and third three sets of numbers, respectively.
When lattice parameters of unit cell (set by POSCAR) are the column vectors of au , bu , and cu , those of supercell, ap ,
bp , cp , are determined by,
(ap bp cp ) = (au bu cu )Mp
Be careful that the axes in POSCAR is defined by three row vectors, i.e., (au bu cu )T .

9.2 Displacement creation tags


9.2.1 CREATE_DISPLACEMENTS
Supercells with displacements are created. This tag is used as the post process of phonon calculation.
CREATE_DISPLACEMENTS = .TRUE.
DIM = 2 2 2

9.2.2 DISPLACEMENT_DISTANCE
Finite atomic displacement distance is set as specified value when creating supercells with displacements. The default
displacement amplitude is 0.01 . When the wien2k option is specified, the default value is changed to 0.02 Bohr.
34

Chapter 9. Setting tags

phonopy manual, Release 1.7.4

9.2.3 DIAG
When this tag is set .FALSE., displacements in diagonal directions are not searched, i.e. all the displacements are
along the lattice vectors. DIAG = .FALSE. is recommended if one of the lattice parameter of your supercell is
much longer or much shorter than the other lattice parameters.

9.2.4 PM
This tag specified how displacements are found. When PM = .FALSE., least displacements that can calculate
force constants are found. This may cause less accurate result. When PM = .TRUE., all the displacements that
are opposite to the least displacements are found. The default setting is PM = AUTO. Plus-minus displacements are
considered with this tag. If the plus and minus displacements are symmetrically equivalent, only the plus displacement
is found. This may be in between .FALSE. and .TRUE.. You can check how it works to see the file DISP where
displacement directions on atoms are written.

9.3 Band structure related tags


9.3.1 BAND, BAND_POINTS
BAND gives sampling band paths. The reciprocal points are specified in reduced coordinates. The given points are
connected for defining band paths. When comma , is inserted between the points, the paths are disconnected.
BAND_POINTS gives the number of sampling points including the path ends. The default value is BAND_POINTS
= 51.
An example of three paths, (0,0,0) to (1/2,0,1/2), (1/2,1/2,1) to (0,0,0), and (0,0,0) to (1/2,1/2,1/2), with 101 sampling
points of each path are as follows:
BAND = 0 0 0 1/2 0 1/2,
BAND_POINTS = 101

1/2 1/2 1

0 0 0

1/2 1/2 1/2

9.3.2 BAND_LABELS
Labels specified are depicted in band structure plot at the points of band segments. The number of labels has to
correspond to the number of band paths specified by BAND plus one.
BAND = 1/2 0 1/2
0 0 0
BAND_LABELS = X \Gamma L

1/2 1/2 1/2

9.3. Band structure related tags

35

phonopy manual, Release 1.7.4

The colors of curves are automatically determined by matplotlib. The same color in a band segment shows the same
kind of band. Between different band segments, the correspondence of colors doesnt mean anything.

9.3.3 BAND_CONNECTION
With this option, band connections are estimated from eigenvectors and band structure is drawn considering band
crossings. In sensitive cases, to obtain better band connections, it requires to increase number of points calculated in
band segments by the BAND_POINTS tag.
BAND = 1/2 0 1/2
0 0 0
BAND_POINTS = 101
BAND_CONNECTION = .TRUE.

1/2 1/2 1/2

9.4 DOS related tags


9.4.1 MP
MP numbers give uniform meshes in each axis. As the default behavior, the center of mesh is determined by the
Monkhorst-Pack scheme, i.e., for odd number, a point comes to the center, and for even number, the center is shifted
half in the distance between neighboring mesh points.

36

Chapter 9. Setting tags

phonopy manual, Release 1.7.4

Examples of an even mesh with center in two ways,


MP = 8 8 8
GAMMA_CENTER = .TRUE.
MP = 8 8 8
MP_SHIFT = 1/2 1/2 1/2

9.4.2 MP_SHIFT
MP_SHIFT gives the shifts in direction along the corresponding reciprocal axes (a , b , c ). 0 or 1/2 (0.5) can be used
as these values. 1/2 means the half mesh shift with respect to neighboring grid points in each direction.

9.4.3 GAMMA_CENTER
Instead of employing the Monkhorst-Pack scheme for the mesh sampling, center mesh is used. The default value is
.FALSE..
GAMMA_CENTER = .TRUE.

9.4.4 DOS_RANGE
DOS_RANGE = 0 40 0.1

Total and partial density of states are drawn with some parameters. The example makes DOS be calculated from
frequency=0 to 40 with 0.1 pitch.

9.4.5 PDOS
PDOS = 1 2, 3 4 5 6

By setting this tag, EIGENVECTORS = .TRUE. is automatically set. PDOS tag controls how elements of eigenvectors are added. Each value gives the atom index in primitive cell. , separates the atom sets. Therefore in the example,
atom 1 and 2 are summarized as one curve and atom 3, 4, 5, and, 6 are summarized as the other curve.
The projection is applied along arbitrary direction using PROJECTION_DIRECTION tag.

9.4.6 PROJECTION_DIRECTION
Eigenvectors are projected along the direction specified by this tag. Projection direction is specified in reduced coordinates, i.e., with respect to a, b, c axes.
PDOS = 1, 2
PROJECTION_DIRECTION = -1 1 1

9.4.7 SIGMA
This tag specifies the deviation of a smearing function. The unit is same as that of final result of DOS, i.e., for VASP
without --factor option, it is THz. The default value is the value given by the difference of maximum and minimum
frequencies divided by 100.

9.4. DOS related tags

37

phonopy manual, Release 1.7.4

SIGMA = 0.1

9.4.8 DEBYE_MODEL
By setting .TRUE., DOS at lower phonon frequencies are fit to a Debye model. By default, the DOS from 0 to 1/4
of the maximum phonon frequencies are used for the fitting. The function used to the fitting is D() = a 2 where
a is the parameter and the Debye frequency is (9N/a)1/3 where N is the number of atoms in unit cell. Users have
to unserstand that this is not a unique way to determine Debye frequency. Debye frequency is dependent on how to
parameterize it.
DEBYE_MODEL = .TRUE.

9.5 Thermal properties related tags


9.5.1 TPROP, TMIN, TMAX, TSTEP
Thermal properties, free energy, heat capacity, and entropy, are calculated from their statistical thermodynamic expressions (see Thermodynamic properties). Thermal properties are calculated from phonon frequencies on a sampling
mesh in the reciprocal space. Therefore These tags are used with MP tag and their convergence with respect to the
sampling mesh has to be checked. Usually this calculation is not computationally demanding, so the convergence is
easily achieved with increasing the density of the sampling mesh. -p option can be used together to plot the thermal
propreties. Phonon frequencies have to be calculated in THz. Therefore unit conversion factor to THz may be specified
using --factor option. The calculated values are written into thermal_properties.yaml. The unit systems
of free energy, heat capacity, and entropy are kJ/mol, J/K/mol, and J/K/mol, respectively, where 1 mol means NA
your input unit cell (not formula unit), i.e. you have to divide the value by number of formula unit in your unit cell by
yourself. For example, in MgO (conventional) unit cell, if you want to compare with experimental results in kJ/mol,
you have to divide the phonopy output by four.
TMIN, TMAX, and TSTEP tags are used to specify the temperature range to be calculated. The default values of them
are 0, 1000, and 10, respectively.
TPROP = .TRUE.
TMAX = 2000

9.6 Thermal displacements


Experimental

9.6.1 TDISP, TMAX, TMIN, TSTEP


Mean square displacements projected to Cartesian axes as a function of temperature are calculated from the number of
phonon excitations. The usages of TMAX, TMIN, TSTEP tags are same as those in thermal properties tags. The result
is writen into thermal_displacements.yaml. See the detail of the method, Mean square displacement.
The projection is applied along arbitrary direction using PROJECTION_DIRECTION tag (PROJECTION_DIRECTION).
TDISP = .TRUE.
PROJECTION_DIRECTION = 1 1 0

38

Chapter 9. Setting tags

phonopy manual, Release 1.7.4

9.6.2 TDISPMAT, TMAX, TMIN, TSTEP


Mean square displacement matricies are calculated. The difinition is shown at Mean square displacement. The result
is writen into thermal_displacement_matrices.yaml where six matrix elements are given in the order of
xx, yy, zz, yz, xz, xy.
TDISPMAT = .TRUE.

9.7 Specific q-points


9.7.1 QPOINTS
When QPOINTS = .TRUE., QPOINTS file in your working directory is read, and the q-points written in this file
are calculated.

9.7.2 WRITEDM
WRITEDM = .TRUE.

Dynamical matrices D are written into qpoints.yaml in the following 6N 3N format, where N is the number
of atoms in the primitive cell.

D11 D12 D13


D21 D22 D23

D = D31 D32 D33


,

..
.
and Djj 0 is

Djj 0

xy
xy
xx
xx
xz
xz
Re(Djj
Im(Djj
Re(Djj
Im(Djj
Re(Djj
Im(Djj
0)
0)
0)
0)
0)
0)
yx
yx
yy
yy
yz
yz
= Re(Djj 0 ) Im(Djj 0 ) Re(Djj 0 ) Im(Djj 0 ) Re(Djj 0 ) Im(Djj 0 ) ,
zy
zy
zx
zx
zz
zz
Re(Djj
Im(Djj
Re(Djj
Im(Djj
Re(Djj
Im(Djj
0)
0)
0)
0)
0)
0)

where j and j are the atomic indices in the primitive cell. The phonon frequencies may be recovered from
qpoints.yaml by writing a simple python script. For example, qpoints.yaml is obtained for NaCl at
q = (0, 0.5, 0.5) by
phonopy --dim="2 2 2" --pa="0 1/2 1/2

1/2 0 1/2

1/2 1/2 0" --qpoints="0 1/2 1/2" --writedm

and the dynamical matrix may be used as


#!/usr/bin/env python
import yaml
import numpy as np
data = yaml.load(open("qpoints.yaml"))
dynmat = []
dynmat_data = data[phonon][0][dynamical_matrix]
for row in dynmat_data:
vals = np.reshape(row, (-1, 2))
dynmat.append(vals[:, 0] + vals[:, 1] * 1j)

9.7. Specific q-points

39

phonopy manual, Release 1.7.4

dynmat = np.array(dynmat)
eigvals, eigvecs, = np.linalg.eigh(dynmat)
frequencies = np.sqrt(np.abs(eigvals.real)) * np.sign(eigvals.real)
conversion_factor_to_THz = 15.633302
print frequencies * conversion_factor_to_THz

9.8 Non-analytical term correction


9.8.1 NAC
Non-analytical term correction is applied to dynamical matrix. BORN file has to be prepared in the current directory.
See BORN (optional) and Non-analytical term correction.
NAC = .TRUE.

9.9 Group velocity


9.9.1 GROUP_VELOCITY
Group velocities at q-points are calculated by using this tag. The group velocities are written into a yaml file corresponding to the run mode in Cartesian coordinates. The physical unit depends on physical units of input files and
frequency conversion factor, but if VASP and the default settings (e.g., THz for phonon frequency) are simply used,
then the physical unit will be Angstrom THz.
GROUP_VELOCITY = .TRUE.

Technical details are shown at Method.

9.9.2 GV_DELTA_Q
The reciprocal distance used for finite difference method is specified. The default value is 1e-4.
GV_DELTA_Q = 0.01

9.10 Symmetry
9.10.1 SYMMETRY
P1 symmetry is enforced to the input unit cell by setting SYMMETRY = .FALSE.

9.10.2 MESH_SYMMETRY
Symmetry search on the reciprocal sampling mesh is disabled by setting MESH_SYMMETRY = .FALSE..

40

Chapter 9. Setting tags

phonopy manual, Release 1.7.4

9.10.3 FC_SYMMETRY
This tag is used to symmetrize force constants partly. The number of iteration of the following set of symmetrization
applied to force constants is specified. The default value is 0. In the case of VASP, this tag is usually unnecessary to
be specified.
FC_SYMMETRY = 1

From the translation invariance condition,


X

ij = 0, for all j, , ,

where i and j are the atom indices, and and are the Catesian indices for atoms i and j, respectively. Force constants
are symmetric in each pair as

ij =

2U

u
i uj

2U
uj u
i

=
ji

These symmetrizations break the symmetry conditions each other. Be careful that the other symmetries of force constants, i.e., the symmetry from crystal symmetry or rotational symmetry, are broken to force applying FC_SYMMETRY.

9.11 Force constants


9.11.1 FORCE_CONSTANTS
FORCE_CONSTANTS = READ

There are three values to be set, which are READ and WRITE, and .FALSE..
The default is
.FALSE..
When FORCE_CONSTANTS = READ, force constants are read from FORCE_CONSTANTS
file. With FORCE_CONSTANTS = WRITE, force constants calculated from FORCE_SETS are written to
FORCE_CONSTANTS file.
The file format of FORCE_CONSTANTS is shown here.

9.12 Create animation file


9.12.1 ANIME_TYPE
ANIME_TYPE = JMOL

There are V_SIM, ARC, XYZ, JMOL, and POSCAR settings. Those may be viewed by v_sim, gdis, jmol (animation), jmol (vibration), respectively. For POSCAR, a set of POSCAR format structure files corresponding to respective
animation images are created such as APOSCAR-000, APOSCAR-001,....
There are several parameters to be set in the ANIME tag.

9.12.2 ANIME
The format of ANIME tag was modified after ver. 0.9.3.3.

9.11. Force constants

41

phonopy manual, Release 1.7.4

For v_sim
ANIME = 0.5 0.5 0

The values are the q-point to be calculated. An animation file of anime.ascii is generated.
How to watch animation

To watch each phonon mode, v_sim is recommended. The file anime.ascii is supposed to work with v_sim
version 3.51 or later. An example how to watch phonon modes at a q-point is shown as follows.
First, you need to create a phonopy input file with, e.g., ANIME = 0.5 0.5 0. After running phonopy with this
input file, you get anime.ascii that contains all phonon modes at the q-point. Then start v_sim
v_sim anime.ascii

After opening the graphical user interface, you can find a tab called Phonons. There you can see the phonon
modes at the q-point that you specified in the phonopy input file. Then select one of the phonon modes and watch
by pushing the play button. Because only the unit cell shows up at the start of v_sim, if you want to watch a
phonon modulation with a longer period, then change the values of Expand nodes in the Box and symmetry tab
(http://inac.cea.fr/L_Sim/V_Sim/user_guide.html#trans). This is especially important when you choose a q-point other
than the -point.
V_sim has a good graphical user interface and also a lot of command line options. To read the manual well and to
check the command line options help you to use v_sim comfortably, e.g.,
v_sim -w oneWindow anime.ascii -x 1:1:0 -t 0.5:0.5:0.5

For the other animation formats


Phonon is only calculated at point. So q-point is not necessary to be set.
anime.arc, anime.xyz, anime.xyz_jmol, or APOSCAR-* are generated according to the ANIME_TYPE
setting.
ANIME = 4 5 20

0.5 0.5 0

The values are as follows from left:


1. Band index given by ascending order in phonon frequency.
2. Magnitude to be multiplied. In the harmonic phonon calculation, there is no amplitude information obtained
directly. The relative amplitude among atoms in primitive cell can be obtained from eigenvectors with the
constraint of the norm or the eigenvectors equals one, i.e., number of atoms in the primitive is large, the displacements become small. Therefore this has to be adjusted to make the animation good looking.
3. Number of images in one phonon period.
4. (4-6) Shift of atomic points in reduced coordinate in real space. These values can be omitted and the default
values are 0 0 0.
For anime.xyz_jmol, the first and third values are not used, however dummy values, e.g. 0, are required.

42

Chapter 9. Setting tags

phonopy manual, Release 1.7.4

9.13 Create modulated structure


9.13.1 MODULATION
The MODULATION tag is used to create a crystal structure with displacements along normal modes at q-point in the
specified supercell dimension.
Atomic displacement of the j-th atom is created from the real part of the eigenvectors with amplitudes and phase
factors as
A
Re [exp(i)ej exp(q rj )] ,

mj
where A is the amplitude, is the phase, and mj is the mass of the j-th atom, q is the q-point specified, rjl is the
position of the j-th atom and in the l-th unit cell, and ej is the j-th part of eigenvector. Convention of eigenvector or
dynamical matrix employed in phonopy is shown in Dynamical matrix.
If several modes are specified as shown in the example above, they are overlapped on the structure. The output filenames are MPOSCAR.... Each modulated structure of a normal mode is written in MPOSCAR-<number> where the
numbers correspond to the order of specified sets of modulations. MPOSCAR is the structure where all the modulations
are summed. MPOSCAR-orig is the structure without containing modulation, but the dimension is the one that is
specified. Some information is written into modulation.yaml.
Usage
The first three values correspond to the supercell dimension. The following values are used to describe how the atoms
are modulated. Multiple sets of modulations can be specified by separating by comma ,. In each set, the first three
values give a Q-point in the reduced coordinates in reciprocal space. Then the next three values are the band index
from the bottom with ascending order, amplitude, and phase factor in degrees. The phase factor is optional. If it is not
specified, 0 is used.
Before multiplying user specified phase factor, the phase of the modulation vector is adjusted as the largest absolute

value, |ej | / mj , of element of 3N dimensional modulation vector to be real. The complex modulation vector is
shown in modulation.yaml.
MODULATION = 3 3 1, 1/3 1/3 0 1 2, 1/3 1/3 2 3.5
MODULATION = 3 3 1, 1/3 1/3 0 1 2, 1/3 0 0 2 2
MODULATION = 3 3 1, 1/3 1/3 0 1 1 0, 1/3 1/3 0 1 1 90

9.14 Characters of irreducible representations of phonon modes


9.14.1 IRREPS
Characters of irreducible representations (IRs) of phonon modes are shown. For this calculation, a primitive cell
has to be used. If the input unit cell is a non-primitive cell, it has to be transformed to a primitive cell using
PRIMITIVE_AXIS tag.
The first three values gives a q-point in reduced coordinates to be calculated. The degenerated modes are searched
only by the closeness of frequencies. The frequency difference to be tolerated is specified by the fourth value in the
frequency unit that the user specified.

9.13. Create modulated structure

43

phonopy manual, Release 1.7.4

IRREPS = 0 0 0 1e-3

Only the databases of IRs for a few point group types at the point are implemented. If the database is available, the
symbols of the IRs and the rotation operations are shown.

9.14.2 SHOW_IRREPS
Experimental
Irreducible representations are shown along with character table.
IRREPS = 1/3 1/3 0
SHOW_IRREPS = .TRUE.

44

Chapter 9. Setting tags

CHAPTER

TEN

COMMAND OPTIONS
Some of command-line options are equivalent to respective setting tags:
--amplitude (DISPLACEMENT_DISTANCE)
--anime (ANIME)
-d (CREATE_DISPLACEMENTS = .TRUE.
--dim (DIM)
--mp, --mesh (MP)
--band (BAND)
--band_points (BAND_POINTS)
--band_connection (BAND_CONNECTION = .TRUE.)
--eigvecs, --eigenvectors (EIGENVECTORS = .TRUE.)
--fits_debye_model (DEBYE_MODEL = .TRUE.)
--gc, --gamma_center (GAMMA_CENTER)
--gv, --group_velocity (GROUP_VELOCITY = .TRUE.)
--gv_delta_q (GV_DELTA_Q)
--irreps (IRREPS)
--show_irreps (SHOW_IRREPS)
--modulation (MODULATION)
--nac (NAC = .TRUE.)
--nosym (SYMMETRY = .FALSE.)
--nomeshsym (MESH_SYMMETRY = .FALSE.)
--pa, --primitive_axis (PRIMITIVE_AXIS)
--pd, --projection_direction (PROJECTION_DIRECTION)
--pdos (PDOS)
--readfc (FORCE_CONSTANTS = READ)
--sigma (SIGMA)
-t (TPROP)
--td (TDISP)

45

phonopy manual, Release 1.7.4

--tdm (TDISPMAT)
--tmin (TMIN)
--tmax (TMAX)
--tstep (TSTEP)
--writedm (WRITEDM = .TRUE.)
--writefc (FORCE_CONSTANTS = WRITE)
When both of command-line option and setting tag for the same purpose are set simultaneously, the command-line
options overide the setting tags.

10.1 Help (-h or --help)


Review of options is shown.

10.2 Create FORCE_SETS


10.2.1 -f or --forces and --fz
VASP interface
FORCE_SETS file is created from disp.yaml, which is an output file when creating supercell with displacements,
and vasprun.xmls, which are the VASP output files. disp.yaml in the current directory is automatically read.
The order of displacements written in disp.yaml file has to correpond to that of vasprun.xml files .
% phonopy -f disp-001/vasprun.xml disp-002/vasprun.xml ...

Attention:
Site-projected wave function information (the same information as PROCAR) siginificantly increases the size of
vasprun.xml. So parsing xml file uses huge memory space. It is recommended
to switch off to calculate it.
If there are many displacements, shell expansions are useful, e.g.,
disp-*/vasprun.xml, or disp-{001..128}/vasprun.xml (for zsh, and recent bash).
--fz option is used to subtract residual forces in the equilibrium supercell.
% phonopy --fz sposcar/vasprun.xml disp-001/vasprun.xml ...

Usually the -f option is preferable to --fz.


WIEN2k interface
This is experimental support to generage FORCE_SETS. Insted of this, you can use the external tool called
scf2forces to generate FORCE_SETS. scf2forces is found at http://www.wien2k.at/reg_user/unsupported/.
FORCE_SETS file is created from disp.yaml, which is an output file when creating supercell with displacements,
and case.scfs, which are the WIEN2k output files. The order of displacements in disp.yaml file and the order
of case.scfs have to be same. For Wien2k struct file, only negative atom index with the P lattice format is
supported.

46

Chapter 10. Command options

phonopy manual, Release 1.7.4

% phonopy --wien2k=case.struct -f case_001/case_001.scf case_002/case_002.scf ...

For more information, Wien2k & phonopy calculation.

10.3 Create FORCE_CONSTANTS


10.3.1 --fc or --force_constants
Currently this option supports only VASP output.
VASP output of force constants is imported from vasprun.xml and FORCE_CONSTANTS is created.
% phonopy --fc vasprun.xml

This FORCE_CONSTANTS can be used instead of FORCE_SETS. For more details, please refer VASP-DFPT &
phonopy calculation.

10.4 Graph plotting


10.4.1 -p
Result is plotted.
% phonopy -p

10.4.2 -p -s
Result is plotted (saved) to PDF file.
% phonopy -p -s

10.5 Calculate DOS


10.5.1 --dos
Density of states are calculated using this option with MP tag. When -p option with MP tag is set, --dos is automatically set. Therefore this tag is used when you want to calculate DOS, but you dont need to plot.

10.6 Unit conversion factor


10.6.1 --factor
Unit conversion factor of frequency from
input values to your favorite unit is specified. The default value is that of
VASP to THz, which is calculated by eV/AMU/( 2 1012 ) (=15.633302) in SI base unit. When the wien2k
option is specified, the default value is changed to 3.44595, which is the factor to convert from Wien2k to THz.

10.3. Create FORCE_CONSTANTS

47

phonopy manual, Release 1.7.4

When calculating thermal property, the factor to THz is required. Otherwise the calculated thermal properties have
wrong units. In the case of band structure plot, any factor can be used, where the frequency is simply shown in the
unit you specified.
% phonopy --factor=521.471

10.7 Log level


10.7.1 -v or --verbose
More detailed log are shown

10.7.2 -q or --quiet
No log is shown.

10.8 Crystal symmetry


10.8.1 --tolerance
The specified value is used as allowed tolerance to find symmetry of crystal structure. The default value is 1e-5.
% phonopy --tolerance=1e-3

10.8.2 --symmetry
Using this option, various crystal symmetry information is just printed out and phonopy stops without going to phonon
analysis.
% phonopy --symmetry

This tag can be used together with the --cell, --wien2k, or --primitive_axis option.

10.9 Input cell


10.9.1 -c or --cell
Phonopy searches the POSCAR file in the current directory. Using this tag, you can specify another filename than
POSCAR as the input unit cell.
% phonopy --cell=UPOSCAR

48

Chapter 10. Command options

phonopy manual, Release 1.7.4

10.9.2 --wien2k
This option with WIEN2k struct file, phonopy runs with the WIEN2k mode. In this mode, you dont need to prepare
POSCAR. The supercells with displacements in WIEN2k struct format are created using -d option. The physical unit
is changed to mRydberg and Bohr. Only the WIEN2k struct with the P lattice is supported. See more information
Wien2k & phonopy calculation.
% phonopy --wien2k=case.struct

10.9. Input cell

49

phonopy manual, Release 1.7.4

50

Chapter 10. Command options

CHAPTER

ELEVEN

AUXILIARY TOOLS
A few auxiliary tools are prepared. They are stored in bin directory as well as phonopy.

11.1 bandplot
Band structure is plotted reading phonopy output in band.yaml format. -o option with a file name is used to save
the plot into a file in PDF format. A few more options are prepared and shown by -h option. If you specify more than
two yaml files, they are plotted together.
bandplot band.yaml

To obtain a simple text format data:


bandplot --gnuplot band.yaml

11.2 pdosplot
Partial density of states (PDOS) are plotted.
-i option is used as
pdosplot -i 1 2 4 5, 3 6 -o pdos.pdf partial_dos.dat

The indices and comma in 1 2 3 4, 5 6 mean as follows. The indices are separated into blocks by comma (1 2 4 5
and 3 6). PDOS specified by the successive indices separated by space in each block are summed up. The PDOS of
blocks are drawn simultaneously. Indices usually correspond to atoms. A few more options are prepared and shown
by -h option.

11.3 propplot
Thermal properties are plotted. Options are prepared and shown by -h option. If you specify more than two yaml
files, they are plotted together.
proplot thermal_properties_A.yaml thermal_properties_B.yaml

51

phonopy manual, Release 1.7.4

11.4 dispmanager
This is used for two purposes.
The first argument is the displacement file (disp.yaml type). The default file name is disp.yaml.

11.4.1 -a, --amplitude, -s, -o, --overwite


-o is used to specify the output file name of the new displacement file and --overwrite is used to overwrite the
displacement file.
-a is specified with an atom index and a direction of displacement as a character string. The first value is the atom
index and remaining three values are for direction. --amplitude is used with -a and specify the displacement
amplitude. An example is as follows:
dispmanager disp.yaml -o disp-new.yaml -a "33 1 1 0" --amplitude 0.05

disp-new.yaml is created from disp.yaml with a new displacement of the thirty-third atom (index 33) with the
direction of (1,1,0) with the amplitude of 0.05. The direction is defined against lattice vectors. The amplitude unit is
same as the lattice vectors.
-s is specified with displacement indices. For example when there are four dependent displacements and only the first
and third displacements are needed, dispmanager is used like
dispmanager disp.yaml -o disp-new.yaml -s "1 3"

11.4.2 -w
The option is used to create supercells with displacements in POSCAR format from a displacement file.
DPOSCAR-xxx files are created.

11.4.3 --compatibility
The old style displacement file DISP is compared with disp.yaml whether the directions of the displacements are
equivalent or not.

11.5 outcar-born
This script is used to create a BORN style file from VASP output file of OUTCAR. The first and second arguments are
OUTCAR type file and POSCAR type file, respectively. If both are omitted, POSCAR and OUTCAR in current directory
are read.

11.5.1 --pa, --primitive_axis


This is same as PRIMITIVE_AXIS.

52

Chapter 11. Auxiliary tools

CHAPTER

TWELVE

QUASI HARMONIC APPROXIMATION


12.1 Usage of phonopy-qha
Using phonopy results of thermal properties, thermal expansion and heat capacity at constant pressure can be calculated under the quasi-harmonic approximation. phonopy-qha is the script to calculate them. An example of the
usage is as follows:
phonopy-qha e-v.dat thermal_properties-{1..10}.yaml

1st argument is the filename of volume-energy data (in the above expample, e-v.dat). The volume and energy of
the cell (default units are in 3 and eV, respectively). An example of the volume-energy file is:
#

cell volume
156.7387309525
154.4138492700
152.2544070150
150.2790355600
148.4469296725
146.7037426750
145.1182305450
143.5676103350
142.1282086200
139.4989658225

energy of cell other than phonon


-104.5290025375
-104.6868148175
-104.8064238800
-104.8911768625
-104.9470385875
-104.9783724075
-104.9871878600
-104.9765270775
-104.9485225225
-104.8492814250

Lines starting with # are ignored. The other arguments are the filenames of thermal_properties.yaml calculated at the respective volumes given in the 1st argument. The thermal_properties.yaml at volume points have
to be calculated with the same temperature ranges and same temperature steps. thermal_properties.yaml can
be calculated by following Thermal properties related tags, where the physical unit of the Helmholtz free energy is
kJ/mol as the default, i.e., no need to convert the physical unit in usual cases.
The example for Aluminum is found in the example directory.
If the condition under puressure is expected, P V terms may be included in the energies.

12.1.1 Options
-h
Show help. The available options are shown. Without any option, the results are saved into text files in simple data
format.

53

phonopy manual, Release 1.7.4

--tmax
The maximum temperature calculated is specified. This temperature has to be lower than the maximum temperature
calculated in thermal_properties.yaml to let at least two temperature points fewer. The default value is
--tmax=1000.
-p
The fitting results, volume-temperature relation, and thermal expansion coefficient are plotted on the display.
--sparse
This is used with -s or -p to thin out the number of plots of the fitting results at temperatures. When --sparse=10,
1/10 is only plotted.
-s
The calculated values are written into files.
--pressure
This option is not yet well tested. Please report to the mailing list when you get wrong results.
Pressure is specified in GPa. This corresponds to the pV term described in the following section Theory of quasiharmonic approximation.
-b
Fitting volume-energy data to an EOS, and show bulk modulus (without considering phonons). This is made by:
phonopy-qha -b e-v.dat

12.1.2 Output files


Bulk modulus vs T (bulk_modulus-temperature.*)
Gibbs free energy vs T (gibbs-temperature.*)
Volume change with respect to the volume at 300 K vs T (volume_expansion.*)
2

Heat capacity at constant pressure vs T derived by T TG2 (Cp-temperature.*)


Heat capacity at constant puressure
(Cp-temperature_polyfit.*)

vs

by

polynomial

fittings

of

Cv

and

Helmholtz free energy vs volume (helmholtz-volume.*). When --pressure option is specified, energy
offset of pV is added. See also the following section (Theory of quasi-harmonic approximation).
Volume vs T (volume-temperature.*)
Thermal expansion coefficient vs T (thermal_expansion.*)

54

Chapter 12. Quasi harmonic approximation

phonopy manual, Release 1.7.4

12.2 Theory of quasi-harmonic approximation


Here the word quasi-harmonic approximation is used for an approximation that introduces volume dependence of
phonon frequencies as a part of anharmonic effect.
A part of temperature effect can be included into total energy of electronic structure through phonon (Helmholtz)
free energy at constant volume. But what we want to know is thermal properties at constant pressure. We need
some transformation from function of V to function of p. Gibbs free energy is defined at a constant pressure by the
transformation:
G(T, p) = min [U (V ) + Fphonon (T ; V ) + pV ] ,
V

where
min[function of V ]
V

means to find unique minimum value in the brackets by changing volume. Since volume dependencies of energies in
electronic and phonon structures are different, volume giving the minimum value of the energy function in the square
brackets shifts from the value calculated only from electronic structure even at 0 K. By increasing temperature, the
volume dependence of phonon free energy changes, then the equilibrium volume at temperatures changes. This is
considered as thermal expansion under this approximation.
phonopy-qha collects the values at volumes and transforms into the thermal properties at constant pressure.

12.2. Theory of quasi-harmonic approximation

55

phonopy manual, Release 1.7.4

56

Chapter 12. Quasi harmonic approximation

CHAPTER

THIRTEEN

CALCULATION OF MODE GRNEISEN


PARAMETERS
Experimental

13.1 Usage of gruneisen


It is necessary to run three phonon calculations. One is calculated at the equilibrium volume and the remaining two
are calculated at the slightly larger volume and smaller volume than the equilibrium volume. The unitcells at these
volumes have to be fully relaxed under the constraint of each volume.
The files named POSCAR, FORCE_SETS (or FORCE_CONSTANTS with --readfc option), and optionally BORN
are stored in three different directories named, e.g., equiv, plus, and minus.
The calculated results are written into the file gruneisen.yaml.
In the example directory, an example of silicon (Si-gruneisen) is prepared. A calculation along paths in reciprocal
space can be made by
% gruneisen orig plus minus --dim="2 2 2" --pa="0 1/2 1/2 1/2 0 1/2 1/2 1/2 0" --band="1/2 1/4 3/4 0

In this calculation, neighboring q-points in each band segment are connected considering their phonon symmetry to
treat band crossing correctly. Therefore the phonon frequencies may not be ordered in gruneisen.yaml. In the
plot (-p option), the colors of phonon bands correspond to those of mode Grneinen parameters.
A calculation on a reciprocal mesh is made by

57

phonopy manual, Release 1.7.4

% gruneisen orig plus minus --dim="2 2 2"

--pa="0 1/2 1/2 1/2 0 1/2 1/2 1/2 0" --mesh="20 20 20" -p

In the plot (-p option), the colors of mode Grneinen parameters are set for band indices with ascending order of
phonon frequencies.
Mode Grneinen parameter may diverge around -point. In the above example for band paths, mode Grneinen
parameters are calculated at -point, but gruneisen script avoids showing the values on the plot. Instead the values
at the neighboring q-points of -point are used for the plot.

13.1.1 Command options


The following command options can be used. They work similarly to those for phonopy script.
--dim
--mp, --mesh
--band
--pa, --primitive_axis
--readfc
--band_points
--nac
-p
-c
-s, --save
-o
The --color option (RB, RG, RGB) is used to gradually change the marker colors with respect to band indices. For
the mesh-sampling plot, a few more options to control matplotlib parameters are prepared.

58

Chapter 13. Calculation of mode Grneisen parameters

phonopy manual, Release 1.7.4

13.2 Method to calculate mode Grneisen parameters


Mode Grneisen parameter (q) at the wave vector q and band index is given by
V (q)
(q) V




D(q)
V


=
e(q)
e(q) ,
2[(q)]2
V

(q) =

where V is the volume, (q) is the phonon frequency, D(q) is the dynamical matrix, and e(q) is the eigenvector.
This is approximated by the finite difference method:




D(q)
V


e(q)
e(q) .
(q) '
2[(q)]2
V
The gruneisen script requires three phonon calculations at corresponding three volume points. One is for eigenvectors at the equilibrium volume (V ) and the remaining two are for D(q) with slightly larger and smaller volumes
than V .

13.2. Method to calculate mode Grneisen parameters

59

phonopy manual, Release 1.7.4

60

Chapter 13. Calculation of mode Grneisen parameters

CHAPTER

FOURTEEN

INTERFACES
14.1 VASP & phonopy calculation
Please follow the page Tutorial using VASP as calculator and Examples.

14.2 VASP-DFPT & phonopy calculation


VASP can calculate force constants in real space using DFPT. The procedure to calculate phonon properties may be as
follows:
1. Prepare unit cell structure named, e.g., POSCAR-unitcell. The following structure is a conventional unit
cell of NaCl.
Na Cl
1.00000000000000
5.6903014761756712
0.0000000000000000
0.0000000000000000
0.0000000000000000
5.6903014761756712
0.0000000000000000
0.0000000000000000
0.0000000000000000
5.6903014761756712
4
4
Direct
0.0000000000000000 0.0000000000000000 0.0000000000000000
0.0000000000000000 0.5000000000000000 0.5000000000000000
0.5000000000000000 0.0000000000000000 0.5000000000000000
0.5000000000000000 0.5000000000000000 0.0000000000000000
0.5000000000000000 0.5000000000000000 0.5000000000000000
0.5000000000000000 0.0000000000000000 0.0000000000000000
0.0000000000000000 0.5000000000000000 0.0000000000000000
0.0000000000000000 0.0000000000000000 0.5000000000000000

2. Prepare a perfect supercell structure from POSCAR-unitcell, e.g.,


% phonopy -d --dim="2 2 2" -c POSCAR-unitcell

3. Rename SPOSCAR created in (2) to POSCAR (POSCAR-{number} and disp.yaml files will never be used.)
% mv SPOSCAR POSCAR

4. Calculate force constants of the perfect supercell by running VASP with IBRION = 8 and NSW = 1. An
example of INCAR for insulator may be such like (just an example!):
PREC = Accurate
ENCUT = 500

61

phonopy manual, Release 1.7.4

IBRION
EDIFF
IALGO
ISMEAR
LREAL
ADDGRID
LWAVE
LCHARG

=
=
=
=
=
=
=
=

8
1.0e-08
38
0; SIGMA = 0.1
.FALSE.
.TRUE.
.FALSE.
.FALSE.

5. After finishing the VASP calculation, confirm vasprun.xml contains hessian elements, and then create
FORCE_CONSTANTS:
% phonopy --fc vasprun.xml

6. Run phonopy with the original unit cell POSCAR-unitcell and setting tag FORCE_CONSTANTS = READ
or --readfc option, e.g., as found in example/NaCl-VASPdfpt
% phonopy --dim="2 2 2" -c POSCAR-unitcell band.conf
_
_ __ | |__
___ _ __
___
_ __ _
_
| _ \| _ \ / _ \| _ \ / _ \ | _ \| | | |
| |_) | | | | (_) | | | | (_) || |_) | |_| |
| .__/|_| |_|\___/|_| |_|\___(_) .__/ \__, |
|_|
|_|
|___/
1.1
Band structure mode
Settings:
Force constants: read
Supercell: [2 2 2]
Primitive axis:
[ 0.
0.5 0.5]
[ 0.5 0.
0.5]
[ 0.5 0.5 0. ]
Spacegroup: Fm-3m (225)
Paths in reciprocal reduced coordinates:
[ 0.00 0.00 0.00] --> [ 0.50 0.00 0.00]
[ 0.50 0.00 0.00] --> [ 0.50 0.50 0.00]
[ 0.50 0.50 0.00] --> [-0.00 -0.00 0.00]
[ 0.00 0.00 0.00] --> [ 0.50 0.50 0.50]

62

Chapter 14. Interfaces

phonopy manual, Release 1.7.4

14.3 Wien2k & phonopy calculation


The Wien2k-phonopy calculation works as follows:
1. Read a Wien2k struct file with the P lattice format and create supercells with the Wien2k struct format of P
lattice using --wien2k option (wien2k):
% phonopy -d --dim="2 2 2" --wien2k=case.struct

In this example, 2x2x2 supercells are created. case.structS and case.structS-xxx (xxx are numbers) are the perfect supercell and the supercells with displacements, respectively. Perhaps these are renamed to
case-xxx.struct and stored in case-xxx directories, then to be calculated using Wien2k.
2. Calculate forces on atoms in the supercells with displacements. Select to use case.struct_nn file when
running init_lapw. In the Wien2k calculations, the force convergence option of -fc has to be specified
to obtain total forces. A first attempt of the force convergence criterion may be 0.1 (mRy/a.u.). It is
recommended to try more strict convergence criteria with saving one by one using save_lapw.
3. Create FORCE_SETS
Use scf2forces that is found at http://www.wien2k.at/reg_user/unsupported/.
Or try experimetal support of -f option:
% phonopy --wien2k=case.struct -f case-001.scf case-002.scf ...

where case-xxx.scf are the Wien2k results for the supercells. case-xxx.scf has to contain
FGLxxx lines with total forces. When calculating supercells, the number of non-equivalent atoms
determined by nn has to match with the number of non-equivalent atoms determined by phonopy. The
former is found to watch case-xxx.struct after nn (it is supposed that case-xxx.struct created by nn is used to calculate forces), and the later is displayed in the step 1. An example is found in
example/NaCl-wien2k.
The above procedure with -f option may fail. In this case, Wien2k calculations of case-xxx.scf
with P1 symmetry may be used for phonopy testing purpose though it computationally demands a lot. If
phonopy finds that case-xxx.scf are calculated with P1 symmetry, phonopy handles this as a special
case. An example is found in example/NaCl-wien2k-P1.
4. Run post-process of phonopy with the Wien2k unit cell struct file used in the step 1:
% phonopy --wien2k=case.struct [other-OPTIONS] [setting-file]

Phonopy can read only the P lattice format. Therefore you have to convert your struct file to that with the P lattice
format. This may be done using supercell script in the Wien2k package by making 1x1x1 supercell.

14.4 FHI-aims & phonopy calculations


The script phonopy-FHI-aims allows to conveniently employ the infrastructure provided by phonopy in order
to calculate phonons with FHI-aims. For compatibility reasons, most parameters are set via the phonon tag in
control.in as documented for the FHI-aims internal implementation in the FHI-aims manual. But several additional parameters are also handled via command line options as listed by -h.
Some examples can be found under FHI-aims in the example directory of the phonopy tarball. A subset of
them can now also be found among the FHI-aims testcases (only available from the developers repositories at the
moment). They have been slightly modified to also serve as a step-by-step guide.
For questions, please make use of the official FHI-aims forums accessible from here:
https://aimsclub.fhi-berlin.mpg.de
14.3. Wien2k & phonopy calculation

63

phonopy manual, Release 1.7.4

14.5 Using phonopy as a python module


This is under development. Configurations may alter. Requests or suggestions are very welcome.

14.5.1 Import
After setting the phonopy python path, you can import it by
from phonopy import Phonopy

The phonopy Atoms class is imported by


from phonopy.structure.atoms import Atoms as PhonopyAtoms

See the examples in the example/ase directory in the phonopy distribution package.

14.5.2 Work flow


The work flow is schematically shown in Work flow.
Pre-process
Import phonopy and create Phonopy object with
unit cell (Atoms object, see Atoms class in Phonopy)
supercell matrix (3x3 array, see Supercell matrix)
a = 5.404
bulk = PhonopyAtoms(symbols=[Si] * 8,
scaled_positions=[(0, 0, 0),
(0, 0.5, 0.5),
(0.5, 0, 0.5),
(0.5, 0.5, 0),
(0.25, 0.25, 0.25),
(0.25, 0.75, 0.75),
(0.75, 0.25, 0.75),
(0.75, 0.75, 0.25)] )
bulk.set_cell(np.diag((a, a, a)))
phonon = Phonopy(bulk, [[1,0,0],[0,1,0],[0,0,1]], distance=0.01)

Obtain supercells containing respective displacements by get_supercells_with_displacements, which are


given by a list of Atoms objects.
supercells = phonon.get_supercells_with_displacements()

The information of this class object is found at the bottoem of this page.
In general case, unit conversion factor for phonon frequency has to be set by using the factor keyword. The factor
from the VASP unit to THz is the default value of factor. Some of the physical unit conversion factors may be
found in phonopy/units.py. More about the conversion factor is written here.

64

Chapter 14. Interfaces

phonopy manual, Release 1.7.4

Force calculation
Run force calculations for the supercells. Then collect forces from the calculation results. The sets of forces has to be
given in nested list (sets_of_forces) as:
[ [ [ f_1x, f_1y, f_1z ], [ f_2x, f_2y, f_2z ], ... ], # first supercell
[ [ f_1x, f_1y, f_1z ], [ f_2x, f_2y, f_2z ], ... ], # second supercell
...
]

Post process
Prepare dynamical matrix internally (set_post_process) with
primitive matrix (3x3 matrix, see Primitive matrix)
sets of forces
phonon.set_post_process([[0,0.5,0.5],[0.5,0,0.5],[0.5,0.5,0]], sets_of_forces)

Band structure

Set band paths (set_band_structure) and get the results (get_band_structure).


A tuple of (q-points, distances, frequencies, eigenvectors) is obtained by get_band_structure(). Eigenvectors
can be obtained when is_eigenvectors=True at set_band_structure(). Eigenvalues are stored in a
numpy array with the shape of (number_of_bands, len(distances)). Phonon frequency is sqrt(eigenvalue). A negative
eigenvalue has to correspond to the imaginary frequency, but for the plotting, it is set as the negative value in the above
example. In addition, you need to multiply by your unit conversion factor. In the case of VASP to transform to THz,
the factor is 15.633302.
bands = []
q_start = np.array([0.5,0.5,0.0])
q_end
= np.array([0.0,0.0,0.0])
band = []
for i in range(51):
band.append(q_start + (q_end - q_start) / 50 * i)
bands.append(band)
q_start = np.array([0.0,0.0,0.0])
q_end
= np.array([0.5,0.0,0.0])
band = []
for i in range(51):
band.append(q_start + ( q_end - q_start ) / 50 * i)
bands.append(band)
phonon.set_band_structure(bands)
phonon.plot_band_structure().show()
q_points, distances, frequencies, eigvecs = phonon.get_band_structure()

To obtain eigenvectors, it is necessary to inform to store eigenvectors by:


phonon.set_band_structure(bands, is_eigenvectors=True)

14.5. Using phonopy as a python module

65

phonopy manual, Release 1.7.4

Mesh sampling

Set sampling mesh (set_mesh) in reciprocal space. The irreducible q-points and corresponding q-point weights,
eigenvalues, and eigenvectors are obtained by get_mesh. mesh gives the sampling mesh with Monkhorst-Pack
scheme. The keyword shift gives the fractional mesh shift with respect to the neighboring grid points.
mesh = [20, 20, 20]
phonon.set_mesh(mesh)
qpoints, weights, frequencies, eigvecs = phonon.get_mesh()

To obtain eigenvectors, it is necessary to inform to store eigenvectors by:


phonon.set_mesh([20, 20, 20], is_eigenvectors=True)

DOS and PDOS

Before starting mesh sampling has to be finished. Then set parameters (set_total_DOS or set_partial_DOS)
and write the results into files (write_total_DOS and write_partial_DOS). In the case of PDOS, the eigenvectors have to be calculated in the mesh sampling. get_total_DOS and get_partial_DOS are under preparation.
phonon.set_total_DOS()
phonon.plot_total_DOS().show()

Thermal properties

Before starting the thermal property calculation, the mesh sampling calclation has to be done in the THz unit. The unit
conversion factor for phonon frequency is set in the pre-process of Phonopy with the factor keyword. Calculation
range of temperature is set by the parameters set_thermal_properties. Helmholtz free energy, entropy, heat
capacity at contant volume at temperaturs are obtained by get_thermal_properties, where the results are
given as a tuple of temperaturs, Helmholtz free energy, entropy, and heat capacity.
phonon.set_thermal_properties(t_step=10,
t_max=1000,
t_min=0)
for t, free_energy, entropy, cv in np.array(phonon.get_thermal_properties()).T:
print ("%12.3f " + "%15.7f" * 3) % ( t, free_energy, entropy, cv )
phonon.plot_thermal_properties().show()

Non-analytical term correction

To apply non-analytical term correction, Born effective charge tensors for all atoms in primitive cell, dielectric constant tensor, and the unit conversion factor have to be correctly set. The tensors are given in Cartesian coordinates.
The following example is that can be used for NaCl.
born = [[[1.08703, 0, 0],
[0, 1.08703, 0],
[0, 0, 1.08703]],
[[-1.08672, 0, 0],
[0, -1.08672, 0],
[0, 0, -1.08672]]]
epsilon = [[2.43533967, 0, 0],

66

Chapter 14. Interfaces

phonopy manual, Release 1.7.4

[0, 2.43533967, 0],


[0, 0, 2.43533967]]
factors = 14.400
phonon.set_post_process([[0, 0.5, 0.5], [0.5, 0, 0.5], [0.5, 0.5, 0]],
sets_of_forces,
is_nac=True)
phonon.set_nac_params({born: born,
factor: factors,
dielectric: epsilon})

14.5.3 Eigenvectors
Eigenvectors are given as the column vectors.
Internally phonopy uses numpy.linalg.eigh and eigh is
a wrapper of LAPACK. So eigenvectors follow the convention of LAPACK, which can be shown at
http://docs.scipy.org/doc/numpy/reference/generated/numpy.linalg.eigh.html
Eigenvectors corresponding to phonopy yaml output are obtained as follows.
Band structure
if eigvecs is not None:
for eigvecs_on_path in eigvecs:
for eigvecs_at_q in eigvecs_on_path:
for vec in eigvecs_at_q.T:
print vec

Mesh sampling
if eigvecs is not None:
for eigvecs_at_q in eigvecs:
for vec in eigvecs_at_q.T:
print vec

14.5.4 Atoms class in Phonopy


Variables
The following variables are implemented in the Atoms class of Phonopy in atoms.py.
lattice_vectors

Lattice vectors are given in the matrix form in Cartesian coordinates.


[ [ a_x, a_y, a_z ],
[ b_x, b_y, b_z ],
[ c_x, c_y, c_z ] ]

14.5. Using phonopy as a python module

67

phonopy manual, Release 1.7.4

scaled_positions

Atomic positions in fractional coordinates.


[ [ x1_a, x1_b, x1_c ],
[ x2_a, x2_b, x2_c ],
[ x3_a, x3_b, x3_c ],
...
]

positions

Cartesian positions of atoms.


positions = np.dot( scaled_positions, lattice_vectors )

where np means the numpy module (import numpy as np).


symbols

Chemical symbols, e.g.,


[ Zn, Zn, O, O ]

for the ZnO unit cell.


numbers

Atomic numbers, e.g.,


[ 30, 30, 8, 8 ]

for the ZnO unit cell.


masses

Atomic masses, e.g.,


[ 65.38, 65.38, 15.9994, 15.9994 ]

for the ZnO unit cell.


Methods
set_cell( lattice_vectors )
get_cell()
set_positions( positions )
get_positions()
set_scaled_positions( scaled_positions )
get_scaled_positions()
set_masses( masses )
get_masses()
set_chemical_symbols( symbols )
get_chemical_symbols()

68

Chapter 14. Interfaces

phonopy manual, Release 1.7.4

get_number_of_atoms()
get_atomic_numbers()
get_volume()

These methods are compatible to the ASEs Atoms class. The arguments have to be set in the structures shown in
Variables.
The usable keywords in the initialization are:
symbols=None,
positions=None,
numbers=None,
masses=None,
scaled_positions=None,
cell=None

14.5.5 Definitions of variables


Primitive matrix
Primitive matrix Mp is a tranformation matrix from lattice vectors to those of a primitive cell if there exists the
primitive cell in the lattice vectors. Following a crystallography convention, the transformation is given by
(ap bp cp ) = (au bu cu )Mp
where au , bu , and cu are the column vectors of the original lattice vectors, and ap , bp , and cp are the column vectors of
the primitive lattice vectors. Be careful that the lattice vectors of the Atoms class are the row vectors (lattice_vectors).
Therefore the phonopy code, which relies on the Atoms class, is usually written such as
primitive_lattice = np.dot( original_lattice.T, primitive_matrix ).T,

or equivalently,
primitive_lattice = np.dot( primitive_matrix.T, original_lattice )

Supercell matrix
Supercell matrix Ms is a tranformation matrix from lattice vectors to those of a super cell. Following a crystallography
convention, the transformation is given by
(as bs cs ) = (au bu cu )Ms
where au , bu , and cu are the column vectors of the original lattice vectors, and as , bs , and cs are the column vectors of
the supercell lattice vectors. Be careful that the lattice vectors of the Atoms class are the row vectors (lattice_vectors).
Therefore the phonopy code, which relies on the Atoms class, is usually written such as
supercell_lattice = np.dot( original_lattice.T, supercell_matrix ).T,

or equivalently,
supercell_lattice = np.dot( supercell_matrix.T, original_lattice )

Symmetry search tolerance


Symmetry search tolerance (often the name symprec is used in phonopy) is used to determine symmetry operations
of the crystal structures. The physical unit follows that of input crystal structure.
14.5. Using phonopy as a python module

69

phonopy manual, Release 1.7.4

70

Chapter 14. Interfaces

CHAPTER

FIFTEEN

FORMULATIONS
15.1 Second-order force constants
Potential energy of phonon system is represented as functions of atomic positions:
V [r(j1 l1 ), . . . , r(jn lN )],
where r(jl) is the point of the j-th atom in the l-th unit cell and n and N are the number of atoms in a unit cell and
the number of unit cells, respectively. A force and a second-order force constant are given by
F (jl) =

V
r (jl)

and
(jl, j 0 l0 ) =

2V
F (j 0 l0 )
=
,
0
0
r (jl)r (j l )
r (jl)

respectively, where , , ..., are the Cartesian indices, j, j 0 , ..., are the indices of atoms in a unit cell, and l, l0 , ..., are
the indices of unit cells. In the finite displacement method, the equation for the force constants is approximated as
(jl, j 0 l0 ) '

F (j 0 l0 ; r (jl)) F (j 0 l0 )
,
r (jl)

where F (j 0 l0 ; r (jl)) are the forces on atoms with a finite displacement r (jl) and usually F (j 0 l0 ) 0.

15.2 Modified Parlinski-Li-Kawazoe method


The following is a modified and simplified version of the Parlinski-Li-Kawazoe method.
The last equation above is represented by matrices as
F = UP,
where F, P, and U for a pair of atoms, e.g. {jl, j 0 l0 }, are given by
F = Fx

Fy


Fz ,

xx
P = yx
zx

xy
yy
zy

xz
yz ,
zz

71

phonopy manual, Release 1.7.4

U = rx

ry


rz .

The matrix equation is expanded for number of forces and displacements as follows:


U1
F1
U2
F2
= P.
..
..
.
.
With sufficient number of atomic displacements, this may be solved by pseudo inverse such as
+
U1
F1
U2 F2
P = .
..
..
.
.
Required number of atomic displacements to solve the simultaneous equations may be reduced using site-point symmetries. The matrix equation can be written using a symmetry operation as

R(F)
= R(U)P,
is the site symmetry operation centring at r(jl). R(F)

where R
and R(U)
are defined as RF(R1 (j 0 l0 )) and RU,
respectively, where R is the matrix representation of the rotation operation. The combined simultaneous equations are
built such as
(1)
(1)
U1
F1
.
F(2)
..
1

.
(2)
.
U1
.
(1) = (1) P.
U2
F2
(2)
(2)
U
F
2
2
..
..
.
.
where the superscript with parenthesis gives the index of site-symmetry operations. This is solved by pseudo inverse.

15.3 Dynamical matrix


In phonopy, a phase convention of dynamical matrix is used as follows:
X
1
D (jj 0 , q) =
(j0, j 0 l0 ) exp(iq [r(j 0 l0 ) r(j0)]),
mj mj 0 0
l

where m is the atomic mass and q is the wave vector. An equation of motion is written as
X
D (jj 0 , q)e (j 0 , q) = mj [(q)]2 e (j, q).
j0

where the eigenvector of the band index at q is obtained by the diagonalization of D(q):
X
e (j 0 , q) D (jj 0 , q)e (j 0 , q 0 ) = [(q)]2 0 .
jj 0

The atomic displacements u are given as



 12 X

h

1 
u (jl, t) =
[(q)] 2 a
(q) exp(i(q)t) + a
(q) exp(i(q)t) exp(iq r(jl))e (j, q),
2N mj
q,
where a
and a
are the creation and annihilation operators of phonon, h is the reduced Planck constant, and t is the
time.
72

Chapter 15. Formulations

phonopy manual, Release 1.7.4

15.4 Non-analytical term correction


To correct long range interaction of macroscopic electric field induced by polarization of collective ionic motions
near the -point, non-analytical term is added to dynamical matrix (Non-analytical term correction). At q 0, the
dynamical matrix with non-analytical term is given by,
P
P

[ q Zj,
][ 0 q 0 Zj0 , 0 ]
4
0
N
0
P
.
D (jj , q 0) = D (jj , q 0) +

mj mj 0
q  q
Phonon frequencies at general q-points are interpolated by the method of Wang et al. (Interpolation scheme at general
q-points with non-analytical term correction).

15.5 Thermodynamic properties


15.5.1 Phonon number

n=

1
exp(h(q)/kB T ) 1

15.5.2 Harmonic phonon energy

E=

X
q

1
1
+
h(q)

2 exp(
h(q)/kB T ) 1

15.5.3 Constant volume heat capacity



E
T V
X  h(q) 2
exp(
h(q)/kB T )
=
kB
kB T
[exp(
h(q)/kB T ) 1]2
q


CV =

15.5.4 Partition function

Z = exp(/kB T )

Y exp(h(q)/2kB T )
1 exp(h(q)/kB T )
q

15.5.5 Helmholtz free energy


F = kB T ln Z
X 

1X
h(q) + kB T

ln 1 exp(h(q)/kB T )
=+
2 q
q
15.4. Non-analytical term correction

73

phonopy manual, Release 1.7.4

15.5.6 Entropy
F
T
X
1 X
=
h(q) coth(

h(q)/2kB T ) kB
ln [2 sinh(h(q)/2kB T )]
2T q
q

S=

15.6 Thermal displacement


15.6.1 Mean square displacement
From Eq. (10.71) in the book Thermodynamics of Crystal, atomic displacement, u, is written by
u (jl, t) =

h
2N mj

 21 X

12

[ (q)]



a
(q) exp(i (q)t) + a
(q) exp(i (q)t) exp(iq r(jl))e
(j, q)

q,

where j and l are the labels for the j-th atomic position in the l-th unit cell, t is the time, is an axis (a Cartesian axis
in the default behavior of phonopy), m is the atomic mass, N is the number of the unit cells, q is the wave vector, is
the index of phonon mode. e is the polarization vector of the atom jl and the band at q. r(jl) is the atomic position
and is the phonon frequency. a
and a
are the creation and annihilation operators of phonon. The expectation value
of the squared atomic displacement is calculated as,


|u (jl, t)|2 =

X
h
2
(q)1 (1 + 2n (q))|e
(j, q)| ,
2N mj q,

where n is the phonon population, which is give by,


n (q) =

1
,
exp(h (q)/kB T ) 1

where T is the temperature, and kB is the Boltzmann constant. The equation is calculated using the commutation
relation of the creation and annihilation operators and the expectation values of the combination of the operations,
e.g.,
[
a (q), a
0 (q0 )] = (q q0 ) 0 ,
[
a (q), a
0 (q0 )] = 0,
[
a (q), a
0 (q0 )] = 0,
h|
a (q)
a 0 (q0 )|i = 0,
h|
a (q)
a 0 (q0 )|i = 0.

15.6.2 Mean square displacement matrix


Mean square displacement matrix is defined as follows:
B(j, t) =

X
h
(q)1 (1 + 2n (q))e (j, q) e (j, q).
2N mj q,

This is a symmetry matrix and diagonal elements are same as mean square displacement calculated along Cartesian x,
y, z directions.

74

Chapter 15. Formulations

phonopy manual, Release 1.7.4

15.6.3 Projection to an arbitrary axis from the Cartesian axes


In phonopy, eigenvectors are calculated in the Cartesian axes that are defined in the input structure file. Mean square
displacement along an arbitrary axis is obtained projecting eigenvectors in the Cartesian axes as follows:


|u(jl, t)|2 =

X
h
(q)1 (1 + 2n (q))|
n e (j, q)|2
2N mj q,

is an arbitrary unit direction.


where n

15.7 Group velocity


15.7.1 Method
Phonopy calculates group velocity of phonon as follows:
vg (q) =q (q)
(q)
q
[(q)]2
1
=
2(q)
q




D(q)
1
e(q) ,
=
e(q)
2(q)
q
=

where the meanings of the variables are found at Formulations.

15.7.2 Finite difference method


In the previous versions, group velocity was calculated using finite difference method:








D(q)
D(q)
1
1

e(q) '
e(q) .
vg (q) =
e(q)
e(q)
q
2(q)
q
2(q)
Group velocity calculation with the finite difference method is still able to be activated using GV_DELTA_Q tag or
-gv_delta_q option. q = (qx , qy , qz ) is described in Cartesian coordinated in reciprocal space. In the
implementation, central difference is employed, and +q and q are taken to calculate group velocity, where
is the Cartesian index in reciprocal space. q is specified in the unit of reciprocal space distance (1 for the default
case) by --gv_delta_q option or GV_DELTA_Q tag.

15.7. Group velocity

75

phonopy manual, Release 1.7.4

76

Chapter 15. Formulations

CHAPTER

SIXTEEN

HOW TO CITE PHONOPY


16.1 Citation of phonopy
If you have used phonopy, please cite the following article:
First-principles calculations of the ferroelastic transition between rutile-type and CaCl2-type SiO2 at high
pressures, Atsushi Togo, Fumiyasu Oba, and Isao Tanaka, Phys. Rev. B, 78, 134106 (2008)

@article {phonopy,
Journal = {Phys. rev. B},
Year = {2008},
Title = {First-principles calculations of the ferroelastic transition between rutile-type and Ca
Author = {Togo, A and Oba, F and Tanaka, I},
Pages = {134106},
Volume = {78},
Issue = {13},
Month = {Oct}
}

16.1.1 A short history of phonopy


Phonopy development started to replace and extend fropho (http://fropho.sourceforge.net/). The implementation of
fropho is also based on Parlinski-Li-Kawazoe method. Although fropho was implemented from scratch except for the
symmetry finder and input file parser, to start the development, it was motivated by the existence of PHON code. The
important part of the implementation is the symmetry handling. In fropho, at first the symmetry finder in Abinit code
was employed, but later the symmetry finder was replaced by spglib (http://spglib.sourceforge.net/).

77

phonopy manual, Release 1.7.4

78

Chapter 16. How to cite phonopy

CHAPTER

SEVENTEEN

REFERENCES
17.1 Method used in phonopy
17.1.1 Parlinski-Li-Kawazoe method
K. Parlinski, Z. Q. Li, and Y. Kawazoe, Phys. Rev. Lett. 78, 4063 (1997)
Parlinski-Li-Kawazoe method is based on the supercell approach with the finite displacement method. The calculation
and symmetrization of force constants are executed by using singular-value decomposition (pseudo-inverse). The key
of this method would be the matrix formulations of equations, which leads to the coherent and flexible implementation.

17.1.2 Non-analytical term correction


R. M. Pick, M. H. Cohen, and R. M. Martin, Phys. Rev. B 1, 910, (1970)
P. Giannozzi, S. Degironcoli, P. Pavone, and S. Baroni, Phys. Rev. B 43, 7231 (1991)
X. Gonze, and C. Lee, Phys. Rev. B 55, 10355 (1997)

17.1.3 Interpolation scheme at general q-points with non-analytical term correction


Y Wang , J J Wang , W Y Wang , Z G Mei , S L Shang , L Q Chen and Z K Liu, J. Phys.: Condens. Matter. 22,
202201 (2010)
Interpolation scheme at getenral q-points with non-analytical term correction is implemented according to Wang et al
(--nac option).

17.2 Other methods for calculating force constants


17.2.1 Small displacement method
Dario Alf, Computer Physics Communications, 180, 2622 (2009)
PHON is based on the small displacement method.

79

phonopy manual, Release 1.7.4

17.2.2 DFPT
Xavier Gonze and Changyol Lee, Phys. Rev. B 55, 10355 (1997)
The most famous implementation is Abinit. Currently there are many implementations of DFPT. VASP can calculate
force constants using DFPT however only at Gamma-point.

17.3 For the study of basics


Introduction to Lattice Dynamics, Martin. T. Dove, Cambridge university press
Thermodynamics of Crystals, Duane C. Wallace, Dover Publications

80

Chapter 17. References

CHAPTER

EIGHTEEN

CHANGE LOG
18.1 Oct-3-2013: Version 1.7.4
Thermal displacement matrix is implemented. See TDISPMAT, TMAX, TMIN, TSTEP and Mean square displacement.
PDOS with projection along arbitrary direction was implemented. See PROJECTION_DIRECTION.
partial_dos.dat format was changed. XYZ projected PDOS is not output. Instead atom projected PDOS
(sum of XYZ projected PDOS) is written. See Output files.
DOS and PDOS python interface was modified.
freq_something.

The keyword of omega_something is changed to

gruneisen didnt run because it didnt follow the move of the file_IO.py file location. This is fixed.
The formula of non-analytical term correction implemented in phonopy is not translational invariant in reciprocal
space. This induces tiny difference of the choice of equivalent q-points being different by reciprocal primitive
vectors. Now in the mesh sampling mode (MP), q-points are automatically moved to inside first-Brillouin-zone.
In the mesh sampling mode, consistency of symmetry of mesh numbers to crystal symmetry is checked. If
the symmetry disagrees with crystal symmetry, mesh symmetrization (equivalent to MESH_SYMMETRY =
.FALSE.) is disabled.
Wien2k interface is updated to adapt Wien2k-13.
Fix the problem that only Vinet EOS worked in phonopy-qha.

18.2 Sep-17-2013: Version 1.7.3


Fix. Segmentation fault happens in some specific systems (e.g. Kubuntu 12.04 32bit) due to a different behavior
of numpy array creation.
Group velocity for degenerate phonon mode is calculated slightly different from older version and now it is
symmetrized by site-symmetry of q-point.

18.3 Aug-4-2013: Version 1.7.2


group_velocity/__init__.py is moved to phonon directory.
hphonopy/file_IO.py is moved to top directory.

81

phonopy manual, Release 1.7.4

New harmonic/derivative_dynmat.py: Analytical derivatives of dynamical matrix


Group velocity is computed by analytical derivatives of dynamical matrix in the default configuration instead
of previous finite difference method. Group velocity calculation with the finite difference method can be still
activated by --gv_delta_q option.
Force constants solver was partially rewritten. The order and shape of matrices in the formula is rearranged
(Modified Parlinski-Li-Kawazoe method).

18.4 July-14-2013: Version 1.7.1


--pdos option was created. This is same as PDOS tag.
Group velocity with degenerate modes was improved.

18.5 Jun-21-2013: Version 1.7


The tag CHARACTER_TABLE was renamed to IRREPS (IRREPS), and the option of --ct was renamed to --irreps as well. To show Ir-representations along with characters, SHOW_IRREPS tag (or
--show_irreps option) is used. The output file name was also renamed to irreps.yaml. In the ir-reps
calculation, display and file outputs were modified to show the arguments of complex value characters.
Numpy array types of double and intc for those arrays passed to numpy C-API are used.
thermal_displacement.py is slightly modified for the preparation to include thermal displacement matrix.
Symmetry finder update (spglib 1.4.2).

18.6 Apr-13-2013: Version 1.6.4


Group velocity can be calculated using GROUP_VELOCITY tag or --gv option (Group velocity).
Non-analytical term correction is implemented in C, which accelerates the calculation speed.

18.7 Feb-7-2013: Version 1.6.3


Arbitral projection direction is allowed for thermal displacements calculation. (TDISP, TMAX, TMIN, TSTEP)
A new tag WRITEDM and an option writedm are implemented. Dynamical matrices are written into
qpoints.yaml when this is used togather with the QPOINTS mode. (WRITEDM)

18.8 Nov-13-2012: Version 1.6.2


A small fix of FHIaims.py.

82

Chapter 18. Change Log

phonopy manual, Release 1.7.4

18.9 Nov-4-2012: Version 1.6.1


Implementation of database of character table for another type of point group -3m.
A new option --irreps or IRREPS tag (Experimental).
character_table.yaml output.
Eigenvectors output inmodulation.yaml was recovered.

18.10 Oct-22-2012: Version 1.6


Experimental support of band connection. (BAND_CONNECTION)
Experimental support of mode Grneisen parameter calculation. (Calculation of mode Grneisen parameters)
Format of MODULATION tag was modified. (Create modulated structure)
Phonopy is controlled by command line options more than before. --qpoints, --modulation and
--anime options are prepared.
Symmetry finder update.
Implementation of database of character table for the point group 32. Fix -3m database.

18.11 June-29-2012: Version 1.5


Bug fix on plotting PDOS with labels.
The array structures of qpoints, distances, frequencies, eigenvalues, eigenvectors in BandStructure are changed
to the lists of those values of segments of band paths. For qpoints, frequencies, eigenvalues, eigenvectors, the
previous array structures are recovered by numpy.vstack and for distances, numpy.hstack.
Experimental support on thermal displacement.
Experimental support on fitting DOS to a Debye model (DEBYE_MODEL) implemented by Jrg Meyer.

18.12 May-22-2012: Version 1.4.2


Bug fix on showing the values of thermal properties. No bug in plot and yaml.

18.13 May-21-2012: Version 1.4.1


Avoid list comprehension with else statement, because it is not supported in old python versions.

18.14 May-13-2012: Version 1.4


--writefc option is implemented.
In using MODULATION tag, phase factor for each mode can be specified as the third value of each mode in
degrees.
18.9. Nov-4-2012: Version 1.6.1

83

phonopy manual, Release 1.7.4

Arguments of get_modulation in Phonopy module were modified. The phase factor is now included in
phonon_modes.
Class Phonopy was refactored. All private variables were renamed as those starting with an underscore. Some
basic variables are obtained with the same variable names without the underscode, which was implemented by
the function property.
The labels of segments of band structure plot are specified by BAND_LABELS (BAND_LABELS).
--band option is implemented.
GAMMA_CENTER tag and --gc, --gamma_center option are implemented (MP).
phonopy-qha was polished. Most of the code was moved to phonopy/qha/__init__.py.
Phonopy::get_mesh and Phonopy::get_band_structure were modified. Instead of eigenvalues,
frequencies are returned.
The order of return values of Phonopy::get_thermal_properties was changed as numpy arrays of
temperatures, Helmhotlz free energies, entropies, and heat capacities at constant volume.
Arguments of the class ThermalProperties, Dos, and PartialDOS were changed. Instead of eigenvalues, frequencies are used.
The default sigma value used for total and partial DOS was changed to (max_frequency - min_frequency) / 100.
Symmetry finder update.

18.15 Mar-20-2012: Version 1.3


C implementations of a few parts of force_constants.py to speed up.
spglib update.
Many small modifications.
License is changed to the new BSD from the LGPL.

18.16 Oct-13-2011: Version 1.2.1


Bug fix of the option --dim with 9 elements.

18.17 Oct-12-2011: Version 1.2


Closing support of the --nac_old option.
The option --nomeshsym is available on the manual.
Symmetry finder update that includes the bug fix of Wyckoff letter assignment.
Showing site-symmetry symbols with respective orientations in the output of --symmetry option.
Code cleanings of settings.py, force_constant.py, etc.
Starting implementation of character_table.py (IRREPS).

84

Chapter 18. Change Log

phonopy manual, Release 1.7.4

18.18 Sep-19-2011: Version 1.1


--readfc option is implemented.
A bit of clean-up of the code dynamical_matrix.py, force_constant.py and _phonopy.c to
make implementations similar to the formulations often written in text books.

18.19 Sep-5-2011: Version 1.0


settings.py is moved to phonopy/cui/Phonopy. The configure parser from a file and options is modified.
Usage of MODULATION tag was changed.
The option --nosym is available on the manual.

18.20 Aug-8-2011: Version 0.9.6


Symmetry finder update
Wyckoff positions are shown with --symmetry option

18.21 Jun-7-2011: Version 0.9.5.1


Bug fix of get_surrounding_frame in cells.py by Jrg Meyer and Christian Carbogno.

18.22 Errata of document


The cell matrix definition of Atoms class was transposed.

18.23 Jun-3-2011: Version 0.9.5


Wien2k interface is updated (Wien2k & phonopy calculation), but this is still quite experimental support.
More information is involved in disp.yaml. Along this modification, supercells with displacements can be
created solely from disp.yaml using dispmanager.
Instead of TRANSLATION tag, FC_SYMMETRY is created (FC_SYMMETRY).
Closing support of --fco option.
Add a few more examples in the example directory.
Symmetry finder update
propplot is updated for the --gnuplot option.

18.18. Sep-19-2011: Version 1.1

85

phonopy manual, Release 1.7.4

18.24 Errata of document


The example of FORCE_SETS was wrong and was fixed. The explanation of the document is correct.

18.25 Apr-18-2011: Version 0.9.4.2


In the setting tag BAND, now comma , can be used to disconnect the sequence of band paths (Band structure
related tags).
dispmanager, an auxiliary tool for modifying disp.yaml, is developed (dispmanager).
Symmetry finder update to spglib-1.0.3.1. Almost perfect casting to a Bravais lattice is achieved using
--symmetry option.
The setting tags TRANSLATION, PERMUTATION, and MP_REDUCE are ceased.

18.26 Feb-26-2011: Version 0.9.4.1


Wien2k interface bug fix

18.27 Feb-20-2011: Version 0.9.4


Big phonopy-interface change was imposed. Some of filenames and formats of input and output files are modified. There is no default setting filename like INPHON (setting file is passed as the first argument). Some of
tag names and those usage are also modified. Please first check Examples for the new usage.
List of changes:
Setting file has to be passed to phonopy as the first argunment.
FORCES is replaced by FORCE_SETS (Force file (FORCE_SETS)).
DISP is replaced by disp.yaml.
LSUPER tag is removed. Please use -d option.
NDIM and MATDIM tags are replaced by DIM tag (DIM).
Band structure setting tags are changed to BAND tag (Band structure related tags).
DOS tag is renamed to DOS_RANGE tag (DOS related tags).
These changes are applied only for the phonopy interface. Internal simulation code has not been touched, so
physical results would not be affected. If you have any questions, please send e-mail to phonopy mailinglist.
phonopy-FHI-aims had not worked in some of previous versions. Now it works by Jrg Meyer and Christian
Carbogno.
Directory structure of the code was changed.
Symmetry finder update to spglib-1.0.2
[Experimental] Finding Bravais lattice using --symmetry option.
[Experimental] Modulated structure along specified phonon modes by MODULATION tag (Create modulated
structure).

86

Chapter 18. Change Log

phonopy manual, Release 1.7.4

18.28 Jan-21-2011: Version 0.9.3.3


Animation file output update (Create animation file). The ANIME tag format was changed.

18.29 Jan-12-2011: Version 0.9.3.2


phonopy-qha is updated. A few options are added (Options). Calculation under pressure is supported by
--pressure option.
Primitive cell search and Bravais lattice output are integrated into the symmetry search with --symmetry
option.

18.30 Errata of document


There were mistakes in the documents for the PRIMITIVE_AXIS and MATDIM. The 9 values are read from
the first three to the last three as respective rows of the matrices defined.

18.31 Dec-30-2010: Version 0.9.3.1


Bug fix of -f option.
The output filenames of phonopy-qha are modified and summarized at Output files.

18.32 Dec-5-2010: Version 0.9.3


The license is changed to LGPL.
MASS tag is recreated (MASS).
--mp option is created. This works like the MP tag.
Improvement of phonopy-qha both in the code and manual.
The bug in --fco option was fixed.

18.33 Nov-26-2010: Version 0.9.2


spglib update (ver. 1.0.0)
ASE.py is removed. Compatible class and functions, Atoms, write_vasp, and read_vasp, are implemented.
A vasprun.xml parser wrapper is implemened to avoid the broken PRECFOCK in vasprun.xml of VASP
5.2.8.

18.28. Jan-21-2011: Version 0.9.3.3

87

phonopy manual, Release 1.7.4

18.34 Sep-22-2010: Version 0.9.1.4


The new tag ANIME_TYPE supports xyz and xyz_jmol formats by Jrg Meyer and Christian Carbogno, and
also A set of POSCAR files corresponding to animation frames.
Fix bugs in trim_cell and Primitive.__supercell_to_primitive_map in cells.py. When
Ms1 Mp is not symmetric, the supercell was not created correctly.
phonopy-FHI-aims update by jm.

18.35 Aug-24-2010: Version 0.9.1.3


Update symmetry finder of spglib. Now precision is in Cartesian distance.
The animation output for arc didnt work. Now it works.
Qpoint mode didnt work with bugs. Now it works.
--vasp option is renamed to --cell or -c.
The new options --symmetry, --displacement or -d, --dim, --primitive_axis are implemented.
The option --ndim is replaced with --dim with -d option.

18.36 June-10-2010: Version 0.9.1.2


The code on non-analytical term correction is included in the DynamicalMatrix class. Data sets read by
parse_BORN are set by set_non_analytical_term and gotten by get_non_analytical_term.
The q-vector direction (only direction is used in the non-analytical term correction) is set by
set_q_non_analytical_term. However for emprical damping function, some distance is used, i.e.,
when a q-point is getting away, non-analytical term is weaken. For this purpose, the second argument of
set_q_non_analytical_term is used.
At the same time, a small problem on the previous implementation was found. When a reduced q-point is out
of the first Brillouin zone, it is not correctly handled. Currently it is fixed so as that when absolute values of
elements of the reduced q-point are over 0.5, they are reduced into -0.5 < q < 0.5.
[Attention] The previous --nac option is moved to --nac_old. --nac is used for different method of the
non-analytical term correction at general q-points. This will be documented soon.
Bug fix on write_FORCES in file_IO.py. When order of displacements in DISP file is not ascending
order of atom indices, it was not correctly re-ordered. Because the default order of phonopy is ascending order,
usually there is no problem for the most users.
phonopy-FHI-aims
adapted to extensions of dynamical_matrix with respect to non-analytical corrections
added support for animation infrastructure
moved several options to control.in
by Jrg Meyer and Christian Carbogno

88

Chapter 18. Change Log

phonopy manual, Release 1.7.4

18.37 May-11-2010: Version 0.9.1.1


phonopy-FHI-aims adapted to split of dos array into the two seperate omega, dos arrays in TotalDOS class
by Jrg Meyer.

18.38 May-10-2010: Version 0.9.1


The methods of get_partial_DOS and get_total_DOS are added to the Phonopy class.

18.39 Apr-12-2010: Version 0.9.0.2


spglib bug was fixed. If the crystal structure has non-standard origin, the translation was not correctly handled.
This problem happened after version 0.9.0.

18.40 Apr-12-2010: Version 0.9.0.1


spglib update

18.41 Apr-10-2010: Version 0.9.0


Phonopy module (__init.py__) is heavily revised and the script phonopy is rewritten using the phonopy
module. Therefore there may be bugs. Be careful. Document of the phonopy module will be updated gradually.
A small Wien2k interface document is added (Wien2k & phonopy calculation).
A script phonopy-FHI-aims and its examples are added by Jrg Meyer.
spglib update

18.42 Mar-10-2010: Version 0.7.4


spglib update
Animation mode (Create animation file)

18.43 Feb-10-2010: Version 0.7.3


Bug fix for Wien2k mode

18.44 Jan-12-2010: Version 0.7.2


[Experimental] Non-analytical term correction was implemented.

18.37. May-11-2010: Version 0.9.1.1

89

phonopy manual, Release 1.7.4

18.45 Dec-8-2009: Version 0.7.1 released


Auxiliary tools propplot is added.
Memory consumption is reduced when using -f option to handle large vasprun.xml files.

18.46 Nov-24-2009: Version 0.7.0 released


Auxiliary tools bandplot and pdosplot are prepared.
Formats of band.yaml, mesh.yaml, and qpoints.yaml are slightly modified.
There was bug in PERMUTATION tag to calculate symmetrized force constants. Now it is fixed. Usually this is
not necessary to set because this does not affect to result.
Symmetry finder spglib is updated.
PM tag is implemented. See Setting tags. Behaviors in the previous versions are PM = AUTO.

18.47 Oct-14-2009: Version 0.6.2 released


Installation process was changed slightly. See Download and install.
The command phonopy is stored in the bin directory. phonopy.py is renamed to phonopy.
setup system is improved by Maxim V. Losev.
--fz tag was implemented experimentally. This is supposed to enable to subtract residual forces on atoms in
equilibrium structure from those in structure with atomic displacements.

90

Chapter 18. Change Log

Potrebbero piacerti anche