OFFSET
2,1
COMMENTS
FORMULA
a(n) = (n^n*(n^n*(n-2)+2)-n^2+n-1)/(n-1)^2.
EXAMPLE
a(2) = 5 = 101_2;
a(8) = 34466324363639 = 765432101234567_8;
a(10) = 9876543210123456789;
a(16) = 21173125052858393282329502187520773615 = FEDC...876543210123456789ABCDEF_16.
PROG
(Python)
def A068793(n): return ((m:=n**n)*(m*(n-2)+2)-n**2+n-1)//(n-1)**2 # Chai Wah Wu, Mar 18 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Mar 04 2002
STATUS
approved