## Triangular Lattice

Discussing the best way to implement feature X
bart
Posts: 26
Joined: 23 Jan 2019, 09:35

### Triangular Lattice

It would be useful to have an implementation for a triangular lattice integrated into the main code (tenpy.models.lattice), since it comes up so frequently. Many thanks
Johannes
Posts: 442
Joined: 21 Jul 2018, 12:52
Location: TU Munich

### Re: Triangular Lattice

Agreed.
The Triangular lattice is basically just a simple square lattice with one of the basis vectors rotated by 30 degrees towards the other. I'd suggest to use

Code: Select all

basis = np.array([[0.5 *np.sqrt(3), 0.5], # first basis vector
[0., 1.]]) # second basis vector: y-direction

If you quickly write down the (next-)(next-)nearest neighbors, I'll copy over the code from the tenpy.models.lattice.Square lattice and make the figure.
bart
Posts: 26
Joined: 23 Jan 2019, 09:35

### Re: Triangular Lattice

Using this basis, for a point at the origin:

There are 6 NN at a distance 1.
There are 6 nNN at a distance sqrt(3).
There are 6 nnNN at a distance 2.

Code: Select all

NN = {1/2 {Sqrt[3], 1}, {0, 1}, -(1/2) {Sqrt[3], 1}, -{0, 1}, 1/2 {Sqrt[3], -1}, 1/2 {-Sqrt[3], 1}};
nNN = {{Sqrt[3], 0}, {-Sqrt[3], 0}, 1/2 {Sqrt[3], 3}, -(1/2) {Sqrt[3], 3}, 1/2 {-Sqrt[3], 3}, 1/2 {Sqrt[3], -3}};
nnNN = {{0, 2}, {0, -2}, {Sqrt[3], 1}, -{Sqrt[3], 1}, {-Sqrt[3], 1}, {Sqrt[3], -1}};
Checked with Mathematica. Many thanks
Johannes
Posts: 442
Joined: 21 Jul 2018, 12:52
Location: TU Munich

### Re: Triangular Lattice

Implemented
bart
Posts: 26
Joined: 23 Jan 2019, 09:35

### Re: Triangular Lattice

Thank you very much!