Is it possible that the Kwant-interface can deal with Polyatomic
tron1989 opened this issue · comments
Hi Dominik,
I just found that your Tbmodels code group all the orbitals into one site when interfacing with kwant.
Is there a way to deal with Polyatomic case that simulate the real system which has different sites and different orbitals on each site?
Thanks
Xiangru
Hi Xiangru,
If you have a model with multiple orbitals that share the same position, these should be grouped into a single site. So for example, if your .pos
is [[0, 0, 0], [0, 0, 0], [0.5, 0.5, 0.5]]
, the first sub-lattice should contain the first two orbitals, while the second sub-lattice contains the last orbital.
Is this what you were looking for, or do you need something different? In general, the kwant
interface is a bit limited as it is.
Cheers,
Dominik
Hi Dominik,
Thanks for your reply.
I was thinking reproducing band structures firstly by Kwant from the wannier90 output files which there are more than one site (Wannier postion) and different number of orbitals on each site.
I checked TBmodels, I guessed it group all the orbitals into one site, and one site per unit cell. Because, it seems that there are no postion information provided in wannier90_hr.dat file.
Thanks
Xiangru
Hi Dominik,
Sorry, I am idiot.
I just found that TBmodels can read Wannier centers, and it seems that it takes every wannier position as a sublattice.
Xiangru
it takes every wannier position as a sublattice.
In general, yes - it will only group different orbitals into the same sublattice if they have the same position. If that's undesired, you can modify the pos
attribute manually before creating the kwant model.
Hi Dominik,
I have tested a case with 32 orbitals (considering SOC) on a laptop, it took much long time to run
model.add_hoppings_kwant(kwant_sys)
I had to kill it. Is there something wrong?
Because when only read wannier90_hr.dat file, it is easy to run.
Thanks
Xiangru
Well, it's to be expected that it is slower than having them all at the same position. If they are all at the same site, it can set each 32x32 matrix of hoppings in a single step. When they are separate sites, each hopping needs to be set individually.
It will depend also on the range of your hoppings (how many non-zero hoppings there are), and the size of your kwant shape (i.e., if you are constructing a large finite structure that will be expensive).
Maybe a good middle ground is to group Wannier centers according to the atom that is nearest to them: This can be done automatically by using pos_kind='nearest_atom'
when reading the Wannier90 output: https://tbmodels.greschd.ch/en/latest/reference.html#tbmodels.Model.from_wannier_files
Hi Dominik,
Thank you very much. I have tested it successfully.
You code is really helpful. It will save me a lot of time as I planned to write by myself.
Best
Xiangru
Good to hear, and you're very welcome!
I'll close this issue then, but feel free to open another one if you have more questions.
Dominik, FYI Kwant now added vectorized setting of hoppings and onsites, so perhaps it can be used to speed up things.