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

A175541 A007505 in binary.

Original entry on oeis.org

10, 101, 1011, 10111, 101111, 10111111, 101111111, 1011111111111, 10111111111111111111, 101111111111111111111111111111111111, 1011111111111111111111111111111111111111
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jun 24 2010

Keywords

Comments

Primes of the form 10, 101, 1011, 10111,..

Examples

			a(12)=101111111111111111111111111111111111111111111.
		

Programs

  • Mathematica
    FromDigits/@Select[Table[PadRight[{1,0},n,1],{n,0,50}], PrimeQ[ FromDigits[ #,2]]&] (* Harvey P. Dale, Nov 12 2011 *)

Formula

A275247 a(n) = number of decimal digits of A007505(n).

Original entry on oeis.org

1, 1, 2, 2, 2, 3, 3, 4, 6, 11, 12, 14, 18, 20, 24, 29, 32, 44, 63, 66, 93, 99, 119, 139, 142, 250, 384, 987, 1267, 1546, 2276, 3817, 4486, 5457, 5666, 7734, 7966, 12532, 15470, 21610, 24183, 25795, 26543, 29220, 37217, 46941, 49667, 70671, 124880, 176102, 211335, 219060, 298833, 361552, 370947, 696203, 944108, 1274988, 1833429, 3457035, 3531640, 3580969
Offset: 1

Views

Author

Zak Seidov, Jul 21 2016

Keywords

Crossrefs

Cf. A055642, A007505 (primes of form 3*2^n-1), A002235 (numbers n such that 3*2^n-1 is prime).

Formula

a(n) = A055642(A007505(n)). - Michel Marcus, Jul 23 2016

A083329 a(0) = 1; for n > 0, a(n) = 3*2^(n-1) - 1.

Original entry on oeis.org

1, 2, 5, 11, 23, 47, 95, 191, 383, 767, 1535, 3071, 6143, 12287, 24575, 49151, 98303, 196607, 393215, 786431, 1572863, 3145727, 6291455, 12582911, 25165823, 50331647, 100663295, 201326591, 402653183, 805306367, 1610612735, 3221225471, 6442450943
Offset: 0

Views

Author

Paul Barry, Apr 27 2003

Keywords

Comments

Apart from leading term (which should really be 3/2), same as A055010.
Binomial transform of A040001. Inverse binomial transform of A053156.
a(n) = A105728(n+1,2). - Reinhard Zumkeller, Apr 18 2005
Row sums of triangle A133567. - Gary W. Adamson, Sep 16 2007
Row sums of triangle A135226. - Gary W. Adamson, Nov 23 2007
a(n) = number of partitions Pi of [n+1] (in standard increasing form) such that the permutation Flatten[Pi] avoids the patterns 2-1-3 and 3-1-2. Example: a(3)=11 counts all 15 partitions of [4] except 13/24, 13/2/4 which contain a 2-1-3 and 14/23, 14/2/3 which contain a 3-1-2. Here "standard increasing form" means the entries are increasing in each block and the blocks are arranged in increasing order of their first entries. - David Callan, Jul 22 2008
An elephant sequence, see A175654. For the corner squares four A[5] vectors, with decimal values 42, 138, 162, 168, lead to this sequence. For the central square these vectors lead to the companion sequence A003945. - Johannes W. Meijer, Aug 15 2010
The binary representation of a(n) has n+1 digits, where all digits are 1's except digit n-1. For example: a(4) = 23 = 10111 (2). - Omar E. Pol, Dec 02 2012
Row sums of triangle A209561. - Reinhard Zumkeller, Dec 26 2012
If a Stern's sequence based enumeration system of positive irreducible fractions is considered (for example, A007305/A047679, A162909/A162910, A071766/A229742, A245325/A245326, ...), and if it is organized by blocks or levels (n) with 2^n terms (n >= 0), and the fractions, term by term, are summed at each level n, then the resulting sequence of integers is a(n) + 1/2, apart from leading term (which should be 1/2). - Yosu Yurramendi, May 23 2015
For n >= 2, A083329(n) in binary representation is a string [101..1], also 10 followed with (n-1) 1's. For n >= 3, A036563(n) in binary representation is a string [1..101], also (n-2) 1's followed with 01. Thus A083329(n) is a reflection of the binary representation of A036563(n+1). Example: A083329(5) = 101111 in binary, A036563(6) = 111101 in binary. - Ctibor O. Zizka, Nov 06 2018
For n > 0, a(n) is the minimum number of turns in (n+1)-dimensional Euclidean space needed to visit all 2^(n+1) vertices of the (n+1)-cube (e.g., {0,1}^(n+1)) and return to the starting point, moving along straight-line segments between turns (turns may occur elsewhere in R^(n+1)). - Marco Ripà, Aug 14 2025

Examples

			a(0) = (3*2^0 - 2 + 0^0)/2 = 2/2 = 1 (use 0^0=1).
		

Crossrefs

Essentially the same as A055010 and A052940.
Cf. A007505 (primes).
Cf. A266550 (independence number of the n-Mycielski graph).

Programs

  • Haskell
    a083329 n = a083329_list !! n
    a083329_list = 1 : iterate ((+ 1) . (* 2)) 2
    -- Reinhard Zumkeller, Dec 26 2012, Feb 22 2012
    
  • Magma
    [1] cat [3*2^(n-1)-1: n in [1..40]]; // Vincenzo Librandi, Jan 01 2016
  • Maple
    seq(ceil((2^i+2^(i+1)-2)/2), i=0..31); # Zerinvary Lajos, Oct 02 2007
  • Mathematica
    a[1] = 2; a[n_] := 2a[n - 1] + 1; Table[ a[n], {n, 31}] (* Robert G. Wilson v, May 04 2004 *)
    Join[{1}, LinearRecurrence[{3, -2}, {2, 5}, 40]] (* Vincenzo Librandi, Jan 01 2016 *)
  • PARI
    a(n)=(3*2^n-2+0^n)/2 \\ Charles R Greathouse IV, Sep 24 2015
    

Formula

a(n) = (3*2^n - 2 + 0^n)/2.
G.f.: (1-x+x^2)/((1-x)*(1-2*x)). [corrected by Martin Griffiths, Dec 01 2009]
E.g.f.: (3*exp(2*x) - 2*exp(x) + exp(0))/2.
a(0) = 1, a(n) = sum of all previous terms + n. - Amarnath Murthy, Jun 20 2004
a(n) = 3*a(n-1) - 2*a(n-2) for n > 2, a(0)=1, a(1)=2, a(2)=5. - Philippe Deléham, Nov 29 2013
From Bob Selcoe, Apr 25 2014: (Start)
a(n) = (...((((((1)+1)*2+1)*2+1)*2+1)*2+1)...), with n+1 1's, n >= 0.
a(n) = 2*a(n-1) + 1, n >= 2.
a(n) = 2^n + 2^(n-1) - 1, n >= 2. (End)
a(n) = A086893(n) + A061547(n+1), n > 0. - Yosu Yurramendi, Jan 16 2017

A055010 a(0) = 0; for n > 0, a(n) = 3*2^(n-1) - 1.

Original entry on oeis.org

0, 2, 5, 11, 23, 47, 95, 191, 383, 767, 1535, 3071, 6143, 12287, 24575, 49151, 98303, 196607, 393215, 786431, 1572863, 3145727, 6291455, 12582911, 25165823, 50331647, 100663295, 201326591, 402653183, 805306367, 1610612735, 3221225471, 6442450943, 12884901887
Offset: 0

Views

Author

Henry Bottomley, May 31 2000

Keywords

Comments

Apart from leading term (which should really be 3/2), same as A083329.
Written in binary, a(n) is 1011111...1.
The sequence 2, 5, 11, 23, 47, 95, ... apparently gives values of n such that Nim-factorial(n) = 2. Cf. A059970. However, compare A060152. More work is needed! - John W. Layman, Mar 09 2001
With offset 1, number of (132,3412)-avoiding two-stack sortable permutations.
Number of descents after n+1 iterations of morphism A007413.
a(n) = A164874(n,1), n>0; subsequence of A030130. - Reinhard Zumkeller, Aug 29 2009
Let A be the Hessenberg matrix of order n, defined by: A[1,j]=[i,i]:=1, A[i,i-1]=-1, and A[i,j]=0 otherwise. Then, for n>=1, a(n-1)=(-1)^n*charpoly(A,-1). - Milan Janjic, Jan 24 2010
a(n) is the total number of records over all length n binary words. A record in a word a_1,a_2,...,a_n is a letter a_j that is larger than all the preceding letters. That is, a_j>a_i for all iGeoffrey Critzer, Jul 18 2020
Called Thabit numbers after the Syrian mathematician Thābit ibn Qurra (826 or 836 - 901). - Amiram Eldar, Jun 08 2021
a(n) is the number of objects in a pile that represents a losing position in a Nim game, where a player must select at least one object but not more than half of the remaining objects, on their turn. - Kiran Ananthpur Bacche, Feb 03 2025

Examples

			a(3) = 3*2^2 - 1 = 3*4 - 1 = 11.
		

Crossrefs

Cf. A007505 for primes in this sequence. Apart from initial term, same as A052940 and A083329.
Cf. A266550 (independence number of the n-Mycielski graph).

Programs

Formula

a(n) = A118654(n-1, 4), for n > 0.
a(n) = 2*a(n-1) + 1 = a(n-1) + A007283(n-1) = A007283(n)-1 = A000079(n) + A000225(n + 1) = A000079(n + 1) + A000225(n) = 3*A000079(n) - 1 = 3*A000225(n) + 2.
a(n) = A010036(n)/2^(n-1). - Philippe Deléham, Feb 20 2004
a(n) = A099258(A033484(n)-1) = floor(A033484(n)/2). - Reinhard Zumkeller, Oct 09 2004
G.f.: x*(2-x)/((1-x)*(1-2*x)). - Philippe Deléham, Oct 04 2011
a(n+1) = A196168(A000079(n)). - Reinhard Zumkeller, Oct 28 2011
E.g.f.: (3*exp(2*x) - 2*exp(x) - 1)/2. - Stefano Spezia, Sep 14 2024

A002235 Numbers m such that 3*2^m - 1 is prime.

Original entry on oeis.org

0, 1, 2, 3, 4, 6, 7, 11, 18, 34, 38, 43, 55, 64, 76, 94, 103, 143, 206, 216, 306, 324, 391, 458, 470, 827, 1274, 3276, 4204, 5134, 7559, 12676, 14898, 18123, 18819, 25690, 26459, 41628, 51387, 71783, 80330, 85687, 88171, 97063, 123630, 155930, 164987, 234760
Offset: 1

Views

Author

Keywords

References

  • H. Riesel, Prime numbers and computer methods for factorization, Progress in Mathematics, Vol. 57, Birkhauser, Boston, 1985, Chap. 4, see pp. 381-384.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Mathematica
    lst={};Do[If[PrimeQ[3*2^n-1], Print[n];AppendTo[lst, n]], {n, 10^5}];lst (* Vladimir Joseph Stephan Orlovsky, Aug 21 2008 *)
  • PARI
    is(n)=ispseudoprime(3<Charles R Greathouse IV, Aug 27 2014

Extensions

More terms from Eric W. Weisstein, Sep 29 2007
a(60) = 11484018 from The Prime Pages, from Pierre CAMI, Nov 25 2014
a(61)-a(62) from The Prime Pages, from Eric W. Weisstein, Nov 03 2015
Terms moved from Data to b-file, and more terms added to b-file, by Jeppe Stig Nielsen, Sep 07 2021

A281993 Integers m such that sigma(m) + sigma(2*m) = 6*m.

Original entry on oeis.org

10, 44, 184, 752, 12224, 49024, 12580864, 206158168064, 885443715520878608384, 226673591177468092350464, 232113757366000005450563584, 3894222643901120685369075227951104, 1020847100762815390371677078221595082752, 17126972312471518572699356075530215722269540352
Offset: 1

Views

Author

Michel Marcus, Feb 04 2017

Keywords

Comments

This is the case h = 2 of the h-perfect numbers as defined in the Harborth link.

Examples

			10 is a term since sigma(10) + sigma(20) = 60, that is 6*10.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10^7], DivisorSigma[1, #] + DivisorSigma[1, 2 #] == 6 # &] (* Michael De Vlieger, Feb 04 2017 *)
  • PARI
    isok(n, h=2) = sigma(n) + sigma(h*n) == 2*n*(h+1);

Formula

a(n) = 2^A002235(n+1) * A007505(n+1). - Daniel Suteu, Feb 08 2017 [See Harborth link for a proof.]

Extensions

More terms from Jinyuan Wang, Feb 11 2020

A332216 Fixed points of A332221: Numbers k such that A156552(sigma(k)) is equal to k.

Original entry on oeis.org

2, 3, 5, 7, 11, 19, 23, 31, 47, 55, 79, 87, 127, 191, 383, 1279, 5119, 6143, 8191, 20479, 81919, 131071, 524287, 786431, 1310719, 2147483647
Offset: 1

Views

Author

Antti Karttunen, Feb 10 2020

Keywords

Comments

Equally, numbers k such that sigma(k) is equal to A005940(1+k).
The primes in this sequence are obtained by subtracting 1 from those terms of A029747 that are one more than a prime.
Questions: Are there other composite terms than 55 and 87? Are there other even terms than 2? (All such even terms should also occur in A332218).

Crossrefs

Programs

  • Mathematica
    Select[Range[10^5], DivisorSigma[1, #] == Block[{p = Partition[Split[Join[IntegerDigits[#, 2], {2}]], 2], q}, Times @@ Flatten[Table[q = Take[p, -i]; Prime[Count[Flatten[q], 0] + 1]^q[[1, 1]], {i, Length[p]}]]] &] (* Michael De Vlieger, Feb 12 2020, after Robert G. Wilson v at A005940 *)

A344384 Prime numbers p such that p-1 or p+1 is a number of least prime signature (A025487).

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 17, 23, 29, 31, 37, 47, 59, 61, 71, 73, 97, 127, 179, 181, 191, 193, 211, 239, 241, 257, 359, 383, 419, 421, 431, 433, 479, 577, 719, 769, 839, 863, 1151, 1153, 1259, 1297, 1439, 1801, 2161, 2309, 2311, 2521, 2591, 2593, 2879, 3359, 3361
Offset: 1

Views

Author

Hal M. Switkay, May 16 2021

Keywords

Comments

The corresponding numbers of least prime signature are A344385.
19 is the first prime not in this sequence.
This sequence unites many familiar sequences of primes, including Fermat primes (A019434), Mersenne primes (A000668), primorial primes (A018239 and A057705), factorial primes (A088054), A007505, and A039687.
Questions: 1) Is this sequence infinite? 2) Is log(a(n)) = O(log(n)^2)?

Examples

			17 is a term because 17 - 1 = 16 is a number of least prime signature.
		

Crossrefs

Programs

  • Mathematica
    {2}~Join~Select[Prime@ Range[2, 900], AnyTrue[# + {-1, 1}, Times @@ MapIndexed[Prime[First[#2]]^#1 &, Sort[FactorInteger[#][[All, -1]], Greater] ] == # &] &] (* Michael De Vlieger, May 16 2021 *)

A076373 Solutions to n + 2*phi(n) = sigma(n) where phi is A000010 and sigma is A000203.

Original entry on oeis.org

10, 44, 184, 752, 3796, 12224, 49024, 12580864, 60610624, 1091389696, 2936313088, 46672718384, 58082557696, 78857645056, 118480915456, 206158168064, 292776422368, 346109272672, 393960181792
Offset: 1

Views

Author

Labos Elemer, Oct 15 2002

Keywords

Comments

Is the number of solutions finite? Do solutions to n+k*phi(n)=sigma(n) exist for all values of k? For k=1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 the number of solutions I know below 1000000 is {1, 7, 2, 2, 1, 5, 3, 3, 0, 1, 1}. Not more for larger k.
If 3*2^n-1 is prime for n>0, then 2^n(3*2^n-1) belongs to the sequence; therefore this sequence is infinite if the sequence of primes of the form 3*2^n-1 (A007505) is infinite. - Matthew Vandermast, Jul 31 2004
3796 = 4*13*73 and 60610624 = 64*199*4759 do not belong to the class of numbers mentioned above by Vandermast.
a(20) > 10^12. - Donovan Johnson, Feb 29 2012
a(20) > 10^13. - Giovanni Resta, Apr 24 2016

Examples

			n=44, phi(n)=20, sigma(44)=1+2+4+11+22+44=84=44+2*20.
		

Crossrefs

A subsequence of A066679.

Programs

  • Mathematica
    ta={{0}};k=2;Do[g=n;If[Equal[n+k*EulerPhi[n], DivisorSigma[1, n]], ta=Append[ta, n];Print[n]], {n, 1, 182000000}];{ta, g}
  • PARI
    is(n)=2*eulerphi(n)==sigma(n)-n \\ Charles R Greathouse IV, Feb 19 2013

Extensions

a(8)-a(9) from Labos Elemer, Aug 04 2004
a(10)-a(19) from Donovan Johnson, Feb 29 2012

A164523 Nonnegative numbers n such that 6*2^n-1 is prime.

Original entry on oeis.org

0, 1, 2, 3, 5, 6, 10, 17, 33, 37, 42, 54, 63, 75, 93, 102, 142, 205, 215, 305, 323, 390, 457, 469, 826, 1273, 3275, 4203, 5133, 7558, 12675, 14897, 18122, 18818, 25689, 26458, 41627, 51386, 71782, 80329, 85686, 88170, 97062
Offset: 1

Views

Author

Vincenzo Librandi, Aug 15 2009

Keywords

Comments

The associated primes are in A007505.

Examples

			n=0 is in the sequence because 6*2^0-1=5 is prime. n=1 is in the sequence because 6*2^1-1=11 is prime.
		

Crossrefs

Cf. A157341.

Programs

Formula

a(n) = A002235(n+1)-1. - R. J. Mathar, Aug 17 2009

Extensions

Extended by R. J. Mathar, Aug 17 2009
a(28)-a(43) from Donovan Johnson, Jul 09 2010
Showing 1-10 of 14 results. Next