Dear Kwant developers, I am trying to calculate the retarded Green's function for a simple 2D square lattice with two leads. Rather than using the following: G = kwant.greens_function(sys, energy) Gr10=G.submatrix(1,0)
I need to calculate Green's function by Gr = (EI-H-Sigma_L-Sigma_R)^-1. But apparently I coudn't properly construct it in Kwant: Gr2=Np.linalg.inv(energy*Np.identity(W)-H-Sigma_Lr-Sigma_Rr) H = sys.hamiltonian_submatrix() The problem is dimensions of self energy matrices are WxW, where W is the width sites. However the Hamiltonian matrix I get above has the dimensions of NxN, where N is the number of sites in the scattering region. Do I use the wrong Hamiltonian? How should I implement Gr = (EI-H-Sigma_L-Sigma_R)^-1 correctly in Kwant? Thanks for your time, Ran