Dear Jerry; I guess it might work if you add site family to your symmetry. *your_sym*.add_site_family(*your_latice*.sublattices[0], other_vectors=[*v*]), where v is a tuple and in your case it might be like *v=(-1, 2)* Best wishes, Adel
Le ven. 8 oct. 2021 à 05:37, Jerry xhm <xiaoxiao.zh...@riken.jp> a écrit : > Hello Kwant community, > Given a square lattice Hamiltonian, I am trying to put a rectangular > sample along an oblique direction to the x,y axes of the underlying square > lattice, i.e., the rectangular sides are along new rotated X,Y axes. One > can fix the site at the origin (0,0) in the rotation. I have done this > successfully using commensurate rotation angles in the following code. The > comments in the code explain in detail. The sample looks like this ( > https://www.dropbox.com/s/2rd9bjbd7ataosy/lattice_fig.pdf?dl=0). > > Then I would like to attach leads along the new X-axis (just normally > connect to the rectangular sample that doesn't need adding extra sites). I > put the translation symmetry rotated to X and confine the lead shape in Y. > I expected the lead would just connect to the sample with the interface in > Y direction. However, many extra sites are added and the interface is > rendered in the old y direction, although the lead does extend in X. The > code below attaches only one lead in order to contrast the interface and > the opposite unaffected sample edge. The system looks like this ( > https://www.dropbox.com/s/3wj6r2ws5ev20p5/lattice_fig0.pdf?dl=0). > > So the question is how to attach leads in the expected way. Thanks! >