Dear Sir,
I am a PhD student of Hong Kong University of Science and Technology. I
want to use KWANT to caculate Hall resistance of a Hall bar structure.We
can get the conductance between 6 electrodes, but how to get hall
resistance? Can you give me some help? Thank you very much.
Best Regards,
Zhang Bing

Dear all,
I am using Kwant to study a system with both spins and electron and hole,
so the hopping matrix is 4X4. Now I want to know how to separate the spins,
electron and hole. I study this through the "2.6. Superconductors: orbital
degrees of freedom, conservation laws and symmetries"
smatrix = kwant.smatrix(syst, energy)
data.append(smatrix.submatrix((0, 0), (0, 0)).shape[0]
-smatrix.transmission((0, 0), (0, 0)) +smatrix.transmission((0, 1), (0, 0)))
I do not find more information about this for kwant.
For my system, if I have 3 leads, and the hopping and onsite energy is set
in this order:
(e↑,0,0,0)- spin up electron,first row of the 4X4matrix
(0,e↓,0,0)- spin down electron,second row of the 4X4matrix
(0,0, h↑ ,0)- spin up hole,third row of the 4X4matrix
(0,0, 0, h ↓ )- spin down hole,fourth row of the 4X4matrix
I want to obtain the transmissions from 0 →2.
smatrix = kwant.smatrix(syst, energy)
The transmission from h↑ to e↑ is: smatrix.transmission((2, 1), (0, 2))
The transmission from h ↓ to e↑ is: smatrix.transmission((2, 1), (0, 3))
Is my understanding correct?
Thanks very much in advance!
Hosein Khani

Dear all,
I find in the discussion list that we can use kwant.plot to plot the
hopping strength,
def hopping_strength(site1, site2):
return sys.hamiltonian(site1, site2)
kwant.plot(sys, hop_lw=hopping_strength)
Can we plot the onsite energy of the system similarly?
Regards
Khani Hosein

Hello to all
Recently I installed tkwant using conda on Windows 10.
When I try to run the program, I get the following error:
from mpi4py import MPI
ImportError: DLL load failed: The specified module could not be found.
However, I downloaded the "mpi.py" file from Github again and put it in
the tkwant folder, But this error still exists.
How can I solve this problem?
Thanks
Javad Tavakkoli

Dear all,
i used a slightly modified "discretize.py" code of
https://kwant-project.org/doc/1/tutorial/discretize (see attached file)
and added the term
""" + kappa * kron(sigma_z,sigma_0) """
to the hamiltonian (splitting up the different spins). When checking the
unitarity of the scattering matrix at energy=0 by applying the function
"check_unitarity(matrix)" for
kappa=0 and kappa=10**(-9) the unitarity-error is increasing from order
10**(-13) to 10**(-6) !
Why is the error of $ S^\dagger S$ getting so high?
Thanks in advance!
Andreas Bereczuk

Dear all,
I want to use the code in the example to calculate the conductivity,but I
found that the results are not accurate. I want to increase the accuracy or
zoom in a small energy scale to increase the accuracy.
The code is:
lat, fsyst = make_syst_topo()
where = lambda s: np.linalg.norm(s.pos) < 1
s_factory = kwant.kpm.LocalVectors(fsyst, where)
cond_xy = kwant.kpm.conductivity(fsyst, alpha='x', beta='y', mean=True,
num_vectors=None, vector_factory=s_factory)
energies = cond_xx.energies
cond_array_xy = np.array([cond_xy(e, temperature=0.01) for e in energies])
Now, what I know is adding energy_resolution to cond_xy, for example
cond_xy = kwant.kpm.conductivity(fsyst, alpha='x', beta='y', mean=True,
num_vectors=None,energy_resolution=0.01
vector_factory=s_factory)
My question is:
1 Is there any other way to increase the accuracy?
2 Can we zoom in a smaller energy scale to increase the accuracy?
3 What is the units for temperature=0.01? Is it 0.01t (t is the nearest
hopping)?
Thanks in advance!
Khani Hosein

Dear all,
I want to discretize the continuous Hamiltonian using
kwant.continuum.discretize, but I have problems in inputing my hamiltonian.
In the example, we only have elements in
H(0,0),H(0,1),H(1,0),H(1,1),H(2,2),H(2,3),H(3,2),H(3,3), but in my system
(for example, bilayer graphene) I have elements in
H(0,2),H(1,3),H(2,0),H(3,1). How to input my hamiltonian into it.
For example,
hamiltonian = """
+ M * kron(sigma_z, sigma_0)
+A * k_x * kron(sigma_0, sigma_x)
+A * k_y * kron(sigma_0, sigma_y)+ Tc*[[0, 0, 1, 0], [0, 0, 0,
1],[1, 0, 0, 0] ],[0, 1, 0, 0]]
"""
The term Tc*[[0, 0, 1, 0], [0, 0, 0, 1],[1, 0, 0, 0] ],[0, 1, 0, 0]] will
cause errors.
Thank you very much.
Khani Hosein