
Dear Cezar, You need to provide the parameters as a dictionary: Imagine you have the onsite potential and the hopping functions as follow: def onsite(site, V, t): return V+2*t def hop(site1, site2, B, S): return exp(1j*B*S) site1, site2 are the usual variables these functions take. V, t, B and S are parameters needed to execute the functions. You need to provide them for the kwant functions as follows: Ex: kwant.wave_function(sys, energy=-1, params=dict(B=3,S=5,V=2,t=1) ) So do not use args anymore. I hope this helps Adel On Sun, Jun 28, 2020 at 1:59 AM Cesar Nuñez <cesarprofis@gmail.com> wrote:
Dear Kwant community
I try to execute from conda-kwant the code for the Haldane model from course "Topology in Condensed Matter: Tying Quantum Knots" on my computer.
When executing the code appears the next issue:
haldane_model.py:162: KwantDeprecationWarning: The 'args' parameter has been deprecated since version 1.4 -- Instead, provide named parameters as a dictionary via 'params'.
mat = sys.hamiltonian_submatrix(args=[par])
I read kwant manual but the change from "args" to "params" modify the definition of others functions and appear other issues.
Maybe it is a silly question but I am stuck.
Thank you and I look forward to your answer. César
-- Abbout Adel