PAOFLOW.elphon.anisotropic_eliashberg#

Anisotropic Migdal-Eliashberg equations on the Fermi surface.

Fermi-surface-restricted (FSR) solution of the anisotropic equations, following EPW’s laniso / limag / lpade (E. R. Margine and F. Giustino, Phys. Rev. B 87, 024505 (2013); EPW tutorial 04, MgB2). The input is the folded pair coupling Lambda_ab(omega) of the irreducible Fermi-surface states a = (n, k) written by FermiSurfacePairCoupling, the Coulomb pseudopotential mu* and the temperature.

With the pair coupling on the bosonic Matsubara frequencies nu_l = 2 pi l k_B T,

\[\lambda_{ab}(l) = \int d\omega\,\Lambda_{ab}(\omega)\, \frac{\omega^2}{\omega^2 + \nu_l^2},\]

and the sums restricted to positive fermionic frequencies w_j = (2j+1) pi k_B T <= wscut, the imaginary-axis equations are

\[ \begin{align}\begin{aligned}Z_a(j) = 1 + \frac{\pi T}{\omega_j}\sum_{b, j'} [\lambda_{ab}(j-j') - \lambda_{ab}(j+j'+1)]\,\frac{\omega_{j'}}{R_b(j')},\\Z_a(j)\Delta_a(j) = \pi T\sum_{b, j'} [\lambda_{ab}(j-j') + \lambda_{ab}(j+j'+1) - 2\mu^* C_{ab}]\, \frac{\Delta_b(j')}{R_b(j')},\end{aligned}\end{align} \]

with \(R = \sqrt{\omega^2 + \Delta^2}\) and \(C_{ab}\) the Coulomb weights of coulomb_weights(): the Fermi-surface weight \(c_b = W_b / N_F\) of state b, restricted to the (k, k+q) pairs of the phonon kernel. For a single state they reduce to the isotropic equations of PAOFLOW.elphon.migdal_eliashberg, with Lambda(omega) = 2 a2F(omega) / omega.

The kernel omega^2 / (omega^2 + nu_l^2) sampled on the phonon grid and on the bosonic frequencies has a low numerical rank. Its singular-value decomposition makes the kernel separable, \(\lambda_{ab}(l) = \sum_r L_{ab,r} V_r(l)\), so that each iteration costs N^2 r n_w operations instead of N^2 n_w^2. Energies are in eV and temperatures in kelvin.

Functions#

coupling_strength(coupling)

State-resolved and isotropic coupling from the Fermi-surface pair coupling.

matsubara_kernel(coupling, T, wscut[, rank_tol])

Separable anisotropic kernel on the positive Matsubara frequencies.

coulomb_weights(coupling)

Weights C_ab of the Coulomb pseudopotential in the gap equation.

solve_imag_aniso(coupling, T, mu_star, wscut[, ...])

Self-consistent anisotropic Delta_nk(i w_j) and Z_nk(i w_j).

linearized_max_eigenvalue_aniso(coupling, T, mu_star, ...)

Largest eigenvalue of the linearised anisotropic gap equation.

pade_continuation_aniso(wn, Z, delta, w_real[, npade])

Real-axis Z_nk(w), Delta_nk(w) from Pade approximants, state by state.

gap_distribution(values, weights, grid, smearing)

Gaussian-broadened, weighted distribution of state-resolved values.

epw_gap_distribution(gaps, weights[, nbin])

Gap distribution of EPW's gap_distribution_FS (file imag_aniso_gap0_<T>).

migdal_eliashberg_aniso(coupling, temps[, mu_star, ...])

Anisotropic Migdal-Eliashberg solution over a set of temperatures.

linearized_eigenvalues_aniso(coupling, temps[, ...])

Largest linearised anisotropic eigenvalue at each temperature, and Tc.

write_me_aniso_outputs(result, coupling, outdir, prefix)

Write the anisotropic Migdal-Eliashberg results in EPW's file formats.

Module Contents#

PAOFLOW.elphon.anisotropic_eliashberg.coupling_strength(coupling)[source]#

State-resolved and isotropic coupling from the Fermi-surface pair coupling.

Parameters:

coupling (dict) – Fermi-surface coupling (read_fs_coupling()).

Returns:

lambda_nk (N,) (EPW lambda_nk), lambda (isotropic average), dos_ef (N_F, states/eV/spin per cell), omega and a2F (isotropic Eliashberg function on the coupling frequency grid).

Return type:

dict

Notes

\[\lambda_a = \sum_b\int d\omega\,\Lambda_{ab}(\omega),\qquad \lambda = \sum_a c_a\lambda_a,\qquad \alpha^2F(\omega) = \frac{\omega}{2}\sum_{ab} c_a\Lambda_{ab}(\omega).\]
PAOFLOW.elphon.anisotropic_eliashberg.matsubara_kernel(coupling, T, wscut, rank_tol=1e-10)[source]#

Separable anisotropic kernel on the positive Matsubara frequencies.

Parameters:
  • coupling (dict) – Fermi-surface coupling.

  • T (float) – Temperature (K).

  • wscut (float) – Matsubara cutoff (eV).

  • rank_tol (float, optional) – Relative singular-value cutoff of the frequency kernel (default 1e-10).

Returns:

wn (nw,); pair_factors (N, N * r), the factors \(L_{ab,r}\) flattened over (b, r); plus and minus (r, nw, nw), \(V_r(|j-j'|) \pm V_r(j+j'+1)\); fractions (N,), the weights c_b; coulomb (N, N), the Coulomb weights \(C_{ab}\) (coulomb_weights()); and rank.

Return type:

dict

Notes

With \(h_{\beta l} = \omega_\beta^2/(\omega_\beta^2 + \nu_l^2)\) on the coupling grid and \(h = U S V^T\), the kept rank r has \(S_r > \mathrm{rank\_tol}\,S_0\) and \(L_{ab,r} = \sum_\beta \Lambda_{ab}(\omega_\beta) U_{\beta r} S_r\).

PAOFLOW.elphon.anisotropic_eliashberg.coulomb_weights(coupling)[source]#

Weights C_ab of the Coulomb pseudopotential in the gap equation.

Parameters:

coupling (dict) – Fermi-surface coupling.

Returns:

C_ab = M_ab / N_F from the Coulomb pairs M_ab of the coupling (fermi_surface_coupling), which restrict mu* to the (k, k+q) pairs of the phonon kernel; without them, C_ab = c_b for every row.

Return type:

ndarray, shape (N, N)

Notes

The rows sum to about 1. The two forms agree when the q-grid equals the k-grid; with a coarser q-grid only the pair-restricted one is consistent with the phonon kernel.

PAOFLOW.elphon.anisotropic_eliashberg.solve_imag_aniso(coupling, T, mu_star, wscut, nsiter=500, conv_thr=0.0001, delta0=None, mix=0.7, nhist=8, normal_floor=1e-07, rank_tol=1e-10)[source]#

Self-consistent anisotropic Delta_nk(i w_j) and Z_nk(i w_j).

Parameters:
  • coupling (dict) – Fermi-surface coupling (read_fs_coupling()).

  • T (float) – Temperature (K).

  • mu_star (float) – Coulomb pseudopotential (EPW muc).

  • wscut (float) – Matsubara cutoff (eV, EPW wscut).

  • nsiter (int, optional) – Maximum number of iterations (EPW nsiter).

  • conv_thr (float, optional) – Convergence threshold (EPW conv_thr_iaxis).

  • delta0 (float or array_like, optional) – Initial gap (eV): a scalar, one value per state (N,) or one per state and frequency (N, nw). Defaults to 1.764 k_B Tc with the Allen-Dynes Tc of the isotropic a2F.

  • mix (float, optional) – Anderson mixing parameter.

  • nhist (int, optional) – Number of previous steps kept by the mixing.

  • normal_floor (float, optional) – Gap (eV) below which the solution is taken as the normal state.

  • rank_tol (float, optional) – Singular-value cutoff of matsubara_kernel().

Returns:

wn (nw,), Z and delta (N, nw) (eV), niter, converged and the kernel rank. The Fermi-surface average of delta(i w_0) is positive.

Return type:

dict

Notes

The equations are those of the module docstring, solved with anderson_fixed_point().

PAOFLOW.elphon.anisotropic_eliashberg.linearized_max_eigenvalue_aniso(coupling, T, mu_star, wscut, rank_tol=1e-10)[source]#

Largest eigenvalue of the linearised anisotropic gap equation.

Parameters:
  • coupling (dict) – Fermi-surface coupling.

  • T (float) – Temperature (K).

  • mu_star (float) – Coulomb pseudopotential.

  • wscut (float) – Matsubara cutoff (eV).

  • rank_tol (float, optional) – Singular-value cutoff of matsubara_kernel().

Returns:

The eigenvalue rho: above 1 below Tc, 1 at Tc.

Return type:

float

Notes

Near Tc

\[\rho\,\Delta_a(j) = \frac{\pi T}{Z^N_a(j)}\sum_{b, j'} [\lambda_{ab}(j-j') + \lambda_{ab}(j+j'+1) - 2\mu^* C_{ab}]\, \frac{\Delta_b(j')}{\omega_{j'}},\]

with the normal-state Z^N. The leading eigenvalue (largest real part) is found with ARPACK on the matrix-free operator.

PAOFLOW.elphon.anisotropic_eliashberg.pade_continuation_aniso(wn, Z, delta, w_real, npade=90)[source]#

Real-axis Z_nk(w), Delta_nk(w) from Pade approximants, state by state.

Parameters:
  • wn (array_like, shape (nw,)) – Matsubara frequencies (eV).

  • Z (array_like, shape (N, nw)) – Imaginary-axis solution (solve_imag_aniso()).

  • delta (array_like, shape (N, nw)) – Imaginary-axis solution (solve_imag_aniso()).

  • w_real (array_like, shape (nreal,)) – Real frequencies (eV).

  • npade (float, optional) – Percentage of the Matsubara frequencies used (EPW npade).

Returns:

Z_real, delta_real

Return type:

ndarray, shape (N, nreal), complex

PAOFLOW.elphon.anisotropic_eliashberg.gap_distribution(values, weights, grid, smearing)[source]#

Gaussian-broadened, weighted distribution of state-resolved values.

Parameters:
  • values (array_like, shape (N,)) – One value per state (e.g. Delta_nk or lambda_nk); nan values are ignored.

  • weights (array_like, shape (N,)) – Fermi-surface weights.

  • grid (array_like) – Points where the distribution is evaluated (units of values).

  • smearing (float) – Gaussian width (units of values).

Returns:

The distribution on grid, normalised to unit integral.

Return type:

ndarray

PAOFLOW.elphon.anisotropic_eliashberg.epw_gap_distribution(gaps, weights, nbin=300)[source]#

Gap distribution of EPW’s gap_distribution_FS (file imag_aniso_gap0_<T>).

Parameters:
  • gaps (array_like, shape (N,)) – Delta_nk of every Fermi-surface state (eV); nan values are ignored.

  • weights (array_like, shape (N,)) – Fermi-surface weights W_a (1/eV per spin, summing to N_F).

  • nbin (int, optional) – Number of bins (EPW: 300).

Returns:

  • grid (ndarray, shape (nbin,)) – Gap values (eV).

  • scaled (ndarray, shape (nbin,)) – Distribution normalised to a maximum of 1.

  • raw (ndarray, shape (nbin,)) – Unnormalised distribution (1/eV^2, both spins), EPW’s dist. (not scaled).

  • None is returned when every gap is zero (normal state).

Notes

As EPW, the bins cover \([0.9\,\Delta_{\min}, 1.1\,\Delta_{\max}]\) and every state is a Gaussian of width half a bin,

\[\rho(\Delta) = \sum_a 2W_a\,\frac{e^{-(\Delta-\Delta_a)^2/s^2}}{\sqrt\pi\,s}, \qquad s = \frac{1.1\,\Delta_{\max} - 0.9\,\Delta_{\min}}{2\,n_{\rm bin}},\]

with the factor 2 for the spins of EPW’s k-point weights. Its integral is therefore \(2N_F\).

PAOFLOW.elphon.anisotropic_eliashberg.migdal_eliashberg_aniso(coupling, temps, mu_star=0.1, wscut=0.1, nsiter=500, conv_thr_iaxis=0.0001, npade=90, lpade=True, real_axis_max=None, n_real=2000, rank_tol=1e-10, verbose=False)[source]#

Anisotropic Migdal-Eliashberg solution over a set of temperatures.

Parameters:
  • coupling (dict) – Fermi-surface coupling (read_fs_coupling()).

  • temps (array_like) – Temperatures (K); solved in ascending order.

  • mu_star (float, optional) – Coulomb pseudopotential (EPW muc, default 0.1).

  • wscut (float, optional) – Matsubara cutoff (eV, default 0.1).

  • nsiter (int, optional) – Maximum iterations (EPW nsiter).

  • conv_thr_iaxis (float, optional) – Convergence threshold on the imaginary axis.

  • npade (float, optional) – Percentage of Matsubara points in the Pade approximants.

  • lpade (bool, optional) – Continue each state to the real axis (EPW lpade).

  • real_axis_max (float, optional) – Upper real frequency (eV); defaults to 0.2 * wscut.

  • n_real (int, optional) – Number of real frequencies (default 2000).

  • rank_tol (float, optional) – Singular-value cutoff of matsubara_kernel().

  • verbose (bool, optional) – Print one summary line per temperature.

Returns:

temps (K); gap0 and Z0 (ntemps, N), Delta_nk(i w_0) (eV) and Z_nk(i w_0); gap_edge (ntemps, N), the Pade gap edge of every state (eV, nan where not computed); gap_mean, gap_min, gap_max (Fermi-surface average and range of gap0); niter, converged; qdos (ntemps, n_real) (N_S/N_F, nan where not computed) and pade_mean (list of the Fermi-surface averaged (Z(w), Delta(w)) or None); imag (list of (wn, Z, delta)); w_real; Tc_gap (K, tc_from_gap() on the largest gap); mu_star, wscut; and the coupling summary of coupling_strength().

Return type:

dict

Warns:

UserWarning – If the coupling was computed with a q-grid coarser than the k-grid, whose sublattices of k+q are independent superconductors.

Notes

Each temperature starts from the gap of the previous one, interpolated on its Matsubara grid.

PAOFLOW.elphon.anisotropic_eliashberg.linearized_eigenvalues_aniso(coupling, temps, mu_star=0.1, wscut=0.1)[source]#

Largest linearised anisotropic eigenvalue at each temperature, and Tc.

Parameters:
  • coupling (dict) – Fermi-surface coupling.

  • temps (array_like) – Temperatures (K).

  • mu_star (float, optional) – Coulomb pseudopotential (default 0.1).

  • wscut (float, optional) – Matsubara cutoff (eV, default 0.1).

Returns:

temps (sorted, K), max_eigenvalue and Tc_linear (K).

Return type:

dict

PAOFLOW.elphon.anisotropic_eliashberg.write_me_aniso_outputs(result, coupling, outdir, prefix, linear=None, smearing_mev=0.1, lambda_smearing=0.01, n_grid=500)[source]#

Write the anisotropic Migdal-Eliashberg results in EPW’s file formats.

Parameters:
  • result (dict) – Output of migdal_eliashberg_aniso().

  • coupling (dict) – The Fermi-surface coupling used.

  • outdir (str) – Output directory (created if needed).

  • prefix (str) – File prefix (EPW prefix).

  • linear (dict, optional) – Output of linearized_eigenvalues_aniso().

  • smearing_mev (float, optional) – Gaussian width of the gap distributions (meV, default 0.1).

  • lambda_smearing (float, optional) – Gaussian width of the lambda_nk distribution (default 0.01).

  • n_grid (int, optional) – Number of points of the distributions.

Returns:

Writes <prefix>.lambda_FS (k in Cartesian 2 pi / alat, band, e - E_F in eV, lambda_nk) and <prefix>.lambda_k_pairs (distribution of lambda_nk); for every temperature <T> (temperature_tag()) <prefix>.imag_aniso_<T> (w_j, e - E_F, Z, Delta, eV), <prefix>.imag_aniso_gap0_<T> and <prefix>.pade_aniso_gap0_<T> (distributions of Delta_nk(i w_0) and of the Pade gap edges in EPW’s columns, epw_gap_distribution(); not written in the normal state), <prefix>.imag_aniso_gap_FS_<T> (Delta_nk(i w_0) of every state), <prefix>.pade_aniso_<T> (Fermi-surface averaged Z(w), Delta(w)) and <prefix>.qdos_<T>; gap_vs_T_aniso.dat, max_eigenvalue_aniso.dat (with linear) and migdal_eliashberg_aniso.npz.

Return type:

None