Hello Kwant community,

I am trying to use kwant.wave_function(...) on a system with norbs=1. For 
example, if I try to plot the wave function in the Kwant example file 
quantum_wire.py  (which may be found here 
https://kwant-project.org/doc/1.0/_downloads/quantum_wire.py ), I get an error: 
"vector is incorrect shape."

The code to plot the wave function is:
wf = kwant.wave_function(sys,energy=0)(0)
rho = kwant.operator.Density(sys)
density = rho(wf)
kwant.plotter.density(sys, density)

When I do print(np.shape(wf)) I get (0, 300); where 300 is the number of sites 
in this example lattice. Thus it seems like the wave function information might 
be contained in the returned object, but I am not sure how to access it. Please 
let me know if you have any idea on what I am doing incorrectly here.

Thank you,
Derek

Reply via email to