Sure, the script is below. The script was identical for the (110) surface, except, of course, for the different unit cell, and the k-points (which were 8 6 8 in that case)
# Set up lattice
vector_a = [3.84001408591, 0.0, 0.0]*Angstrom
vector_b = [0.0, 3.84001408591, 0.0]*Angstrom
vector_c = [0.0, 0.0, 5.4306]*Angstrom
lattice = UnitCell(vector_a, vector_b, vector_c)
# Define elements
elements = [Silicon, Silicon, Silicon, Silicon]
# Define coordinates
fractional_coordinates = [[ 5.00000000e-01, -3.33066907e-16, 2.50000000e-01],
[ 5.00000000e-01, 5.00000000e-01, 5.00000000e-01],
[ -1.11022302e-16, 5.00000000e-01, 7.50000000e-01],
[ 2.22044605e-16, -2.46519033e-32, 1.00000000e+00]]
# Set up configuration
bulk_configuration = BulkConfiguration(
bravais_lattice=lattice,
elements=elements,
fractional_coordinates=fractional_coordinates
)
#----------------------------------------
# Exchange-Correlation
#----------------------------------------
exchange_correlation = MGGA.TB09LDA
# -------------------------------------------------------------
# Calculator
# -------------------------------------------------------------
numerical_accuracy_parameters = NumericalAccuracyParameters(
k_point_sampling=(8, 8, 6),
)
calculator = LCAOCalculator(
numerical_accuracy_parameters=numerical_accuracy_parameters,
)
bulk_configuration.setCalculator(calculator)
nlprint(bulk_configuration)
bulk_configuration.update()
nlsave('analysis.nc', bulk_configuration)
# -------------------------------------------------------------
# Density of states
# -------------------------------------------------------------
density_of_states = DensityOfStates(
configuration=bulk_configuration,
kpoints=MonkhorstPackGrid(8,8,6),
energy_zero_parameter=AbsoluteEnergy,
bands_above_fermi_level=None,
)
nlsave('analysis.nc', density_of_states)
nlprint(density_of_states)
# -------------------------------------------------------------
# Transmission spectrum
# -------------------------------------------------------------
transmission_spectrum = TransmissionSpectrum(
configuration=bulk_configuration,
energies=numpy.linspace(-5,5,501)*eV,
kpoints=MonkhorstPackGrid(8,8),
energy_zero_parameter=AbsoluteEnergy,
infinitesimal=1e-06*eV,
self_energy_calculator=RecursionSelfEnergy(),
)
nlsave('analysis.nc', transmission_spectrum)
nlprint(transmission_spectrum)
# -------------------------------------------------------------
# Chemical potential
# -------------------------------------------------------------
chemical_potential = ChemicalPotential(bulk_configuration)
nlsave('analysis.nc', chemical_potential)
nlprint(chemical_potential)
# -------------------------------------------------------------
# Bandstructure
# -------------------------------------------------------------
bandstructure = Bandstructure(
configuration=bulk_configuration,
route=None,
points_per_segment=20,
bands_above_fermi_level=All
)
nlsave('analysis.nc', bandstructure)