Consider the four lattice polygons below. Each shape is over the coordinates. lattice polygons

If reflected or flipped on the major axes and diagonals, these four polygons remain distinct. However, this is the same polygon each time. The last three are rotations of the first, with the rotation matrix built from the arctan of different pythagorean triple based fractions: -12/5, 63/16, and 4/3.

One way to determine if a lattice polygon has a different rotational embedding is to apply all of the arctan pythagorean fraction rotation matrices and to see if the points stay on the lattice. Is there an easier method?

  • 1
    $\begingroup$ Cannot be only rotations: third polygon has a different chirality than the others. $\endgroup$ Jun 15, 2017 at 6:49
  • $\begingroup$ Correct about chirality, there is also a reflection in there. I'm looking for canonical forms of lattice polygons. $\endgroup$
    – Ed Pegg
    Jun 15, 2017 at 14:19

3 Answers 3


To find all polygons having the same rotational embedding as a given polygon $p$, let $r$ be the length of the shortest side of $p$ and consider all lattice points $P$ lying on the circle of center $O=(0,0)$ and radius $r$. Segments $OP$ are all the possible rotations of the shortest side of $p$: you must then check if the same rotations, applied to the other vertices, carry them to lattice points.

In diagram below I applied this technique to your first polygon (blue) with some rotated polygons shaded in gray: in this case we are lucky and all possible rotated polygons are permitted. Notice that you need only check rotations up to 90°.

enter image description here

  • $\begingroup$ I edited my answer: now it may be closer to what you are looking for. $\endgroup$ Jun 16, 2017 at 10:36

You could encode a polygon by the data $(\ell_1, \cos\theta_1, \ell_2, \cos\theta_2, \ldots,\ell_n,\cos\theta_n)$ where $\ell_i$ is the side-length of the $i$-th side, and $\theta_i$ is the (unsigned) angle between the $i$-th and $(i+1)$-th sides.

The lengths and cosines of angles are computable from the data of the lattic coordinates. For example, in your example we would have the data $$(\sqrt{65},-\frac1{\sqrt{2}},\sqrt{130},0, \sqrt{130}, \frac1{\sqrt{10}}, \sqrt{325}, \frac1{\sqrt{5}}).$$

Two convex* polygons are congruent if and only if this associated data is the same up to a cyclic shift or reversal.

*If the polygons are not convex, this doesn't necessarily work. But in those cases it may be clear from just eyeballing the shapes.


One way to check for congruence is to compute the six squared lengths between vertices for each quadrilateral. If two quadrilateral have the same set of lengths they are congruent.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .