cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A226756 Number of elements X in the matrix ring M_2(Z_n) such that X^2 == X (mod n).

This page as a plain text file.
%I A226756 #12 Apr 04 2016 06:56:47
%S A226756 1,8,14,26,32,112,58,98,110,256,134,364,184,464,448,386,308,880,382,
%T A226756 832,812,1072,554,1372,752,1472,974,1508,872,3584,994,1538,1876,2464,
%U A226756 1856,2860,1408,3056,2576,3136,1724,6496,1894,3484,3520,4432,2258,5404,2746
%N A226756 Number of elements X in the matrix ring M_2(Z_n) such that X^2 == X (mod n).
%t A226756 ring[n_] := Flatten[Table[{{a, b}, {c, d}}, {a, 0, n - 1}, {b, 0, n - 1}, {c, 0, n - 1}, {d, 0, n - 1}], 3]; a[n_] := Length@Select[ring[n], Mod[#.#, n] == # &]; Table[a[n], {n, 44}]
%o A226756 (PARI) a(n) = sum(i=0, n-1, sum(j=0, n-1, sum(k=0, n-1, sum(l=0, n-1, m = Mod([i,j;k,l], n); m^2 == m)))); \\ _Michel Marcus_, Apr 04 2016
%Y A226756 Cf. A087726.
%K A226756 nonn,mult
%O A226756 1,2
%A A226756 _José María Grau Ribas_, Jun 16 2013