OFFSET
1,3
LINKS
R. J. Mathar, Table of n, a(n) for n = 1..434 augmenting an earlier file of 188 elements by R. H. Hardin
EXAMPLE
Table starts
.....1.....1......1......1......1......1......1.......1.......1.......1......1
.....2.....3......4......5......6......7......8.......9......10......11.....12
.....3.....4......5......8......9.....10.....11......12......15......16.....17
....12....17.....25.....34.....46.....57.....75......88.....108.....125....147
....25....45.....64.....88....117....159....216.....270.....333.....421....500
...106...176....286....421....636....862...1206....1587....2114....2698...3450
...376...644...1055...1696...2596...3796...5443....7674...10392...14198..18641
..1670..2983...5191...8373..13343..20224..30358...43750...62354...86173.118859
..7315.13675..24135..40681..66452.105208.160866..242128..354103..510107.717077
.35808.67487.122238.211234.354806.573982.907542.1393159.2104002.3099873
Some solutions for n=5 k=3
.-4...-6...-5....0...-4...-1...-5...-3...-5...-5...-6...-6...-6...-4...-1...-4
.-2...-5...-5....0...-1....0...-2...-2....1....0....0...-6....3....2...-1...-1
.-2....3....3....0....2....0....2...-2....2....0....0....0....3....2...-1...-1
.-1....4....4....0....2....0....3....1....2....0....0....6....3....2...-1....3
..5....6....5....0....3....1....4....4....4....5....6....6....3....2....2....3
MAPLE
A188002rec := proc(n, nminusfE, E)
option remember ;
local a, fEminus, fEplus, f0 ;
if E = 0 then
if n = 0 then
1;
else
0;
end if;
else
a :=0 ;
for fEminus from 0 to nminusfE do
for fEplus from 0 to nminusfE-fEminus do
f0 := nminusfE-fEminus-fEplus ;
a := a+procname(n-E^2*fEminus+E^2*fEplus, f0, E-1) ;
end do:
end do:
a ;
end if;
end proc:
A188002 := proc(n, k)
A188002rec(0, n, n+k-2) ;
end proc:
seq(seq( A188002(n, d-n), n=1..d-1), d=2..10) ; # R. J. Mathar, May 09 2023
MATHEMATICA
f[n_, nminusfE_, E_] := f[n, nminusfE, E] = Module[{a, fEminus , fEplus, f0}, If[E == 0, If[n == 0, 1, 0], a = 0; For[fEminus = 0, fEminus <= nminusfE, fEminus++, For[fEplus = 0, fEplus <= nminusfE - fEminus, fEplus++, f0 = nminusfE - fEminus - fEplus; a = a + f[n - E^2*fEminus + E^2*fEplus, f0, E - 1]]]; a]];
T[n_, k_] := T[n, k] = f[0, n, n + k - 2];
Table[Table[ T[n, d - n], {n, 1, d - 1}], {d, 2, 12}] // Flatten (* Jean-François Alcover, Aug 21 2023, after R. J. Mathar *)
PROG
(PARI) A188002(n, k) = my(s, X, Y, p, pi, pj); s = (n+k-2)^2*n\2; Y = 'y + O('y^(s+1)); X = 'x + O('x^(n+1)); p = prod(i=1, n+k-2, 1/(1-X*Y^(i^2))); sum(i=0, n, pi=polcoef(p, i); sum(j=i, n-i, pj=polcoef(p, j); sum(d=0, s, polcoef(pi, d)*polcoef(pj, d)) * (2-(i==j)) )); \\ Max Alekseyev, Sep 18 2023
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
R. H. Hardin, Mar 18 2011
STATUS
approved