Closed pablosanjose closed 1 year ago
This is a good summary of the available methods. I think there will always be a tension between methods that provided the Green's function for all energies (diagonalization and KPM) vs methods that only provide the Green's function for a fixed energy. Whenever possble, I think it is a good idea to provide methods for both cases.
I would add the methods based on recursion and based on propagating states for the evalaution of boundary self-energies for the case of semi-infinite leads. I think a good reference for these is: https://iopscience.iop.org/article/10.1088/0953-8984/16/21/R01
Can we write down a method analogous to the linear-solve approach for periodic Hamiltonians? Maybe writing the linear equation for g(ω, dcell) using Bloch theorem?
I believe we could, but using Bloch theorem would require a summation over k-points in the Brillouin zone. In the same way, If the unit cell is very large, we could combine a Chebyshev expansion of $G_{k}(\omega)$ for each k.
One question, in your simple solver
(s::InversionSolver)(ω) = P' * inv(ω*I - bloch(s.hamiltonian)) * P
Doesn't this first compute the full inverse of ω*I - bloch(s.hamiltonian)
and only after that projects it? Shouldn't it be
(s::InversionSolver)(ω) = P' * (ω*I - bloch(s.hamiltonian))\ P
?
Thanks for the reference Bruno, I'll check it out.
Regarding (s::InversionSolver)(ω) = P' * (ω*I - bloch(s.hamiltonian))\ P
, yes, that is method 2 in the list. Method 1 of projected inverse is completely useless in practice, although it is conceptually clear.
This issue discusses the design of
GreenFunction
, which holds the essential spectral information of aHamiltonian
or anEffectiveHamiltonian
(see pablosanjose/Elsa.jl#50 for discussion on the latter). With aGreenFunction
we should be able to compute global/local density of states, transport or linear response coefficients of aHamiltonian
(the latter would be two-bodyGreenFunction
s). In more general terms, one can use theGreenFunction
of a given Hamiltonian to compute the self-energy induced on another in the presence of a coupling.CC: @fernandopenaranda, @BacAmorim
Workflow
The workflow would typically be the following. You want to compute some quantity that can be expressed in terms of the Green function of a Hamiltonian
h
. You would dog = greenfunction(h; projector = ..., solver =...)
, whereprojector
is a projector on a unit cell subspace. Theng(ω, celldst, cellsrc)
would yield the Green function as a matrix on the projected space between the two specified cells. In the above, one could replaceh::Hamiltonian
by anh::EffectiveHamiltonian
describing a coupled system. In that case, theg
would be restricted to the intra-Hamiltonian propagator, which I expect greatly simplifies the implementation.(If we would really want the inter-Hamiltonian propagator from subsystem 1 to 2 in a coupled system, it is rather simple to write as
G_12 = G_1 * W * g_2
whereG_1
includes the self-energy from 2, butg_2
is the decoupled Green function of 2, and W is the coupling.)In the following we discuss how we could compute
g
andG
of aHamiltonian
and anEffectiveHamiltonian
, respectively.Hamiltonian
Zero-dimensional Hamiltonian
Let us start with the
g::GreenFunction
of a zero-dimensionalh::Hamiltonian
, with matrixm = bloch(h)
. The goal is to be able to obtain theg(ω)
projected matrix (alias forg(ω, celldst, cellsrc)
with zerocelldst
andcellsrc
). This can be done in a number of ways. I can think of the following:P
:g(ω) = P * inv(ω - m) * P'
g(ω)[:,i] = P * ((ω - m) \ δ_i)
whereδ_i
is a vector with zero in all elements except a 1 in thei
-th. This can be done with e.g. SparseArrays, Pardiso or Mumpsm
and then dog(ω)=Σ_i Pψᵢψᵢ⁺P'/(ω-ε_i))
μ_n
ofm
(they will be matrices in the projected space) and then dog(ω) = ∑_n μ_n G_n(ω)
for the appropriate Chebyshev transformsG_n(ω)
.The preferred solution in many codes, as far as I know, seems to be to use Pardiso (equus) or Mumps (kwant) to compute specific elements of the inverse. Definitely the worse is computing the full inverse and then projecting. In either case we need to do the full calculation again for any
ω
(as far as I understand). There is no way to reuse the factorization ofω - m
for differentω
s.In contrast, a full diagonalization yields
g(ω)
for all ω's, but it is impossibly slow for large systems (does not exploit sparsity of the problem). KPM also yields all ω's in one go, and is very efficient, but its accuracy depends on the expansion order.The ideal would be to support as many methods as possible. We would need to set up different
GreenFunctionSolver
s, each with its relevant information, that is passed using the solver keyword. The we defineFor example, we could have the trivial solver written as
(Recall that type parameters are
Hamiltonian{E,L,T,...}
.)Similarly for other methods, storing in each case whatever data is required to produce
g(ω)
by callingsolver(ω)
.Unbounded
L
-dimensional HamiltonianIn this case we have less options to draw from, since we need to somehow integrate over momenta or otherwise incorporate the infinite character of the Hamiltonian. As mentioned in Workflow, the Green function projected matrix could be computed with a syntax
g(ω, celldst, cellsrc)
.I can think of the following methods
Bandstructure
, which is properly split into smoothly connected subbands. Then sum the contribution of each simplex in each subband to yieldg(ω, celldst, cellsrc)
. This is analogous to the full-spectrum approach above. It is unfeasible in the case of very large unit cells, however.μ_n
projected on pairs of cells up to a cutoff, and keep it in the form of an unflattenedL
-dimensional tensor indcell = celldst - cellsrc
space or similar. There is a limit to the range ofdcell
that can be computed from these momenta (given by the expansion order), but likewise there is a limit (set by the momentum-sampling resolution) for which theBandstructure
approach can give reliable results.g(ω, dcell)
using Bloch theorem?In view of the above, we could perhaps concentrate on only two generic solvers to start with: exact-diagonalization (small unit cells) and KPM (arbitrary unit cells)
Semibounded Hamiltonians
This case involves the method of images relative to the boundary. The
g
should then be in generalg(ω, celldst, cellsrc) = g´(ω, celldst, cellsrc) - g´(ω, celldst, cellsrc´) + ...
, whereg´
are unboundedGreenFunction
s andcellsrc´
is the specular image ofcellsrc
on a given boundary.EffectiveHamiltonian
As discussed in pablosanjose/Elsa.jl#50, we'll probably end up implementing coupled systems in terms of
EffectiveHamiltonian
s, i.e. Hamiltonians with additional self-energies, computed from theg
's of attached hamiltonians. The question then arises as to how one should computeG
(coupled Green function) from theEffectiveHamiltonian
.Unbounded EffectiveHamiltonian
The core of the problem is to solve Dyson's equation. The coupled Green function reads, symbolically,
where
h
should be thought of as a block matrix in cell space, with intracell matrices in the diagonal, and Bloch harmonics in the off-diagonals.Σ(ω)
is the total self energy, restricted to a given set of cells, and to sites within theP
subspace.P
is the site projector.As the above is the inverse of an infinite matrix in cell space it is unclear how to do this directly. We write an alternative form, using
P'(ω-h)^{-1}P = g(ω)
andΣ(ω) = PΣ(ω)P'
:In general, then, a simplistic algorithm to get
G(ω)
would require that we build theg(ω) * Σ(ω)
within the finite setC_Σ
of cells with non-zero self-energy, invert the finite-size matrix(1 - g(ω) * Σ(ω))
, and multiply byg
that propagates fromC_Σ
to any other cell.Bounded EffectiveHamiltonian
The case of a bounded (0D)
EffectiveHamiltonian
can also be solved as described above. However, it allows a second approach based onsince the inverted matrix is now of finite size. It has the added advantage that the matrix is typically sparse. In this case we can also follow the direct solve approach, using
SparseArrays
,Pardiso
orMumps
:G(ω) = P * ((ω - h - Σ(ω)) \ δ_i)
.It is not clear a priori which method would be preferable. It all depends on how expensive is your method to compute
g(ω)
of the boundedHamiltonian
(which may involve a single calculation for allω
), as opposed to doing a factorization and direct solve ofω - h - Σ(ω)
(which must be repeated for eachω
). The best would be to allow both approaches.