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.
%I A239880 #15 Aug 29 2016 11:10:26 %S A239880 0,1,1,1,1,1,2,2,3,3,5,5,7,7,10,11,14,15,19,22,26,30,35,42,47,56,62, %T A239880 76,83,100,108,132,142,171,184,222,239,284,306,363,394,460,500,581, %U A239880 636,730,802,914,1010,1139,1262,1415,1577,1753,1956,2163,2423,2663 %N A239880 Number of strict partitions of n having an ordering in which no parts of equal parity are juxtaposed and the first and last terms have the same parity. %C A239880 A strict partition is one in which every part has multiplicity 1. %C A239880 a(n) = A240021(n,-1) + A240021(n,1). - _Alois P. Heinz_, Apr 02 2014 %H A239880 Alois P. Heinz, <a href="/A239880/b239880.txt">Table of n, a(n) for n = 0..1000</a> %e A239880 a(12) counts these 7 partitions: [12], [9,2,1], [3,8,1], [7,4,1], [7,2,3], [5,6,1], [5,4,3]. %p A239880 b:= proc(n, i, t) option remember; `if`(n>i*(i+1)/2 or %p A239880 abs(t)-n>1, 0, `if`(n=0, abs(t), b(n, i-1, t)+ %p A239880 `if`(i>n, 0, b(n-i, i-1, t+(2*irem(i, 2)-1))))) %p A239880 end: %p A239880 a:= n-> b(n$2, 0): %p A239880 seq(a(n), n=0..80); # _Alois P. Heinz_, Apr 02 2014 %t A239880 d[n_] := Select[IntegerPartitions[n], Max[Length /@ Split@#] == 1 &]; %t A239880 p[n_] := p[n] = Select[d[n], Abs[Count[#, _?OddQ] - Count[#, _?EvenQ]] == 1 &]; t = Table[p[n], {n, 0, 12}] %t A239880 TableForm[t] (* shows the partitions *) %t A239880 u = Table[Length[p[n]], {n, 0, 60}] (* A239880 *) %t A239880 (* _Peter J. C. Moses_, Mar 10 2014 *) %t A239880 b[n_, i_, t_] := b[n, i, t] = If[n > i*(i+1)/2 || Abs[t]-n>1, 0, If[n==0, Abs[t], b[n, i-1, t] + If[i>n, 0, b[n-i, i-1, t + (2*Mod[i, 2]-1)]]]]; a[n_] := b[n, n, 0]; Table[a[n], {n, 0, 80}] (* _Jean-François Alcover_, Aug 29 2016, after _Alois P. Heinz_ *) %Y A239880 Cf. A239833, A239835, A239881. %K A239880 nonn,easy %O A239880 0,7 %A A239880 _Clark Kimberling_, Mar 29 2014