%I #72 Dec 12 2023 07:39:46
%S 0,0,0,1,2,1,3,3,3,4,5,4,6,6,6,7,8,7,9,9,9,10,11,10,12,12,12,13,14,13,
%T 15,15,15,16,17,16,18,18,18,19,20,19,21,21,21,22,23,22,24,24,24,25,26,
%U 25,27,27,27,28,29,28,30,30,30,31,32,31,33,33,33,34,35,34,36,36,36,37
%N Number of symmetry classes of 3 X 3 reduced magic squares with distinct values and maximum value 2n; also, with magic sum 3n.
%C In a reduced magic square the row, column, and two diagonal sums must all be equal (the "magic sum") and the minimum entry is 0. The maximum entry is necessarily even and = (2/3)*(magic sum). The symmetries are those of the square.
%C a(n) is a quasipolynomial with period 6.
%C The second differences of A108577 are a(n/2) for even n and 0 for odd n. The first differences of A108579 are a(n/3).
%C For n>=3 equals a(n) the number of partitions of n-3 using parts 1 and 2 only, with distinct multiplicities. Example: a(7) = 3 because [2,2], [2,1,1], [1,1,1,1] are such partitions of 7-3=4. - _T. Amdeberhan_, May 13 2012
%C a(n) is equal to the number of partitions of n of length 3 with exactly two equal entries (see below example). - _John M. Campbell_, Jan 29 2016
%C a(k) + 2 =:t(k), k >= 1, based on sequence A300069, is used to obtain for 2^t(k)*O_{-k} integer coordinates in the quadratic number field Q(sqrt(3)), where O_{-k} is the center of a k-family of regular hexagons H_{-k} forming part of a discrete spiral. See the linked W. Lang paper, Lemma 5, and Table 7. - _Wolfdieter Lang_, Mar 30 2018
%C a(n) is equal to the number of incongruent isosceles triangles (excluding equilateral triangles) formed from the vertices of a regular n-gon. - _Frank M Jackson_, Oct 30 2022
%H Thomas Zaslavsky, <a href="/A174257/b174257.txt">Table of n, a(n) for n = 1..10000</a>.
%H Matthias Beck and Thomas Zaslavsky, <a href="https://people.math.binghamton.edu/zaslav/Tpapers/SLSfiles/">"Six Little Squares and How their Numbers Grow" Web Site</a>: Maple worksheets and supporting documentation.
%H Matthias Beck and Thomas Zaslavsky, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL13/Zaslavsky/sls.html">Six little squares and how their numbers grow</a>, Journal of Integer Sequences, Vol. 13 (2010), Article 10.6.2.
%H Wolfdieter Lang, <a href="/A300068/a300068_1.pdf">On a Conformal Mapping of Regular Hexagons and the Spiral of its Centers</a>.
%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (0,1,1,0,-1).
%F G.f.: x^4*(1+2*x) / ( (1+x)*(1+x+x^2)*(x-1)^2 ).
%F a(n) = (1/8)*A174256(n).
%F a(n) = floor((n-1)/2) + floor((n-1)/3) - floor(n/3). - _Mircea Merca_, May 14 2013
%F a(n) = A300069(n-1) + 3*floor((n-1)/6), n >= 1. Proof via g.f.. - _Wolfdieter Lang_, Feb 24 2018
%F a(n) = (6*n - 13 - 8*cos(2*n*Pi/3) - 3*cos(n*Pi))/12. - _Wesley Ivan Hurt_, Oct 04 2018
%e From _John M. Campbell_, Jan 29 2016: (Start)
%e For example, there are a(16)=7 partitions of 16 of length 3 with exactly two equal entries:
%e (14,1,1) |- 16
%e (12,2,2) |- 16
%e (10,3,3) |- 16
%e (8,4,4) |- 16
%e (7,7,2) |- 16
%e (6,6,4) |- 16
%e (6,5,5) |- 16
%e (End)
%p seq(floor((n-1)/2)+floor((n-1)/3)-floor(n/3),n=1..100) # _Mircea Merca_, May 14 2013
%t Rest@ CoefficientList[Series[x^4 (1 + 2 x)/((1 + x) (1 + x + x^2) (x - 1)^2), {x, 0, 76}], x] (* _Michael De Vlieger_, Jan 29 2016 *)
%t Table[Length@Select[Length/@Union/@IntegerPartitions[n, {3}], # == 2 &], {n,
%t 1, 100}] (* _Frank M Jackson_, Oct 30 2022 *)
%o (PARI) concat(vector(3), Vec(x^4*(1+2*x) / ( (1+x)*(1+x+x^2)*(x-1)^2 ) + O(x^90))) \\ _Michel Marcus_, Jan 29 2016
%Y Cf. A108576, A108577, A174256, A300069.
%K nonn,easy
%O 1,5
%A _Thomas Zaslavsky_, Mar 14 2010
%E Information added to name and comments by _Thomas Zaslavsky_, Apr 24 2010