|
|
A213991
|
|
Number of 2 X 2 0..n matrices whose square is also a 0..n matrix.
|
|
1
|
|
|
11, 24, 36, 72, 92, 126, 148, 183, 243, 291, 321, 391, 431, 461, 521, 639, 677, 764, 812, 906, 980, 1040, 1062, 1196, 1362, 1414, 1492, 1632, 1696, 1836, 1912, 2011, 2097, 2177, 2269, 2565, 2667, 2723, 2825, 3067, 3145, 3319, 3377, 3523, 3699, 3803, 3821
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
|
|
LINKS
|
|
|
EXAMPLE
|
Some solutions for n=3:
..1..1....0..2....0..1....1..0....1..3....0..0....0..3....0..0....0..3
..0..0....1..0....1..0....0..0....0..0....0..0....0..0....0..1....1..0
|
|
PROG
|
(Python) # see linked program for a much faster version
from itertools import product
def a(n): return sum(all(k <= n for k in [a*a+b*c, a*b+b*d, c*a+d*c, c*b+d*d]) for a, b, c, d in product(range(n+1), repeat=4))
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|