This is my scripter:
from ATK.TwoProbe import *
from ATK.MPI import processIsMaster
# Generate time stamp
if processIsMaster():
import platform, time
print '#',time.ctime()
print '#',platform.node(),platform.platform()+'\n'
# Scattering elements and coordinates
scattering_elements = [Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Carbon, Carbon, Carbon, Carbon,
Carbon, Carbon, Carbon, Carbon,
Hydrogen, Hydrogen, Hydrogen, Hydrogen,
Hydrogen, Hydrogen, Hydrogen, Hydrogen,
Iron, Carbon, Carbon, Carbon,
Carbon, Carbon, Carbon, Carbon,
Carbon, Hydrogen, Hydrogen, Hydrogen,
Hydrogen, Hydrogen, Hydrogen, Hydrogen,
Hydrogen, Iron, Carbon, Carbon,
Carbon, Carbon, Carbon, Carbon,
Carbon, Carbon, Hydrogen, Hydrogen,
Hydrogen, Hydrogen, Hydrogen, Hydrogen,
Hydrogen, Hydrogen, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold, Gold, Gold,
Gold, Gold]
scattering_coordinates = [[ 0. , 0. , 4.07800007],
[ 0. , 2.8835814 , 4.07800007],
[ 0. , 5.7671628 , 4.07800007],
[ 0. , 8.65074444, 4.07800007],
[ 2.8835814 , 0. , 4.07800007],
[ 2.8835814 , 2.8835814 , 4.07800007],
[ 2.8835814 , 5.7671628 , 4.07800007],
[ 2.8835814 , 8.65074444, 4.07800007],
[ 5.7671628 , 0. , 4.07800007],
[ 5.7671628 , 2.8835814 , 4.07800007],
[ 5.7671628 , 5.7671628 , 4.07800007],
[ 5.7671628 , 8.65074444, 4.07800007],
[ 8.65074444, 0. , 4.07800007],
[ 8.65074444, 2.8835814 , 4.07800007],
[ 8.65074444, 5.7671628 , 4.07800007],
[ 8.65074444, 8.65074444, 4.07800007],
[ 1.4417907 , 1.4417907 , 6.1170001 ],
[ 1.4417907 , 4.32537222, 6.1170001 ],
[ 1.4417907 , 7.20895386, 6.1170001 ],
[ 1.4417907 , 10.09253502, 6.1170001 ],
[ 4.32537222, 1.4417907 , 6.1170001 ],
[ 4.32537222, 4.32537222, 6.1170001 ],
[ 4.32537222, 7.20895386, 6.1170001 ],
[ 4.32537222, 10.09253502, 6.1170001 ],
[ 7.20895386, 1.4417907 , 6.1170001 ],
[ 7.20895386, 4.32537222, 6.1170001 ],
[ 7.20895386, 7.20895386, 6.1170001 ],
[ 7.20895386, 10.09253502, 6.1170001 ],
[ 10.09253502, 1.4417907 , 6.1170001 ],
[ 10.09253502, 4.32537222, 6.1170001 ],
[ 10.09253502, 7.20895386, 6.1170001 ],
[ 10.09253502, 10.09253502, 6.1170001 ],
[ 3.02664982, 5.03114932, 11.19394743],
[ 3.64980839, 3.62328051, 11.19235987],
[ 5.08596092, 3.06840383, 11.19343848],
[ 6.49382888, 3.69155847, 11.19655144],
[ 7.04870211, 5.1277089 , 11.1998752 ],
[ 6.42554365, 6.53557764, 11.20146275],
[ 4.98939115, 7.09045445, 11.20038415],
[ 3.58152317, 6.46729969, 11.19727121],
[ 1.89673768, 5.00402291, 11.19228215],
[ 2.87002312, 2.80513106, 11.18980259],
[ 5.11309019, 1.93849217, 11.19148725],
[ 7.31198059, 2.91177164, 11.19634923],
[ 8.17861425, 5.15483531, 11.20154048],
[ 7.20532905, 7.35372721, 11.20402003],
[ 4.96226188, 8.22036587, 11.2023354 ],
[ 2.76337134, 7.24708663, 11.1974734 ],
[ 5.03538535, 5.07661079, 12.79707573],
[ 3.02206932, 5.02551366, 14.39372049],
[ 3.64522778, 3.61764489, 14.39213286],
[ 5.08138034, 3.06276821, 14.39321146],
[ 6.48924826, 3.68592285, 14.39632449],
[ 7.04412161, 5.12207324, 14.39964829],
[ 6.42096316, 6.52994202, 14.40123592],
[ 4.98481057, 7.08481871, 14.40015731],
[ 3.57694267, 6.46166407, 14.39704428],
[ 1.89215718, 4.99838725, 14.39205513],
[ 2.86544262, 2.79949556, 14.38957558],
[ 5.10850961, 1.93285667, 14.39126024],
[ 7.30740009, 2.9061359 , 14.39612231],
[ 8.17403375, 5.14919965, 14.40131364],
[ 7.20074831, 7.34809147, 14.40379319],
[ 4.9576813 , 8.21473037, 14.40210853],
[ 2.75879084, 7.24145089, 14.39724646],
[ 5.03080556, 5.07097611, 15.99629293],
[ 3.01748859, 5.019878 , 17.5934938 ],
[ 3.64064716, 3.61200927, 17.59190593],
[ 5.07679976, 3.05713259, 17.59298454],
[ 6.48466765, 3.68028723, 17.59609733],
[ 7.03954099, 5.11643758, 17.59942136],
[ 6.41638254, 6.52430628, 17.60100875],
[ 4.98022999, 7.07918297, 17.59993015],
[ 3.57236205, 6.45602845, 17.59681735],
[ 1.88757645, 4.9927516 , 17.59182821],
[ 2.86086188, 2.79385983, 17.58934865],
[ 5.10392903, 1.92722093, 17.59103332],
[ 7.3028196 , 2.90050017, 17.59589515],
[ 8.16945325, 5.14356399, 17.60108648],
[ 7.19616781, 7.34245573, 17.60356603],
[ 4.95310072, 8.20909463, 17.60188136],
[ 2.75421034, 7.23581539, 17.59701953],
[ 0. , 0. , 22.67700092],
[ 0. , 2.8835814 , 22.67700092],
[ 0. , 5.7671628 , 22.67700092],
[ 0. , 8.65074444, 22.67700092],
[ 2.8835814 , 0. , 22.67700092],
[ 2.8835814 , 2.8835814 , 22.67700092],
[ 2.8835814 , 5.7671628 , 22.67700092],
[ 2.8835814 , 8.65074444, 22.67700092],
[ 5.7671628 , 0. , 22.67700092],
[ 5.7671628 , 2.8835814 , 22.67700092],
[ 5.7671628 , 5.7671628 , 22.67700092],
[ 5.7671628 , 8.65074444, 22.67700092],
[ 8.65074444, 0. , 22.67700092],
[ 8.65074444, 2.8835814 , 22.67700092],
[ 8.65074444, 5.7671628 , 22.67700092],
[ 8.65074444, 8.65074444, 22.67700092],
[ 1.4417907 , 1.4417907 , 24.71600096],
[ 1.4417907 , 4.32537222, 24.71600096],
[ 1.4417907 , 7.20895386, 24.71600096],
[ 1.4417907 , 10.09253502, 24.71600096],
[ 4.32537222, 1.4417907 , 24.71600096],
[ 4.32537222, 4.32537222, 24.71600096],
[ 4.32537222, 7.20895386, 24.71600096],
[ 4.32537222, 10.09253502, 24.71600096],
[ 7.20895386, 1.4417907 , 24.71600096],
[ 7.20895386, 4.32537222, 24.71600096],
[ 7.20895386, 7.20895386, 24.71600096],
[ 7.20895386, 10.09253502, 24.71600096],
[ 10.09253502, 1.4417907 , 24.71600096],
[ 10.09253502, 4.32537222, 24.71600096],
[ 10.09253502, 7.20895386, 24.71600096],
[ 10.09253502, 10.09253502, 24.71600096]]*Angstrom
electrode_elements = [Gold, Gold]
electrode_coordinates = [[ 0. , 0. , 0. ],
[ 1.44179073, 1.44179073, 2.039 ]]*Angstrom
electrode_cell = [[ 2.88358145, 0. , 0. ],
[ 0. , 2.88358145, 0. ],
[ 0. , 0. , 4.078 ]]*Angstrom
# Set up electrodes
electrode_configuration = PeriodicAtomConfiguration(
electrode_cell,
electrode_elements,
electrode_coordinates
)
# Set up two-probe configuration
twoprobe_configuration = TwoProbeConfiguration(
(electrode_configuration,electrode_configuration),
scattering_elements,
scattering_coordinates,
electrode_repetitions=[[4,4],[4,4]],
equivalent_atoms=([0,0],[1,98])
)
if processIsMaster(): nlPrint(twoprobe_configuration)
######################################################################
# Central region parameters
######################################################################
exchange_correlation_type = GGA.revPBE
iteration_mixing_parameters = iterationMixingParameters(
algorithm = IterationMixing.Pulay,
diagonal_mixing_parameter = 0.1,
quantity = IterationMixing.Hamiltonian,
history_steps = 6
)
electron_density_parameters = electronDensityParameters(
mesh_cutoff = 150.0*Rydberg,
initial_scaled_spin = [ 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
0., 0., 0., 0., 0., 0., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.,
1., 1., 1., 1., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.,
0., 0., 0., 0., 0., 0., 0., 0., 0., 0. ]
)
basis_set_parameters_Common = basisSetParameters(
type = DoubleZetaPolarized,
radial_sampling_dr = 0.001*Bohr,
energy_shift = 0.01*Rydberg,
delta_rinn = 0.8,
v0 = 40.0*Rydberg,
charge = 0.0,
split_norm = 0.15
)
basis_set_parameters_Gold = basisSetParameters(
type = SingleZetaPolarized,
energy_shift = 0.01*Rydberg,
delta_rinn = 0.8,
v0 = 40.0*Rydberg,
charge = 0.0,
split_norm = 0.15,
element = Gold
)
basis_set_parameters = [
basis_set_parameters_Common,
basis_set_parameters_Gold
]
iteration_control_parameters = iterationControlParameters(
tolerance = 1e-005,
criterion = IterationControl.TotalEnergy,
max_steps = 100
)
electrode_voltages = (0.0,0.0)*Volt
two_probe_algorithm_parameters = twoProbeAlgorithmParameters(
electrode_constraint = ElectrodeConstraints.Off,
initial_density_type = InitialDensityType.EquivalentBulk
)
energy_contour_integral_parameters = energyContourIntegralParameters(
circle_points = 30,
integral_lower_bound = 3*Rydberg,
fermi_line_points = 10,
fermi_function_poles = 4,
real_axis_infinitesimal = 0.01*electronVolt,
real_axis_point_density = 0.02*electronVolt
)
two_center_integral_parameters = twoCenterIntegralParameters(
cutoff = 2500.0*Rydberg,
points = 1024
)
######################################################################
# Left electrode parameters
######################################################################
left_electrode_electron_density_parameters = electronDensityParameters(
mesh_cutoff = 200.0*Rydberg,
initial_scaled_spin = [ 0., 0. ]
)
left_electrode_iteration_control_parameters = iterationControlParameters(
tolerance = 1e-005,
criterion = IterationControl.TotalEnergy,
max_steps = 100
)
left_electrode_brillouin_zone_integration_parameters = brillouinZoneIntegrationParameters(
monkhorst_pack_parameters = (30, 30, 100)
)
left_electrode_iteration_mixing_parameters = iterationMixingParameters(
algorithm = IterationMixing.Pulay,
diagonal_mixing_parameter = 0.1,
quantity = IterationMixing.Hamiltonian,
history_steps = 6
)
left_electrode_eigenstate_occupation_parameters = eigenstateOccupationParameters(
temperature = 1000.0*Kelvin
)
######################################################################
# Collect left electrode parameters
######################################################################
left_electrode_parameters = ElectrodeParameters(
brillouin_zone_integration_parameters = left_electrode_brillouin_zone_integration_parameters,
electron_density_parameters = left_electrode_electron_density_parameters,
eigenstate_occupation_parameters = left_electrode_eigenstate_occupation_parameters,
iteration_mixing_parameters = left_electrode_iteration_mixing_parameters,
iteration_control_parameters = left_electrode_iteration_control_parameters
)
######################################################################
# Right electrode parameters
######################################################################
right_electrode_electron_density_parameters = electronDensityParameters(
mesh_cutoff = 150.0*Rydberg,
initial_scaled_spin = [ 0., 0. ]
)
right_electrode_iteration_control_parameters = iterationControlParameters(
tolerance = 1e-005,
criterion = IterationControl.TotalEnergy,
max_steps = 100
)
right_electrode_brillouin_zone_integration_parameters = brillouinZoneIntegrationParameters(
monkhorst_pack_parameters = (30, 30, 100)
)
right_electrode_iteration_mixing_parameters = iterationMixingParameters(
algorithm = IterationMixing.Pulay,
diagonal_mixing_parameter = 0.1,
quantity = IterationMixing.Hamiltonian,
history_steps = 6
)
right_electrode_eigenstate_occupation_parameters = eigenstateOccupationParameters(
temperature = 1000.0*Kelvin
)
######################################################################
# Collect right electrode parameters
######################################################################
right_electrode_parameters = ElectrodeParameters(
brillouin_zone_integration_parameters = right_electrode_brillouin_zone_integration_parameters,
electron_density_parameters = right_electrode_electron_density_parameters,
eigenstate_occupation_parameters = right_electrode_eigenstate_occupation_parameters,
iteration_mixing_parameters = right_electrode_iteration_mixing_parameters,
iteration_control_parameters = right_electrode_iteration_control_parameters
)
######################################################################
# Initialize self-consistent field calculation
######################################################################
two_probe_method = TwoProbeMethod(
electrode_parameters = (left_electrode_parameters,right_electrode_parameters),
exchange_correlation_type = exchange_correlation_type,
iteration_mixing_parameters = iteration_mixing_parameters,
electron_density_parameters = electron_density_parameters,
basis_set_parameters = basis_set_parameters,
iteration_control_parameters = iteration_control_parameters,
energy_contour_integral_parameters = energy_contour_integral_parameters,
two_center_integral_parameters = two_center_integral_parameters,
electrode_voltages = electrode_voltages,
algorithm_parameters = two_probe_algorithm_parameters
)
if processIsMaster(): nlPrint(two_probe_method)
runtime_parameters = runtimeParameters(
verbosity_level = 10,
checkpoint_filename = 'AuFe2COT3Au-scf.nc'
)
# Perform self-consistent field calculation
scf = executeSelfConsistentCalculation(
twoprobe_configuration,
two_probe_method,
runtime_parameters = runtime_parameters
)