MateriApps
物質科学シミュレーションのポータルサイト

現在アプリ掲載数307件

お問合せ / アプリ掲載依頼
    • JP
    • EN
  • MateriApps について
  • レビュー募集
もっと詳しく探す
  • NEWS / 講習会・イベント
  • アプリ一覧
  • アプリ詳細検索
  • キーワード解説
  • レビュー
  • 事例
  • アプリコンシェルジュ
  • インストールしないでアプリを
    試せる「MateriApps LIVE!」

    詳細はこちら
  • MateriApps について
  • レビュー募集
  • プライバシーポリシー
  • お問合せ / アプリ掲載依頼
  • アプリ一覧
  • VASP

VASP

  • 公開度:0 ☆☆☆
  • ドキュメント充実度:3 ★★★

PAW型擬ポテンシャル法を用いた第一原理計算パッケージ。広範な物理系に対して、密度汎関数理論に基づく電子状態計算を高速で行うことができる。有償であるが、世界的に多くのユーザーを有し、利用方法について詳しい情報が容易に入手できる。構造最適化・応答関数・化学反応など充実した機能を有する。

Drawing cd-Si band structure using VASP and pymatgen
Last Update:2021/12/09
あなたはすでに投票済みです!

By MateriApps Development Team

Band structure calculations using VASP involve the following steps:

  1. Obtain a self-consistent electron density using a uniform k-point mesh.
  2. Calculate eigenvalues along high symmetry k-point paths using the electron density obtained above.
  3. Plot the band structure.

This should work with little modification if you are on some Linux server where you can run vasp. The following example works on the Sekirei supercomputer system at the Institute for Solid State Physics, the University of Tokyo.

Obtain a self-consistent density

4 files are necessary for a VASP calculation:

  1. POSCAR – structure information
  2. KPOINTS – K-points for Brillouin zone sampling
  3. INCAR – input parameters related to accuracy, convergence control, etc.
  4. POTCAR – pseudopotential file; you can access this file once you purchase a VASP license

For cubic-diamond Si, example POSCAR file for the primitive unit cell:

Si2
1.0
0.000000 2.750000 2.750000
2.750000 0.000000 2.750000
2.750000 2.750000 0.000000
Si
2
direct
0.750000 0.750000 0.750000 Si
0.500000 0.500000 0.500000 Si

KPOINTS file for a 4 by 4 by 4 mesh centered on the Gamma point:

4x4x4
0
G
4 4 4
0 0 0

Example minimal INCAR file (the defaults set in VASP are usually rather sensible ones):

ISMEAR = 0
SIGMA = 0.01
GGA = PE

We now have input files prepared:

$ ls
INCAR  KPOINTS  POSCAR  POTCAR

If you’re on the ISSP supercomputer, let’s use the interactive queue.

$ qsub -queue i18cpu -node 1 -I

Wait a few seconds until you get a prompt, then run vasp (the above can be skipped if you’re on an individually-running work station).

 $ mpijob -np 4 PATH_TO_VASP

You should see lines of VASP output and the run should finish within a few seconds.

Calculate eigenvalues along high-symmetry paths in the Brillouin zone

To obtain a k-points path for plotting the band structure, we can use pymatgen, which you will need to install yourself.  On ISSP supercomputer system B, this can be done as follows. First set up the python environment provided by the MateriApps team:

$ source /home/issp/materiapps/tool/env.sh

The above should be added to your startup file, e.g., ~/.bashrc. Now, let’s install pymatgen.

$ pip3 install pymatgen --user

Next, prepare a python file make_line_kpoints.py as follows:

from pymatgen.io.vasp.inputs import Kpoints
from pymatgen.core import Structure
from pymatgen.symmetry.bandstructure import HighSymmKpath

struct = Structure.from_file("POSCAR")
kpath = HighSymmKpath(struct)
kpts = Kpoints.automatic_linemode(divisions=40,ibz=kpath)
kpts.write_file("KPOINTS_nsc")
$ python3 make_line_kpoints.py

This results in a file KPOINTS_nsc with k-point line path information based on the AFLOWLIB standard.
Add an option to perform a nonself-consistent calculation to the INCAR file, copy KPOINTS_nsc to KPOINTS, and run vasp.

$ cp KPOINTS_nsc KPOINTS
$ cat INCAR
ISMEAR =  0
SIGMA  =  0.01
GGA    = PE
ICHARG = 11 #Non-SCF
$ mpijob -np 4 PATH_TO_VASP

This should finish within several seconds.

Plot the band structure using pymatgen

(Note: an alternative is to use the GUI program p4vasp, which should be relatively easy if you can get it installed)
To plot the band, prepare a python script “plotband.py” as follows:

from pymatgen.io.vasp.outputs import Vasprun
from pymatgen.electronic_structure.plotter import BSPlotter

vaspout = Vasprun("./vasprun.xml")
bandstr = vaspout.get_band_structure(line_mode=True)
plt = BSPlotter(bandstr).get_plot(ylim=[-12,10])
plt.savefig("band.pdf")

Run this script

$ python3 plotband.py

This results in band.pdf with the following content:

Related reading

  • pymatgen
  • Examples at vaspwiki
  • arXiv:1004.2974 [cond-mat.mtrl-sci] – AFLOWLIB paper presenting standardization of k-paths for band structure plots.

04 / 06

  • 01基本情報
  • 02事例・論文
  • 03講習会
  • 04レビュー
  • 05開発者の声
  • 06このアプリ情報に
    ついてのお問い合わせ
TOP

MateriApps
物質科学シミュレーションのポータルサイト

  • NEWS / 講習会・イベント
  • アプリ一覧
  • アプリ詳細検索
  • キーワード解説
  • 事例
  • アプリコンシェルジュ
  • プライバシーポリシー
お問合せ / アプリ掲載依頼
  • 東京大学 物性研究所 The Institute for Solid State Physics
  • 東京大学 The University of Tokyo
  • CDMSI
  • CCMS

© MateriApps, 2013-2023. All rights reserved.