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.

A051146 Sequence b(n) mentioned in A051145.

Original entry on oeis.org

1, 3, 6, 7, 11, 12, 13, 15, 22, 23, 31, 56, 57, 59, 62, 63, 99, 100, 101, 103, 110, 111, 119, 120, 121, 123, 126, 127, 171, 172, 173, 175, 190, 191, 239, 240, 241, 243, 246, 247, 251, 252, 253, 255, 310, 311, 319, 328, 329, 331, 334, 335, 339, 340, 341, 343
Offset: 1

Views

Author

N. J. A. Sloane, E. M. Rains

Keywords

Crossrefs

Cf. A051145.

Programs

  • Haskell
    import Data.Bits ((.|.))
    a051146 n = a051146_list !! (n-1)
    a051146_list = zipWith (.|.) a051145_list $ tail a051145_list
    -- Reinhard Zumkeller, Oct 25 2012
  • Mathematica
    (* a5 = A051145 *) a5[0] = 0; a5[1] = 1; a5[n_] := a5[n] = (b = 0; While[b++; BitOr[b, a5[n-1]] <= BitOr[a5[n-2], a5[n-1]]]; b); a[n_] := BitOr[a5[n], a5[n+1]]; Table[a[n], {n, 0, 55}] (* Jean-François Alcover, Jan 09 2013 *)

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Oct 03 2000