surfinpy.bulk_mu_vs_mu¶
- surfinpy.bulk_mu_vs_mu.calculate(data, bulk, deltaX, deltaY, x_energy, y_energy)[source]¶
Initialise the free energy calculation.
- Parameters
data (
list
) – List ofsurfinpy.data.DataSet
object for each phasebulk (
surfinpy.data.ReferenceDataSet
) – Reference datasetdeltaX (
dict
) – Range of chemical potential/label for species XDeltaY (
dict
) – Range of chemical potential/label for species Yx_energy (
float
) – DFT energy of adsorbing speciesy_energy (
float
) – DFT energy of adsorbing species
- Returns
system – Plotting object
- Return type
- surfinpy.bulk_mu_vs_mu.calculate_bulk_energy(deltamux, deltamuy, x_energy, y_energy, phase, normalised_bulk)[source]¶
Calculates the free energy of a given phase (DFT calculation) as a function of chemical potential of x and y.
- Parameters
deltamux (
array_like
) – Chemical potential of species xdeltamuy (
array_like
) – Chemical potential of species yx_energy (
float
) – DFT energy or temperature corrected DFT energyy_energy (
float
) – DFT energy or temperature corrected DFT energyphase (
surfinpy.data.DataSet
) – DFT calculationnormalised_bulk (
float
) – Bulk energy normalised to the bulk value.
- Returns
2D array of free energies as a function of chemical potential of x and y
- Return type
array_like
- surfinpy.bulk_mu_vs_mu.evaluate_phases(data, bulk, x, y, nphases, x_energy, y_energy)[source]¶
Calculates the free energies of each phase as a function of chemical potential of x and y. Then uses this data to evaluate which phase is most stable at that x/y chemical potential cross section.
- Parameters
data (
list
) – List ofsurfinpy.data.DataSet
objectsbulk (
surfinpy.data.ReferenceDataSet
object) – Reference datasetx (
dict
) – X axis chemical potential valuesy (
dict
) – Y axis chemical potential valuesnphases (
int
) – Number of phasesx_energy (
float
) – DFT 0 K energy for species xy_energy (
float
) – DFT 0 K energy for species y
- Returns
phase_data – array of ints, with each int corresponding to a phase.
- Return type
array_like
- surfinpy.bulk_mu_vs_mu.normalise_phase_energy(phase, bulk)[source]¶
Converts normalises each phase to be consistent with the bulk. DFT calculations may have differing numbers of formula units compared to the bulk and this must be accounted for. Furthermore, the vibrational entropy and zero point energy are accounted for (if required).
- Parameters
phase (
surfinpy.data.DataSet
) – surfinpy dataset object.bulk (
surfinpy.data.DataSet
) – surfinpy ReferenceDataSet object.
- Returns
Normalised phase energy
- Return type
float