# Set up configuration
central_region = BulkConfiguration(
bravais_lattice=central_region_lattice,
elements=central_region_elements,
cartesian_coordinates=central_region_coordinates
)
device_configuration = DeviceConfiguration(
central_region,
[left_electrode, right_electrode]
)
# -------------------------------------------------------------
# Calculator
# -------------------------------------------------------------
#----------------------------------------
# Basis Set
#----------------------------------------
basis_set = [
LDABasis.Gold_SingleZetaPolarized,
LDABasis.Carbon_DoubleZetaPolarized,
]
#----------------------------------------
# Numerical Accuracy Settings
#----------------------------------------
left_electrode_numerical_accuracy_parameters = NumericalAccuracyParameters(
k_point_sampling=(10, 10, 100),
)
right_electrode_numerical_accuracy_parameters = NumericalAccuracyParameters(
k_point_sampling=(10, 10, 100),
)
device_numerical_accuracy_parameters = NumericalAccuracyParameters(
k_point_sampling=(10, 10, 100),
)
#----------------------------------------
# Poisson Solver Settings
#----------------------------------------
device_poisson_solver = MultigridSolver(
boundary_conditions=[[PeriodicBoundaryCondition,PeriodicBoundaryCondition],
[PeriodicBoundaryCondition,PeriodicBoundaryCondition],
[DirichletBoundaryCondition,DirichletBoundaryCondition]]
)
#----------------------------------------
# Electrode Calculators
#----------------------------------------
left_electrode_calculator = LCAOCalculator(
basis_set=basis_set,
numerical_accuracy_parameters=left_electrode_numerical_accuracy_parameters,
)
right_electrode_calculator = LCAOCalculator(
basis_set=basis_set,
numerical_accuracy_parameters=right_electrode_numerical_accuracy_parameters,
)
#----------------------------------------
# Device Calculator
#----------------------------------------
voltagelist=[0.2*i for i in range(26)]
for myvolt in voltagelist:
calculator = DeviceLCAOCalculator(
basis_set=basis_set,
numerical_accuracy_parameters=device_numerical_accuracy_parameters,
electrode_calculators=
[left_electrode_calculator, right_electrode_calculator],
electrode_voltages=( 0.0*Volt, myvolt*Volt)
)
device_configuration.setCalculator(calculator)
nlprint(device_configuration)
device_configuration.update()
if(myvolt<0.3):
nlsave('/home/hassan/C80/C80mr61.nc', device_configuration)
# -------------------------------------------------------------
# Transmission spectrum
# -------------------------------------------------------------
transmission_spectrum = TransmissionSpectrum(
configuration=device_configuration,
energies=numpy.linspace(-5,5,100)*eV,
kpoints=MonkhorstPackGrid(1,1),
energy_zero_parameter=AverageFermiLevel,
infinitesimal=1e-06*eV,
self_energy_calculator=KrylovSelfEnergy(),
)
nlsave('/home/hassan/C80/C80mr61.nc', transmission_spectrum)
nlprint(transmission_spectrum)
what is wrom with the above script for it does not generate the specified number of transmission curves