Skip to content

Calculate the Spin-Resolved Band Structure

1. Introduction

Calculate the spin-resolved electronic band structure of a material in Quantum ESPRESSO from a starting magnetization per species. Density Functional Theory with Hubbard U (DFT+U) and a relaxation first are optional.

2. Open the notebook

In JupyterLite, the notebook is made/workflows/band_structure_magn.ipynb, entry 4.2.3 "Band Structure (Magnetic)" 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
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 = "FeO"

# 4. Workflow parameters
APPLICATION_NAME = "espresso"
ADD_RELAXATION = False
USE_DFT_U = False

WORKFLOW_SEARCH_TERM = "band_structure_magn.json"
MY_WORKFLOW_NAME = "Band Structure (spin magnetism)" + (" + DFT+U" if USE_DFT_U else "")

# Model parameters
MODEL_SUBTYPE = "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

USE_DFT_U = True adds the Hubbard U values of HUBBARD_U in cell 1.3.

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

Cell 1.3 holds the method and magnetic 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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# 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. [2, 2, 2]
SCF_KGRID = None  # e.g. [2, 2, 2]
KPATH = None
# [
#     {"point": "Γ", "steps": 10},
#     {"point": "L", "steps": 10},
#     {"point": "Y", "steps": 10},
#     {"point": "Z", "steps": 10},
#     {"point": "Γ", "steps": 10},
# ]

# Collinear magnetization by atomic species (with labels), e.g. antiferromagnetic Fe2O3
STARTING_MAGNETIZATION = {"Fe1": -1, "Fe2": 1}
IS_TOTAL_MAGNETIZATION = False
TOTAL_MAGNETIZATION = 0

# DFT+U Hubbard U values by atomic species (with labels); set USE_DFT_U = False to disable
HUBBARD_U = {"Fe1": 5.3, "Fe2": 5.3}

# Patch &CONTROL and &ELECTRONS (recommended for magnetic insulators)
ADDITIONAL_PARAMETERS = {
    # "control": {
    #     "tstress": False,
    #     "tprnfor": False,
    # },
    # "electrons": {
    #     "mixing_mode": "plain",
    #     "mixing_beta": 0.2,
    #     "mixing_ndim": 10,
    #     "conv_thr": "1.0d-8",
    #     "diagonalization": "cg",
    #     "electron_maxstep": 200,
    #     "diago_david_ndim": 4,
    #     "diago_full_acc": True,
    #     "startingwfc": "atomic+random",
    # }
}

# Energy cutoffs
ECUTWFC = 40
ECUTRHO = 200

STARTING_MAGNETIZATION sets the starting magnetization per species. A species is an element followed by its atom label, such as Fe1 and Fe2 for two magnetic sublattices, so an antiferromagnetic structure needs its atoms labeled in Materials Designer before the run; each key has to be a species of the loaded material. HUBBARD_U holds the U values per species, used with USE_DFT_U = True. ADDITIONAL_PARAMETERS patches the &CONTROL and &ELECTRONS namelists; its commented values are recommended for magnetic insulators.

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 spin-resolved band structure.

5. Interactive JupyterLite notebook

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

Spin-Magnetic Band Structure Calculation in Quantum ESPRESSO and DFT+U and Hubbard Parameter Calculation in Quantum ESPRESSO set the magnetization and the Hubbard U from the web interface.