login
A071691
Number of ways to write n as n = x!+y!+z!+t! with 0<=x<=y<=z<=t<=n.
0
0, 0, 0, 5, 4, 3, 2, 1, 4, 3, 2, 1, 0, 3, 2, 1, 0, 0, 2, 1, 0, 0, 0, 1, 0, 0, 4, 3, 2, 1, 0, 3, 2, 1, 0, 0, 2, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 3, 2, 1, 0, 0, 2, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0
OFFSET
1,4
COMMENTS
If a(n) > 1, a(n+1) = a(n) - 1.
Since numbers of the form n! are rare, sequence behaves quite regularly. - Lambert Klasen (lambert.klasen(AT)gmx.de), Dec 23 2004
PROG
(PARI) for(n=1, 54, print1(sum(a=0, n, sum(b=0, a, sum(c=0, b, sum(d=0, c, if(a!+b!+c!+d!-n, 0, 1))))), ", "))
CROSSREFS
Sequence in context: A031016 A261302 A284803 * A319332 A031017 A266084
KEYWORD
easy,nonn
AUTHOR
Benoit Cloitre, Jun 23 2002
EXTENSIONS
More terms from Lambert Klasen (lambert.klasen(AT)gmx.de), Dec 23 2004
STATUS
approved