OFFSET
1,3
COMMENTS
When writing n^(n-1) (A000169) as a sum of powers of n using the binomial theorem, one can separately sum the even and the odd powers of n. This is the odd part. See the Formula section.
FORMULA
a(n+1) = Sum_{k=0..floor((n-1)/2)} n^(2k+1)*binomial(n, 2k+1).
a(n+1) = ((1 + n)^n - (1 - n)^n)/2.
a(n) ~ (1 + (-1)^n/e^2) * n^(n-1) / 2. - Amiram Eldar, Dec 29 2025
MATHEMATICA
Table[Plus @@ Table[(n - 1)^(2 k + 1) Binomial[n - 1, 2 k + 1], {k, 0, Floor[(n - 1)/2]}], {n, 1, 21}]
a[n_] := (n^(n-1) - (2-n)^(n-1))/2; Array[a, 20] (* Amiram Eldar, Dec 29 2025 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Olivier Gérard, Jun 21 2021
STATUS
approved
