This site is supported by donations to The OEIS Foundation.

User:Thomas Scheuerle/Archived A343422

From OeisWiki
Jump to: navigation, search
A343422 		
Triangle read by rows: T(n,k) = log_3(A014682^n(k+1+2^n)-A014682^n(k+1)), k is in the range 0..2^n-1. 		
0, 1, 0, 1, 1, 2, 0, 2, 1, 2, 1, 1, 2, 3, 0, 2, 2, 2, 1, 1, 2, 3, 1, 3, 1, 3, 2, 2, 3, 4, 0, 3, 2, 2, 2, 2, 2, 4, 1, 4, 1, 3, 2, 2, 3, 4, 1, 2, 3, 3, 1, 1, 3, 3, 2, 3, 2, 4, 3, 3, 4, 5, 0, 3, 3, 3, 2, 2, 2, 4, 2, 4, 2, 3, 2, 2, 4, 4, 1, 3, 4, 4, 1, 1, 3, 3, 2, 3, 2, 5, 3 (

	OFFSET 	

0,6
	COMMENTS 	

A014682^n means n times recursion into A014682.

We define A014682^0(n) = n and A014682^1(n) = A014682(n), A014682^2(n) = A014682(A014682(n)).

This sequence is a rearrangement of A023416 (number of 0's in binary expansion of n), with T(0,0) as an exception.

All columns k containing any number smaller than 2 are A181666(k+1).

Let m be the smallest number of column k, then the number k+1 requires a maximum of 3^m operations of the type (3x+1), to reach 1 in the Collatz conjecture. The smallest number in each column is always at its start.

All columns k progress with a formula of the form T(n+m,k) = floor((m+r)/(2^s)), s > 0.

The maximum number in each row n is exactly one plus the maximum of the last row (n-1), this maximum will be found always on the second last position k = (2^n-2).

See the link section for a Collatz graph with each node colored by T(ceiling(log_2(k)),k-1). White color means T(ceiling(log_2(k)),k-1) = 0, green 1, yellow 2, red 3 and magenta 4. It can be seen that each color just touches two other colors in the graph and touches them in the order of the corresponding numbers. All yellow nodes with connections to green nodes are in A198584 (Odd numbers producing 3 odd numbers).
	LINKS 	

Table of n, a(n) for n=0..90.

Media:Backup_A343422.png
Thomas Scheuerle, Collatz graph. Number k colored by smallest value in column k of T(n,k).

Index entries for sequences related to 3x+1 (or Collatz) problem FORMULA

T(n,2^n-1) = 0.

T(n,2^n-2) = n, n > 0.

T(n+m,2^n-1) = floor((m+1)/2).

T(n+1,k*2+1) = T(n,k).

Sum_{k=n..2^n-1} 3^T(n,k) = 2^(2*n).

T(n,m) = A000120(A339694(n,m+1 mod 2^n)) (The binary weight of A339694). - Thomas Scheuerle, Aug 17 2021 EXAMPLE

Triangle begins:

 0;
 1, 0;
 1, 1, 2, 0;
 2, 1, 2, 1, 1, 2, 3, 0;
 2, 2, 2, 1, 1, 2, 3, 1, 3, 1, 3, 2, 2, 3, 4, 0;
 ...

PROG

(MATLAB)

function a = A343422 ( max_n )

   a = 0;
   for n = 1:max_n
       an = [];
       for k = 1: 2^n
         an(k) = log2(A014682_exp(k+2^n, n)-A014682_exp(k, n))/log2(3);
       end
       a = [a an];
   end

end

function [ out ] = A014682_exp( in, num )

   out = in;
   for n = 1:num
       out = A014682( out );
   end

end

function [ out ] = A014682( in )

   if mod(in, 2) == 0
       out = in/2;
   else
       out = ((in*3) + 1)/2;
   end

end

(PARI) f(n) = if(n%2, 3*n+1, n)/2; \\ A014682

fk(k, n) = my(m=n); for(i=1, k, m = f(m)); m;

T(n, k) = valuation(fk(n, k+1+2^n) - fk(n, k+1), 3);

tabf(nn) = for (n=0, nn, for (k=0, 2^n-1, print1(T(n, k), ", ")); print); \\ Michel Marcus, Apr 26 2021 CROSSREFS

Cf. A014682, A023416, A181666, A339694.

Sequence in context: A330868 A178687 A325538 * A238417 A117929 A306439

Adjacent sequences: A343419 A343420 A343421 * A343423 A343424 A343425 KEYWORD

nonn,tabf,changed AUTHOR

Thomas Scheuerle, Apr 25 2021 STATUS

proposed