Electronic Structure¶
Startup¶
-
twod_materials.electronic_structure.startup.
run_hse_calculation
(dim=2, submit=True, force_overwrite=False, destroy_prep_directory=False)[source]¶ Setup/submit an HSE06 calculation to get an accurate band structure. Requires a previous IBZKPT from a standard DFT run. See http://cms.mpi.univie.ac.at/wiki/index.php/Si_bandstructure for more details.
Parameters: - dim (int) – 2 for relaxing a 2D material, 3 for a 3D material.
- submit (bool) – Whether or not to submit the job.
- force_overwrite (bool) – Whether or not to overwrite files if an already converged vasprun.xml exists in the directory.
- destroy_prep_directory (bool) – whether or not to remove (rm -r) the hse_prep directory, if it exists. This can help you to automatically clean up and save space.
-
twod_materials.electronic_structure.startup.
run_hse_prep_calculation
(dim=2, submit=True)[source]¶ Submits a quick static calculation to calculate the IBZKPT file using a smaller number of k-points (200/atom instead of 1000/atom). The other outputs from this calculation are essentially useless.
Parameters:
Analysis¶
-
twod_materials.electronic_structure.analysis.
find_dirac_nodes
()[source]¶ Look for band crossings near (within tol eV) the Fermi level.
Returns: - boolean. Whether or not a band crossing occurs at or near
- the fermi level.
-
twod_materials.electronic_structure.analysis.
get_band_edges
()[source]¶ Calculate the band edge locations relative to the vacuum level for a semiconductor. If spin-polarized, returns all 4 band edges.
-
twod_materials.electronic_structure.analysis.
get_effective_mass
()[source]¶ This function is in a beta stage, and its results are not guaranteed to be useful.
Finds effective masses from a band structure, using parabolic fitting to determine the band curvature at the CBM for electrons and at the VBM for holes. This curvature enters the equation m* = (hbar)**2 / (d^2E/dk^2).
To consider anisotropy, the k-space directions to the left and right of the CBM/VBM in the band diagram are returned separately.
- NOTE Only works for semiconductors and linemode calculations (non-
- spin polarized). >30 k-points per string recommended to obtain reliable curvatures.
- NOTE The parabolic fit can be quite sensitive to the number of
- k-points fit to, so it might be worthwhile adjusting N_KPTS to obtain some sense of the error bar.
- TODO: Warn user if CBM/VBM is at the edge of the diagram, and which
- direction (either left or right) was not actually fit to. Until fixed, this (most likely) explains any negative masses returned.
Returns: - Dictionary of the form
- {‘electron’: {‘left’: e_m_eff_l, ‘right’: e_m_eff_r},
- ‘hole’: {‘left’: h_m_eff_l, ‘right’: h_m_eff_r}}
where ‘left’ and ‘right’ indicate the reciprocal directions to the left and right of the extremum in the band structure.
-
twod_materials.electronic_structure.analysis.
plot_band_alignments
(directories, run_type=u'PBE', fmt=u'pdf')[source]¶ Plot CBM’s and VBM’s of all compounds together, relative to the band edges of H2O.
Parameters:
-
twod_materials.electronic_structure.analysis.
plot_band_structure
(ylim=(-5, 5), draw_fermi=False, fmt=u'pdf')[source]¶ Plot a standard band structure with no projections.
Parameters:
-
twod_materials.electronic_structure.analysis.
plot_color_projected_bands
(ylim=(-5, 5), fmt=u'pdf')[source]¶ Plot a single band structure where the color of the band indicates the elemental character of the eigenvalue.
Parameters:
-
twod_materials.electronic_structure.analysis.
plot_density_of_states
(fmt=u'pdf')[source]¶ Plots the density of states from the DOSCAR in the cwd. Plots spin up in red, down in green, and the sum in black. Efermi = 0.
Parameters: fmt (str) – matplotlib format style. Check the matplotlib docs for options.
-
twod_materials.electronic_structure.analysis.
plot_elt_projected_bands
(ylim=(-5, 5), fmt=u'pdf')[source]¶ Plot separate band structures for each element where the size of the markers indicates the elemental character of the eigenvalue.
Parameters:
-
twod_materials.electronic_structure.analysis.
plot_local_potential
(axis=2, ylim=(-20, 0), fmt=u'pdf')[source]¶ Plot data from the LOCPOT file along any of the 3 primary axes. Useful for determining surface dipole moments and electric potentials on the interior of the material.
Parameters:
-
twod_materials.electronic_structure.analysis.
plot_orb_projected_bands
(orbitals, fmt=u'pdf', ylim=(-5, 5))[source]¶ Plot a separate band structure for each orbital of each element in orbitals.
Parameters:
-
twod_materials.electronic_structure.analysis.
plot_spin_texture
(inner_index, outer_index, center=(0, 0), fmt=u'pdf')[source]¶ Create six plots- one for the spin texture in x, y, and z in each of two bands: an inner band and an outer band. For Rashba spin-splitting, these two bands should be the two that have split.
Parameters: - outer_index (inner_index,) – indices of the two spin-split bands.
- center (tuple) – coordinates of the center of the splitting (where the bands cross). Defaults to Gamma.
- fmt – matplotlib format style. Check the matplotlib docs for options.