|
Search: id:A063169
|
|
| |
|
| 1, 6, 51, 568, 7845, 129456, 2485567, 54442368, 1339822377, 36602156800, 1099126705611, 35986038303744, 1275815323139149, 48693140873545728, 1990581237014772375, 86778247940387209216, 4018626330009931930833
(list; graph; listen)
|
|
|
OFFSET
|
1,2
|
|
|
COMMENT
|
Schenker sums without n-th term.
a(n)/n^n = Q(n) (called Ramanujan's function by Knuth)
Urn, n balls, with replacement: how many selections before a ball is chosen that was chosen already? Expected value is a(n)/n^n.
|
|
REFERENCES
|
D. E. Knuth, The Art of Computer Programming, 3rd ed. 1997, Vol. 1, Addison-Wesley, Reading, MA, 1.2.11.3 p. 116
|
|
LINKS
|
Marijke van Gans, Schenker sums
|
|
FORMULA
|
a(n) = Sum[k=0..n-1] n^k n!/k!
a(n)/n! = Sum[k=0..n-1] n^k/k! (first n terms of e^n power series)
E.g.f.: T/(1-T)^2, where T=T(x) is Euler's tree function (see A000169) - Len Smiley (smiley(AT)math.uaa.alaska.edu), Nov 28 2001
|
|
EXAMPLE
|
e.g. a(4) = (1*2*3*4) + 4*(2*3*4) + 4*4*(3*4) + 4*4*4*(4)
|
|
PROGRAM
|
(UBASIC) 10 for N=1 to 42 : T=N^N : S=0
(UBASIC) 20 for K=N to 1 step -1 : T/=N : T*=K : S+=T : next K
(UBASIC) 30 print N, S : next N
(PARI) a(n)=sum(k=1, n, binomial(n, k)*n^(n-k)*k!) /* Michael Somos Jun 09 2004 */
|
|
CROSSREFS
|
a(n) = A063170(n) - n^n. Cf. A001865.
Sequence in context: A057817 A000405 A113352 this_sequence A134525 A125865 A134276
Adjacent sequences: A063166 A063167 A063168 this_sequence A063170 A063171 A063172
|
|
KEYWORD
|
nonn,easy,nice
|
|
AUTHOR
|
Marijke van Gans (marijke(AT)maxwellian.demon.co.uk)
|
|
|
Search completed in 0.002 seconds
|