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.

Showing 1-10 of 17 results. Next

A037015 Numbers n with property that, reading binary expansion of n from right to left, run lengths strictly increase.

Original entry on oeis.org

0, 1, 3, 6, 7, 14, 15, 28, 30, 31, 57, 60, 62, 63, 120, 121, 124, 126, 127, 241, 248, 249, 252, 254, 255, 483, 496, 497, 504, 505, 508, 510, 511, 966, 993, 995, 1008, 1009, 1016, 1017, 1020, 1022, 1023, 1987, 1990, 2016, 2017, 2019, 2032, 2033, 2040, 2041, 2044
Offset: 1

Views

Author

Keywords

Comments

There are A000009(k) elements of this list consisting of k bits. - Jason Kimberley, Jan 22 2013

Examples

			From _Jason Kimberley_, Jan 30 2013: (Start)
Interleaved lines:
binary expansions,
corresponding run lengths (distinct partitions);
1,
1;
11,
2;
110, 111,
2,1; 3;
1110, 1111,
3,1; 4;
11100, 11110, 11111,
3,2; 4,1; 5;
111001, 111100, 111110, 111111,
3,2,1; 4,2; 5,1; 6;
1111000, 1111001, 1111100, 1111110, 1111111,
4,3; 4,2,1; 5,2; 6,1; 7;
11110001, 11111000, 11111001, 11111100, 11111110, 11111111
4,3,1; 5,3; 5,2,1; 6,2; 7,1; 8;
111100011, 111110000, 111110001, 111111000, 111111001, 111111100, 111111110, 111111111,
4,3,2; 5,4; 5,3,1; 6,3; 6,2,1; 7,2; 8,1; 9;
Notice the reversed sorting when a part corresponds to a run of 0's.
(End)
		

Crossrefs

Subsequence of A037016, cf. A037013, A037014.
Cf. A030308.

Programs

  • Haskell
    import Data.List (group)
    a037015 n = a037015_list !! (n-1)
    a037015_list = filter (all (> 0) . ds) [0..] where
       ds x = zipWith (-) (tail gs) gs where
          gs = map length $ group $ a030308_row x
    -- Reinhard Zumkeller, Jul 31 2013, Mar 10 2012
    
  • Mathematica
    Select[Range[0,2500],Min[Differences[Length/@Split[ Reverse[ IntegerDigits[ #,2]]]]]>0&] (* Harvey P. Dale, Nov 18 2014 *)
    Select[Range[0,2100],Max[Differences[Length/@Split[IntegerDigits[#,2]]]]<0&] (* Harvey P. Dale, Jun 28 2020 *)
  • Python
    from itertools import groupby
    A037015_list = []
    for n in range(10**5):
        c = None
        for x, y in groupby(bin(n)[2:]):
            z = len(list(y))
            if c != None and z >= c:
                break
            c = z
        else:
            A037015_list.append(n) # Chai Wah Wu, Sep 14 2021

Extensions

More terms from Patrick De Geest, Feb 15 1999
Offset fixed and missing 1023 inserted by Reinhard Zumkeller, Mar 10 2012

A037016 Numbers n with property that reading binary expansion from right to left (least significant to most significant), run lengths do not decrease.

Original entry on oeis.org

0, 1, 2, 3, 5, 6, 7, 10, 12, 13, 14, 15, 21, 25, 26, 28, 29, 30, 31, 42, 50, 51, 53, 56, 57, 58, 60, 61, 62, 63, 85, 101, 102, 106, 113, 114, 115, 117, 120, 121, 122, 124, 125, 126, 127, 170, 202, 204, 205, 213, 226, 227, 229, 230, 234, 240, 241, 242, 243, 245, 248
Offset: 1

Views

Author

Keywords

Comments

There are A000041(k) elements of this list consisting of k bits: a partition of k written in nonincreasing order corresponds to the binary expansion which when read left to right has run lengths as listed in the partition (reading left to right forces the initial run to be of 1s). - Jason Kimberley, Feb 08 2013
This sequence is a subsequence of A061854 (if we allow the initial 0 to be represented by the empty bit string). - Jason Kimberley, Feb 08 2013
The positive entries are those n for which row n of A101211 is weakly decreasing. Example: 6 is in the sequence because row 6 of A101211 is [2,1]; 8 is not in the sequence because row 8 of A101211 is [1,3]. - Emeric Deutsch, Jan 21 2018

Crossrefs

Cf. A037015 (subsequence), A037014, A037013.

Programs

  • Haskell
    import Data.List (unfoldr, group)
    a037016 n = a037016_list !! (n-1)
    a037016_list = 0 : filter
       (all (>= 0) . (\x -> zipWith (-) (tail $ rls x) $ rls x)) [1..] where
           rls = map length . group . unfoldr
                 (\x -> if x == 0 then Nothing else Just $ swap $ divMod x 2)
    -- Reinhard Zumkeller, Mar 10 2012
  • Mathematica
    Select[ Range[0, 250], OrderedQ[ Reverse[ Length /@ Split[ IntegerDigits[#, 2] ] ] ]&] (* Jean-François Alcover, Apr 05 2013 *)

Extensions

More terms from Patrick De Geest, Feb 15 1999
Offset fixed by Reinhard Zumkeller, Mar 10 2012

A037014 Numbers n with property that reading binary expansion from right to left (from least significant to most significant), run lengths do not increase.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 7, 8, 10, 11, 12, 15, 16, 19, 20, 21, 23, 24, 31, 32, 39, 40, 42, 43, 44, 47, 48, 51, 56, 63, 64, 71, 76, 79, 80, 83, 84, 85, 87, 88, 95, 96, 103, 112, 127, 128, 143, 152, 159, 160, 167, 168, 170, 171, 172, 175, 176, 179, 184, 191, 192, 199, 204, 207
Offset: 1

Views

Author

Keywords

Crossrefs

Cf. A037013 (subsequence), A037016, A037015.

Programs

  • Haskell
    import Data.List (unfoldr, group)
    a037014 n = a037014_list !! (n-1)
    a037014_list = 0 : filter
       (all (<= 0) . (\x -> zipWith (-) (tail $ rls x) $ rls x)) [1..] where
           rls = map length . group . unfoldr
                 (\x -> if x == 0 then Nothing else Just $ swap $ divMod x 2)
    -- Reinhard Zumkeller, Mar 10 2012
  • Mathematica
    Select[Range[0,250],Min[Differences[Length/@Split[IntegerDigits[ #,2]]]]>= 0&] (* Harvey P. Dale, Jan 30 2013 *)

Extensions

More terms from Patrick De Geest, Feb 15 1999
Offset fixed by Reinhard Zumkeller, Mar 10 2012

A048321 Reading a(n) expansion from left to right, run lengths strictly decrease.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 22, 33, 44, 55, 66, 77, 88, 99, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 330, 331, 332, 333, 334, 335, 336, 337, 338, 339, 440, 441, 442, 443, 444, 445, 446, 447, 448
Offset: 1

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Crossrefs

Programs

  • Haskell
    import Data.List (group)
    a048321 n = a048321_list !! (n-1)
    a048321_list = filter f [0..] where
       f x = all (< 0) $ zipWith (-) (tail zs) zs
             where zs =  map length $ group $ show x
    -- Reinhard Zumkeller, May 01 2015

A048314 Numbers whose base-3 expansions, read from left to right, have run lengths that strictly decrease.

Original entry on oeis.org

0, 1, 2, 4, 8, 12, 13, 14, 24, 25, 26, 39, 40, 41, 78, 79, 80, 117, 120, 121, 122, 125, 234, 238, 240, 241, 242, 352, 353, 360, 363, 364, 365, 368, 375, 376, 703, 704, 714, 716, 720, 724, 726, 727, 728, 1080, 1081, 1082, 1089, 1092, 1093, 1094, 1097, 1104, 1105
Offset: 1

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Examples

			714 = 222110_3, which contains runs of three 2's, two 1's, and one 0. - _Jon E. Schoenfield_, Oct 12 2019
		

Crossrefs

A048315 Numbers whose base-4 expansions, read from left to right, have run lengths that strictly decrease.

Original entry on oeis.org

0, 1, 2, 3, 5, 10, 15, 20, 21, 22, 23, 40, 41, 42, 43, 60, 61, 62, 63, 84, 85, 86, 87, 168, 169, 170, 171, 252, 253, 254, 255, 336, 340, 341, 342, 343, 346, 351, 672, 677, 680, 681, 682, 683, 687, 1008, 1013, 1018, 1020, 1021, 1022, 1023, 1345, 1346, 1347
Offset: 0

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Crossrefs

A048316 Numbers whose base-5 expansions, read from left to right, have run lengths that strictly decrease.

Original entry on oeis.org

0, 1, 2, 3, 4, 6, 12, 18, 24, 30, 31, 32, 33, 34, 60, 61, 62, 63, 64, 90, 91, 92, 93, 94, 120, 121, 122, 123, 124, 155, 156, 157, 158, 159, 310, 311, 312, 313, 314, 465, 466, 467, 468, 469, 620, 621, 622, 623, 624, 775, 780, 781, 782, 783, 784, 787, 793, 799, 1550
Offset: 0

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Crossrefs

A048317 Numbers whose base-6 expansions, read from left to right, have run lengths that strictly decrease.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 7, 14, 21, 28, 35, 42, 43, 44, 45, 46, 47, 84, 85, 86, 87, 88, 89, 126, 127, 128, 129, 130, 131, 168, 169, 170, 171, 172, 173, 210, 211, 212, 213, 214, 215, 258, 259, 260, 261, 262, 263, 516, 517, 518, 519, 520, 521, 774, 775, 776, 777, 778, 779
Offset: 0

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[0,800],Max[Differences[Length/@Split[IntegerDigits[ #,6]]]]<0&] (* Harvey P. Dale, Jul 30 2019 *)

A048318 Numbers whose base-7 expansions, read from left to right, have run lengths that strictly decrease.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 8, 16, 24, 32, 40, 48, 56, 57, 58, 59, 60, 61, 62, 112, 113, 114, 115, 116, 117, 118, 168, 169, 170, 171, 172, 173, 174, 224, 225, 226, 227, 228, 229, 230, 280, 281, 282, 283, 284, 285, 286, 336, 337, 338, 339, 340, 341, 342, 399, 400, 401
Offset: 0

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[0,500],Max[Differences[Length/@Split[IntegerDigits[ #, 7]]]]<0&] (* Harvey P. Dale, Apr 27 2018 *)

A048319 Numbers whose base-8 expansions, read from left to right, have run lengths that strictly decrease.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 9, 18, 27, 36, 45, 54, 63, 72, 73, 74, 75, 76, 77, 78, 79, 144, 145, 146, 147, 148, 149, 150, 151, 216, 217, 218, 219, 220, 221, 222, 223, 288, 289, 290, 291, 292, 293, 294, 295, 360, 361, 362, 363, 364, 365, 366, 367, 432, 433, 434, 435
Offset: 0

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[0,500],Max[Differences[Length/@Split[IntegerDigits[#,8]]]] < 0&] (* Harvey P. Dale, Nov 14 2020 *)
Showing 1-10 of 17 results. Next