-
Notifications
You must be signed in to change notification settings - Fork 25
Using the tight binding module from Python
Atomistica's ASE interface exposes a simplified interface to the tight-binding module that can be used for calculations that do not require charge self-consistency.
from atomistica import TightBinding
c = TightBinding(width=0.01)
a.set_calculator(c)
The parameter width
determines the electronic temperature. There is an additional parameter database_folder
that can be used to specify the location of the Slaster-Koster database. The default is to use the current folder. Atomistica currently supports reading of Hotbit, DFTB and BOPFOX Slater-Koster tables.
For self-consistent calculations the native Atomistica interface needs to be used to piece together tight-binding and Coulomb solvers. The Coulomb solver consists of a long-ranged and a short-ranged part. Currently only direct summation (DirectCoulomb
) is supported for the long-ranged part. The short ranged part can be used to specify either Slater (SlaterCharges
) or Gaussian (GaussianCharges
) charges and requires a cutoff
parameter.
from atomistica import Atomistica
from atomistica.native import TightBinding, DirectCoulomb, SlaterCharges
c = Atomistica([TightBinding(SolverLAPACK=dict(electronic_T=0.01),
SCC=dict(dq_crit=1e-4,
mixing=0.1,
andersen_memory=4,
maximum_iterations=250,
log=True)),
DirectCoulomb(),
SlaterCharges(cutoff=10.0)],
avgn=1000)
a.set_calculator(c)
In the above example SolverLAPACK
can be replaced by SolverCP
(with an empty dictionary because it does not take any parameters). SolverCP
is an implementation of the canonical purification solver by Palser & Manolopoulos implemented for dense matrices and non-orthogonal systems. For dense matrices, LAPACK is generally faster than canonical purification.
SCC
enables Andersen mixing for charge self-consistency. The mixing
and andersen_memory
parameters can be used to tune speed of convergence. Good values for mixing
are between 0.05 and 0.3 and good values for andersen_memory
are between 2 and 5.