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.

A209081 Floor(A152170(n)/n^n). Floor of the expected value of the cardinality of the image of a function from [n] to [n].

Original entry on oeis.org

1, 1, 2, 2, 3, 3, 4, 5, 5, 6, 7, 7, 8, 9, 9, 10, 10, 11, 12, 12, 13, 14, 14, 15, 15, 16, 17, 17, 18, 19, 19, 20, 21, 21, 22, 22, 23, 24, 24, 25, 26, 26, 27, 27, 28, 29, 29, 30, 31, 31, 32, 33, 33, 34, 34, 35, 36, 36, 37, 38
Offset: 1

Views

Author

Washington Bomfim, Mar 05 2012

Keywords

Comments

From the first commentary of A152170, a(n)= floor(A152170(n)/n^n) = floor((n(n^n-(n-1)^n))/n^n) = floor(n-(n-1)^n/n^(n-1)).

Examples

			a(1) = 1 because the image of a function from [1] to [1] has one value. a(2) = 1 since we can consider functions with domain {x,y}, and image {X,Y}. We can have f(x)=X, f(y)=X; f(x)=X, f(y)=Y; f(x)=Y, f(y)=Y; f(x)=Y, f(y)=X.
The sum of the cardinalities of the images divided by the number of functions is (1+2+1+2)/4 = 1.5. Floor(1.5)=1.
		

Crossrefs

Cf. A152170.

Formula

a(n) = floor(n-(n-1)^n/n^(n-1)).