Hi, > Thank you Joseph for the highlight. It make sens since the tests on a > square lattice seemed working fine. > > I checked the 'plot_2d_bands' function but could not identify the > transformation you were mentioning. Could you help me in this please?
It requires a bit of reading but we can extract the following snippets from 'wraparound' (I have reworded some comments to make sense without the surrounding context of the 'wraparound' module): # calculate the reciprocal symmetry vectors: these # are the columns of 'A' B = np.array(symmetry.periods).T A = B.dot(np.linalg.inv(B.T.dot(B))) ... # transforms a momentum in the basis (kx, ky) to the basis of # reciprocal symmetry vectors def momentum_to_lattice(k): k, residuals = scipy.linalg.lstsq(A, k)[:2] if np.any(abs(residuals) > 1e-7): raise RuntimeError("Requested momentum doesn't correspond" " to any lattice momentum.") return k We could then use 'momentum_to_lattice' like so: syst = make_wrapped_around_syst() H_k(kx, ky): k = (kx, ky) k_prime = momentum_to_lattice(k) return syst.hamiltonian_submatrix(args=k_prime) Does this help? > Just to check my understanding for this module, could you tell me if I am > right: > 1) one can plot the system sys (before wraping) > 2) check the extra-cell hoppings > 3) take them off and add terms of the form -t exp(i k .Vj) for the > corresponding intra-cell hopping (Vj is the vector of the eliminated > hopping) > with this, we obtain the Hamiltonian of the wrapped system > > am I correct ? Yes, in addition to the caveat that inter-cell hoppings between a site and its image under the symmetry will correspond to *onsite* terms in the wrapped around system (imagine a simple chain of sites with nearest-neighbor hoppings). Happy Kwanting, Joe
signature.asc
Description: PGP signature