
Hi there, I tried the functions ldos.cunsum() and ldos.cumprod() and succeeded in obtaining the plot;but I do not know what the plots told me. Anyone can help ?Below is the codes for the plot data1 = []energies = np.linspace(1,4,101)for energy in energies: ldos = kwant.ldos(sys,energy) data1.append(ldos.cumsum())pyplot.figure()pyplot.plot(energies, data1)pyplot.xlabel("energy [t]")pyplot.ylabel("ldos")pyplot.show() and for the other plot I just changed the function ldos.cumsum() with ldos.cumprod(). Thank you in advance. Kind Regards, Dedi

Hi Dedi,
Hi there, I tried the functions ldos.cunsum() and ldos.cumprod() and succeeded in obtaining the plot;but I do not know what the plots told me. Anyone can help ?
Can you try and give some context as to what you are doing? It will be extremely difficult to help you if we do not know what it is that you are trying to do.
Was there a previous message in this thread that I missed?
Below is the codes for the plot data1 = []energies = np.linspace(1,4,101)for energy in energies: ldos = kwant.ldos(sys,energy) data1.append(ldos.cumsum())pyplot.figure()pyplot.plot(energies, data1)pyplot.xlabel("energy [t]")pyplot.ylabel("ldos")pyplot.show() and for the other plot I just changed the function ldos.cumsum() with ldos.cumprod().
Could you please submit the code either: in the body of the email but properly formatted (so that it can be easily cut/pasted and be a valid Python program), or put it as an attachment.
Thanks,
Joe

Me again,
Below is the codes for the plot data1 = []energies = np.linspace(1,4,101)for energy in energies: ldos = kwant.ldos(sys,energy) data1.append(ldos.cumsum())pyplot.figure()pyplot.plot(energies, data1)pyplot.xlabel("energy [t]")pyplot.ylabel("ldos")pyplot.show() and for the other plot I just changed the function ldos.cumsum() with ldos.cumprod().
Could you please submit the code either: in the body of the email but properly formatted (so that it can be easily cut/pasted and be a valid Python program), or put it as an attachment.
Apologies for this; in my email client the code appeared (as you can see) as a single line, and so was not valid Python. When I looked at your message in the Gmail web interface everything was correctly formatted.
I have a suspicion that this is to do with the fact that the email was composed as a HTML email, and the conversion to raw text was somehow scrambled by you mail user agent.
Sorry about that,
Joe

Dear Joe, I am trying to investigate a graphene using kwant and I would like to see if any defect in the material (e.g. using del sys [a(0,0)] ) could make the material becomes magnetic. Can this transformation be indicated by some changes in DOS ? I enclose the python codes. Regards, Dedi
Date: Tue, 29 Sep 2015 08:32:29 +0200 From: joseph.weston@cea.fr To: setiabudidaya@hotmail.com CC: kwant-discuss@kwant-project.org Subject: Re: [Kwant] ldos.cumsum or ldos.cumprod
Hi Dedi,
Hi there, I tried the functions ldos.cunsum() and ldos.cumprod() and succeeded in obtaining the plot;but I do not know what the plots told me. Anyone can help ?
Can you try and give some context as to what you are doing? It will be extremely difficult to help you if we do not know what it is that you are trying to do.
Was there a previous message in this thread that I missed?
Below is the codes for the plot data1 = []energies = np.linspace(1,4,101)for energy in energies: ldos = kwant.ldos(sys,energy) data1.append(ldos.cumsum())pyplot.figure()pyplot.plot(energies, data1)pyplot.xlabel("energy [t]")pyplot.ylabel("ldos")pyplot.show() and for the other plot I just changed the function ldos.cumsum() with ldos.cumprod().
Could you please submit the code either: in the body of the email but properly formatted (so that it can be easily cut/pasted and be a valid Python program), or put it as an attachment.
Thanks,
Joe

Hi again,
I am trying to investigate a graphene using kwant and I would like to see if any defect in the material (e.g. using del sys [a(0,0)] ) could make the material becomes magnetic. Can this transformation be indicated by some changes in DOS ? I enclose the python codes.
I took a quick look at your notebook, but as far as I can tell you just put a spatially-varying potential on the sites of the ribbon. Given that you don't include spin anywhere in your model, I cannot see how you could ever have a magnetic effects which arise.
Also I am not sure what you are trying to calculate. I do not know what multiplying the density of states on each site together corresponds to physically.
I should probably say as well that we try to keep this mailing list specifically about Kwant, rather than about general physics questions. It seems that your question is more about general physics, than specifically how to do a particular (and well defined) thing in Kwant. I think that you may get more useful responses by posting on a specific physics forum, for example https://physics.stackexchange.com/
Hope that helps,
Joe

Dear Joe, Thank you for your comments. You have greatly encouraged me to learn kwant more; I have never used spin before. And by training, I am a paleomagnetist not a solid state physicist; so, multiplying the ldos just my wild idea. Regards, Dedi
Date: Tue, 29 Sep 2015 13:57:18 +0200 From: joseph.weston@cea.fr To: setiabudidaya@hotmail.com CC: kwant-discuss@kwant-project.org Subject: Re: [Kwant] ldos.cumsum or ldos.cumprod
Hi again,
I am trying to investigate a graphene using kwant and I would like to see if any defect in the material (e.g. using del sys [a(0,0)] ) could make the material becomes magnetic. Can this transformation be indicated by some changes in DOS ? I enclose the python codes.
I took a quick look at your notebook, but as far as I can tell you just put a spatially-varying potential on the sites of the ribbon. Given that you don't include spin anywhere in your model, I cannot see how you could ever have a magnetic effects which arise.
Also I am not sure what you are trying to calculate. I do not know what multiplying the density of states on each site together corresponds to physically.
I should probably say as well that we try to keep this mailing list specifically about Kwant, rather than about general physics questions. It seems that your question is more about general physics, than specifically how to do a particular (and well defined) thing in Kwant. I think that you may get more useful responses by posting on a specific physics forum, for example https://physics.stackexchange.com/
Hope that helps,
Joe
participants (3)
-
Dedi Setiabudidaya
-
Joseph Weston
-
Joseph Weston