## Calculate eigenstates for every k point in the MBZ k_points = bandcalc.generate_monkhorst_pack_set(rec_m, 30).astype(np.float32) hamiltonian = bandcalc.calc_hamiltonian(rec_moire_lattice, potential_matrix, mass) ## Calculate MBZ and choose some K-points for the k-path vor_m = Voronoi(rec_moire_lattice) sorted_vertices = np.array( sorted(vor_m.vertices, key=lambda x: np.abs(x.view(complex))))[:6] sorted_vertices = np.array( sorted(sorted_vertices, key=lambda x: np.angle(x.view(complex)))) points = np.array([[0, 0], sorted_vertices[0], sorted_vertices[1], sorted_vertices[3]]) k_names = [r"$\gamma$", r"$\kappa'$", r"$\kappa''$", r"$\kappa$"] path = bandcalc.generate_k_path(points, N) ## Calculate bandstructure bandstructure, prefix = bandcalc.get_unit_prefix( bandcalc.calc_bandstructure(path, hamiltonian)) sorted_bandstructure = np.sort(bandstructure) fig, ax = plt.subplots(nrows=7, ncols=2, figsize=(7, 20)) for i in range(7): ## Calculate the wannier function R = 1 / 3 * (moire_lattice[5] + moire_lattice[3] + moire_lattice[6]).astype(np.float32) r = 5 * bandcalc.generate_monkhorst_pack_set(m, 80) wannier_function = bandcalc.calc_wannier_function_gpu(hamiltonian,
moire_lattice = bc.generate_lattice_by_shell(m, shells) # Moire potential coefficients Vj = np.array([V if i%2 else np.conjugate(V) for i in range(1, 7)]) potential_matrix = bc.calc_potential_matrix_from_coeffs(rec_moire_lattice, Vj) ## Calculate MBZ and choose some K-points for the k-path vor_m = Voronoi(rec_moire_lattice) sorted_vertices = np.array(sorted(vor_m.vertices, key=lambda x: np.abs(x.view(complex))))[:6] sorted_vertices = np.array(sorted(sorted_vertices, key=lambda x: np.angle(x.view(complex)))) points = np.array([ [0, 0], sorted_vertices[0], sorted_vertices[1], sorted_vertices[3]]) path = bc.generate_k_path(points, 1000) k_names = [r"$\gamma$", r"$\kappa'$", r"$\kappa''$", r"$\kappa$"] ## Calculate the band structure # The bandstructure is slightly different from the bandstructure in the # original paper, but that is most likely just a small difference in # some parameters, like the lattice constants hamiltonian = bc.calc_hamiltonian(rec_moire_lattice, potential_matrix, mass) bandstructure = bc.calc_bandstructure(path, hamiltonian) ## Fit the Hubbard (Tight Binding) Hamiltonian # Construct function number_nearest_neighbours = 2 triangulation = Delaunay(moire_lattice) zero_vec_ind = bc.find_vector_index(moire_lattice, [0, 0]) nn = np.vstack([moire_lattice[bc.find_k_order_delaunay_neighbours(zero_vec_ind, triangulation, k,