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

A001359 Lesser of twin primes.

Original entry on oeis.org

3, 5, 11, 17, 29, 41, 59, 71, 101, 107, 137, 149, 179, 191, 197, 227, 239, 269, 281, 311, 347, 419, 431, 461, 521, 569, 599, 617, 641, 659, 809, 821, 827, 857, 881, 1019, 1031, 1049, 1061, 1091, 1151, 1229, 1277, 1289, 1301, 1319, 1427, 1451, 1481, 1487, 1607
Offset: 1

Views

Author

Keywords

Comments

Also, solutions to phi(n + 2) = sigma(n). - Conjectured by Jud McCranie, Jan 03 2001; proved by Reinhard Zumkeller, Dec 05 2002
The set of primes for which the weight as defined in A117078 is 3 gives this sequence except for the initial 3. - Rémi Eismann, Feb 15 2007
The set of lesser of twin primes larger than three is a proper subset of the set of primes of the form 3n - 1 (A003627). - Paul Muljadi, Jun 05 2008
It is conjectured that A113910(n+4) = a(n+2) for all n. - Creighton Dement, Jan 15 2009
I would like to conjecture that if f(x) is a series whose terms are x^n, where n represents the terms of sequence A001359, and if we inspect {f(x)}^5, the conjecture is that every term of the expansion, say a_n * x^n, where n is odd and at least equal to 15, has a_n >= 1. This is not true for {f(x)}^k, k = 1, 2, 3 or 4, but appears to be true for k >= 5. - Paul Bruckman (pbruckman(AT)hotmail.com), Feb 03 2009
A164292(a(n)) = 1; A010051(a(n) - 2) = 0 for n > 1. - Reinhard Zumkeller, Mar 29 2010
From Jonathan Sondow, May 22 2010: (Start)
About 15% of primes < 19000 are the lesser of twin primes. About 26% of Ramanujan primes A104272 < 19000 are the lesser of twin primes.
About 46% of primes < 19000 are Ramanujan primes. About 78% of the lesser of twin primes < 19000 are Ramanujan primes.
A reason for the jumps is in Section 7 of "Ramanujan primes and Bertrand's postulate" and in Section 4 of "Ramanujan Primes: Bounds, Runs, Twins, and Gaps". (End)
Primes generated by sequence A040976. - Odimar Fabeny, Jul 12 2010
Primes of the form 2*n - 3 with 2*n - 1 prime n > 2. Primes of the form (n^2 - (n-2)^2)/2 - 1 with (n^2 - (n-2)^2)/2 + 1 prime so sum of two consecutive odd numbers/2 - 1. - Pierre CAMI, Jan 02 2012
Conjecture: For any integers n >= m > 0, there are infinitely many integers b > a(n) such that the number Sum_{k=m..n} a(k)*b^(n-k) (i.e., (a(m), ..., a(n)) in base b) is prime; moreover, when m = 1 there is such an integer b < (n+6)^2. - Zhi-Wei Sun, Mar 26 2013
Except for the initial 3, all terms are congruent to 5 mod 6. One consequence of this is that no term of this sequence appears in A030459. - Alonso del Arte, May 11 2013
Aside from the first term, all terms have digital root 2, 5, or 8. - J. W. Helkenberg, Jul 24 2013
The sequence provides all solutions to the generalized Winkler conjecture (A051451) aside from all multiples of 6. Specifically, these solutions start from n = 3 as a(n) - 3. This gives 8, 14, 26, 38, 56, ... An example from the conjecture is solution 38 from twin prime pairs (3, 5), (41, 43). - Bill McEachen, May 16 2014
Conjecture: a(n)^(1/n) is a strictly decreasing function of n. Namely a(n+1)^(1/(n+1)) < a(n)^(1/n) for all n. This conjecture is true for all a(n) <= 1121784847637957. - Jahangeer Kholdi and Farideh Firoozbakht, Nov 21 2014
a(n) are the only primes, p(j), such that (p(j+m) - p(j)) divides (p(j+m) + p(j)) for some m > 0, where p(j) = A000040(j). For all such cases m=1. It is easy to prove, for j > 1, the only common factor of (p(j+m) - p(j)) and (p(j+m) + p(j)) is 2, and there are no common factors if j = 1. Thus, p(j) and p(j+m) are twin primes. Also see A067829 which includes the prime 3. - Richard R. Forberg, Mar 25 2015
Primes prime(k) such that prime(k)! == 1 (mod prime(k+1)) with the exception of prime(991) = 7841 and other unknown primes prime(k) for which (prime(k)+1)*(prime(k)+2)*...*(prime(k+1)-2) == 1 (mod prime(k+1)) where prime(k+1) - prime(k) > 2. - Thomas Ordowski and Robert Israel, Jul 16 2016
For the twin prime criterion of Clement see the link. In Ribenboim, pp. 259-260 a more detailed proof is given. - Wolfdieter Lang, Oct 11 2017
Conjecture: Half of the twin prime pairs can be expressed as 8n + M where M > 8n and each value of M is a distinct composite integer with no more than two prime factors. For example, when n=1, M=21 as 8 + 21 = 29, the lesser of a twin prime pair. - Martin Michael Musatov, Dec 14 2017
For a discussion of bias in the distribution of twin primes, see my article on the Vixra web site. - Waldemar Puszkarz, May 08 2018
Since 2^p == 2 (mod p) (Fermat's little theorem), these are primes p such that 2^p == q (mod p), where q is the next prime after p. - Thomas Ordowski, Oct 29 2019, edited by M. F. Hasler, Nov 14 2019
The yet unproved "Twin Prime Conjecture" states that this sequence is infinite. - M. F. Hasler, Nov 14 2019
Lesser of the twin primes are the set of elements that occur in both A162566, A275697. Proof: A prime p will only have integer solutions to both (p+1)/g(p) and (p-1)/g(p) when p is the lesser of a twin prime, where g(p) is the gap between p and the next prime, because gcd(p+1,p-1) = 2. - Ryan Bresler, Feb 14 2021
From Lorenzo Sauras Altuzarra, Dec 21 2021: (Start)
J. A. Hervás Contreras observed the subsequence 11, 311, 18311, 1518311, 421518311... (see the links), which led me to conjecture the following statements.
I. If i is an integer greater than 2, then there exist positive integers j and k such that a(j) equals the concatenation of 3k and a(i).
II. If k is a positive integer, then there exist positive integers i and j such that a(j) equals the concatenation of 3k and a(i).
III. If i, j, and r are positive integers such that i > 2 and a(j) equals the concatenation of r and a(i), then 3 divides r. (End)

References

  • Milton Abramowitz and Irene A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 870.
  • T. M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1976, page 6.
  • Jan Gullberg, Mathematics from the Birth of Numbers, W. W. Norton & Co., NY & London, 1997, §3.2 Prime Numbers, p. 81.
  • Paulo Ribenboim, The New Book of Prime Number Records, Springer-Verlag NY 1996, pp. 259-260.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See pp. 192-197.
  • 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).
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, pages 111-112.

Crossrefs

Subsequence of A003627.
Cf. A104272 (Ramanujan primes), A178127 (lesser of twin Ramanujan primes), A178128 (lesser of twin primes if it is a Ramanujan prime).

Programs

  • Haskell
    a001359 n = a001359_list !! (n-1)
    a001359_list = filter ((== 1) . a010051' . (+ 2)) a000040_list
    -- Reinhard Zumkeller, Feb 10 2015
    
  • Magma
    [n: n in PrimesUpTo(1610) | IsPrime(n+2)];  // Bruno Berselli, Feb 28 2011
    
  • Maple
    select(k->isprime(k+2),select(isprime,[$1..1616])); # Peter Luschny, Jul 21 2009
    A001359 := proc(n)
       option remember;
       if n = 1
          then 3;
       else
          p := nextprime(procname(n-1)) ;
          while not isprime(p+2) do
             p := nextprime(p) ;
          end do:
          p ;
       end if;
    end proc: # R. J. Mathar, Sep 03 2011
  • Mathematica
    Select[Prime[Range[253]], PrimeQ[# + 2] &] (* Robert G. Wilson v, Jun 09 2005 *)
    a[n_] := a[n] = (p = NextPrime[a[n - 1]]; While[!PrimeQ[p + 2], p = NextPrime[p]]; p); a[1] = 3; Table[a[n], {n, 51}]  (* Jean-François Alcover, Dec 13 2011, after R. J. Mathar *)
    nextLesserTwinPrime[p_Integer] := Block[{q = p + 2}, While[NextPrime@ q - q > 2, q = NextPrime@ q]; q]; NestList[nextLesserTwinPrime@# &, 3, 50] (* Robert G. Wilson v, May 20 2014 *)
    Select[Partition[Prime[Range[300]],2,1],#[[2]]-#[[1]]==2&][[All,1]] (* Harvey P. Dale, Jan 04 2021 *)
    q = Drop[Prepend[p = Prime[Range[100]], 2], -1];
    Flatten[q[[#]] & /@ Position[p - q, 2]] (* Horst H. Manninger, Mar 28 2021 *)
  • PARI
    A001359(n,p=3) = { while( p+2 < (p=nextprime( p+1 )) || n-->0,); p-2}
    /* The following gives a reasonably good estimate for any value of n from 1 to infinity; compare to A146214. */
    A001359est(n) = solve( x=1,5*n^2/log(n+1), 1.320323631693739*intnum(t=2.02,x+1/x,1/log(t)^2)-log(x) +.5 - n)
    /* The constant is A114907; the expression in front of +.5 is an estimate for A071538(x) */ \\  M. F. Hasler, Dec 10 2008
    
  • Python
    from sympy import primerange, isprime
    print([n for n in primerange(1, 2001) if isprime(n + 2)]) # Indranil Ghosh, Jul 20 2017

Formula

a(n) = A077800(2n-1).
A001359 = { n | A071538(n-1) = A071538(n)-1 }; A071538(A001359(n)) = n. - M. F. Hasler, Dec 10 2008
A001359 = { prime(n) : A069830(n) = A087454(n) }. - Juri-Stepan Gerasimov, Aug 23 2011
a(n) = prime(A029707(n)). - R. J. Mathar, Feb 19 2017

A030461 Primes that are concatenations of two consecutive primes.

Original entry on oeis.org

23, 3137, 8389, 151157, 157163, 167173, 199211, 233239, 251257, 257263, 263269, 271277, 331337, 353359, 373379, 433439, 467479, 509521, 523541, 541547, 601607, 653659, 661673, 677683, 727733, 941947, 971977, 10131019
Offset: 1

Views

Author

Keywords

Comments

Any term in the sequence (apart from the first) must be a concatenation of consecutive primes differing by a multiple of 6. - Francis J. McDonnell, Jun 26 2005

Examples

			a(2) is 3137 because 31 and 37 are consecutive primes and after concatenation 3137 is also prime. - _Enoch Haga_, Sep 30 2007
		

Crossrefs

Cf. A030459.
Subsequence of A045533.

Programs

  • Haskell
    a030461 n = a030461_list !! (n-1)
    a030461_list = filter ((== 1) . a010051') a045533_list
    -- Reinhard Zumkeller, Apr 20 2012
    
  • Magma
    [Seqint( Intseq(NthPrime(n+1)) cat Intseq(NthPrime(n)) ): n in [1..200 ]| IsPrime(Seqint( Intseq(NthPrime(n+1)) cat Intseq(NthPrime(n)) )) ]; // Marius A. Burtea, Mar 21 2019
  • Maple
    conc:=proc(a,b) local bb: bb:=convert(b,base,10): 10^nops(bb)*a+b end: p:=proc(n) local w: w:=conc(ithprime(n),ithprime(n+1)): if isprime(w)=true then w else fi end: seq(p(n),n=1..250); # Emeric Deutsch
  • Mathematica
    Select[Table[p=Prime[n]; FromDigits[Join[Flatten[IntegerDigits[{p,NextPrime[p]}]]]],{n,170}],PrimeQ] (* Jayanta Basu, May 16 2013 *)
  • PARI
    {digits(n) = if(n==0,[0],u=[];while(n>0,d=divrem(n,10);n=d[1];u=concat(d[2],u));u)} {m=1185;p=2;while(pKlaus Brockhaus
    
  • PARI
    o=2;forprime(p=3,1e4, isprime(eval(Str(o,o=p))) & print1(precprime(p-1),p",")) \\ M. F. Hasler, Feb 06 2011
    

Formula

A030461(n) = concat(A030459(n),A030460(n)) = A045533( A000720( A030459(n))). - M. F. Hasler, Feb 06 2011

Extensions

Edited by N. J. A. Sloane, Apr 19 2009 at the suggestion of Zak Seidov

A086040 Prime p concatenated with next 4 primes is also prime.

Original entry on oeis.org

7, 47, 53, 67, 97, 101, 149, 401, 431, 479, 487, 757, 827, 887, 1061, 1171, 1409, 1429, 1543, 1721, 1789, 1811, 1889, 1987, 2099, 2113, 2137, 2273, 2689, 2719, 2857, 3203, 3571, 3613, 3623, 3761, 3853, 3917, 3929, 4007, 4217, 4441, 4943, 5039, 5209, 5281, 5449
Offset: 1

Views

Author

Chuck Seggelin, Jul 07 2003

Keywords

Examples

			a(1) = 7 because 7, 11, 13, 17 and 19 concatenated together yield 711131719, which is prime.
		

Crossrefs

Programs

  • Mathematica
    Select[Partition[Prime[Range[800]],5,1],PrimeQ[FromDigits[Flatten[IntegerDigits/@#]]]&][[;;,1]] (* Harvey P. Dale, May 25 2025 *)
  • Python
    from itertools import islice
    from sympy import isprime, nextprime
    def agen(): # generator of terms
        plst = [2, 3, 5, 7, 11]
        slst = list(map(str, plst))
        while True:
            if isprime(int("".join(slst))):
                yield plst[0]
            plst = plst[1:] + [nextprime(plst[-1])]
            slst = slst[1:] + [str(plst[-1])]
    print(list(islice(agen(), 50))) # Michael S. Branicky, Jan 26 2023

Extensions

Offset corrected by Arkadiusz Wesolowski, May 10 2012
a(15) and beyond from Michael S. Branicky, Jan 26 2023

A174031 The smallest integer k>0 such that the double-concatenation prime(n) // prime(n+1) // k is a prime number.

Original entry on oeis.org

3, 3, 1, 19, 1, 1, 1, 1, 1, 1, 9, 11, 11, 17, 3, 1, 1, 3, 11, 17, 21, 19, 1, 7, 37, 7, 23, 37, 7, 1, 7, 7, 7, 11, 7, 33, 29, 31, 1, 13, 11, 17, 7, 11, 11, 9, 9, 1, 7, 7, 1, 13, 11, 19, 67, 1, 13, 21, 49, 13, 13, 1, 1, 23, 1, 1, 29, 1, 29, 7
Offset: 1

Views

Author

Eva-Maria Zschorn (e-m.zschorn(AT)zaschendorf.km3.de), Mar 06 2010

Keywords

Comments

Leading zeros in k are not allowed.
All entries k are odd with final digit 1, 3, 7 or 9.
Dirichlet's prime number theorem for arithmetic progressions says that the sequence is infinite.
Conjecture: 1 appears infinitely often.

Examples

			n=1: 2//3//1 = 231 = 3 * 7 * 11 is not prime, so k<>1. 233 = prime(51), therefore 3 is the first entry.
n=2: 3//5//1 = 351 = 3^3 * 13 is not prime, so k <> 1, but 353 = prime(71), therefore 3 is the second entry.
n=30: 113//127//1 = 1131271 = prime(87976), so the 30th entry is 1.
		

Crossrefs

Programs

  • Maple
    read("transforms") ;
    A174031 := proc(n) for e from 1 do if isprime(digcatL([ithprime(n),ithprime(n+1),e])) then return e ; end if; end do: end proc:

Extensions

Entries checked; replaced variables by OEIS standard names - R. J. Mathar, Nov 17 2010

A030460 Previous prime concatenated with this prime p is a prime.

Original entry on oeis.org

3, 37, 89, 157, 163, 173, 211, 239, 257, 263, 269, 277, 337, 359, 379, 439, 479, 521, 541, 547, 607, 659, 673, 683, 733, 947, 977, 1019, 1039, 1187, 1193, 1213, 1229, 1277, 1373, 1459, 1471, 1663, 1693, 1721, 1747, 1867, 1979, 2081, 2179
Offset: 1

Views

Author

Keywords

Comments

Terms 157, 257, 263, 541, 1187, 1459, 2179 also belong to A030459. [Carmine Suriano, Jan 27 2011]

Programs

  • Mathematica
    Transpose[Select[Partition[Prime[Range[400]],2,1], PrimeQ[FromDigits[ Flatten[IntegerDigits/@#]]]&]][[2]] (* Harvey P. Dale, Dec 23 2011 *)
  • PARI
    c=0; o=2; s=1; forprime(p=3,default(primelimit), p>s & s*=10; isprime(o*s+o=p) & write("b030460.txt",c++," ",p))  \\ M. F. Hasler, Feb 06 2011

Formula

A030459(n) = A151799(a(n)). - M. F. Hasler, Feb 06 2011
A030461(n) = concat(A030459(n),a(n)) = A045533( A000720( A030459(n))). - M. F. Hasler, Feb 06 2011

Extensions

Offset changed from 0 to 1 by M. F. Hasler, Feb 06 2011

A034591 Numbers whose concatenation with the next prime yields a prime.

Original entry on oeis.org

0, 2, 6, 8, 9, 12, 27, 31, 36, 42, 44, 45, 51, 56, 63, 68, 69, 78, 83, 86, 93, 94, 96, 98, 102, 104, 105, 108, 115, 117, 118, 123, 126, 132, 138, 150, 151, 154, 156, 157, 160, 167, 176, 180, 183, 186, 192, 194, 195, 199, 201, 205, 213, 217, 219, 225, 230, 233
Offset: 1

Views

Author

Patrick De Geest, Oct 15 1998

Keywords

Examples

			8 is a term because nextprime(8) = 11 and 811 is prime.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[0,250],PrimeQ@FromDigits@Flatten[IntegerDigits/@{#,NextPrime@#}]&] (* Giorgos Kalogeropoulos, Jul 30 2021 *)
  • PARI
    isok(m) = isprime(eval(Str(m, nextprime(m+1)))); \\ Michel Marcus, Oct 03 2014 and Jul 30 2021

A034593 Cycle of 3 steps possible for 'concatenate a(n) and nextprime(a(n)) is a prime'.

Original entry on oeis.org

467, 941, 8834, 9548, 13012, 22302, 23592, 26208, 47538, 58578, 78910, 86447, 86925, 116230, 118040, 123716, 128055, 213493, 234146, 238326, 273057, 285315, 286422, 389336, 399261, 457810, 468764, 481476, 502590, 525402, 541102, 570205
Offset: 0

Views

Author

Patrick De Geest, Oct 15 1998

Keywords

Examples

			a(n)=78910 -> nextprime(a(n)) is 78919 so '7891078919' is prime (=step 1); a(n2)=7891078919 -> nextprime(a(n2)) is 7891078931 so '78910789197891078931' is prime (=step 2); a(n3)=78910789197891078931 -> nextprime(a(n3)) is 78910789197891078949 so '7891078919789107893178910789197891078949' is prime (=step 3).
		

Crossrefs

A036341 Concatenation of prime p and nextprime(p) is prime -> cycles of 4 steps possible.

Original entry on oeis.org

127787377, 1510818931, 3147482977, 3307903909, 3621408103, 3964636549, 7224979183, 7881628361, 8043354509, 8740618759, 10091655397, 10164789521, 10194261067, 10380609119, 10436432219, 11472028801, 12059694769, 13887362681, 14880879703, 15197340049
Offset: 1

Views

Author

Patrick De Geest, Dec 15 1998

Keywords

Comments

a(1)-a(5) found by Jo Yeong Uk (hyukjo(AT)sigma.chungnam.ac.kr).

Crossrefs

Extensions

Offset corrected and terms a(6) and beyond added by Giovanni Resta, May 14 2020

A034594 Concatenation of nextprime(a(n)) and a(n) is a prime.

Original entry on oeis.org

3, 27, 33, 39, 47, 51, 53, 61, 63, 91, 111, 123, 129, 131, 143, 173, 189, 199, 211, 217, 219, 231, 233, 237, 257, 273, 279, 301, 319, 341, 353, 357, 417, 423, 429, 473, 481, 489, 493, 501, 519, 523, 529, 531, 537, 551, 561, 573, 579, 587, 597, 607, 609, 619
Offset: 1

Views

Author

Patrick De Geest, Oct 15 1998

Keywords

Examples

			a(n)=27 -> nextprime(a(n)) is 29 so '2927' is a prime.
		

Crossrefs

Programs

  • PARI
    isok(n)=isprime(fromdigits(concat(digits(nextprime(n+1)), digits(n)))) \\ Andrew Howroyd, Aug 13 2024

Extensions

Offset changed by Andrew Howroyd, Aug 13 2024

A036339 Concatenation of prime p and nextprime(p) is prime -> cycles of 2 steps possible.

Original entry on oeis.org

467, 941, 13681, 14461, 21787, 22171, 22369, 24049, 24151, 25457, 29333, 37397, 41221, 42467, 43481, 46511, 48023, 54133, 56681, 68699, 75883, 85081, 101341, 103511, 117443, 120193, 126199, 137363, 144323, 145133, 158791, 175853, 181891, 183797
Offset: 1

Views

Author

Patrick De Geest, Dec 15 1998

Keywords

Crossrefs

Extensions

Offset corrected and missing 181891 inserted by Sean A. Irvine, Oct 26 2020
Showing 1-10 of 25 results. Next