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 A369786 #25 Feb 02 2024 07:43:46 %S A369786 1,1,2,2,2,3,3,4,6,7,10,15,21,33,50,83,126,208,321,498,688,934,1208, %T A369786 1496,1798,2140,2482,2862,3268,3690,4145,4619,5142,5687,6265,6880, %U A369786 7530,8214,8937,9700,10489,11339,12218,13142,14112,15123,16181,17288,18438,19639,20888 %N A369786 Number of different coefficient values in expansion of Product_{k=1..n} (1+x^(k^2)). %H A369786 Vaclav Kotesovec, <a href="/A369786/b369786.txt">Table of n, a(n) for n = 0..500</a> %F A369786 Conjecture: a(n) ~ n^3/6. - _Vaclav Kotesovec_, Feb 02 2024 %t A369786 p = 1; Join[{1}, Table[p = Expand[p*(1 + x^(n^2))]; Length[Union[CoefficientList[p, x]]], {n, 1, 50}]] (* or *) %t A369786 nmax = 50; poly = ConstantArray[0, nmax*(nmax + 1)*(2*nmax + 1)/6 + 1]; poly[[1]] = 1; poly[[2]] = 1; Flatten[{{1, 1}, Table[Do[poly[[j + 1]] += poly[[j - k^2 + 1]], {j, k*(k + 1)*(2*k + 1)/6, k^2, -1}]; Length[Union[poly]], {k, 2, nmax}]}] (* _Vaclav Kotesovec_, Feb 01 2024 *) %o A369786 (PARI) a(n) = #Set(Vec(prod(k=1, n, 1+x^k^2))); %o A369786 (Python) %o A369786 from collections import Counter %o A369786 def A369786(n): %o A369786 c = {0:1} %o A369786 for k in range(1,n+1): %o A369786 m, d = k**2, Counter(c) %o A369786 for j in c: %o A369786 d[j+m] += c[j] %o A369786 c = d %o A369786 return len(set(c.values()))+int(max(c)+1>len(c)) # _Chai Wah Wu_, Feb 01 2024 %Y A369786 Cf. A033461, A039822. %K A369786 nonn %O A369786 0,3 %A A369786 _Seiichi Manyama_, Feb 01 2024