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.

A191145 Increasing sequence S generated by these rules: a(1)=1, and if x is in S then both 3x+2 and 4x+3 are in S.

Original entry on oeis.org

1, 5, 7, 17, 23, 31, 53, 71, 95, 127, 161, 215, 287, 383, 485, 511, 647, 863, 1151, 1457, 1535, 1943, 2047, 2591, 3455, 4373, 4607, 5831, 6143, 7775, 8191, 10367, 13121, 13823, 17495, 18431, 23327, 24575, 31103, 32767, 39365, 41471, 52487, 55295, 69983, 73727, 93311, 98303, 118097, 124415, 131071, 157463, 165887
Offset: 1

Views

Author

Clark Kimberling, May 28 2011

Keywords

Comments

See A191113.

Crossrefs

See A191113.

Programs

  • Haskell
    import Data.Set (singleton, deleteFindMin, insert)
    a191145 n = a191145_list !! (n-1)
    a191145_list = f $ singleton 1
       where f s = m : (f $ insert (3*m+2) $ insert (4*m+3) s')
                 where (m, s') = deleteFindMin s
    -- Reinhard Zumkeller, Jun 01 2011
  • Mathematica
    h = 3; i = 2; j = 4; k = 3; f = 1; g = 11;
    a = Union[Flatten[NestList[{h # + i, j # + k} &, f, g]]]  (* A191145 *)
    b = (a - 2)/3; c = (a - 3)/4; r = Range[1, 16000];
    d = Intersection[b, r] (* A191145 *)
    e = Intersection[c, r] (* A191145 *)
    m = (a + 1)/2  (* A025613 *)