Hi Ousmane et al,
I actually want the block of unit cells to be perpendicular to the scattering region as in the Wanted_System.png, attached. Note that it is a representative plot, I didn't produce it via Kwant but I want to attach the red lead to the black region in that direction, not like in Unwanted_System.png, which is also attached and produced via the code:
##########################################
import kwant
import numpy as np
import matplotlib.pyplot as plt
from types import SimpleNamespace
def make_system(a, W, L):
def shape(pos):
(x, y) = pos
return (0 <= y <= W/2 and -x/2 <= y <= (-x + L)/2) # or (-W <= y <= 0 and 0 <= x <= L)
def onsite(site, par):
return 4 * par.t - par.mu
def hopx(par):
return -par.t
def hopy(par):
return -par.t
# lead
lat = kwant.lattice.square(a, norbs=1)
syst = kwant.Builder()
syst[lat.shape(shape, (0, 0))] = onsite
syst[kwant.builder.HoppingKind((1, 0), lat, lat)] = hopx
syst[kwant.builder.HoppingKind((0, 1), lat, lat)] = hopy
lead = kwant.Builder(kwant.TranslationalSymmetry((-a, -2*a)))
def lead_shape(pos):
(x, y) = pos
return -W <= x <= 0
def lead_hopx(site1, site2, par):
return -par.t
def lead_onsite(site, par):
return 4 * par.t - par.mu
lead[lat.shape(lead_shape, (-2*a, -a))] = lead_onsite
lead[kwant.builder.HoppingKind((1, 0), lat, lat)] = lead_hopx
lead[kwant.builder.HoppingKind((0, 1), lat, lat)] = hopy
syst.attach_lead(lead)
syst = syst.finalized()
return syst
syst = make_system(a=5, W=100, L=100)
kwant.plot(syst)
##########################################
I couldn't make the lead rotated in the perpendicular direction to the surface. Is there a way to do it?
Thanks,
Barış