cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A252735 a(1) = 0; for n > 1: a(2n) = a(n), a(2n+1) = 1 + a(A064989(n)).

This page as a plain text file.
%I A252735 #17 Dec 23 2014 00:37:44
%S A252735 0,0,1,0,2,1,3,0,1,2,4,1,5,3,2,0,6,1,7,2,3,4,8,1,2,5,1,3,9,2,10,0,4,6,
%T A252735 3,1,11,7,5,2,12,3,13,4,2,8,14,1,3,2,6,5,15,1,4,3,7,9,16,2,17,10,3,0,
%U A252735 5,4,18,6,8,3,19,1,20,11,2,7,4,5,21,2,1,12,22,3,6,13,9,4,23,2,5,8,10,14,7,1,24,3,4,2,25,6,26,5,3,15,27,1
%N A252735 a(1) = 0; for n > 1: a(2n) = a(n), a(2n+1) =  1 + a(A064989(n)).
%C A252735 Consider the binary tree illustrated in A005940: If we start from any n, computing successive iterations of A252463 until 1 is reached (i.e., we are traversing level by level towards the root of the tree, starting from that vertex of the tree where n is located at), a(n) gives the number of odd numbers > 1 encountered on the path (i.e., excluding the final 1 from the count but including the starting n if it was odd).
%H A252735 Michael De Vlieger, <a href="/A252735/b252735.txt">Table of n, a(n) for n = 1..10000</a>
%F A252735 a(1) = 0; for n > 1: a(2n) = a(n), a(2n+1) =  1 + a(A064989(n)).
%F A252735 a(n) = A080791(A156552(n)). [Number of nonleading 0-bits in A156552(n).]
%F A252735 Other identities:
%F A252735 For all n >= 2:
%F A252735 a(n) = A061395(n) - 1.
%F A252735 a(n) = A000120(A243071(n)) - 1. [One less than the binary weight of A243071(n).]
%F A252735 a(n) = A252464(n) - A252736(n) - 1.
%t A252735 a252735[n_] := Prepend[Rest@Array[PrimePi[FactorInteger[#][[-1]][[1]]] - 1 &, n], 0]; a252735[108] (* _Michael De Vlieger_, Dec 21 2014, after _Stefan Steinerberger_ at A061395 *)
%o A252735 (Scheme, with memoization-macro definec) (definec (A252735 n) (cond ((= 1 n) 0) ((odd? n) (+ 1 (A252735 (A064989 n)))) (else (A252735 (/ n 2)))))
%Y A252735 Essentially one less than A061395.
%Y A252735 Cf. A252464, A252736.
%Y A252735 Cf. A000120, A005940, A064989, A080791, A156552, A243071, A252462, A252464, A252736.
%Y A252735 Cf. also A246369.
%K A252735 nonn
%O A252735 1,5
%A A252735 _Antti Karttunen_, Dec 21 2014