24 block2_gf<Mesh, matrix_valued>
const &Sigma_dynamic,
25 nda::array<nda::matrix<dcomplex>, 2>
const &Sigma_static) {
28 auto n_k = obe.
H.
n_k();
31 auto n_nu_k = range(n_k) | stdv::transform([&obe](
auto k_idx) {
return obe.
H.
N_nu(0, k_idx); }) | tl::to<std::vector>();
32 auto n_nu = *std::max_element(begin(n_nu_k), end(n_nu_k));
35 auto N_nu_nup_k = nda::zeros<dcomplex>(n_k, n_sigma, n_nu, n_nu);
38 auto glatt_at_k = detail::lattice_gf_at_k(obe, mu, Sigma_dynamic, Sigma_static);
42 for (
auto k_idx : range(n_k)) {
43 for (
auto const &sigma : range(n_sigma)) {
44 auto r_window = nda::range(0, obe.
H.
N_nu(sigma, k_idx));
45 N_nu_nup_k(k_idx, sigma, r_window, r_window) =
density(glatt_at_k(k_idx, sigma));