Algorithms

IntegralProblem algorithms

Quadrature

AutoBZCore.QuadratureFunctionType
QuadratureFunction(; fun=trapz, npt=50)

Quadrature rule for the standard interval [-1,1] computed from a function x, w = fun(npt). The nodes and weights should be set so the integral of f on [-1,1] is sum(w .* f.(x)). The default quadrature rule is trapz, although other packages provide rules, e.g.

using FastGaussQuadrature
alg = QuadratureFunction(fun=gausslegendre, npt=100)
source
AutoBZCore.AuxQuadGKJLType
AuxQuadGKJL(; order = 7, norm = norm)

Generalization of the QuadGKJL provided by Integrals.jl that allows for AuxValued integrands for auxiliary integration and multi-threaded evaluation with the batch argument to IntegralProblem

source

Cubature

AutoBZCore.MonkhorstPackType
MonkhorstPack(; npt=50, syms=nothing)

Periodic trapezoidal rule with a fixed number of k-points per dimension, npt, using the PTR rule from AutoSymPTR.jl. The caller should check that the integral is converged w.r.t. npt.

source
AutoBZCore.AutoSymPTRJLType
AutoSymPTRJL(; norm=norm, a=1.0, nmin=50, nmax=1000, n₀=6, Δn=log(10), keepmost=2)

Periodic trapezoidal rule with automatic convergence to tolerances passed to the solver with respect to norm using the routine autosymptr from AutoSymPTR.jl. This algorithm is the most efficient for smooth integrands.

source

Meta-algorithms

AutoBZCore.NestedQuadType
NestedQuad(alg::IntegralAlgorithm)
NestedQuad(algs::IntegralAlgorithm...)

Nested integration by repeating one quadrature algorithm or composing a list of algorithms. The domain of integration must be an AbstractIteratedLimits from the IteratedIntegration.jl package. Analogous to nested_quad from IteratedIntegration.jl. The integrand should expect SVector inputs. Do not use this for very high-dimensional integrals, since the compilation time scales very poorly with respect to dimensionality.

source
AutoBZCore.EvalCounterType
EvalCounter(alg::IntegralAlgorithm)

This algorithm wrapper will count the number of function evaluations used by integration algorithm alg during a solve. This information is found in the sol.stats.numevals field of an IntegralSolution.

source
AutoBZCore.EvalLoggerType
EvalLogger(alg::IntegralAlgorithm)

This algorithm wrapper will record the quadrature points used by integration algorithm alg during a solve. This information is found in the sol.stats.evallog field of an IntegralSolution.

source

AutoBZProblem algorithms

Although different algorithms may use different representations of the BZ, the BZ loaded from load_bz can be called with any of the algorithms below, which are aliases for algorithms above

AutoBZCore.AutoBZAlgorithmType
AutoBZAlgorithm

Abstract supertype for Brillouin zone integration algorithms. All integration problems on the BZ get rescaled to fractional coordinates so that the Brillouin zone becomes [0,1]^d, and integrands should have this periodicity. If the integrand depends on the Brillouin zone basis, then it may have to be transformed to the Cartesian coordinates as a post-processing step. These algorithms also use the symmetries of the Brillouin zone and the integrand.

source
AutoBZCore.IAIType
IAI(alg::IntegralAlgorithm=AuxQuadGKJL())
IAI(algs::IntegralAlgorithm...)

Iterated-adaptive integration using nested_quad from IteratedIntegration.jl. This algorithm is the most efficient for localized integrands.

source
AutoBZCore.TAIType
TAI(; norm=norm, initdivs=1)

Tree-adaptive integration using hcubature from HCubature.jl. This routine is limited to integration over hypercube domains and may not use all symmetries.

source
AutoBZCore.PTRType
PTR(; npt=50)

Periodic trapezoidal rule with a fixed number of k-points per dimension, npt, using the routine ptr from AutoSymPTR.jl. The caller should check that the integral is converged w.r.t. npt.

source
AutoBZCore.AutoPTRType
AutoPTR(; norm=norm, a=1.0, nmin=50, nmax=1000, n₀=6, Δn=log(10), keepmost=2)

Periodic trapezoidal rule with automatic convergence to tolerances passed to the solver with respect to norm using the routine autosymptr from AutoSymPTR.jl. This algorithm is the most efficient for smooth integrands.

source

DOSProblem algorithms

Currently the available algorithms are an initial release and we would like to include the following reference algorithms that are also common in the literature in a future release:

  • Adaptive Gaussian broadening
AutoBZCore.GGRType
GGR(; npt=50)

Generalized Gilat-Raubenheimer method as in "Generalized Gilat–Raubenheimer method for density-of-states calculation in photonic crystals". This method requires the Hamiltonian and its derivatives, and performs a linear extrapolation at each k-point in an equispace grid. The algorithm is expected to show second-order convergence and suffer reduced error at band crossings compared to interpolatory methods.

Arguments

  • npt: the number of k-points per dimension
source
AutoBZCore.BCDType
BCD(npt, α, ΔE)

Brillouin Contour Deformation method was developed in "Efficient extraction of resonant states in systems with defects". This method requires the Hamiltonian and its first and second order derivatives. It performs a deformation of the Brillouin zone into the complex planes based on the first derivative of the Hamiltonian at singularity points. The deformation is controlled by two parameters α and ΔE which scale the deformation around singularity respectively in amplitude and width. This method is expected to show exponential convergence and is not highly sensitive to the choice of parameters. Therefore it can be used with default parameters in most cases.

Arguments

  • npt: the number of k-points per dimension
  • α: a scaling parameter for the amplitude of the deformation
  • ΔE: a parameter which impacts the width of the deformation at singularities
source
AutoBZCore.LTType
LT(npt)

Linear Tetrahedron method "High-precision sampling for Brillouin-zone integration in metals". This method requires Hamiltonian's eigenvalues. It performs a linear interpolation of the eigenvalues on a tetrahedric decomposition of the Brillouin zone. Therefore only the eigenvalues are needed at each k-point to perform interpolation. This method is expected to show quadratic convergence.

Arguments

  • npt: the number of k-points per dimension
source