pythtb.TBModel.quantum_metric#

TBModel.quantum_metric(k_pts, occ_idxs=None, plane=None, *, cartesian=False, non_abelian=False, param_periods=None, diff_scheme='central', diff_order=2, use_tensorflow=False, **params)[source]#

Quantum metric in the energy eigenbasis computed via Kubo formula.

The quantum metric is computed as the Hermitian part of the quantum geometric tensor \(Q_{\mu \nu}(k)\) from quantum_geometric_tensor(), i.e., in the non-Abelian case (non_abelian=True):

\[g_{\mu \nu;\ mn}(k) = \frac{1}{2} \left( Q_{\mu \nu;\ mn}(k) + Q_{\mu \nu;\ nm}^*(k) \right)\]

In the Abelian case (non_abelian=False), the quantum metric is given by the band-trace of the above quantity. This reduces to the well-known expression for the quantum metric in terms of the quantum geometric tensor.

\[g_{\mu \nu}(k) = \mathrm{Re} \, Q_{\mu \nu}(k),\]

By specifying the plane parameter, we choose a particular \((\mu, \nu)\) pair of the Berry curvature tensor to return.

Added in version 2.0.0.

Parameters:
k_pts(nk, dim_k) array-like

Array of k-points with shape (nk, dim_k), where nk is the number of points and dim_k is the dimensionality of the k-space.

occ_idxs1D array, optional

Indices of the occupied bands. Defaults to the first half of the states.

planetuple of int, optional

Tuple of two integers specifying the plane in k-space for which to compute the curvature. If None (default), computes all components of the Berry curvature tensor. This will affect the shape of the returned array.

cartesianbool, optional

If True, computes the velocity operator in Cartesian coordinates. Default is False (reduced coordinates).

non_abelianbool, optional

If True, returns the full Berry curvature tensor (non-abelian case). If False, returns the band-trace of the Berry curvature tensor (abelian case). Default is False. This will affect the shape of the returned array.

param_periodsdict[str, float], optional

Optional map {param_name: period} for swept parameters. When supplied, assumes the parameter is cyclic and trims any duplicated endpoints, or endpoints equal to the start plus the given period, before building finite-difference stencils. This can improve numerical accuracy by using centered differences throughout the parameter range. Otherwise, the function will use a backward difference at the endpoint and a forward difference at the start.

diff_schemestr, optional

Finite difference scheme to use for parameter derivatives. Options are “central” (default) or “forward”. This parameter is only relevant when passing varying parameters.

diff_orderint, optional

Order of accuracy for finite difference lambda derivatives. Must be an even integer for “central” scheme (default is 4), and a positive integer for “forward” scheme. This parameter is only relevant when passing varying parameters.

use_tensorflow: bool, optional

If True, will use TensorFlow to speed up linear algebra routines. Requires TensorFlow to be installed. Default is False.

**params

Keyword arguments mapping parameter names to value(s). Each value can be a scalar or a 1D array of values. If any values are array-like, the quantum metric is evaluated at all combinations of parameter values, and the final array is stacked with the k-axis leading, followed by each parameter axis in the order of given parameter names.

Returns:
gnp.ndarray

Quantum metric tensor. Full shape is (dim_tot, dim_tot, Nk, Nparam1, Nparam2, ..., n_orb, n_orb), where dim_tot = dim_k + n_params is the total number of independent coordinates (crystal momenta plus varying parameters). If plane is specified, the first two axes are indexed by the specified directions, and the shape is (Nk, Nparam1, Nparam2, ..., n_orb, n_orb). If non_abelian=False, the returned array is the band-trace of the full tensor and the last two dimensions are contracted. The order of the parameter axes follows the order of the parameter names in **params.

See also

quantum_geometric_tensor
berry_curvature
velocity
Quantum geometric tensor

Jupyter notebook tutorial on quantum geometric tensor.

Notes

  • The quantum metric is computed using the Kubo formula, which requires knowledge of \(\partial_\mu H_k\). This operator is computed using the gradient of the Hamiltonian provided by velocity().

  • Specifically, for \((m,n) \in \text{occ}\), the non-Abelian quantum metric tensor is given by (when non_abelian=True):

    \[g_{\mu \nu;\ mn}(k) = \frac{1}{2} \sum_{l \notin \text{occ}} \frac{ \langle u_{mk} | \partial_{\mu} H_k | u_{lk} \rangle \langle u_{lk} | \partial_{\nu} H_k | u_{nk} \rangle + m \leftrightarrow n }{ (E_{nk} - E_{lk})(E_{mk} - E_{lk}) }\]
  • This quantity is symmetric under \(\mu \leftrightarrow \nu\).

  • When using parameter sweeps via params, the quantum metric is computed at all combinations of parameter values, and the resulting array has parameter axes added after the k-point axis in the output.

  • The plane indices use the combined coordinate ordering of k-space dimensions followed by swept parameters \([k_0, ..., k_{\text{dim_k}}, \lambda_0, \lambda_1, ...]\). For example, in a 2D model with one swept parameter, the valid plane indices are 0, 1, and 2, where 0 and 1 refer to the two k-space dimensions, and 2 refers to the swept parameter axis. Swept parameters are those provided as array-like values in **params. The order of swept parameters is determined by the order in which they appear in the **params keyword arguments.

Warning

  • This requires a global energy gap between occupied and unoccupied bands.

  • The quantum metric is defined only when the total number of independent coordinates (crystal momenta plus varying parameters) is at least two, i.e. dim_k + n_params >= 2 where n_params is the number of varying parameters set with lists of values.