treams.lattice¶
Lattice sums.
Calculates the lattice sums of the forms
and
that arise when translating and summing the spherical and cylindrical solutions of the Helmholtz equation in a periodic arrangement. These sums have a notoriously slow convergence and at least for lattices with a dimension \(d > 1\) it is not advisable to use the direct approach. Fortunately, it is possible to convert them to exponentially convergent series, which are implemented here. For details on the math, see the references below.
The lattice of dimension \(d \leq 3\) (\(d \leq 2\) in the second case) is denoted with \(\Lambda_d\) and consists of all vectors \(\boldsymbol R = \sum_{i=1}^{d} n_i \boldsymbol a_i\) with \(\boldsymbol a_i\) being basis vectors of the lattice and \(n_i \in \mathbb Z\). For \(d = 2\) the lattice is in the z = 0 plane and for \(d = 1\) it is along the z-axis. The vector \(\boldsymbol r\) is arbitrary but for best convergence it should be reduced to the Wigner-Seitz cell of the lattice. The summation excludes the point \(\boldsymbol R + \boldsymbol r = 0\) if it exists, which is indicated by the prime next to the summation sign.
The wave in the lattice is defined by its – possibly complex-valued – wave number \(k\) and the (real) components of the wave vector \(\boldsymbol k_\parallel \in \mathbb R^d\) that are parallel to the lattice.
The expressions include the (spherical) Hankel functions of first kind \(H_m^{(1)}\) (\(h_l^{(1)}\)) and the spherical harmonics \(Y_{lm}\). The angles \(\theta\) and \(\varphi\) are the polar and azimuthal angle, when expressing the points in spherical coordinates. In the first case, the degree is \(l \in \mathbb N_0\) and the order is \(\mathbb Z \ni m \leq l\). In the second case \(m \in \mathbb Z\).
Available functions¶
Accelerated lattice summations¶
|
Fast summation of cylindrical functions on a 1d lattice |
|
Fast summation of cylindrical functions on a 1d lattice with out of lattice shifts |
|
Fast summation of cylindrical functions on a 2d lattice |
|
Fast summation of spherical functions on a 1d lattice |
|
Fast summation of spherical functions on a 1d lattice with out of lattice shifts |
|
Fast summation of spherical functions on a 2d lattice |
|
Fast summation of spherical functions on a 2d lattice with out of lattice shifts |
|
Fast summation of spherical functions on a 3d lattice |
Direct summations¶
The functions are almost only here for benchmarking and comparison.
|
Direct summation of cylindrical functions on a 1d lattice |
|
Direct summation of cylindrical functions on a 1d lattice with out of lattice shifts |
|
Direct summation of cylindrical functions on a 2d lattice |
|
Direct summation of spherical functions on a 1d lattice |
|
Fast summation of spherical functions on a 1d lattice with out of lattice shifts |
|
Direct summation of spherical functions on a 2d lattice |
|
Direct summation of spherical functions on a 2d lattice with out of lattice shifts |
|
Direct summation of spherical functions on a 3d lattice |
Miscellaneous functions¶
|
Calculate the signed volume (area) |
|
All integer points in a d-dimensional cube of sidelength 2n |
|
All integer points on the surface of a d-dimensional cube of sidelength 2n |
|
Diffraction orders in a circle. |
|
Reciprocal vectors in two- and three-dimensional space |
|
Calculate the signed volume (area) |
Cython module¶
Cython versions of lattice functions. |
References