I want to calculate a problem of Hofstadter model, of which the tunneling term Jx is different in different sites.so i set Jx to be an array. for example:
Code: Select all
Lx = 6 Ly = 1 Nmax = 2 t = np.array([1,1.5,1,1.5,1]) Jy = np.array() U = 0 parms1 = dict(bc_MPS='finite',filling=(1,1),Lx=Lx,Ly=Ly,Nmax=Nmax,Jx=t,Jy=Jy,U=U,verbose=False) M = HofstadterBosons(parms1)
ValueError: don't know how to cast `a` to required dimensions.emerge. I check the .add_coupling method, parameter J in add_coupling can be an array, and the an array of t in BoseHubbardModel works too. So what should i do to solve the problem?