gem.lattice.Lattice.fit_mu_fragment

Lattice.fit_mu_fragment(n_target, Fragments_list, T=0.01, nsteps=30, dmu0=0.1, ntol=0.0001, mu_old=0.0, max_expand=60, mu_tol=1e-08)[source]

Procedure to fit the chemical potential from the fragment problem.

In an incompressible region n(mu) is flat at the target over a whole interval of mu, so the constraint does not determine mu uniquely. The first mu found within the given tolerance is returned.

On return the fragments are left solved at the returned mu (at the requested T), so the caller need not re-solve them.

Parameters:
  • n_target – float. Target filling.

  • Fragments_list – List of Fragment objects that contain the self-energies.

  • T – float, optional. Electronic temperature (default: 1e-2).

  • nsteps – int, optional. Maximum number of refinement steps (default: 30).

  • dmu0 – float, optional. Initial bracket half-width, doubled while expanding (default: 1e-1).

  • ntol – float, optional. Tolerance on the filling for convergence (default: 1e-4).

  • mu_old – float, optional. Previous chemical potential, used as the starting point of the bracket search (default: 0.0).

  • max_expand – int, optional. Maximum number of bracket expansions (default: 60).

  • mu_tol – float, optional. Stop once the bracket is this narrow (default: 1e-8).

Return:

mu: float. Chemical potential reproducing n_target, or the closest bracket endpoint found if the target filling is unreachable.