OFFSET
0,5
COMMENTS
a(n) > n if n is in A058080 Union {0}, and, a(n) <= n if n is in A007964; indeed, a(n) = n only for n = 1. - Bernard Schott, Sep 22 2019
LINKS
David A. Corneth, Table of n, a(n) for n = 0..9999 (first 5001 terms from Robert Israel)
FORMULA
a(n) = [x^n] Product_{d|n, d <= sqrt(n)} 1 / (1 - x^d).
a(p) = 1, where p is prime.
a(p*q) = q+1 if p <= q are primes. - Robert Israel, Sep 22 2019
EXAMPLE
The divisors of 6 are 1, 2, 3, 6 and sqrt(6) = 2.449..., so the possible partitions are 1+1+1+1+1+1 = 1+1+1+1+2 = 1+1+2+2 = 2+2+2; thus a(6) = 4. - Bernard Schott, Sep 22 2019
MAPLE
f:= proc(n) local x, t, S;
S:= 1;
for t in numtheory:-divisors(n) do
if t^2 <= n then
S:= series(S/(1-x^t), x, n+1);
fi
od;
coeff(S, x, n);
end proc:
map(f, [$0..100]); # Robert Israel, Sep 22 2019
MATHEMATICA
a[n_] := SeriesCoefficient[Product[1/(1 - Boole[d <= Sqrt[n]] x^d), {d, Divisors[n]}], {x, 0, n}]; Table[a[n], {n, 0, 70}]
PROG
(Magma) [1] cat [#RestrictedPartitions(n, {d:d in Divisors(n)| d le Sqrt(n)}):n in [1..70]]; // Marius A. Burtea, Sep 20 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Ilya Gutkovskiy, Sep 20 2019
STATUS
approved