# Canonical form of symmetric integer matrix M

Let $M$, $N$ be a symmetric matrix over a ring $R$. $M$ and $N$ are said to be equivalent if there exist an invertible matrix $U$ (over the same ring $R$) such that $N=U M U^T$ ($U^T$ is the transpose of $U$). A question is that what is the simple canonical form of $M$ under such an equivalent relation.

We know that when $R$ is the ring of real numbers, every real symmetric matrix is equivalent to an diagonal matrix with diagonal entries being 1, -1, or 0.

When $R$ is the ring of integers, do we have a similar result?

If there is no nice results, we may assume $M$ to satisfy additional conditions:

(a) $|\det(M)|=1$

(b) There exist a $J$ such that $J^2=1$ and $JMJ^T=-M$.

Thanks!

Edit: I am also interested in finding the simple canonical form of integer symmetric matrices $M$, that satisfy

(a) $|\det(M)|=1$

(b) There exist a $J$ such that $J^2=-1$ and $JMJ^T=-M$.

-
There is not really any canonical form, even for definite matrices, as soon as dimension reaches 4. Could you please indicate some examples in dimension 2 and dimension 4? Your condition (b) requires that $\det M = \det (-M),$ so the dimension is even. –  Will Jagy May 20 '12 at 1:34

It's all in the correct reference. Cassels, Rational Quadratic Forms, chapter 9 "Integral Forms over the Rational Integers," pages 163-164, Examples 9-11. Example 11(i) says that, for "odd" matrices, we can cut down the dimension by 2 and write $y_1^2 - y_2^2 + g(z_1, \ldots , z_{n-2}).$ The determinant of $g$ is still $\pm 1,$ so the only problem is that $g$ may be "even."

Next, if $f$ is "even" the quadratic form can, in fact, be written $2y_1 y_2 + g(z_1, \ldots , z_{n-2}).$

So, all we really need is to show, as in Sylvester's Law of Inertia, that the resulting form $g$ continues to be indefinite. Presumably your condition with $J M J^T = -M$ can do this.

Otherwise, without your $J$ condition, Example 11(vi) says that either $f$ or $-f,$ if "even," is equivalent to a sum of some $2x_j y_j$ terms along with a single $\mathbb E_8$ lattice. CASSELS

I was uneasy about the possible need to mix 2 by 2 blocks of both types, despite Hahn's statement, but $$\left( \begin{array}{cccc} 3 & 4 & 2 & 2 \\\ 2 & 3 & 1 & 2 \\\ 0 & 1 & 1 & 1 \\\ 2 & 3 & 2 & 1 \end{array} \right) \left( \begin{array}{cccc} 1 & 0 & 0 & 0 \\\ 0 & -1 & 0 & 0 \\\ 0 & 0 & 0 & 1 \\\ 0 & 0 & 1 & 0 \end{array} \right) \left( \begin{array}{cccc} 3 & 2 & 0 & 2 \\\ 4 & 3 & 1 & 3 \\\ 2 & 1 & 1 & 2 \\\ 2 & 2 & 1 & 1 \end{array} \right) = \left( \begin{array}{cccc} 1 & 0 & 0 & 0 \\\ 0 & -1 & 0 & 0 \\\ 0 & 0 & 1 & 0 \\\ 0 & 0 & 0 & -1 \end{array} \right)$$

-
Indeed, one needs the right refs (and right term to Google). On page 672 of math.nd.edu/assets/20630/hahntoulouse.pdf: An odd indefinite unimodular quadratic form over Z is equivalent to $M=a_1x_1^2+...+a_nx_n^2$ with $a_i=\pm 1$. An even indefinite unimodular quadratic form is equivalent to $M=2x_1x_2+2x_3x_4+...+E_8+E_8+...$ or $M=2x_1x_2+2x_3x_4+...-E_8-E_8-...$ where $E_8$ is the quadratic form of E8 lattice of the remaining variables. –  Xiao-Gang Wen May 20 '12 at 12:43
With the additional condition $JMJ^T=−M$, we see that the canonical form for even $M$ is the direct sum of $2x_1x_2$, and the canonical form for odd $M$ is the direct sum of $x_1^2−x_2^2$. –  Xiao-Gang Wen May 20 '12 at 12:45
@Xiao-Gang Wen, I think we need to allow for some of both types of 2 by 2 blocks. Given letters $w,x,y,z,$ I think the form $$w^2 - x^2 + 2 y z$$ is not necessarily equivalent to any $$r^2 - s^2 + t^2 - u^2$$ in letters $r,s,t,u.$ This is what I was worried about when I wrote, above, "so the only problem is that $g$ may be even." Anyway, it should not take long to check this one example, now that I know what I am looking at. –  Will Jagy May 20 '12 at 19:24
@Xiao-Gang Wen, On the other hand, the Hahn survey is very nice and the theorem you quote entirely clear. Strange that I do not recognize his name, I guess he does the more algebraic side of this area. The references in his article are just about everything I would recommend for integral forms, outside of Watson and SPLAG. –  Will Jagy May 20 '12 at 19:48

For symplectic unimodular symmetric (or skew) matrices, such a result is shown in Zarrow, Robert A canonical form for symmetric and skew-symmetric extended symplectic modular matrices with applications to Riemann surface theory. Trans. Amer. Math. Soc. 204 (1975), 207–227.

You might be able to extend it to the nonsymplectic case (though I am a bit skeptical).

-
Indeed, Zarrow came very close to what I need. Zarrow found a simple canonical form the symmetric that satisfy (a) and (b') There exist a $J$ such that $J^2=-1$ and $J M J^T=−M^{-1}$. –  Xiao-Gang Wen May 20 '12 at 4:12
I am also interested finding the canonical form for symmetric matrices that satisfy (a) and (b'') There exist a $J$ such that $J^2=−1$ and $J M J^T=−M$. –  Xiao-Gang Wen May 20 '12 at 4:36
it is customary to up-vote answers you find helpful. –  Igor Rivin May 20 '12 at 15:28

I don't see how to diagonalize the quadratic form $2xy.$ As far as your conditions, we have $$M = \left( \begin{array}{cc} 0 & 1 \\\ 1 & 0 \end{array} \right)$$ and $$J = \left( \begin{array}{cc} 1 & 0 \\\ 0 & -1 \end{array} \right),$$ with $$\left( \begin{array}{cc} 1 & 0 \\\ 0 & -1 \end{array} \right) \left( \begin{array}{cc} 0 & 1 \\\ 1 & 0 \end{array} \right) \left( \begin{array}{cc} 1 & 0 \\\ 0 & -1 \end{array} \right) = \left( \begin{array}{cc} 0 & -1 \\\ -1 & 0 \end{array} \right)$$ However, the only diagonal matrices with determinant $-1$ are $\pm J,$ which does not work as $x^2 - y^2$ does not represent any numbers congruent to $2 \pmod 4.$

Let's see, Conway and Sloane refer to Watson for his 2-adic canonical form for their work on the Mass Formula, so I can recommend the book Integral Quadratic Forms by George Leo Watson. More recent, SPLAG, which is Sphere Packings, Lattices, and Groups by Conway and Sloane.

-
I suppose it is possible that one of your matrices must be equivalent to something that decomposes into 2 by 2 blocks, along the main diagonal only. That is the sort of thing that L. E. Dickson liked, but I do not believe he considered your condition. If so, you are probably in good shape. So I guess the questions are (A) have you proved your 2 by 2 case (you say "may have," and (B) does it appear that 4 by 4 examples decompose into blocks? –  Will Jagy May 20 '12 at 2:29
We do not need to diagonalize M. We just need to find some simple canonical form. We may have the following results for 2 x 2 integer matrices that satisfy (a) and (b): All even matrices are equivalent to $$\left( \begin{array}{cc} 0 & 1 \\ 1 & 0 \end{array} \right)$$ All odd matrices are equivalent to $$\left( \begin{array}{cc} 0 & 1 \\ 1 & 1 \end{array} \right) \sim \left( \begin{array}{cc} 1 & 0 \\ 0 & -1 \end{array} \right)$$ Do we have a similar simple result in general? – Xiao-Gang Wen 0 secs ago – Xiao-Gang Wen 0 secs ago –  Xiao-Gang Wen May 20 '12 at 2:31
I'm reading Watson, I do not see an answer yet. It would be nice to see some 4 by 4 examples. –  Will Jagy May 20 '12 at 2:48
What are even and odd matrices? –  Igor Rivin May 20 '12 at 3:37
@Igor, I think it is whether the quadratic form takes only even values or sometimes odd. So this is consistent with SPLAG terminology for lattices. –  Will Jagy May 20 '12 at 3:52