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 16 results. Next

A272919 Numbers of the form 2^(n-1)*(2^(n*m)-1)/(2^n-1), n >= 1, m >= 1.

Original entry on oeis.org

1, 2, 3, 4, 7, 8, 10, 15, 16, 31, 32, 36, 42, 63, 64, 127, 128, 136, 170, 255, 256, 292, 511, 512, 528, 682, 1023, 1024, 2047, 2048, 2080, 2184, 2340, 2730, 4095, 4096, 8191, 8192, 8256, 10922, 16383, 16384, 16912, 18724, 32767, 32768, 32896, 34952, 43690, 65535, 65536, 131071
Offset: 1

Views

Author

Ivan Neretin, May 10 2016

Keywords

Comments

In other words, numbers whose binary representation consists of one or more repeating blocks with only one 1 in each block.
Also, fixed points of the permutations A139706 and A139708.
Each a(n) is a term of A064896 multiplied by some power of 2. As such, this sequence must also be a subsequence of A125121.
Also the numbers that uniquely index a Haar graph (i.e., 5 and 6 are not in the sequence since H(5) is isomorphic to H(6)). - Eric W. Weisstein, Aug 19 2017
From Gus Wiseman, Apr 04 2020: (Start)
The k-th composition in standard order (row k of A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions. This sequence lists all positive integers k such that the k-th composition in standard order is constant. For example, the sequence together with the corresponding constant compositions begins:
0: () 136: (4,4)
1: (1) 170: (2,2,2,2)
2: (2) 255: (1,1,1,1,1,1,1,1)
3: (1,1) 256: (9)
4: (3) 292: (3,3,3)
7: (1,1,1) 511: (1,1,1,1,1,1,1,1,1)
8: (4) 512: (10)
10: (2,2) 528: (5,5)
15: (1,1,1,1) 682: (2,2,2,2,2)
16: (5) 1023: (1,1,1,1,1,1,1,1,1,1)
31: (1,1,1,1,1) 1024: (11)
32: (6) 2047: (1,1,1,1,1,1,1,1,1,1,1)
36: (3,3) 2048: (12)
42: (2,2,2) 2080: (6,6)
63: (1,1,1,1,1,1) 2184: (4,4,4)
64: (7) 2340: (3,3,3,3)
127: (1,1,1,1,1,1,1) 2730: (2,2,2,2,2,2)
128: (8) 4095: (1,1,1,1,1,1,1,1,1,1,1,1)
(End)

Crossrefs

Cf. A137706 (smallest number indexing a new Haar graph).
Compositions in standard order are A066099.
Strict compositions are ranked by A233564.

Programs

  • Maple
    N:= 10^6: # to get all terms <= N
    R:= select(`<=`,{seq(seq(2^(n-1)*(2^(n*m)-1)/(2^n-1), m = 1 .. ilog2(2*N)/n), n = 1..ilog2(2*N))},N):
    sort(convert(R,list)); # Robert Israel, May 10 2016
  • Mathematica
    Flatten@Table[d = Reverse@Divisors[n]; 2^(d - 1)*(2^n - 1)/(2^d - 1), {n, 17}]

Formula

From Gus Wiseman, Apr 04 2020: (Start)
A333381(a(n)) = A027750(n).
For n > 0, A124767(a(n)) = 1.
If n is a power of two, A333628(a(n)) = 0, otherwise = 1.
A333627(a(n)) is a power of 2.
(End)

A056538 Irregular triangle read by rows: row n lists the divisors of n in decreasing order.

Original entry on oeis.org

1, 2, 1, 3, 1, 4, 2, 1, 5, 1, 6, 3, 2, 1, 7, 1, 8, 4, 2, 1, 9, 3, 1, 10, 5, 2, 1, 11, 1, 12, 6, 4, 3, 2, 1, 13, 1, 14, 7, 2, 1, 15, 5, 3, 1, 16, 8, 4, 2, 1, 17, 1, 18, 9, 6, 3, 2, 1, 19, 1, 20, 10, 5, 4, 2, 1, 21, 7, 3, 1, 22, 11, 2, 1, 23, 1, 24, 12, 8, 6, 4, 3, 2, 1, 25, 5, 1, 26, 13, 2, 1, 27, 9
Offset: 1

Views

Author

Antti Karttunen, Jun 20 2000

Keywords

Comments

Old name was "Replace n by its divisors in reverse order."
This gives the second elements of the ordered pairs (a,b), a >= 1, b >= 1, ordered by their product ab.
T(n,k) = n / A027750(n,k) = A027750(n,n-k+1), 1 <= k <= A000005(n). - Reinhard Zumkeller, Sep 28 2014
The 2nd column of the triangle is the largest proper divisor (A032742). - Charles Kusniec, Jan 30 2021

Examples

			Triangle begins:
1;
2, 1;
3, 1;
4, 2, 1;
5, 1;
6, 3, 2, 1;
7, 1;
8, 4, 2, 1;
9, 3, 1;
10, 5, 2, 1;
11, 1;
12, 6, 4, 3, 2, 1;
13, 1;
14, 7, 2, 1;
15, 5, 3, 1;
16, 8, 4, 2, 1;
17, 1;
18, 9, 6, 3, 2, 1;
19, 1;
20, 10, 5, 4, 2, 1;
		

Crossrefs

Cf. A027750 for the first elements, A056534, A168017, A000005 (row lengths), A000203 (row sums), A032742 (largest proper divisor).

Programs

  • Haskell
    a056538 n k = a056538_tabf !! (n-1) !! (k-1)
    a056538_row n = a056538_tabf !! (n-1)
    a056538_tabf = map reverse a027750_tabf
    -- Reinhard Zumkeller, Sep 28 2014
    
  • Magma
    [Reverse(Divisors(n)) : n in [1..30]];
    
  • Maple
    map(op,[seq(reverse(sort(divisors(j))),j=1..30)]);
    cdr := proc(l) if 0 = nops(l) then ([]) else (l[2..nops(l)]): fi: end:
    reverse := proc(l) if 0 = nops(l) then ([]) else [op(reverse(cdr(l))), l[1]]; fi: end:
  • Mathematica
    Table[Reverse@ Divisors@ n, {n, 27}] // Flatten (* Michael De Vlieger, Jul 27 2016 *)
  • PARI
    row(n)=Vecrev(divisors(n)) \\ Charles R Greathouse IV, Sep 02 2015

Formula

a(n) = A064894(A064896(n)).

Extensions

Definition revised by N. J. A. Sloane, Jul 27 2016

A295235 Numbers k such that the positions of the ones in the binary representation of k are in arithmetic progression.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 15, 16, 17, 18, 20, 21, 24, 28, 30, 31, 32, 33, 34, 36, 40, 42, 48, 56, 60, 62, 63, 64, 65, 66, 68, 72, 73, 80, 84, 85, 96, 112, 120, 124, 126, 127, 128, 129, 130, 132, 136, 144, 146, 160, 168, 170, 192, 224, 240, 248
Offset: 1

Views

Author

Rémy Sigrist, Nov 18 2017

Keywords

Comments

Also numbers k of the form Sum_{b=0..h-1} 2^(i+j*b) for some h >= 0, i >= 0, j > 0 (in fact, h = A000120(k), and if k > 0, i = A007814(k)).
There is a simple bijection between the finite sets of nonnegative integers in arithmetic progression and the terms of this sequence: s -> Sum_{i in s} 2^i; the term 0 corresponds to the empty set.
For any n > 0, A054519(n) gives the numbers of terms with n+1 digits in binary representation.
For any n >= 0, n is in the sequence iff 2*n is in the sequence.
For any n > 0, A000695(a(n)) is in the sequence.
The first prime numbers in the sequence are: 2, 3, 5, 7, 17, 31, 73, 127, 257, 8191, 65537, 131071, 262657, 524287, ...
This sequence contains the following sequences: A000051, A000079, A000225, A000668, A002450, A019434, A023001, A048645.
For any k > 0, 2^k - 2, 2^k - 1, 2^k, 2^k + 1 and 2^k + 2 are in the sequence (e.g., 14, 15, 16, 17, and 18).
Every odd term is a binary palindrome (and thus belongs to A006995).
Odd terms are A064896. - Robert Israel, Nov 20 2017

Examples

			The binary representation of the number 42 is "101010" and has ones evenly spaced, hence 42 appears in the sequence.
The first terms, alongside their binary representations, are:
   n  a(n)  a(n) in binary
  --  ----  --------------
   1    0           0
   2    1           1
   3    2          10
   4    3          11
   5    4         100
   6    5         101
   7    6         110
   8    7         111
   9    8        1000
  10    9        1001
  11   10        1010
  12   12        1100
  13   14        1110
  14   15        1111
  15   16       10000
  16   17       10001
  17   18       10010
  18   20       10100
  19   21       10101
  20   24       11000
		

Crossrefs

Cf. A029931, A048793 (binary indices triangle), A070939, A291166, A325328 (prime indices rather than binary indices), A326669, A326675.

Programs

  • Maple
    f:= proc(d) local i,j,k;
      op(sort([seq(seq(add(2^(d-j*k),k=0..m),m=1..d/j),j=1..d),2^(d+1)]))
    end proc:
    0,1,seq(f(d),d=0..10); # Robert Israel, Nov 20 2017
  • Mathematica
    bpe[n_]:=Join@@Position[Reverse[IntegerDigits[n,2]],1];
    Select[Range[100],SameQ@@Differences[bpe[#]]&] (* Gus Wiseman, Jul 22 2019 *)
  • PARI
    is(n) = my(h=hammingweight(n)); if(h<3, return(1), my(i=valuation(n,2),w=#binary(n)); if((w-i-1)%(h-1)==0, my(j=(w-i-1)/(h-1)); return(sum(k=0,h-1,2^(i+j*k))==n), return(0)))

A076270 Numbers of the form (3^{mr}-1)/(3^r-1) for positive integers m, r.

Original entry on oeis.org

1, 4, 10, 13, 28, 40, 82, 91, 121, 244, 364, 730, 757, 820, 1093, 2188, 3280, 6562, 6643, 7381, 9841, 19684, 20440, 29524, 59050, 59293, 66430, 88573, 177148, 265720, 531442, 532171, 538084, 551881, 597871, 797161, 1594324, 2391484, 4782970, 4785157, 5380840
Offset: 1

Views

Author

N. J. A. Sloane, Nov 06 2002

Keywords

Crossrefs

Cf. A064896 (k=2), A076270 (k=3), A076275 (k=4), A076284 (k=5), A076286 (k=7), A076287 (k=8), A076288 (k=9), A076289 (k=10).

Programs

  • Maple
    f := proc(p) local m,r,t1; t1 := {}; for m from 1 to 10 do for r from 1 to 10 do t1 := {op(t1), (p^(m*r)-1)/(p^r-1)}; od: od: sort(convert(t1,list)); end; f(3); # very crude!

A076289 Numbers of the form (10^(m*r)-1)/(10^r-1) for positive integers m, r.

Original entry on oeis.org

1, 11, 101, 111, 1001, 1111, 10001, 10101, 11111, 100001, 111111, 1000001, 1001001, 1010101, 1111111, 10000001, 11111111, 100000001, 100010001, 101010101, 111111111, 1000000001, 1001001001, 1111111111, 10000000001, 10000100001, 10101010101, 11111111111
Offset: 1

Views

Author

N. J. A. Sloane, Nov 06 2002

Keywords

Crossrefs

Cf. A064896 (k=2), A076270 (k=3), A076275 (k=4), A076284 (k=5), A076285 (k=6), A076286 (k=7), A076287 (k=8), A076288 (k=9), A076289 (k=10).

Programs

  • Maple
    N::= 20: # for terms <= 10^N
    R:= {1}:
    for n from 1 to 2*N do
      R:= R union select(`<=`, {seq((10^n-1)/(10^d-1), d = numtheory:-divisors(n))},10^N);
    od:
    sort(convert(R,list)); # Robert Israel, May 19 2024

A076286 Numbers of the form (7^{mr}-1)/(7^r-1) for positive integers m, r.

Original entry on oeis.org

1, 8, 50, 57, 344, 400, 2402, 2451, 2801, 16808, 19608, 117650, 117993, 120100, 137257, 823544, 960800, 5764802, 5767203, 5884901, 6725601, 40353608, 40471600, 47079208, 282475250, 282492057, 288360150, 329554457, 1977326744, 2306881200, 13841287202
Offset: 1

Views

Author

N. J. A. Sloane, Nov 06 2002

Keywords

Crossrefs

Cf. A064896 (k=2), A076270 (k=3), A076275 (k=4), A076284 (k=5), A076285 (k=6), A076287 (k=8), A076288 (k=9), A076289 (k=10).

Programs

  • Maple
    [1,seq(seq((7^(d+r)-1)/(7^r-1),r = sort(convert(numtheory:-divisors(d),list),`>`)),d=1..20)]; # Robert Israel, Aug 27 2018

A076287 Numbers of the form (8^{mr}-1)/(8^r-1) for positive integers m, r.

Original entry on oeis.org

1, 9, 65, 73, 513, 585, 4097, 4161, 4681, 32769, 37449, 262145, 262657, 266305, 299593, 2097153, 2396745, 16777217, 16781313, 17043521, 19173961, 134217729, 134480385, 153391689, 1073741825, 1073774593, 1090785345, 1227133513, 8589934593, 9817068105
Offset: 1

Views

Author

N. J. A. Sloane, Nov 06 2002

Keywords

Comments

Numbers which in base 8 contain only 0's and 1's, with equally spaced 1's. - Robert Israel, Jan 15 2019

Crossrefs

Cf. A064896 (k=2), A076270 (k=3), A076275 (k=4), A076284 (k=5), A076285 (k=6), A076286 (k=7), A076288 (k=9), A076289 (k=10).

Programs

  • Maple
    1, seq(seq((8^(k+r)-1)/(8^r-1), r = ListTools:-Reverse(sort(convert(numtheory:-divisors(k),list)))), k=1..20); # Robert Israel, Jan 15 2019

A076275 Numbers of the form (4^{mr}-1)/(4^r-1) for positive integers m, r.

Original entry on oeis.org

1, 5, 17, 21, 65, 85, 257, 273, 341, 1025, 1365, 4097, 4161, 4369, 5461, 16385, 21845, 65537, 65793, 69905, 87381, 262145, 266305, 349525, 1048577, 1049601, 1118481, 1398101, 4194305, 5592405, 16777217, 16781313, 16843009, 17043521, 17895697, 22369621
Offset: 1

Views

Author

N. J. A. Sloane, Nov 06 2002

Keywords

Crossrefs

Cf. A064896 (k=2), A076270 (k=3), A076284 (k=5), A076285 (k=6), A076286 (k=7), A076287 (k=8), A076288 (k=9), A076289 (k=10).

A076284 Numbers of the form (5^{mr}-1)/(5^r-1) for positive integers m, r.

Original entry on oeis.org

1, 6, 26, 31, 126, 156, 626, 651, 781, 3126, 3906, 15626, 15751, 16276, 19531, 78126, 97656, 390626, 391251, 406901, 488281, 1953126, 1968876, 2441406, 9765626, 9768751, 10172526, 12207031, 48828126, 61035156, 244140626, 244156251, 244531876, 246109501
Offset: 1

Views

Author

N. J. A. Sloane, Nov 06 2002

Keywords

Crossrefs

Cf. A064896 (k=2), A076270 (k=3), A076275 (k=4), A076285 (k=6), A076286 (k=7), A076287 (k=8), A076288 (k=9), A076289 (k=10).

A076288 Numbers of the form (9^{mr}-1)/(9^r-1) for positive integers m, r.

Original entry on oeis.org

1, 10, 82, 91, 730, 820, 6562, 6643, 7381, 59050, 66430, 531442, 532171, 538084, 597871, 4782970, 5380840, 43046722, 43053283, 43584805, 48427561, 387420490, 387952660, 435848050, 3486784402, 3486843451, 3530369206, 3922632451, 31381059610, 35303692060
Offset: 1

Views

Author

N. J. A. Sloane, Nov 06 2002

Keywords

Crossrefs

Cf. A064896 (k=2), A076270 (k=3), A076275 (k=4), A076284 (k=5), A076285 (k=6), A076286 (k=7), A076287 (k=8), A076289 (k=10).
Showing 1-10 of 16 results. Next