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!)
A362942 Partial sums of A229037. 2

%I #25 Sep 27 2023 15:08:02

%S 1,2,4,5,6,8,10,14,18,19,20,22,23,24,26,28,32,36,38,42,46,51,56,64,69,

%T 74,83,84,85,87,88,89,91,93,97,101,102,103,105,106,107,109,111,115,

%U 119,121,125,129,134,139,147,152,157,166,175,179,183,188,193

%N Partial sums of A229037.

%H Michael S. Branicky, <a href="/A362942/b362942.txt">Table of n, a(n) for n = 1..100000</a> (using b-file in A229037)

%H N. J. A. Sloane, New Gilbreath Conjectures, Sum and Erase, Dissecting Polygons, and Other New Sequences, Doron Zeilberger's Exper. Math. Seminar, Rutgers, Sep 14 2023: <a href="https://vimeo.com/866583736?share=copy">Video</a>, <a href="http://neilsloane.com/doc/EMSep2023.pdf">Slides</a>, <a href="http://neilsloane.com/doc/EMSep2023.Updates.txt">Updates</a>. (Mentions this sequence.)

%t a[1] = 1; a[n_] := a[n] = Block[{z = 1}, While[Catch[Do[If[z == 2*a[n - k] - a[n - 2*k], Throw@ True], {k, Floor[(n - 1)/2]}]; False], z++]; z]; Accumulate@ Array[a, 120] (* _Michael De Vlieger_, Sep 12 2023, after _Giovanni Resta_ at A229037 *)

%o (Python)

%o from itertools import count, islice

%o def A362942_gen(): # generator of terms

%o blist, c = [], 0

%o for n in count(0):

%o i, j, b = 1, 1, set()

%o while n-(i<<1) >= 0:

%o b.add((blist[n-i]<<1)-blist[n-2*i])

%o i += 1

%o while j in b:

%o j += 1

%o blist.append(j)

%o yield (c:=c+j)

%o A362942_list = list(islice(A362942_gen(),30)) # _Chai Wah Wu_, Sep 12 2023

%Y Cf. A003002, A229037.

%K nonn

%O 1,2

%A _N. J. A. Sloane_, Sep 12 2023

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 September 15 06:13 EDT 2024. Contains 375931 sequences. (Running on oeis4.)