login
A333818
G.f.: Sum_{k>=1} x^(k*(3*k - 2)) / (1 - x^(6*k)).
6
1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1
OFFSET
1
COMMENTS
Number of ways to write n as the difference of two octagonal numbers.
a(n) = 2 if n = 133, 175, 176, 217, 224, 259, 272, 280, 301, 320, 343, 368, 385, 400, ... a(n) = 3 if n = 560, 637, 896, 935, ... a(n) = 4 if n = 1729, 2240, 2275, ... - R. J. Mathar, Oct 08 2020 [modified by Ilya Gutkovskiy, Oct 09 2020]
FORMULA
G.f.: Sum_{i>=0} Sum_{j>=i} Product_{k=i..j} x^(6*k + 1).
EXAMPLE
a(1729) = 4 with representations 1729 = 1825-96 = 2465-736 = 5985-4256 = 249985-248256. - R. J. Mathar, Oct 08 2020
MAPLE
A333818 := proc(n)
local a, hi, hiO, lo, loO;
a := 0 ;
for hi from 1 do
hiO := A000567(hi) ;
for lo from hi-1 to 1 by -1 do
loO := A000567(lo) ;
if lo = hi-1 and hiO-loO > n then
return a;
end if;
if hiO-loO = n then
a := a+1 ;
elif hiO-loO > n then
break;
end if ;
end do:
end do:
end proc:
seq( A333818(n), n=1..300) ; # R. J. Mathar, Oct 08 2020
MATHEMATICA
nmax = 95; CoefficientList[Series[Sum[x^(k (3 k - 2))/(1 - x^(6 k)), {k, 1, nmax}], {x, 0, nmax}], x] // Rest
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Apr 06 2020
STATUS
approved