# [seqfan] Re: trouble with A132337 and A132336

Richard Mathar mathar at strw.leidenuniv.nl
Fri Oct 8 22:58:43 CEST 2010

```A132337 has of course the typo using 'n' for 'r' in the formula:
(and the Lajos program is off board, because it fails where a=2015 and beyond):

%I A132337
%S A132337 0,2,5,9,14,20,27,35,44,54,65,77,90,104,119,135,152,170,189,209,230,252,
%T A132337 275,299,324,350,377,405,434,464,495,527,560,594,629,665,702,740,779,
%U A132337 819,860,902,945,989,1034,1080,1127,1175,1224,1274,1325,1377,1430,1484
%N A132337 Sum of the integers from 0 to n, excluding the sixth powers.
%F A132337 Let r = floor(n^(1/6)). Then a(n) = n(n+1)/2 - (r^7/7+r^6/2+r^5/2-r^3/ 6+n/42) = A000217(n)-A000540(r).
%p A132337 A000217 := proc(n) n*(n+1)/2 ; end proc:
%p A132337 A000540 := proc(n) n^7/7+n^6/2+n^5/2-n^3/6+n/42 ; end proc:
%p A132337 A132337 := proc(n) r := floor(n^(1/6)) ; A000217(n)-A000540(r); end proc: seq(A132337(n),n=1..40) ; # R. J. Mathar
%o A132337 (PARI) g6(n)=for(x=1,n,r=floor(x^(1/6));sum6=r^7/7+r^6/2+r^5/2-r^3/6+r/ 42;sn=x* (x+1)/2;print1(sn-sum6","))
%Y A132337 Different from A000096.
%Y A132337 Adjacent sequences: A132334 A132335 A132336 this_sequence A132338 A132339 A132340
%Y A132337 Sequence in context: A132336 A000096 A080956 this_sequence A134189 A109470 A112873
%K A132337 nonn,new
%O A132337 1,2
%A A132337 Cino Hilliard (hillcino368(AT)hotmail.com), Nov 07 2007
%E A132337 Incorrect formula deleted by Jon Schoenfield, Jun 12 2010
%E A132337 Incorrect program replaced by R. J. Mathar, Oct 08 2010

```