%I #31 Apr 13 2023 10:43:55
%S 0,0,1,1,1,1,1,2,1,1,1,2,1,1,2,2,1,1,1,2,2,1,1,4,1,1,1,2,1,2,1,2,2,1,
%T 2,2,1,1,2,4,1,2,1,2,2,1,1,4,1,1,2,2,1,1,2,4,2,1,1,4,1,1,2,2,2,2,1,2,
%U 2,2,1,4,1,1,2,2,2,2,1,4,1,1,1,4,2,1,2
%N Number of primitive inequivalent sublattices of square lattice having mirrors parallel to the diagonals of the unit cell of the parent lattice of index n.
%C After a(2), this matches A034380 except for n = 63, 65, 80, 85, ... - _R. J. Mathar_, Feb 27 2009 [Updated by _Andrey Zabolotskiy_, May 09 2018]
%H Andrey Zabolotskiy, <a href="/A157230/b157230.txt">Table of n, a(n) for n = 1..5000</a>
%H J. S. Rutherford, <a href="https://doi.org/10.1107/S010876730804333X">Sublattice enumeration. IV. Equivalence classes of plane sublattices by parent Patterson symmetry and colour lattice group type</a>, Act. Cryst. A65 (2009) 156-163, Table 5 symmetry *mm2.
%F From _Andrey Zabolotskiy_, Sep 30 2018: (Start)
%F a(n) = (A060594(n) - A019590(n))/2.
%F a(n) = 2^(A046072(n)-1) for n>2. Thus a(n) = 1 if n>2 is in A033948, a(n) = 2 if n is in A272592, etc. (End)
%t a[n_] := If[n <= 2, 0, Sum[Boole[Mod[k^2, n] == 1], {k, 1, n}]/2];
%t Table[a[n], {n, 1, 100}] (* _Jean-François Alcover_, Apr 12 2023 *)
%Y Cf. A145393 (all sublattices of the square lattice), A019590, A157228, A157226, A157231, A304182, A060594, A046072, A033948, A272592.
%K nonn
%O 1,8
%A _N. J. A. Sloane_, Feb 25 2009
%E New name and more terms from _Andrey Zabolotskiy_, May 09 2018