QuantumATK W-2024.09 version released on Sep 9, 2024
0 Members and 1 Guest are viewing this topic.
device_configuration.update()
# -------------------------------------------------------------# Two-probe Configuration# -------------------------------------------------------------# -------------------------------------------------------------# Left Electrode# -------------------------------------------------------------# Set up latticevector_a = [5.0, 0.0, 0.0]*Angstromvector_b = [0.0, 5.0, 0.0]*Angstromvector_c = [0.0, 0.0, 9.0]*Angstromleft_electrode_lattice = UnitCell(vector_a, vector_b, vector_c)# Define elementsleft_electrode_elements = [Lithium, Lithium, Lithium]# Define coordinatesleft_electrode_coordinates = [[ 2.5, 2.5, 1.5], [ 2.5, 2.5, 4.5], [ 2.5, 2.5, 7.5]]*Angstrom# Set up configurationleft_electrode = BulkConfiguration( bravais_lattice=left_electrode_lattice, elements=left_electrode_elements, cartesian_coordinates=left_electrode_coordinates )# -------------------------------------------------------------# Right Electrode# -------------------------------------------------------------# Set up latticevector_a = [5.0, 0.0, 0.0]*Angstromvector_b = [0.0, 5.0, 0.0]*Angstromvector_c = [0.0, 0.0, 9.0]*Angstromright_electrode_lattice = UnitCell(vector_a, vector_b, vector_c)# Define elementsright_electrode_elements = [Lithium, Lithium, Lithium]# Define coordinatesright_electrode_coordinates = [[ 2.5, 2.5, 1.5], [ 2.5, 2.5, 4.5], [ 2.5, 2.5, 7.5]]*Angstrom# Set up configurationright_electrode = BulkConfiguration( bravais_lattice=right_electrode_lattice, elements=right_electrode_elements, cartesian_coordinates=right_electrode_coordinates )# -------------------------------------------------------------# Central Region# -------------------------------------------------------------# Set up latticevector_a = [5.0, 0.0, 0.0]*Angstromvector_b = [0.0, 5.0, 0.0]*Angstromvector_c = [0.0, 0.0, 22.0]*Angstromcentral_region_lattice = UnitCell(vector_a, vector_b, vector_c)# Define elementscentral_region_elements = [Lithium, Lithium, Lithium, Hydrogen, Hydrogen, Lithium, Lithium, Lithium]# Define coordinatescentral_region_coordinates = [[ 2.5, 2.5, 1.5], [ 2.5, 2.5, 4.5], [ 2.5, 2.5, 7.5], [ 2.5, 2.5, 10.5], [ 2.5, 2.5, 11.5], [ 2.5, 2.5, 14.5], [ 2.5, 2.5, 17.5], [ 2.5, 2.5, 20.5]]*Angstrom# Set up configurationcentral_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# -------------------------------------------------------------#----------------------------------------# Numerical Accuracy Settings#----------------------------------------left_electrode_k_point_sampling = MonkhorstPackGrid( na=1, nb=1, nc=100, )left_electrode_numerical_accuracy_parameters = NumericalAccuracyParameters( k_point_sampling=left_electrode_k_point_sampling, )right_electrode_k_point_sampling = MonkhorstPackGrid( na=1, nb=1, nc=100, )right_electrode_numerical_accuracy_parameters = NumericalAccuracyParameters( k_point_sampling=right_electrode_k_point_sampling, )#----------------------------------------# Poisson Solver Settings#----------------------------------------left_electrode_poisson_solver = FastFourier2DSolver( boundary_conditions=[[PeriodicBoundaryCondition(),PeriodicBoundaryCondition()], [PeriodicBoundaryCondition(),PeriodicBoundaryCondition()], [PeriodicBoundaryCondition(),PeriodicBoundaryCondition()]] )right_electrode_poisson_solver = FastFourier2DSolver( boundary_conditions=[[PeriodicBoundaryCondition(),PeriodicBoundaryCondition()], [PeriodicBoundaryCondition(),PeriodicBoundaryCondition()], [PeriodicBoundaryCondition(),PeriodicBoundaryCondition()]] )#----------------------------------------# Electrode Calculators#----------------------------------------left_electrode_calculator = HuckelCalculator( numerical_accuracy_parameters=left_electrode_numerical_accuracy_parameters, poisson_solver=left_electrode_poisson_solver, )right_electrode_calculator = HuckelCalculator( numerical_accuracy_parameters=right_electrode_numerical_accuracy_parameters, poisson_solver=right_electrode_poisson_solver, )#----------------------------------------# Device Calculator#----------------------------------------calculator = DeviceHuckelCalculator( electrode_calculators= [left_electrode_calculator, right_electrode_calculator], )device_configuration.setCalculator(calculator)nlprint(device_configuration)device_configuration.update()nlsave('ivcurve.nc', device_configuration)# -------------------------------------------------------------# IV Curve# -------------------------------------------------------------biases = [0.000000, 0.200000, 0.400000, 0.600000, 0.800000, 1.000000, 1.200000, 1.400000, 1.600000, 1.800000, 2.000000]*Voltiv_curve = IVCurve( configuration=device_configuration, biases=biases, energies=numpy.linspace(-2,2,101)*eV, kpoints=MonkhorstPackGrid(1,1), self_energy_calculator=RecursionSelfEnergy(), energy_zero_parameter=AverageFermiLevel, infinitesimal=1e-06*eV, selfconsistent_configurations_filename_prefix="ivcurve_selfconsistent_configuration_", log_filename_prefix="ivcurve_" )nlsave('ivcurve.nc', iv_curve)nlprint(iv_curve)