I have a periodic lattice, and I would like to associate some phase parameters connecting to the neighbors that can be thought of as a hopping parameter.
Now the choice of these phase parameters is not completely arbitrary. The question is all about the choice of these parameters for a particular lattice.
I illustrate my point with an example. Let us consider for simplicity a square lattice with 25 sites, as shown below.
The above lattice can also be thought a graph where the edges connect neighboring nodes. The condition for the phase parameters can be seen by choosing a plaquette (or face of a graph). Let us consider the plaquette formed by lattice sites 1
, 2
, 9
, 8
. Then we associate a parameter to the links (or edges). If a particle hop (or goes) from 1
to 2
, it is $b$, if it goes from 2
to 9
, it is $c$, if it goes from 9
to 8
, it is $d$ and if it goes from 8
back to 1
, it is $a$. Then these phase parameters should add up to a value let us say $\alpha$, i.e. $\alpha = b + c + d + a $. Most importantly, the direction (or orientation) of the particle hopping is very crucial. If we go from, let us say, 1
to 8
, then the phase parameter is $-a$, and so on so forth. This whole idea of orientation is essentially illustrated in the below figure, where we consider clockwise orientation.
Now the system has periodic boundary conditions, which are shown by the colored boundaries. The same color corresponds to the same boundary. Thus this phase parameter choice should still be respected, as shown for plaquette 4-5-16-15
and 7-8-23-22
.
Coding part (my logic):
I have a matrix $M_{hop}$ that generates the above lattice or any lattice of size $N$, where $N$ is the number of nodes or lattice sites. In the above case, it is 25. Then $M_{hop}$ is $N\times N$.
Then, I can find all the plaquettes or faces of the periodic lattices using
FindCycles
.Orienting all the cycles (clockwise in the above case) in such a way that the above-discussed condition is met.
Then we have set equations $=$ the number of plaquettes in the lattice. They can be solved using
FindInstance
, since many possible solution might exist, so one is fine. In the above case, these equations were $\alpha = b + c + d + a $, $\alpha = e + f + g - a $, $\alpha = h + i + j - g $, $\alpha = k + l + m - i $, so on so forth. Thus, addition of all parameters inside each plaquette in right orientation should add to $\alpha$.Then, I will have a new $M_{hop}$, which is a function of only $\alpha$, no more any parameters.
My MWE:
mhop={{0, 1, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0}, {1, 0, 1, 0, 0, 0,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 0, 0, 0, 0, 1, 0,
0}, {0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0,
1, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1,
0, 0, 1, 0, 0, 0, 0}, {0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0,
0, 1, 0, 1, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0,
0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 1, 0, 0,
1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1}, {0, 0, 0,
0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 1, 0,
0}, {0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0,
1, 0, 1, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0,
0, 0, 0, 0, 1, 0, 1}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0,
0, 0, 0, 0, 0, 1, 0, 0, 1, 0}};
FindCycle[mhop,{4},All]
I have no idea how to take into account the orientation that will be general, that means for nay kind lattice with any number of sides with any lattice numbering. My guess is to use ConnectedComponets
mostly used in graph stuffs.
mhop
is an adjacency matrix? also, will you ever have non-grid-like lattices? if not, @Teabelly 's implicitly-mentioned matrix encoding, e.g.mhop = {{17, 16, 15, ...}, ...}
might offer speedups. (periodicity can be achieved without too much fuss.) $\endgroup$FindCycle
doesn't know "which orientation" to find the plaquette in. That is, if you naively try to turn one of the resulting cycles into an equation, you don't know whether the corresponding sum should be equal to $\alpha$ or $-\alpha$. I think you might need a different data structure that implicitly encodes orientation, or a way of determining the orientation of each cycle. So, this depends on whether you can stick to grid-like lattices or need more generality! $\endgroup$