pymatgen.analysis.defects.thermodynamics module¶
-
class
DefectPhaseDiagram(entries, vbm, band_gap, filter_compatible=True)[source]¶ Bases:
monty.json.MSONableThis is similar to a PhaseDiagram object in pymatgen, but has ability to do quick analysis of defect formation energies when fed DefectEntry objects
uses many of the capabilities from PyCDT’s DefectsAnalyzer class…
- This class is able to get:
- stability of charge states for a given defect,
- list of all formation ens
c) transition levels in the gap d)
Parameters: dentries ([DefectEntry]) – A list of DefectEntry objects -
all_stable_entries¶ List all stable entries (defect+charge) in the DefectPhaseDiagram
-
all_unstable_entries¶ List all unstable entries (defect+charge) in the DefectPhaseDiagram
-
defect_concentrations(chemical_potentials, temperature=300, fermi_level=0.0)[source]¶ Give list of all concentrations at specified efermi in the DefectPhaseDiagram :param chemical_potentials = {Element: number} is dictionary of chemical potentials to provide formation energies for :param temperature = temperature to produce concentrations from: :param fermi_level: (float) is fermi level relative to valence band maximum
Default efermi = 0 = VBM energyReturns: list of dictionaries of defect concentrations
-
defect_types¶ List types of defects existing in the DefectPhaseDiagram
-
find_stable_charges()[source]¶ Sets the stable charges and transition states for a series of defect entries. This function uses scipy’s HalfspaceInterection to oncstruct the polygons corresponding to defect stability as a function of the Fermi-level. The Halfspace Intersection constructs N-dimensional hyperplanes, in this case N=2, based on the equation of defect formation energy with considering chemical potentials:
E_form = E_0^{Corrected} + Q_{defect}*(E_{VBM} + E_{Fermi})Extra hyperplanes are constructed to bound this space so that the algorithm can actually find enclosed region.
This code was modeled after the Halfspace Intersection code for the Pourbaix Diagram
-
solve_for_fermi_energy(temperature, chemical_potentials, bulk_dos)[source]¶ Solve for the Fermi energy self-consistently as a function of T and p_O2 Observations are Defect concentrations, electron and hole conc :param bulk_dos: bulk system dos (pymatgen Dos object) :param gap: Can be used to specify experimental gap.
Will be useful if the self consistent Fermi level is > DFT gapReturns: Fermi energy