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!)
A297212 a(0)=1; a(1)=1; for n >= 2, a(n) = a(A023416(n)) + a(A000120(n)). 1

%I #28 Mar 16 2022 20:00:08

%S 1,1,2,3,3,3,3,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,4,5,5,5,4,5,4,4,4,4,5,

%T 5,6,5,6,6,5,5,6,6,5,6,5,5,4,5,6,6,5,6,5,5,4,6,5,5,4,5,4,4,4,4,5,5,6,

%U 5,6,6,6,5,6,6,6,6,6,6,5,5,6,6,6,6,6,6,5,6,6

%N a(0)=1; a(1)=1; for n >= 2, a(n) = a(A023416(n)) + a(A000120(n)).

%H Michael De Vlieger, <a href="/A297212/b297212.txt">Table of n, a(n) for n = 0..10000</a>

%H B. Balamohan, A. Kuznetsov and S. Tanny, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL10/Tanny/tanny3.html">On the behavior of a variant of Hofstadter's Q-sequence</a>, J. Integer Sequences, Vol. 10 (2007), #07.7.1.

%H Nathaniel D. Emerson, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL9/Emerson/emerson6.html">A Family of Meta-Fibonacci Sequences Defined by Variable-Order Recursions</a>, J. Integer Sequences, Vol. 9 (2006), #06.1.8.

%e n=7, A000120(7)=3 , A023416(7)=0. a(7)=a(3)+a(0), a(3)=a(2)+a(0), a(2)=a(1)+a(1). So a(7) = a(1)+a(1)+a(0)+a(0) = 2*a(0) + 2*a(1) = 4.

%t a[0] = a[1] = 1; a[n_] := a[n] = a[#1] + a[#2] & @@ DigitCount[n, 2]; Array[a, 90, 0]] (* _Michael De Vlieger_, Mar 16 2022 *)

%o (PARI) a(n) = if (n<=1, 1, a(hammingweight(n)) + a(#binary(n)-hammingweight(n)));

%Y Cf. A000120, A023416.

%K nonn,base

%O 0,3

%A _Ctibor O. Zizka_, Dec 27 2017

%E More terms from _Michel Marcus_, Mar 16 2022

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 4 10:30 EDT 2024. Contains 372240 sequences. (Running on oeis4.)