login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A247083 a(n) = 0 for n <= 0: Starting with n=1, a(n) = 1 + the sum of the digital sums of a(0) through a(n-3). 1
0, 1, 1, 1, 2, 3, 4, 6, 9, 13, 19, 28, 32, 42, 52, 57, 63, 70, 82, 91, 98, 108, 118, 135, 144, 154, 163, 172, 182, 192, 202, 213, 225, 229, 235, 244, 257, 267, 277, 291, 306, 322, 334, 343, 350, 360, 370, 378, 387, 397, 415, 433, 452, 462, 472, 483, 495, 508, 523, 541, 554, 564, 574 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,5
LINKS
FORMULA
a(n) = 1 + Sum_{k=0..n-3} digsum(a(k)).
a(n) = a(n-1) + A007953(a(n-3)).
EXAMPLE
a(10) = 28 because (0+1+1+2+3+5+8+1+3+2+1) + 1 = 28.
MAPLE
A247083 := proc(n)
option remember;
if n <= 0 then
0;
else
1+add(digsum(procname(i)), i=0..n-3) ;
end if;
end proc: # R. J. Mathar, Dec 02 2014
MATHEMATICA
a247083[n_Integer] := Module[{t = Table[1, {i, n + 1}], j, k},
t[[1]] = 0; j = 5; While[j <= Length[t], t[[j]] = Sum[Plus @@ IntegerDigits[t[[k]]], {k, 1, j - 3}]; j++]; Drop[t, {2}]]; a247083[63] (* Michael De Vlieger, Nov 26 2014 *)
PROG
(Sage)
n=100
a=[0, 1, 1]
for i in [3..n]:
a.append(1+sum(sum(a[j].digits()) for j in [1..(i-3)]))
a # Tom Edgar, Nov 25 2014
(PARI) v=[0]; n=1; while(n<100, s=0; for(i=1, #v-2, s+=sumdigits(v[i])); v=concat(v, 1+s); n++); v \\ Derek Orr, Nov 26 2014
CROSSREFS
Sequence in context: A017983 A139077 A017825 * A159848 A017826 A068921
KEYWORD
nonn,base,easy
AUTHOR
Bob Selcoe, Nov 17 2014
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 3 06:05 EDT 2024. Contains 372205 sequences. (Running on oeis4.)