cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A065440 a(n) = (n-1)^n.

Original entry on oeis.org

1, 0, 1, 8, 81, 1024, 15625, 279936, 5764801, 134217728, 3486784401, 100000000000, 3138428376721, 106993205379072, 3937376385699289, 155568095557812224, 6568408355712890625, 295147905179352825856, 14063084452067724991009, 708235345355337676357632
Offset: 0

Views

Author

Len Smiley, Nov 17 2001

Keywords

Comments

a(n) is the number of functions from {1,2,...,n} into {1,2,...,n} that have no fixed points.
The probability that a random function from {1,2,...,n} into {1,2,...,n} has no fixed point is equal to a(n)/n^n; it tends to 1/e when n tends to infinity. - Robert FERREOL, Mar 29 2017

Crossrefs

Essentially the same as A007778 - note T(x) = -W(-x).
Column k=0 of A055134.
Row sums of A350452.

Programs

Formula

a(n) = A007778(n-1).
E.g.f.: x/(T(x)*(1-T(x))) (where T(x) is Euler's tree function, the E.g.f. for n^(n-1)) (see A000169).
a(n) = Sum_{k=0..n} (-1)^k*binomial(n,k)*n^(n-k). - Robert FERREOL, Mar 28 2017
a(n) = Sum_{k=0..n} (-1)^k*binomial(n+2,k+2)*(k+1)*(2*k+n+3)^n. - Vladimir Kruchinin, Aug 13 2025