|
Search: id:A072921
|
|
|
| A072921 |
|
a(1)=1; a(n) = a(n-1) + [sum of all decimal digits present so far in the sequence]. |
|
+0 5
|
|
| 1, 2, 5, 13, 25, 44, 71, 106, 148, 203, 263, 334, 415, 506, 608, 724, 853, 998, 1169, 1357, 1561, 1778, 2018, 2269, 2539, 2828, 3137, 3460, 3796, 4157, 4535, 4930, 5341, 5765, 6212, 6670, 7147, 7643, 8159, 8698, 9268, 9863, 10484, 11122
(list; graph; listen)
|
|
|
OFFSET
|
1,2
|
|
|
FORMULA
|
a(1)=1,a(2)=2; a(n+1)=2a(n)-a(n-1)+sod(a(n)) (sod = "sum of digits"). - Farideh Firoozbakht (mymontain(AT)yahoo.com), Oct 01 2009
Asymptotically it seems a(n)~c*n^2*log(n) for c~1.99... [From Benoit Cloitre (benoit7848c(AT)orange.fr), Oct 07 2009]
|
|
MAPLE
|
Maple program from Alois Heinz:
b:= proc(n) option remember; local m;
m:= a(n);
`if` (n=1, 0, b(n-1));
while m>0 do
%+ irem (m, 10, 'm')
od;
%
end;
a:= proc(n) option remember;
`if` (n=1, 1, a(n-1) +b(n-1))
end;
seq (a(n), n=1..50);
|
|
MATHEMATICA
|
a[1]=1; a[2]=2; a[n_]:=a[n]=2*a[n-1]-a[n-2]+Apply[Plus, IntegerDigits[a[n-1]]]; Table[a[n], {n, 100}] (from Farideh Firoozbakht (mymontain(AT)yahoo.com), Oct 01 2009)
a[1] = 1; a[n_] := a[n] = a[n - 1] + Plus @@ Flatten[ Map[ IntegerDigits, Array[a, n - 1]]]; Array[a, 100] - Robert G. Wilson, v, Oct 01 2009
|
|
CROSSREFS
|
Cf. A152231-A152234.
Adjacent sequences: A072918 A072919 A072920 this_sequence A072922 A072923 A072924
Sequence in context: A106009 A079780 A048871 this_sequence A087250 A065301 A126656
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
N. J. A. Sloane, Oct 07 2009, based on a posting to the Sequence Fans Mailing List by Eric Angelini (Eric.Angelini(AT)kntv.be), Oct 01 2009
|
|
EXTENSIONS
|
More terms from Alois Heinz, Oct 01 2009
|
|
|
Search completed in 0.002 seconds
|