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!)
A107751 a(n) = A107750(n+1) - A107750(n). 2

%I #8 Dec 23 2018 16:13:08

%S 1,1,1,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,

%T 1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,

%U 2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2,1,1,2

%N a(n) = A107750(n+1) - A107750(n).

%H Antti Karttunen, <a href="/A107751/b107751.txt">Table of n, a(n) for n = 0..65537</a>

%F a(n) = if n<=4 then 1 else 0^(a(n-1)-1) + 0^(a(n-2)-1).

%t A107751[ nmax_ ] := Length /@ Split[ (Total[ 1 - IntegerDigits[ #1, 2 ] ] &) /@ Range[ 0, nmax ] ]; A107751[ 200 ] - Peter Pein (petsie(AT)dordos.net), Oct 12 2007

%o (PARI)

%o up_to = 65537;

%o A107751list(up_to) = { my(v=vector(up_to)); v[1]=v[2]=v[3]=v[4]=1; for(n=5,up_to,v[n] = (0^(v[n-1]-1) + 0^(v[n-2]-1))); (v); };

%o v107751 = A107751list(up_to);

%o A107751(n) = if(!n,1,v107751[n]); \\ _Antti Karttunen_, Dec 23 2018

%Y Cf. A100063, A099837, A100051, A107688.

%K nonn

%O 0,6

%A _Reinhard Zumkeller_, May 23 2005

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 April 25 01:35 EDT 2024. Contains 371964 sequences. (Running on oeis4.)