OFFSET
0,3
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..300
FORMULA
a(n) = ((n - sqrt(n+1))^n + (n + sqrt(n+1))^n)/2.
MAPLE
seq( round(((n-sqrt(n+1))^n + (n+sqrt(n+1))^n)/2), n=0..20); # G. C. Greubel, Jan 09 2020
MATHEMATICA
Table[Round[((n+Sqrt[n+1])^n + (n-Sqrt[n+1])^n)/2], {n, 0, 20}] (* G. C. Greubel, Jan 09 2020 *)
PROG
(PARI) vector(21, n, round(((n-1-sqrt(n))^(n-1) + (n-1+sqrt(n))^(n-1))/2) ) \\ G. C. Greubel, Jan 09 2020
(Magma) [Round(((n-Sqrt(n+1))^n + (n+Sqrt(n+1))^n)/2): n in [0..20]]; // G. C. Greubel, Jan 09 2020
(Sage) [round(((n-sqrt(n+1))^n + (n+sqrt(n+1))^n)/2) for n in (0..20)] # G. C. Greubel, Jan 09 2020
(GAP) List([0..20], n-> ((n-Sqrt(n+1))^n + (n+Sqrt(n+1))^n)/2); # G. C. Greubel, Jan 09 2020
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paul Barry, May 11 2003
STATUS
approved