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.

A187108 Odd numbers not in the trajectory of a smaller number under the Collatz (3x+1) iteration.

Original entry on oeis.org

1, 3, 7, 9, 15, 19, 21, 25, 27, 33, 37, 39, 43, 45, 51, 55, 57, 63, 69, 73, 75, 79, 81, 87, 93, 97, 99, 105, 109, 111, 115, 117, 123, 127, 129, 133, 135, 141, 145, 147, 151, 153, 159, 163, 165, 169, 171, 177, 181, 183, 187, 189, 195, 199, 201, 207, 213, 217
Offset: 1

Views

Author

Jimin Park, Mar 05 2011

Keywords

Comments

These are the odd numbers in A061641, which gives a more detailed explanation. - T. D. Noe, Mar 05 2011

Crossrefs

Cf. A061641.

Programs

  • ActionScript
    // AS3
    var a:Array=new Array();
    var i:int;
    var n:int=0;
    var ni:int;
    var s:String='';
    for (i=0;i<50;i++){
    while(a[n]!=undefined) n++;
    s+=String(2*n+1)+',';
    a[n]=1;
    ni=2*n+1;
    while(ni>=2*n+1&&ni>1){
    ni=3*ni+1;
    while(ni%2==0)ni/=2;
    a[(ni-1)/2]=1;
    }
    }
    trace(s);