reviewed
approved
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”).
reviewed
approved
proposed
reviewed
editing
proposed
def g(n, k):
def g(n, k): return (0 if n > k else 1) + (0 if isprime(n) else sum([0 if d>k else g(n//d, d) for d in divisors(n)[1:-1]] if d <= k))
p = reduce(mul, [(prime(t + 1)**l[t] for t in range(len(l))]))
else:
else: return 0 if i<1 else sum([b(n - i*j, i - 1, l + [i]*j) for j in range(n//i + 1)])
def a(n): return b(n, n, [])
return b(n, n, [])
for n in range(1, 11): print (a(n) ) # Indranil Ghosh, Aug 19 2017, after Maple code
approved
editing
proposed
approved
editing
proposed
Andrew Howroyd, <a href="/A035310/b035310.txt">Table of n, a(n) for n = 1..50</a>
1, 4, 12, 47, 170, 750, 3255, 16010, 81199, 448156, 2579626, 15913058, 102488024, 698976419, 4976098729, 37195337408, 289517846210, 2352125666883, 19841666995265, 173888579505200, 1577888354510786, 14820132616197925, 143746389756336173, 1438846957477988926
(PARI)
EulerT(v)={Vec(exp(x*Ser(dirmul(v, vector(#v, n, 1/n))))-1, -#v)}
D(p, n)={my(v=vector(n)); for(i=1, #p, v[p[i]]++); my(u=EulerT(v)); Vec(1/prod(k=1, n, 1 - u[k]*x^k + O(x*x^n))-1, -n)/prod(i=1, #v, i^v[i]*v[i]!)}
seq(n)={my(s=0); forpart(p=n, s+=D(p, n)); s} \\ Andrew Howroyd, Dec 30 2020
nonn,more,nice
Terms a(16) and beyond from Andrew Howroyd, Dec 30 2020
approved
editing
proposed
approved
editing
proposed