Skip to content

Calculate the Band Structure and Density of States

1. Introduction

Calculate the electronic band structure of a material and, optionally, its density of states (DOS) in Quantum ESPRESSO, with or without a relaxation first.

2. Open the notebook

In JupyterLite, the notebook is made/workflows/band_structure.ipynb, entry 4.2.1 "Band Structure / Band Structure + DOS" of made/workflows/Introduction.ipynb.

3. Set the parameters

Cell 1.2 holds the material, workflow and compute parameters:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
from datetime import datetime
from mat3ra.ide.compute import QueueName

# 2. Auth and organization parameters
ORGANIZATION_NAME = None

# 3. Material parameters
FOLDER = "../uploads"
MATERIAL_NAME = "Graphene"

# 4. Workflow parameters
# Options: "band_structure" / "band_structure_dos"
CALCULATION_TYPE = "band_structure"

APPLICATION_NAME = "espresso"
ADD_RELAXATION = False

WORKFLOW_SEARCH_TERM = f"{CALCULATION_TYPE}.json"
MY_WORKFLOW_NAME = CALCULATION_TYPE.replace("_", " ").title() + (" (relax)" if ADD_RELAXATION else "")

# Model parameters
MODEL_SUBTYPE = "gga"  # "gga" or "lda"

# 5. Compute parameters
CLUSTER_NAME = None  # specify full or partial name i.e. "cluster-001" to select
QUEUE_NAME = QueueName.D
PPN = 1

# 6. Job parameters
timestamp = datetime.now().strftime("%Y-%m-%d %H:%M")
POLL_INTERVAL = 30  # seconds

CALCULATION_TYPE selects the Standata workflow <CALCULATION_TYPE>.json: "band_structure", or "band_structure_dos", which adds the DOS.

The overview explains the account, material, workflow, compute and job parameters.

Cell 1.3 holds the method parameters:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
# Method parameters
PSEUDOPOTENTIAL_TYPE = "us"  # "us" (ultrasoft), "nc" (norm-conserving), "paw"
FUNCTIONAL = "pbe"           # for gga: "pbe", "pbesol"; for lda: "pz"

# K-grids and k-path
RELAXATION_KGRID = None  # e.g. [4, 4, 4]
SCF_KGRID = None         # e.g. [8, 8, 8]
NSCF_KGRID = None        # e.g. [12, 12, 12] — used for band_structure_dos
KPATH = None             # [{"point": "Γ", "steps": 10}, {"point": "M", "steps": 10}, {"point": "K", "steps": 10}, {"point": "Γ", "steps": 10}]

# Energy cutoffs
ECUTWFC = 40
ECUTRHO = 200

# Additional QE input parameters per unit
# Format: {"unit_name": {"namelist": {"parameter": value}}}
ADDITIONAL_PARAMETERS = {
    # "pw_nscf": {"system": {"occupations": "tetrahedra_opt"}},
}

NSCF_KGRID applies to the non-self-consistent step of "band_structure_dos". ADDITIONAL_PARAMETERS is keyed by unit, then by namelist. The overview explains the model, k-point and cutoff and engine input parameters.

4. Run and read the result

Run the notebook with Run > Run All and log in when it asks, as in Authentication in JupyterLite.

After the job finishes, section 8 plots the band structure and, with "band_structure_dos", the DOS.

5. Interactive JupyterLite notebook

The interactive JupyterLite notebook for calculating the band structure can be accessed below.

Electronic Band Structure Calculation and Calculate Electronic Density of States calculate the same properties from the web interface.