Dear Luca, If done correctly, both approaches lead to the same answer, but Kwant utilizes the second one. Best regards, Anton Akhmerov On Mon, 29 Jul 2019 at 16:57, Luca Lepori <llepori81@gmail.com> wrote:

Dear Kwant developers,

I write concerning the group velocites of the modes in the leads. In particular, I wonder how Kwant calculates them.

I see two possibilities (leads along x): 1) knowing the dispersion along x, from the usual definition v(kx) = \partial E(kx) / \partial kx; 2) working equivalently in the real space basis, and in particular on a unitary cell of a lead, one can calculate vx also as: vx = <\psi |i [H, \hat{x}] | \psi>, being \psi the wavefunction of the mode and H the Hamiltonian respectively, both defined on the unitary cell of the lead, and \hat{x} the position operator. The second approach can be useful also to estimate the expectation value of the velocities in the direction orthogonal to the leads (say when close boundary conditions are assumed).

Does Kwant utilizes directly one of these two strategies ?

Thank you very much and best regards

L. L.