Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pablo Piskunow
kwant
Commits
f2c8d839
Commit
f2c8d839
authored
Sep 08, 2013
by
Michael Wimmer
Committed by
Christoph Groth
Sep 08, 2013
Browse files
fix a few more typos
parent
f106f961
Changes
4
Hide whitespace changes
Inline
Side-by-side
doc/source/tutorial/tutorial1.rst
View file @
f2c8d839
...
...
@@ -53,6 +53,8 @@ The remainder of this section demonstrates how to realize the discretized
Hamiltonian in Kwant and how to perform transmission calculations. For
simplicity, we choose to work in such units that :math:`t = a = 1`.
.. _tutorial_quantum_wire:
Transport through a quantum wire
................................
...
...
@@ -416,16 +418,16 @@ And one ``main`` function.
Finally, we use the following standard Python construct [#]_ to execute
``main`` if the program is used as a script (i.e. executed as
``python
tutorial1b
.py``):
``python
quantum_wire_revisited
.py``):
.. literalinclude:: quantum_wire_revisited.py
:start-after: #HIDDEN_BEGIN_ypbj
:end-before: #HIDDEN_END_ypbj
If the example, however, is imported inside Python using ``import
tutorial1b``,
``main`` is not executed automatically.
Instead, you can execute it
manually using ``
tutorial1b
.main()``. On the other
hand, you also
have access to the other functions, ``make_system`` and
If the example, however, is imported inside Python using ``import
quantum_wire_revisted as qw``,
``main`` is not executed automatically.
Instead, you can execute it
manually using ``
qw
.main()``. On the other
hand, you also
have access to the other functions, ``make_system`` and
``plot_conductance``, and can thus play with the parameters.
The result of the example should be identical to the previous one.
...
...
doc/source/tutorial/tutorial2.rst
View file @
f2c8d839
...
...
@@ -136,9 +136,9 @@ case of a position-dependent potential:
H = \frac{\hbar^2}{2 m} (\partial_x^2+\partial_y^2) + V(x, y)
The position-dependent potential enters in the onsite energies.
One
possibility would be to again set the onsite matrix elements
of each
lattice point individually (as in tutorial
1a.py
). However,
The position-dependent potential enters in the onsite energies.
One
possibility would be to again set the onsite matrix elements
of each
lattice point individually (as in
:ref:`
tutorial
_quantum_wire`
). However,
changing the potential then implies the need to build up the system again.
Instead, we use a python *function* to define the onsite energies. We
...
...
doc/source/tutorial/tutorial3.rst
View file @
f2c8d839
...
...
@@ -27,11 +27,11 @@ invariant system needed for band structure calculations.
In the previous examples `~kwant.builder.Builder` instances like the one
created above were attached as leads to the ``Builder`` instance of the
scattering region and the latter was finalized. The thus created system
contained implicitly finalized versions of the attached leads.
But now we are
working with a single lead and there is no scattering region.
So we have to
finalize
d
the ``Builder`` of our sole lead explicitly.
contained implicitly finalized versions of the attached leads.
However, now
we are
working with a single lead and there is no scattering region.
Hence, we
have to
finalize the ``Builder`` of our sole lead explicitly.
That finalized lead is then passed to `~kwant.plotter.bands`.
This function
That finalized lead is then passed to `~kwant.plotter.bands`. This function
calculates energies of various bands at a range of momenta and plots the
calculated energies. It is really a convenience function, and if one needs to
do something more profound with the dispersion relation these energies may be
...
...
@@ -65,7 +65,7 @@ In this example, we compute the wave functions of a closed circular quantum dot
and its spectrum as a function of magnetic field (Fock-Darwin spectrum).
To compute the eigenenergies and eigenstates, we will make use of the sparse
linear algebra functionality of `
s
ci
p
y <http://www.scipy.org>`_, which
linear algebra functionality of `
S
ci
P
y <http://www.scipy.org>`_, which
interfaces the ARPACK package:
.. literalinclude:: closed_system.py
...
...
doc/source/tutorial/tutorial4.rst
View file @
f2c8d839
...
...
@@ -84,8 +84,9 @@ The leads are defined almost as before:
Note the method `~kwant.lattice.Polyatomic.vec` used in calculating the
parameter for `~kwant.lattice.TranslationalSymmetry`. The latter expects a
real-space symmetry vector, but for many lattices symmetry vectors are more
easily expressed in the natural coordinate system of the lattice. The ``vec``
method of lattices maps a lattice vector to a real-space vector.
easily expressed in the natural coordinate system of the lattice. The
`~kwant.attices.Polyatomic.vec`-method is thus used to map a lattice vector
to a real-space vector.
Observe also that the translational vectors ``graphene.vec((-1, 0))`` and
``graphene.vec((0, 1))`` are *not* orthogonal any more as they would have been
...
...
@@ -108,10 +109,7 @@ in the following piece of code:
:end-before: #HIDDEN_END_zydk
Here we use in contrast to the previous example a sparse matrix and
the sparse linear algebra functionality of SciPy (this requires
SciPy version >= 0.9.0; since the remaining part of the example does not
depend on this eigenenergy calculation, a ``try``-block simply skips this
calculation if a lower SciPy version is installed.)
the sparse linear algebra functionality of SciPy.
The code for computing the band structure and the conductance is identical
to the previous examples, and needs not be further explained here.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment