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.
%I A319936 #30 May 30 2022 16:33:48 %S A319936 113,227,453,906,909,1812,1813,1818,2417,3624,3626,3636,3637,7248, %T A319936 7252,7253,7272,7281,9669,14496,14504,14544,14549,14562,14563,19338, %U A319936 28992,29008,29013,29088,29124,29125,30559,38676,38677,38833,38835,45839,54327,57984 %N A319936 Numbers with more than one Collatz tripling step whose odd Collatz trajectory does not contain primes. %C A319936 The starting number itself is not counted in the trajectory, otherwise prime numbers like 113 or 227 wouldn't appear in this sequence. %C A319936 The "odd Collatz trajectory" of a number k is the subset of odd numbers of the full Collatz trajectory of k. %e A319936 113 is in this sequence because 113*3+1 = 340; 340/2 = 170; 170/2 = 85; 85*3+1 = 256, which goes to 1. The trajectory has 2 (> 1) tripling steps and 85 isn't a prime. %e A319936 114 is not in this sequence because 114/2 = 57; 57*3+1 = 172; 172/2 = 86; 86/2 = 43, which is a prime, and this trajectory has more than 1 tripling step. %t A319936 Select[Range[3, 60000], And[Count[#, _?OddQ] > 1, NoneTrue[Rest@ #, PrimeQ]] &@ NestWhileList[If[EvenQ@ #, #/2, 3 # + 1] &, #, # > 2 &, 1, Infinity, -1] &] (* _Michael De Vlieger_, Nov 07 2018 *) %o A319936 (Java) %o A319936 for(int i = 0; i < DIM; i++) { %o A319936 if(!collatzAtLeastOnePrime(c) && collatzTriplingSteps(c) > 1) %o A319936 System.out.print(c + ", "); %o A319936 } %o A319936 boolean collatzAtLeastOnePrime(int i) { %o A319936 //first step outside the while loop... %o A319936 if(i % 2 == 0) %o A319936 i /= 2; %o A319936 else %o A319936 i = 3 * i + 1; %o A319936 //...otherwise prime numbers like 113 or 227 would be excluded %o A319936 while(i > 1) { %o A319936 if(i % 2 == 0) { %o A319936 i /= 2; %o A319936 } %o A319936 else { %o A319936 if(BigInteger.valueOf(i).isProbablePrime(10)) %o A319936 return true; %o A319936 i = 3 * i + 1; %o A319936 } %o A319936 } %o A319936 return false; %o A319936 } %Y A319936 Cf. A002450, A006577. %K A319936 nonn %O A319936 1,1 %A A319936 _Alessandro Polcini_, Oct 10 2018