Dear authors, I want to consider the transport in armchair graphene nanoribbons, so I changed the definition of graphene lattice: graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices Now it gives an armchair grphene nanoribbon, but it gives wrong results when I attach the leads. Is there a method to solve my problem? Thanks in advance! Kwok-Long Lee My code is attached: from __future__ import division # so that 1/2 == 0.5, and not 0 from math import pi, sqrt, tanh import kwant # For computing eigenvalues import scipy.sparse.linalg as sla # For plotting from matplotlib import pyplot # Define the graphene lattice graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices def make_system(r=10, w=2.0, pot=0.1): #### Define the scattering region. #### # circular scattering region def circle(pos): x, y = pos return 0<=x<10 and 0<=y<10 #x ** 2 + y ** 2 < r ** 2 sys = kwant.Builder() def potential(site): (x, y) = site.pos d = y * cos_30 + x * sin_30 return pot * tanh(d / w) sys[graphene.shape(circle, (0, 0))] = potential sys[graphene.neighbors()] = -1 def lead0_shape(pos): x, y = pos return 0 <= y < 10 sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) lead0 = kwant.Builder(sym0) lead0[graphene.shape(lead0_shape, (0, 0))] = -pot lead0[graphene.neighbors()] = -1 return sys, lead0 def main(): pot = 0.1 sys, lead0 = make_system(pot=pot) def family_colors(site): return 0 if site.family == a else 1 # Plot the closed system without leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, colorbar=False) sys.attach_lead(lead0) sys.attach_lead(lead0.reversed()) # Then, plot the system with leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, lead_site_lw=0, colorbar=False) # Finalize the system. sys = sys.finalized() # Call the main function if the script gets executed (as opposed to imported). # See <http://docs.python.org/library/__main__.html>. if __name__ == '__main__': main()
Dear Lee Kwok-Long, For the future: please pay more effort when describing a problem. If I understand what you want to achieve correctly, you are trying to create leads with the direction of an armchair ribbon. The lead direction is controlled by the translational symmetry used when creating the lead. Right now you're using sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) so that the lead goes along one of the lattice directions. So if you for example used a lattice vector graphene.vec((-1, 0)), you'd get a lead pointing in one of the armchair directions. Best, Anton On Sat, Apr 25, 2015 at 10:27 AM, Lee Kwok-Long <kwoklonglee@gmail.com> wrote:
Dear authors, I want to consider the transport in armchair graphene nanoribbons, so I changed the definition of graphene lattice: graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices Now it gives an armchair grphene nanoribbon, but it gives wrong results when I attach the leads. Is there a method to solve my problem? Thanks in advance! Kwok-Long Lee My code is attached:
from __future__ import division # so that 1/2 == 0.5, and not 0 from math import pi, sqrt, tanh import kwant
# For computing eigenvalues import scipy.sparse.linalg as sla
# For plotting from matplotlib import pyplot
# Define the graphene lattice graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices def make_system(r=10, w=2.0, pot=0.1): #### Define the scattering region. #### # circular scattering region def circle(pos): x, y = pos return 0<=x<10 and 0<=y<10 #x ** 2 + y ** 2 < r ** 2
sys = kwant.Builder()
def potential(site): (x, y) = site.pos d = y * cos_30 + x * sin_30 return pot * tanh(d / w)
sys[graphene.shape(circle, (0, 0))] = potential sys[graphene.neighbors()] = -1
def lead0_shape(pos): x, y = pos return 0 <= y < 10
sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) lead0 = kwant.Builder(sym0) lead0[graphene.shape(lead0_shape, (0, 0))] = -pot lead0[graphene.neighbors()] = -1
return sys, lead0
def main(): pot = 0.1 sys, lead0 = make_system(pot=pot) def family_colors(site): return 0 if site.family == a else 1
# Plot the closed system without leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, colorbar=False)
sys.attach_lead(lead0) sys.attach_lead(lead0.reversed())
# Then, plot the system with leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, lead_site_lw=0, colorbar=False)
# Finalize the system. sys = sys.finalized()
# Call the main function if the script gets executed (as opposed to imported). # See <http://docs.python.org/library/__main__.html>. if __name__ == '__main__': main()
Dear Anton, Thanks for your reminding.Yes, I am trying to create leads with the direction of an armchair ribbon. I have rotated the "graphene lattice" in the tutorial, but now I do not know how to consider the symmetry of leads. I have read the "Symmetry and leads" by David Abergel <http://search.gmane.org/?author=David+Abergel&sort=date> in the discussion page, it seems the symmetry of leads for my situation is difficult for me. Could you give me an example? Actually, I do not know if we can create a armchair nanoribbon (leads with armchair ribbon) like this. Best wishes, Kwok-Long Lee On Sat, Apr 25, 2015 at 7:12 PM, Anton Akhmerov <anton.akhmerov@gmail.com> wrote:
Dear Lee Kwok-Long,
For the future: please pay more effort when describing a problem. If I understand what you want to achieve correctly, you are trying to create leads with the direction of an armchair ribbon. The lead direction is controlled by the translational symmetry used when creating the lead. Right now you're using sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) so that the lead goes along one of the lattice directions. So if you for example used a lattice vector graphene.vec((-1, 0)), you'd get a lead pointing in one of the armchair directions.
Best, Anton
On Sat, Apr 25, 2015 at 10:27 AM, Lee Kwok-Long <kwoklonglee@gmail.com> wrote:
Dear authors, I want to consider the transport in armchair graphene nanoribbons, so I changed the definition of graphene lattice: graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices Now it gives an armchair grphene nanoribbon, but it gives wrong results when I attach the leads. Is there a method to solve my problem? Thanks in advance! Kwok-Long Lee My code is attached:
from __future__ import division # so that 1/2 == 0.5, and not 0 from math import pi, sqrt, tanh import kwant
# For computing eigenvalues import scipy.sparse.linalg as sla
# For plotting from matplotlib import pyplot
# Define the graphene lattice graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices def make_system(r=10, w=2.0, pot=0.1): #### Define the scattering region. #### # circular scattering region def circle(pos): x, y = pos return 0<=x<10 and 0<=y<10 #x ** 2 + y ** 2 < r ** 2
sys = kwant.Builder()
def potential(site): (x, y) = site.pos d = y * cos_30 + x * sin_30 return pot * tanh(d / w)
sys[graphene.shape(circle, (0, 0))] = potential sys[graphene.neighbors()] = -1
def lead0_shape(pos): x, y = pos return 0 <= y < 10
sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) lead0 = kwant.Builder(sym0) lead0[graphene.shape(lead0_shape, (0, 0))] = -pot lead0[graphene.neighbors()] = -1
return sys, lead0
def main(): pot = 0.1 sys, lead0 = make_system(pot=pot) def family_colors(site): return 0 if site.family == a else 1
# Plot the closed system without leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1,
colorbar=False) > > sys.attach_lead(lead0) > sys.attach_lead(lead0.reversed()) > > # Then, plot the system with leads. > kwant.plot(sys, site_color=family_colors, site_lw=0.1, > lead_site_lw=0, colorbar=False) > > # Finalize the system. > sys = sys.finalized() > > # Call the main function if the script gets executed (as opposed to > imported). > # See <http://docs.python.org/library/__main__.html>. > if __name__ == '__main__': > main() >
Hi, You can compare with the code by Virginia dal Lago: nbviewer.ipython.org/urls/dl.dropbox.com/s/fbfa3uu57jutxnd/Assignment_Week3.ipynb?dl=0 If you scroll down to the plot of a graphene Hall bar, you'll see that the vertical leads are armchair. Best, Anton On Sat, Apr 25, 2015 at 3:04 PM, Lee Kwok-Long <kwoklonglee@gmail.com> wrote:
Dear Anton, Thanks for your reminding.Yes, I am trying to create leads with the direction of an armchair ribbon. I have rotated the "graphene lattice" in the tutorial, but now I do not know how to consider the symmetry of leads. I have read the "Symmetry and leads" by David Abergel in the discussion page, it seems the symmetry of leads for my situation is difficult for me. Could you give me an example? Actually, I do not know if we can create a armchair nanoribbon (leads with armchair ribbon) like this. Best wishes, Kwok-Long Lee
On Sat, Apr 25, 2015 at 7:12 PM, Anton Akhmerov <anton.akhmerov@gmail.com> wrote:
Dear Lee Kwok-Long,
For the future: please pay more effort when describing a problem. If I understand what you want to achieve correctly, you are trying to create leads with the direction of an armchair ribbon. The lead direction is controlled by the translational symmetry used when creating the lead. Right now you're using sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) so that the lead goes along one of the lattice directions. So if you for example used a lattice vector graphene.vec((-1, 0)), you'd get a lead pointing in one of the armchair directions.
Best, Anton
On Sat, Apr 25, 2015 at 10:27 AM, Lee Kwok-Long <kwoklonglee@gmail.com> wrote:
Dear authors, I want to consider the transport in armchair graphene nanoribbons, so I changed the definition of graphene lattice: graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices Now it gives an armchair grphene nanoribbon, but it gives wrong results when I attach the leads. Is there a method to solve my problem? Thanks in advance! Kwok-Long Lee My code is attached:
from __future__ import division # so that 1/2 == 0.5, and not 0 from math import pi, sqrt, tanh import kwant
# For computing eigenvalues import scipy.sparse.linalg as sla
# For plotting from matplotlib import pyplot
# Define the graphene lattice graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices def make_system(r=10, w=2.0, pot=0.1): #### Define the scattering region. #### # circular scattering region def circle(pos): x, y = pos return 0<=x<10 and 0<=y<10 #x ** 2 + y ** 2 < r ** 2
sys = kwant.Builder()
def potential(site): (x, y) = site.pos d = y * cos_30 + x * sin_30 return pot * tanh(d / w)
sys[graphene.shape(circle, (0, 0))] = potential sys[graphene.neighbors()] = -1
def lead0_shape(pos): x, y = pos return 0 <= y < 10
sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) lead0 = kwant.Builder(sym0) lead0[graphene.shape(lead0_shape, (0, 0))] = -pot lead0[graphene.neighbors()] = -1
return sys, lead0
def main(): pot = 0.1 sys, lead0 = make_system(pot=pot) def family_colors(site): return 0 if site.family == a else 1
# Plot the closed system without leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, colorbar=False)
sys.attach_lead(lead0) sys.attach_lead(lead0.reversed())
# Then, plot the system with leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, lead_site_lw=0, colorbar=False)
# Finalize the system. sys = sys.finalized()
# Call the main function if the script gets executed (as opposed to imported). # See <http://docs.python.org/library/__main__.html>. if __name__ == '__main__': main()
Dear Anton, Thanks, my problems are solved. Best, Kwok-Long Lee On Sat, Apr 25, 2015 at 9:19 PM, Anton Akhmerov <anton.akhmerov@gmail.com> wrote:
Hi,
You can compare with the code by Virginia dal Lago:
nbviewer.ipython.org/urls/dl.dropbox.com/s/fbfa3uu57jutxnd/Assignment_Week3.ipynb?dl=0
If you scroll down to the plot of a graphene Hall bar, you'll see that the vertical leads are armchair.
Best, Anton
Dear Anton, Thanks for your reminding.Yes, I am trying to create leads with the direction of an armchair ribbon. I have rotated the "graphene lattice" in the tutorial, but now I do not know how to consider the symmetry of leads. I have read the "Symmetry and leads" by David Abergel in the discussion
On Sat, Apr 25, 2015 at 3:04 PM, Lee Kwok-Long <kwoklonglee@gmail.com> wrote: page,
it seems the symmetry of leads for my situation is difficult for me. Could you give me an example? Actually, I do not know if we can create a armchair nanoribbon (leads with armchair ribbon) like this. Best wishes, Kwok-Long Lee
On Sat, Apr 25, 2015 at 7:12 PM, Anton Akhmerov < anton.akhmerov@gmail.com> wrote:
Dear Lee Kwok-Long,
For the future: please pay more effort when describing a problem. If I understand what you want to achieve correctly, you are trying to create leads with the direction of an armchair ribbon. The lead direction is controlled by the translational symmetry used when creating the lead. Right now you're using sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) so that the lead goes along one of the lattice directions. So if you for example used a lattice vector graphene.vec((-1, 0)), you'd get a lead pointing in one of the armchair directions.
Best, Anton
On Sat, Apr 25, 2015 at 10:27 AM, Lee Kwok-Long <kwoklonglee@gmail.com> wrote:
Dear authors, I want to consider the transport in armchair graphene nanoribbons, so
I
changed the definition of graphene lattice: graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices Now it gives an armchair grphene nanoribbon, but it gives wrong results when I attach the leads. Is there a method to solve my problem? Thanks in advance! Kwok-Long Lee My code is attached:
from __future__ import division # so that 1/2 == 0.5, and not 0 from math import pi, sqrt, tanh import kwant
# For computing eigenvalues import scipy.sparse.linalg as sla
# For plotting from matplotlib import pyplot
# Define the graphene lattice graphene = kwant.lattice.general([(sqrt(3)/2, 1/2), (0, 1)], [(0, 0), (1 / (2*sqrt(3)),1/2)]) a, b = graphene.sublattices def make_system(r=10, w=2.0, pot=0.1): #### Define the scattering region. #### # circular scattering region def circle(pos): x, y = pos return 0<=x<10 and 0<=y<10 #x ** 2 + y ** 2 < r ** 2
sys = kwant.Builder()
def potential(site): (x, y) = site.pos d = y * cos_30 + x * sin_30 return pot * tanh(d / w)
sys[graphene.shape(circle, (0, 0))] = potential sys[graphene.neighbors()] = -1
def lead0_shape(pos): x, y = pos return 0 <= y < 10
sym0 = kwant.TranslationalSymmetry(graphene.vec((-1, 0))) lead0 = kwant.Builder(sym0) lead0[graphene.shape(lead0_shape, (0, 0))] = -pot lead0[graphene.neighbors()] = -1
return sys, lead0
def main(): pot = 0.1 sys, lead0 = make_system(pot=pot) def family_colors(site): return 0 if site.family == a else 1
# Plot the closed system without leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, colorbar=False)
sys.attach_lead(lead0) sys.attach_lead(lead0.reversed())
# Then, plot the system with leads. kwant.plot(sys, site_color=family_colors, site_lw=0.1, lead_site_lw=0, colorbar=False)
# Finalize the system. sys = sys.finalized()
# Call the main function if the script gets executed (as opposed to imported). # See <http://docs.python.org/library/__main__.html>. if __name__ == '__main__': main()
participants (2)
-
Anton Akhmerov -
Lee Kwok-Long