The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A370254 a(0) = 1, a(n) = result of eliminating the digit 7 from the sum of all previous terms for n>=1. 2
1, 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 8192, 16384, 3268, 36036, 202, 224, 2498, 4996, 9992, 89984, 19968, 199936, 39982, 439854, 8908, 888616, 1232, 18464, 196928, 1993856, 39812, 402524, 4430048, 8860096, 120192, 1840384, 1968068 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
LINKS
FORMULA
a(n) = A004182(Sum_{i=0..n-1} a(i)) for n >= 1, a(0) = 1.
a(n) = A011782(n) for n <= 15.
EXAMPLE
a(16) = 3268 since the sum of a(0)..a(15) = 32768. Eliminating the "7" we get 3268.
MAPLE
a:= proc(n) option remember; `if`(n=0, 1, (l-> add(l[i]*10^(i-1),
i=1..nops(l)))(subs(7=NULL, convert(s(n-1), base, 10))))
end:
s:= proc(n) option remember; `if`(n<0, 0, s(n-1)+a(n)) end:
seq(a(n), n=0..40); # Alois P. Heinz, Feb 15 2024
MATHEMATICA
Module[{nmax=50, s=1, a}, NestList[(s+=(a=FromDigits[DeleteCases[IntegerDigits[s], 7]]); a) &, s, nmax]] (* Paolo Xausa, Feb 19 2024 *)
PROG
(PARI) lista(nn) = my(va = vector(nn)); va[1] = 1; for (n=2, nn, va[n] = sum(k=1, n-1, va[k]); my(d=digits(va[n])); if (vecsearch(Set(d), 7), my(list = List()); for (i=1, #d, if (d[i] !=7, listput(list, d[i])); ); va[n] = fromdigits(Vec(list)); ); ); va; \\ Michel Marcus, Feb 13 2024
CROSSREFS
Sequence in context: A190126 A219676 A220469 * A328679 A220051 A220493
KEYWORD
nonn,look,base
AUTHOR
Sergio Pimentel, Feb 13 2024
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 20 16:51 EDT 2024. Contains 372719 sequences. (Running on oeis4.)