login
A135207
a(n)=Sum_digits{n^Sum_digits[a(n-1)]}, with a(0)=1.
1
1, 1, 2, 9, 19, 40, 18, 28, 37, 45, 1, 2, 9, 46, 67, 81, 64, 55, 54, 73, 7, 36, 55, 49, 99, 109, 64, 63, 64, 34, 18, 55, 76, 81, 73, 73, 72, 82, 79, 90, 19, 49, 99, 136, 82, 63, 64, 70, 54, 73, 40, 27, 82, 82, 72, 82, 70, 72, 91, 49, 36, 64, 91, 99, 145, 79, 126, 82, 58, 126, 28
OFFSET
0,3
LINKS
MAPLE
P:=proc(n) local a, i, k, w; a:=1; print(a); for i from 1 by 1 to n do w:=0; k:=a; while k>0 do w:=w+k-(trunc(k/10)*10); k:=trunc(k/10); od; k:=i^w; w:=0; while k>0 do w:=w+k-(trunc(k/10)*10); k:=trunc(k/10); od; a:=w; print(w); od; end: P(100);
MATHEMATICA
nxt[{n_, a_}]:={n+1, Total[IntegerDigits[(n+1)^Total[IntegerDigits[a]]]]}; NestList[nxt, {0, 1}, 70][[;; , 2]] (* Harvey P. Dale, Nov 03 2024 *)
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
STATUS
approved