triqs_dft_tools.sumk_dft_tools.SumkDFTTools.calc_mu

SumkDFTTools.calc_mu(precision=0.01, broadening=None, delta=0.5, max_loops=100, method='dichotomy', beta=None)

Searches for the chemical potential that gives the DFT total charge.

Parameters:
precisionfloat, optional

A desired precision of the resulting total charge.

broadeningfloat, optional

Imaginary shift for the axis along which the real-axis GF is calculated. If not provided, broadening will be set to double of the distance between mesh points in ‘mesh’. Only relevant for real-frequency GF.

max_loopsint, optional

Number of dichotomy loops maximally performed.

methodstring, optional
Type of optimization used:
  • dichotomy: usual bisection algorithm from the TRIQS library

  • newton: newton method, faster convergence but more unstable

  • brent: finds bounds and proceeds with hyperbolic brent method, a compromise between speed and ensuring convergence

betafloat, optional, default = broadening

when using MeshReFreq this determines the temperature for the Fermi function smearing when integrating G(w). If not given broadening will be used (converted to beta)

Returns:
mufloat

Value of the chemical potential giving the DFT total charge within specified precision.