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.

A208127 Cardinality of the set f^n({s}), where f is a variant of the Collatz function that replaces any element x in the argument set with both x/2 and 3*x+1, and s is an arbitrary irrational number.

This page as a plain text file.
%I A208127 #58 Apr 22 2023 10:27:25
%S A208127 1,2,4,8,16,32,64,127,252,495,969,1886,3655,7054,13562,25978,49602,
%T A208127 94440,179380,340001,643276,1215178,2292431,4319603,8131123,15292302,
%U A208127 28738320,53970713,101297742,190028125,356319648,667866054,1251374689,2343968788,4389333758,8217535290,15381296139,28784811039,53859503664
%N A208127 Cardinality of the set f^n({s}), where f is a variant of the Collatz function that replaces any element x in the argument set with both x/2 and 3*x+1, and s is an arbitrary irrational number.
%C A208127 The start value can also be chosen as s = i, the imaginary unit.
%H A208127 Markus Sigg, <a href="/A208127/b208127.txt">Table of n, a(n) for n = 0..42</a>
%H A208127 Markus Sigg, <a href="/A208127/a208127_1.c.txt">C program to calculate as many terms as possible with given amount of memory</a>.
%F A208127 a(n) = |f^n({s})| where f(M) = {x/2 : x in M} union {3x+1 : x in M} and s is an arbitrary irrational number.
%e A208127 a(7) = 127 = 2^7-1 because there are exactly two 7-length sequences of h:=x->x/2 or t:=x->3*x+1 steps yielding the same value: (hhthtth)(s) = (thhhhtt)(s) = 27/16*s + 7/4. - _Alois P. Heinz_, Mar 30 2012
%p A208127 M := {sqrt(2)}:
%p A208127 print(nops(M)):
%p A208127 for i from 1 to 23 do
%p A208127   M := map(x -> x/2, M) union map(x -> 3*x+1, M):
%p A208127   print(nops(M))
%p A208127 end do:
%o A208127 (PARI) \\ maxGB is the available RAM memory size; use allocatemem() before start
%o A208127 a208127(maxGB) = {my (n=log(maxGB)/log(2)+21, v=[I]); for (i=0 , n, if(i>0, v=Set(concat(v/2,3*v+vector(#v,i,1)))); print1(#v,", "))};
%o A208127 a208127(16) \\ _Hugo Pfoertner_, Apr 09 2023
%K A208127 nonn
%O A208127 0,2
%A A208127 _Markus Sigg_, Mar 29 2012
%E A208127 a(23)-a(25) from _Alois P. Heinz_, Mar 30 2012
%E A208127 a(26)-a(28) from _Markus Sigg_, Jul 05 2017
%E A208127 a(29)-a(31) from _Markus Sigg_, Aug 06 2017
%E A208127 a(32) from _Markus Sigg_, Mar 26 2023
%E A208127 a(33)-a(34) from _Hugo Pfoertner_, Mar 26 2023
%E A208127 a(35)-a(38) from _Markus Sigg_, Apr 06 2023