# [seqfan] Number of nXn (0,1)-matrices A with A^2 = J?

Neil Sloane njasloane at gmail.com
Sat Mar 4 07:51:03 CET 2017

```I just came across an old paper of Herb Ryser (A generalization
of the matrix equation A^2=J, Linear Alg. Applic., 3 (1970),451-460)
where he mentions in passing the unsolved problem of finding
the number of n X n real (0,1) matrices A such that A^2 is the
all-ones matrix J.

He says that A must have constant row and column sums c, and c^2 = n.
Also trace A = c. So n must be a square, n=c^2.

There is a long entry in the Index to the OEIS under
matrices, binary
but this problem doesn't seem to be mentioned there.
Is this sequence in the OEIS?  (If so, it should
be mentioned in the index entry.)
I'm pretty sure I've seen the problem before, but a quick
search in the OEIS didn't find it.  Let n = c^2. Then there is one
solution if c=1, and if someone could work out the answers for c=2 and
maybe 3, that might be enough to locate it.

Here is one solution for c=2:
1010
0101
1010
0101
and permuting the rows is allowed - so is the answer 6 if c=2?

Neil
```