Stored Hamiltonian \(H\times\vec{v}\)

The module ed_hamiltonian_nonsu2_stored_hxv constructs the terms of the sector Hamiltonian storing them the sparse_matrix instance: sph0.

The main output of this module are the matrix vector products performed using the stored sparse matrices \(\vec{w} = H\times \vec{v}\).

Quick access

Routines:

ed_buildh_nonsu2_main(), spmatvec_nonsu2_main(), spmatvec_mpi_nonsu2_main()

Used modules

  • ed_hamiltonian_nonsu2_common

Subroutines and functions

subroutine  ed_hamiltonian_nonsu2_stored_hxv/ed_buildh_nonsu2_main(isector[, hmat])

Builds the sector Hamiltonian \(H\) and save each term in a suitable sparse matrix instance for ed_total_ed = True. If the dimension dim of the sector are smaller than lanc_dim_threshold the global matrix is dumped to the optional variable hmat.

All the different electronic terms are collected in the same sparse matrix, possibly using rows splitting and local / non-local blocks according to the MPI_Allgatherv algorithm:
  • \(H_{\rm int} \rightarrow\) sph0 : interaction part of the electronic Hamiltonian

  • \(H_{\rm imp} \rightarrow\) sph0 : impurity part of the eletronic Hamiltonian

  • \(H_{\rm bath} \rightarrow\) sph0: bath levels part of the eletronic Hamiltonian

  • \(H_{\rm hyb} \rightarrow\) sph0 : impurity - bath coupling part of the eletronic Hamiltonian

Parameters:

isector [integer]

Options:

hmat (•, •) [complex] – optional dense matrix

subroutine  ed_hamiltonian_nonsu2_stored_hxv/spmatvec_nonsu2_main(nloc, v, hv)

Serial version of the matrix-vector product \(\vec{w}=H\times\vec{v}\) used in Arpack/Lanczos algorithm. This procedures applies one by one each term of the global Hamiltonian to an input vector using the stored sparse matrices.

Options:

nloc [integer] – Global dimension of the problem. size(v)=Nloc=size(Hv)

Parameters:
  • v (nloc) [complex] – input vector (passed by Arpack/Lanczos) \(\vec{v}\)

  • hv (nloc) [complex] – output vector (required by Arpack/Lanczos) \(\vec{w}\)

subroutine  ed_hamiltonian_nonsu2_stored_hxv/spmatvec_mpi_nonsu2_main(nloc, v, hv)

MPI parallel version of the matrix-vector product \(\vec{w}=H\times\vec{v}\) used in P-Arpack/P-Lanczos algorithm. This procedures applies one by one each term of the global Hamiltonian to a part of the vector own by the thread using the stored sparse matrices.

Options:

nloc [integer] – ==spH0%Nrow

Parameters:
  • v (nloc) [complex] – input vector part (passed by P-Arpack/P-Lanczos) \(\vec{v}\)

  • hv (nloc) [complex] – !output vector (required by P-Arpack/P-Lanczos) \(\vec{w}\)