login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Search: a001422 -id:a001422
     Sort: relevance | references | number | modified | created      Format: long | short | data
Number of partitions of n into distinct squares.
+10
108
1, 1, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 2, 2, 0, 0, 2, 2, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 2, 1, 0, 0, 2, 2, 0, 0, 2, 3, 1, 1, 2, 2, 1, 1, 1, 1, 1, 0, 2, 3, 1, 1, 4, 3, 0, 1, 2, 2, 1, 0, 1, 4, 3, 0, 2, 4, 2, 1, 3, 2, 1, 2, 3, 3, 2, 1, 3, 6, 3, 0, 2, 5, 3, 0, 1, 3, 3, 3, 4
OFFSET
0,26
COMMENTS
"WEIGH" transform of squares A000290.
a(n) = 0 for n in {A001422}, a(n) > 0 for n in {A003995}. - Alois P. Heinz, May 14 2014
Number of partitions of n in which each part i has multiplicity i. Example: a(50)=3 because we have [1,2,2,3,3,3,6,6,6,6,6,6], [1,7,7,7,7,7,7,7], and [3,3,3,4,4,4,4,5,5,5,5,5]. - Emeric Deutsch, Jan 26 2016
The Heinz numbers of integer partitions into distinct pairs are given by A324587. - Gus Wiseman, Mar 09 2019
From Gus Wiseman, Mar 09 2019: (Start)
Equivalent to Emeric Deutsch's comment, a(n) is the number of integer partitions of n where the multiplicities (where if x < y the multiplicity of x is counted prior to the multiplicity of y) are equal to the distinct parts in increasing order. The Heinz numbers of these partitions are given by A109298. For example, the first 30 terms count the following integer partitions:
1: (1)
4: (22)
5: (221)
9: (333)
10: (3331)
13: (33322)
14: (333221)
16: (4444)
17: (44441)
20: (444422)
21: (4444221)
25: (55555)
25: (4444333)
26: (555551)
26: (44443331)
29: (5555522)
29: (444433322)
30: (55555221)
30: (4444333221)
The case where the distinct parts are taken in decreasing order is A324572, with Heinz numbers given by A324571.
(End)
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..10000 (first 1001 terms from T. D. Noe)
M. Brack, M. V. N. Murthy, and J. Bartel, Application of semiclassical methods to number theory, University of Regensburg (Germany, 2020).
Vaclav Kotesovec, Graph - The asymptotic ratio.
M. V. N. Murthy, Matthias Brack, Rajat K. Bhaduri, and Johann Bartel, Semi-classical analysis of distinct square partitions, arXiv:1808.05146 [cond-mat.stat-mech], 2018.
FORMULA
G.f.: Product_{n>=1} ( 1+x^(n^2) ).
a(n) ~ exp(3 * 2^(-5/3) * Pi^(1/3) * ((sqrt(2)-1)*zeta(3/2))^(2/3) * n^(1/3)) * ((sqrt(2)-1)*zeta(3/2))^(1/3) / (2^(4/3) * sqrt(3) * Pi^(1/3) * n^(5/6)), where zeta(3/2) = A078434. - Vaclav Kotesovec, Dec 09 2016
See Murthy, Brack, Bhaduri, Bartel (2018) for a more complete asymptotic expansion. - N. J. A. Sloane, Aug 17 2018
EXAMPLE
a(50)=3 because we have [1,4,9,36], [1,49], and [9,16,25]. - Emeric Deutsch, Jan 26 2016
From Gus Wiseman, Mar 09 2019: (Start)
The first 30 terms count the following integer partitions:
1: (1)
4: (4)
5: (4,1)
9: (9)
10: (9,1)
13: (9,4)
14: (9,4,1)
16: (16)
17: (16,1)
20: (16,4)
21: (16,4,1)
25: (25)
25: (16,9)
26: (25,1)
26: (16,9,1)
29: (25,4)
29: (16,9,4)
30: (25,4,1)
30: (16,9,4,1)
(End)
MAPLE
b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<1, 0,
b(n, i-1) +`if`(i^2>n, 0, b(n-i^2, i-1))))
end:
a:= n-> b(n, isqrt(n)):
seq(a(n), n=0..100); # Alois P. Heinz, May 14 2014
MATHEMATICA
nn=10; CoefficientList[Series[Product[(1+x^(k*k)), {k, nn}], {x, 0, nn*nn}], x] (* T. D. Noe, Jul 24 2006 *)
b[n_, i_] := b[n, i] = If[n==0, 1, If[i<1, 0, b[n, i-1] + If[i^2 > n, 0, b[n - i^2, i-1]]]]; a[n_] := b[n, Floor[Sqrt[n]]]; Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Sep 21 2015, after Alois P. Heinz *)
nmax = 20; poly = ConstantArray[0, nmax^2 + 1]; poly[[1]] = 1; poly[[2]] = 1; Do[Do[poly[[j + 1]] += poly[[j - k^2 + 1]], {j, nmax^2, k^2, -1}]; , {k, 2, nmax}]; poly (* Vaclav Kotesovec, Dec 09 2016 *)
Table[Length[Select[IntegerPartitions[n], Reverse[Union[#]]==Length/@Split[#]&]], {n, 30}] (* Gus Wiseman, Mar 09 2019 *)
PROG
(PARI) a(n)=polcoeff(prod(k=1, sqrt(n), 1+x^k^2), n)
(PARI) first(n)=Vec(prod(k=1, sqrtint(n), 1+'x^k^2, O('x^(n+1))+1)) \\ Charles R Greathouse IV, Sep 03 2015
(Python)
from functools import cache
from sympy.core.power import isqrt
@cache
def b(n, i):
# Code after Alois P. Heinz
if n == 0: return 1
if i == 0: return 0
i2 = i*i
return b(n, i-1) + (0 if i2 > n else b(n - i2, i-1))
a = lambda n: b(n, isqrt(n))
print([a(n) for n in range(1, 101)]) # Darío Clavijo, Nov 30 2023
CROSSREFS
Cf. A001422, A003995, A078434, A242434 (the same for compositions), A279329.
Row sums of A341040.
KEYWORD
nonn,nice
EXTENSIONS
More terms from Michael Somos
STATUS
approved
Sum of (any number of) distinct squares: of form r^2 + s^2 + t^2 + ... with 0 <= r < s < t < ...
+10
28
0, 1, 4, 5, 9, 10, 13, 14, 16, 17, 20, 21, 25, 26, 29, 30, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 61, 62, 63, 64, 65, 66, 68, 69, 70, 71, 73, 74, 75, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 93, 94, 95, 97
OFFSET
1,3
FORMULA
Exponents in expansion of (1+x)*(1+x^4)*(1+x^9)*(1+x^16)*(1+x^25)*(1+x^36)*(1+x^49)*(1+x^64)*(1+x^81)*(1+x^100)*(1+x^121)*(1+x^144)*...
For n > 98, a(n) = n + 30. - Charles R Greathouse IV, Sep 02 2011 (This implies a(n+2) = 2*a(n+1)-a(n) for n > 98.)
MATHEMATICA
lim = 10; s = {0}; Do[s = Union[s, s + n^2], {n, lim}]; Select[s, 0 <= # <= lim^2 &] (* T. D. Noe, Jul 10 2012 *)
PROG
(PARI) a(n)=if(n<1, 0, n=a(n-1); until(polcoeff(prod(k=1, sqrt(n), 1+x^k^2), n), n++); n)
(Haskell)
a003995 n = a003995_list !! (n-1)
a003995_list = filter (p a000290_list) [0..]
where p (q:qs) m = m == 0 || q <= m && (p qs (m - q) || p qs m)
-- Reinhard Zumkeller, Apr 22 2013
CROSSREFS
Cf. A001983, A033461, A008935. Complement of A001422.
KEYWORD
nonn,easy,nice,changed
STATUS
approved
Numbers which cannot be written as a sum of squares > 1.
+10
20
1, 2, 3, 5, 6, 7, 10, 11, 14, 15, 19, 23
OFFSET
1,2
COMMENTS
Numbers such that A078134(n)=0.
"Numbers which cannot be written as sum of squares > 1" is equivalent to "Numbers which cannot be written as sum of squares of primes." Equivalently, numbers which can be written as the sum of nonzero squares can also be written as sum of the squares of primes." cf. A090677 = number of ways to partition n into sums of squares of primes. - Jonathan Vos Post, Sep 20 2006
The sequence is finite with a(12)=23 as last member. Proof: When k=a^2+b^2+..., k+4 = 2^2+a^2+b^2+... If k can be written as sum of the squares of primes, k+4 also has this property. As 24,25,26,27 have the property, by induction, all numbers > 23 can be written as sum of squares>1. - Fung Cheok Yin (cheokyin_restart(AT)yahoo.com.hk), Apr 07 2007
Also, numbers which cannot be written as sum of squares of 2 and 3 (see A078137 for the proof). Explicit representation as sum of squares of primes, or rather of squares of 2 and 3, for numbers m>23: we have m=c*2^2+d*3^2, where c:=((floor(m/4) - 2*(m mod 4))>=0, d:=m mod 4. For that, the finiteness of the sequence is proved constructively. - Hieronymus Fischer, Nov 11 2007
Also numbers n such that every integer partition of n contains a squarefree number. For example, 21 does not belong to the sequence because there are integer partitions of 21 containing no squarefree numbers, namely: (12,9), (9,8,4), (9,4,4,4). - Gus Wiseman, Dec 14 2018
FORMULA
A090677(a(n)) = 0. - Jonathan Vos Post, Sep 20 2006 [corrected by Joerg Arndt, Dec 16 2018]
A033183(a(n)) = 0. [Reinhard Zumkeller, Nov 07 2009]
MATHEMATICA
nn=100;
ser=Product[If[SquareFreeQ[n], 1, 1/(1-x^n)], {n, nn}];
Join@@Position[CoefficientList[Series[ser, {x, 0, nn}], x], 0]-1 (* Gus Wiseman, Dec 14 2018 *)
KEYWORD
nonn,fini,full
AUTHOR
Reinhard Zumkeller, Nov 19 2002
STATUS
approved
Number T(n,k) of partitions of n into k distinct nonzero squares; triangle T(n,k), n>=0, 0<=k<=A248509(n), read by rows.
+10
20
1, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 1
OFFSET
0
COMMENTS
T(n,k) is defined for n, k >= 0. The triangle contains only the terms with 0 <= k <= A248509(n). T(n,k) = 0 for k > A248509(n).
LINKS
FORMULA
T(n,k) = [x^n*y^k] Product_{j>=1} (1 + y*x^(j^2)).
T(A000330(n),n) = 1.
Row n = [0] <=> n in { A001422 }.
Sum_{k>=0} 2^k * T(n,k) = A279360(n).
Sum_{k>=0} k * T(n,k) = A281542(n).
Sum_{k>=0} (-1)^k * T(n,k) = A276516(n).
EXAMPLE
T(62,3) = 2 is the first term > 1 and counts partitions [49,9,4] and [36,25,1].
Triangle T(n,k) begins:
1;
0, 1;
0;
0;
0, 1;
0, 0, 1;
0;
0;
0;
0, 1;
0, 0, 1;
0;
0;
0, 0, 1;
0, 0, 0, 1;
...
MAPLE
b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<1, 0,
b(n, i-1)+`if`(i^2>n, 0, expand(b(n-i^2, i-1)*x))))
end:
T:= n->(p->seq(coeff(p, x, i), i=0..max(0, degree(p))))(b(n, isqrt(n))):
seq(T(n), n=0..45);
MATHEMATICA
b[n_, i_] := b[n, i] = If[n == 0, 1, If[i < 1, 0,
b[n, i - 1] + If[i^2 > n, 0, Expand[b[n - i^2, i - 1]*x]]]];
T[n_] := CoefficientList[b[n, Floor@Sqrt[n]], x] /. {} -> {0};
T /@ Range[0, 45] // Flatten (* Jean-François Alcover, Feb 15 2021, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn,look,tabf
AUTHOR
Alois P. Heinz, Feb 03 2021
STATUS
approved
Numbers that are not the sum of distinct triangular numbers.
+10
18
2, 5, 8, 12, 23, 33
OFFSET
1,1
COMMENTS
The Mathematica program first computes A024940, the number of partitions of n into distinct triangular numbers. Then it finds those n having zero such partitions. It appears that A024940 grows exponentially, which would preclude additional terms in this sequence. - T. D. Noe, Jul 24 2006, Jan 05 2009
REFERENCES
Joe Roberts, Lure of the Integers, The Mathematical Association of America, 1992, page 184, entry 33.
David Wells in "The Penguin Dictionary of Curious and Interesting Numbers, Revised Edition, page 94, states that "33 is the largest number that is not the sum of distinct triangular numbers".
FORMULA
Complement of A061208.
EXAMPLE
a(2) = 5: the 7 partitions of 5 are 5, 4+1, 3+2, 3+1+1, 2+2+1, 2+1+1+1, 1+1+1+1+1. Among those the distinct ones are 5, 4+1, 3+2. None contains all distinct triangular numbers.
12 is a term as it is not a sum of 1, 3, 6 or 10 taken at most once.
MATHEMATICA
nn=100; t=Rest[CoefficientList[Series[Product[(1+x^(k*(k+1)/2)), {k, nn}], {x, 0, nn(nn+1)/2}], x]]; Flatten[Position[t, 0]] (* T. D. Noe, Jul 24 2006 *)
CROSSREFS
Cf. A025524 (number of numbers not the sum of distinct n-th-order polygonal numbers)
Cf. A007419 (largest number not the sum of distinct n-th-order polygonal numbers)
Cf. A001422, A121405 (corresponding sequences for square and pentagonal numbers)
KEYWORD
fini,full,nonn
AUTHOR
Jud McCranie, Mar 19 2000
EXTENSIONS
Entry revised by N. J. A. Sloane, Jul 23 2006
STATUS
approved
Least integer that can be written as a sum of zero or more distinct squares in exactly n ways, or -1 if no such number exists.
+10
17
2, 0, 25, 50, 65, 94, 90, 110, 155, 126, 191, 170, 186, 174, 190, 211, 195, 226, 210, 231, 234, 235, 332, 255, 283, 259, 274, 275, 270, 323, 310, 286, 306, 299, 330, 381, 295, 347, 334, 319, 315, 331, 405, 339, 335, 364, 359, 351, 367, 387, 371, 370, 404, 438
OFFSET
0,1
COMMENTS
a(n) = -1 for almost all n. Conjecture: for n > 34189857569982621, this sequence is the integers > 37163, in order, interspersed with -1s. - Charles R Greathouse IV, Sep 04 2015
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 0..10000
EXAMPLE
a(4) = 65 because we can write 65 as a sum of distinct squares in four ways: 65 = 8^2 + 1^2 = 7^2 + 4^2 = 6^2 + 5^2 + 2^2 = 6^2 + 4^2 + 3^2 + 2^2 and we cannot do this with any smaller integer.
a(0) = 2 because we cannot write 2 as a sum of distinct squares and it is the smallest number with this property.
MAPLE
gf := product(1+x^F(k), k=1..31); ser := series(gf, x=0, 1001); S := [seq(coeff(ser, x^(1*i)), i=1..1000)]; A := proc(i); x := 0; for j from 1 to nops(a) while x = 0 do > if a[j] = i then x := 1; fi; od; j-1; end; seq(A(n), n=1..67);
CROSSREFS
First occurrence of n in A033461; see also A001422 (0 ways) and A003995 (1 or more ways).
KEYWORD
easy,sign
AUTHOR
Isabel C. Lugo (izzycat(AT)gmail.com), Aug 27 2004
EXTENSIONS
Edited by Ray Chandler, Sep 01 2004
STATUS
approved
Infinite square array where row n lists the integers whose n-th power is the sum of distinct n-th powers of positive integers; read by falling antidiagonals.
+10
11
3, 4, 5, 5, 7, 6, 6, 9, 9, 15, 7, 10, 12, 25, 12, 8, 11, 13, 27, 23, 25, 9, 12, 14, 29, 24, 28, 40, 10, 13, 15, 30, 28, 32, 43, 84, 11, 14, 16, 31, 29, 34, 44, 85, 47, 12, 15, 17, 33, 30, 35, 45, 86, 49, 63, 13, 16, 18, 35, 31, 36, 46, 87, 52, 64, 68
OFFSET
1,1
COMMENTS
Each row contains all sufficiently large integers (Sprague). Sequences A001422, A001476, A046039, A194768, A194769, ... mention the largest number which can't be written as sum of distinct n-th powers for n = 2, 3, 4, 5, 6, ...; see also A001661. Sequence A332066 gives the number of positive integers not in row n.
All positive multiples of any T(n,k) appear later in that row (because if s^n = Sum_{x in S} x^n, then (k*s)^n = Sum_{x in k*S} x^n).
FORMULA
T(1,k) = 2 + k for all k. (Indeed, s^1 = (s-1)^1 + 1 and s-1 > 1 for s > 2.)
T(2,k) = 6 + k for all k >= 3. (Use s^2 = (s-1)^2 + 2*s-1 and A001422, A009003.)
T(3,k) = 9 + k for all k >= 3. (Use max A001476 = 12758 < 24^3.)
T(4,k) = 32 + k for all k >= 13. (Use max A046039 < 48^4.)
T(5,k) = 24 + k for all k >= 4. (Use max(N \ A194768) < 37^5.)
T(6,k) = 30 + k for all k >= 4. (Use max(N \ A194769) < 48^6.)
T(7,k) = 41 + k for all k >= 2.
T(9,k) = 49 + k for all k >= 3.
EXAMPLE
The table reads: (Entries from where on T(n,k+1) = T(n,k)+1 are marked by *.)
n | k=1 2 3 4 5 6 7 8 9 10 11 12 13 ...
---+---------------------------------------------------------------------
1 | 3* 4 5 6 7 8 9 10 11 12 13 14 15 ...
2 | 5 7 9* 10 11 12 13 14 15 16 17 18 19 ...
3 | 6 9 12* 13 14 15 16 17 18 19 20 21 22 ...
4 | 15 25 27 29 30 31 33 35 37 39 41 43 45* ...
5 | 12 23 24 28* 29 30 31 32 33 34 35 36 37 ...
6 | 25 28 32 34* 35 36 37 38 39 40 41 42 43 ...
7 | 40 43* 44 45 46 47 48 49 50 51 52 53 54 ...
8 | 84* 85 86 87 88 89 90 91 92 93 94 95 96 ...
9 | 47 49 52* 53 54 55 56 57 58 59 60 61 62 ...
10 | 63* 64 65 66 67 68 69 70 71 72 73 74 75 ...
11 | 68 73* 74 75 76 77 78 79 80 81 82 83 84 ...
...| ...
Row 1: 3^1 = 2^1 + 1^1, 4^1 = 3^1 + 1^1, 5^1 = 4^1 + 1^1, 6^1 = 5^1 + 1^1, ...
Row 2: 5^2 = 4^2 + 3^2, 7^2 = 6^2 + 3^2 + 2^2, 9^2 = 8^2 + 4^2 + 1^2, ...
Row 3: 6^3 = 5^3 + 4^3 + 3^3, 9^3 = 8^3 + 6^3 + 1, 12^3 = 10^3 + 8^3 + 6^3, ...
Row 4: 15^4 = Sum {14, 9, 8, 6, 4}^4, 25^4 = Sum {21, 20, 12, 10, 8, 6, 2}^4, ...
See the link for other rows.
PROG
(PARI) M332065=Map(); A332065(n, m, r)={if(r, if( m<2^n||m>r^n*(r+n+1)\(n+1), m<2, r=min(sqrtnint(m, n), r), m==r^n || while( !A332065(n, m-r^n, r-=1) && (m<r^n*(r+n+1)\(n+1) || r=0), ); r), m||[m=A004736(n), n=A002260(n)]; mapisdefined(M332065, [n, m], &r), r, n<2, m+2, r=if(m>1, A332065(n, m-1), n+2); until(A332065(n, (r+=1)^n, r-1), ); mapput(M332065, [n, m], r); r)} \\ Calls itself with nonzero (optional) 3rd argument to find by exhaustive search whether r can be written as sum of distinct powers <= m^n. (Comment added by M. F. Hasler, May 25 2020)
CROSSREFS
Cf. A030052 (first column), A001661.
Cf. A009003 (hypotenuse numbers; subsequence of row 2).
Cf. A332066.
KEYWORD
nonn,tabl
AUTHOR
M. F. Hasler, Mar 31 2020
EXTENSIONS
More terms from M. F. Hasler, Jul 19 2020
STATUS
approved
Numbers that are not the sum of distinct positive cubes.
+10
10
2, 3, 4, 5, 6, 7, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 29, 30, 31, 32, 33, 34, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 67, 68, 69, 70, 71, 74, 75, 76, 77, 78, 79, 80
OFFSET
1,1
COMMENTS
Complement of A003997.
There are 85 terms below 100, 793 terms below 1000, but only 2765 terms below 10^4, and only 23 more up to the largest term a(2788)=12758. - M. F. Hasler, Feb 25 2012
Indices k such that A279329(k) = 0. - Vaclav Kotesovec, Sep 22 2017
LINKS
T. D. Noe, Table of n, a(n) for n = 1..2788 (complete sequence)
R. E. Dressler and T. Parker, 12,758, Math. Comp. 28 (1974), 313-314.
Eric Weisstein's World of Mathematics, Cubic Number
MATHEMATICA
Cubes[ n_ ] := Block[ {A, i}, A = {0}; if[ n>0, Do[ A = Union[ A, A + i*i*i ], {i, n} ]; ]; Return[ A ]; ]; Q = Complement[ Table[ i, {i, 1, 12760} ], Cubes[ 23 ] ]
PROG
(PARI) select( is_A001476(n, m=n)={m^3>n&&m=sqrtnint(n, 3); n!=m^3&&!while(m>1, is_A001476(n-m^3, m--)||return)}, [1..77]) \\ M. F. Hasler, Apr 21 2020
CROSSREFS
KEYWORD
nonn,fini,full
AUTHOR
Jeff Adams (jeff.adams(AT)byu.net)
EXTENSIONS
Definition clarified by Jeppe Stig Nielsen, Jan 27 2015
STATUS
approved
Indices k such that A276516(k) = 0.
+10
10
2, 3, 6, 7, 8, 11, 12, 15, 18, 19, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 41, 43, 44, 45, 46, 47, 48, 53, 54, 60, 61, 67, 70, 72, 74, 76, 79, 82, 84, 87, 90, 92, 93, 96, 105, 106, 107, 108, 111, 112, 114, 117, 122, 128, 133, 135, 139, 141, 148, 159
OFFSET
1,1
COMMENTS
This is different from A001422, first difference: a(14) = 25, A001422(14) = 27.
Conjecture: for k > 7169 there are no more terms in this sequence (tested for k < 10000000).
LINKS
EXAMPLE
3 is in the sequence because A276516(3) = 0
4 is not in the sequence because A276516(4) = -1
4222 is in the sequence because A276516(4222) = 0
7169 is in the sequence because A276516(7169) = 0
MATHEMATICA
nn = 100; A276516 = Rest[CoefficientList[Series[Product[(1-x^(k^2)), {k, nn}], {x, 0, nn^2}], x]]; Select[Range[nn^2], A276516[[#]]==0&]
nmax = 10000; nn = Floor[Sqrt[nmax]]+1; poly = ConstantArray[0, nn^2 + 1]; poly[[1]] = 1; poly[[2]] = -1; poly[[3]] = 0; Do[Do[poly[[j + 1]] -= poly[[j - k^2 + 1]], {j, nn^2, k^2, -1}]; , {k, 2, nn}]; A276516 = Take[poly, {2, nmax+1}]; Select[Range[nmax], A276516[[#]]==0&]
CROSSREFS
KEYWORD
nonn
AUTHOR
Vaclav Kotesovec, Dec 12 2016
STATUS
approved
Number of positive integers that are not the sum of distinct n-th-order polygonal numbers.
+10
7
6, 31, 61, 94, 134, 192, 277, 328, 372, 453, 577, 676, 738, 822, 943, 1079, 1199, 1308, 1433, 1586, 1728, 1853, 2015, 2210, 2377, 2549, 2724, 2926, 3142, 3337, 3544, 3778, 4032, 4255, 4481, 4750, 5048, 5314, 5575, 5876, 6193, 6506, 6794, 7097, 7460, 7832
OFFSET
3,1
CROSSREFS
Cf. A025524 (number of numbers not the sum of distinct n-th-order polygonal numbers)
Cf. A007419 (largest number not the sum of distinct n-th-order polygonal numbers)
Cf. A053614, A001422, A121405 (sequences for triangular, square, and pentagonal numbers)
KEYWORD
nonn
STATUS
approved

Search completed in 0.018 seconds