Let A be a symmetric matrix of order 2 with integer entries. If the sum of the diagonal elements of A2 is 1, then the possible number of such matrices is
Solutions · 1
Official solution
Let A=(abbc). Then trace(A2)=a2+2b2+c2=1 (integer entries).
The only integer solutions are: one of a,c is ±1 and the other and b are 0 --- giving A=(1000),(−1000),(0001),(000−1).
(Any attempt to use b=±1 forces 2b2=2>1, impossible with integers.)
So there are 4 such matrices.