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

A162652 Primes p such that there are positive integers m and n and a prime q such that p = m^2+m-q = n^2+n+q.

Original entry on oeis.org

7, 13, 31, 43, 73, 211, 241, 421, 463, 1123, 1723, 2551, 2971, 4831, 5701, 6163, 8011, 8191, 9901, 11131, 12433, 14281, 17293, 19183, 20023, 23563, 24181, 28393, 30103, 31153, 35911, 37831, 43891, 46441, 53593, 60271, 77563, 83233, 86143, 95791
Offset: 1

Views

Author

Daniel Tisdale, Jul 08 2009

Keywords

Comments

To test if a prime p is a member, p = n^2+n+q gives a finite list of possible pairs (n,q), and, for each value of q, m^2+m = p+q determines a putative value of m. - N. J. A. Sloane, Jul 17 2009
Also, primes of the form (p^2+3)/4 with p odd prime. - Zak Seidov, May 10 2014

Examples

			7 = 1^2+1+5 = 3^2+3-5.
		

Crossrefs

Cf. A163418. - R. J. Mathar, Feb 05 2010

Programs

  • Maple
    isA002378 := proc(n) if n >= 0 then if issqr(4*n+1) then RETURN(type( sqrt(4*n+1),'odd')) ; else false; fi; else false; fi; end: # primes p such there is a prime q
  • Mathematica
    sol[p_] := m^2 + m - p /. Solve[m>0 && n>0 && 2p == m + m^2 + n + n^2, {m, n}, Integers];
    Reap[For[p = 2, p < 10^6, p = NextPrime[p], qsel = Select[sol[p], PrimeQ]; If[qsel != {}, Print[p]; Sow[p]]]][[2, 1]] (* Jean-François Alcover, Mar 25 2020 *)

Extensions

Definition revised by N. J. A. Sloane, Jul 17 2009
More terms from R. J. Mathar, Jul 17 2009
Extended beyond a(31) by R. J. Mathar, Feb 05 2010

A163419 Primes of the form ((p+1)/2)^2+((p-1)/2), where p is prime.

Original entry on oeis.org

5, 11, 19, 41, 89, 109, 239, 271, 379, 461, 599, 929, 991, 2069, 2969, 3079, 4159, 4421, 4969, 5851, 9311, 10099, 13109, 13339, 14519, 16001, 20021, 23869, 25439, 28729, 30449, 32579, 34039, 38219, 39799, 48619, 50849, 53591, 57839, 59779, 60761
Offset: 1

Views

Author

Keywords

Comments

Subsequence of A002327. - Charles R Greathouse IV, Aug 11 2009

Examples

			((3+1)/2)^2+((3-1)/2) = 4+1 = 5;
((5+1)/2)^2+((5-1)/2) = 9+2 = 11;
((7+1)/2)^2+((7-1)/2) = 16+3 = 19.
		

Crossrefs

Programs

  • Magma
    [a: p in PrimesInInterval(3, 600) | IsPrime(a) where a is (p^2 + 4*p - 1) div 4]; // Vincenzo Librandi, Sep 17 2016
    
  • Mathematica
    f[n_]:=((p+1)/2)^2+((p-1)/2); lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst,f[p]]],{n,6!}];lst
    Select[((#+1)/2)^2+(#-1)/2&/@Prime[Range[500]],PrimeQ] (* Harvey P. Dale, Nov 25 2012 *)
  • PARI
    lista(nn) = forprime(p=3, nn, if(isprime(P=(p^2+4*p-1)/4), print1(P, ", "))); \\ Altug Alkan, Sep 17 2016

A163420 Primes p such that p+(p^2-1)/4 is also prime.

Original entry on oeis.org

3, 5, 7, 11, 17, 19, 29, 31, 37, 41, 47, 59, 61, 89, 107, 109, 127, 131, 139, 151, 191, 199, 227, 229, 239, 251, 281, 307, 317, 337, 347, 359, 367, 389, 397, 439, 449, 461, 479, 487, 491, 569, 587, 601, 617, 659, 661, 677, 701, 719, 727, 769, 809, 839, 911, 941
Offset: 1

Views

Author

Keywords

Examples

			3 is in the sequence because 3+(3^2-1)/4=5 is a prime number.
5 is in the sequence because 5+(5^2-1)/4=11 is a prime number.
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesInInterval(3,1000) | IsPrime(p+(p^2-1) div 4)]; // Vincenzo Librandi, Apr 08 2013
  • Mathematica
    f[n_]:=((p+1)/2)^2+((p-1)/2); lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst, p]],{n,6!}];lst
    Select[Range[700], PrimeQ[#] && PrimeQ[# + (#^2 - 1)/4] &] (* Vincenzo Librandi, Apr 08 2013 *)
    Select[Prime[Range[200]],PrimeQ[#+(#^2-1)/4]&] (* Harvey P. Dale, Jun 18 2014 *)

Formula

A163419(n) = a(n)+( a(n)^2-1 )/4. [R. J. Mathar, Aug 17 2009]
{A000040(k): A000040(k)+A024701(k-1) in A000040}.

Extensions

Definition simplified by R. J. Mathar, Aug 17 2009

A163421 Primes of the form ((p-1)/2)^3+((p+1)/2), p are prime numbers.

Original entry on oeis.org

3, 11, 31, 131, 223, 521, 739, 3391, 5851, 9283, 24419, 27031, 59359, 68963, 85229, 110641, 148931, 157519, 175673, 328579, 405299, 571871, 857471, 1561013, 1728121, 2248223, 2460511, 3112283, 3581731, 3724031, 4741801, 5735519
Offset: 1

Views

Author

Keywords

Comments

Subsequence of A095692.
((3-1)/2)^3+((3+1)/2)=1+2=3, ((5-1)/2)^3+((5+1)/2)=8+3=11, ((7-1)/2)^3+((7+1)/2)=27+4=31,..

Crossrefs

Programs

  • Mathematica
    f[n_]:=((p-1)/2)^3+((p+1)/2); lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst,f[p]]],{n,6!}];lst

Extensions

Comment from Charles R Greathouse IV, Aug 11 2009

A163422 Primes p such that A071568((p-1)/2) is also prime.

Original entry on oeis.org

3, 5, 7, 11, 13, 17, 19, 31, 37, 43, 59, 61, 79, 83, 89, 97, 107, 109, 113, 139, 149, 167, 191, 233, 241, 263, 271, 293, 307, 311, 337, 359, 373, 383, 439, 443, 479, 487, 491, 523, 557, 617, 641, 647, 659, 673, 683, 701, 733, 757, 811, 829, 853, 857, 859, 877
Offset: 1

Views

Author

Keywords

Comments

Primes p such that (p-1)^3/8+(p+1)/2 is also prime, i.e., in A095692.

Examples

			p=3 is in the sequence because (3-1)^3/8+(3+1)/2=3 is prime.
p=5 is in the sequence because (5-1)^3/8+(5+1)/2=11 is prime.
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(1000) | IsPrime((p^3-3*p^2+7*p+3) div 8)]; // Vincenzo Librandi, Apr 10 2013
  • Mathematica
    f[n_]:=((n-1)/2)^3+((n+1)/2); lst={}; Do[p=Prime[n]; If[PrimeQ[f[p]], AppendTo[lst, p]], {n,6!}]; lst
    Select[Prime[Range[180]], PrimeQ[(#-1)^3/8+(#+1)/2]&]  (* Harvey P. Dale, Jan 05 2011 *)

Extensions

Definition rewritten by R. J. Mathar, Aug 17 2009

A163424 Primes of the form (p-1)^3/8 + (p+1)^2/4 where p is prime.

Original entry on oeis.org

5, 17, 43, 593, 829, 2969, 3631, 12743, 27961, 44171, 60919, 127601, 278981, 578843, 737281, 950993, 980299, 1455893, 1969001, 2424329, 2763881, 3605293, 5767739, 7801993, 9305521, 11290049, 12220361, 12704093, 16452089, 22987529, 35720189
Offset: 1

Views

Author

Keywords

Examples

			(3-1)^3/8 + (3+1)^2/4 = 1 + 4 = 5;
(5-1)^3/8 + (5+1)^2/4 = 8 + 9 = 17;
(7-1)^3/8 + (7+1)^2/4 = 27 + 16 = 43.
		

Crossrefs

Subsequence of A100662.
For the corresponding primes p, see A163425.

Programs

  • Mathematica
    f[n_]:=((p-1)/2)^3+((p+1)/2)^2; lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst,f[p]]],{n,7!}];lst
    Select[(#-1)^3/8+(#+1)^2/4&/@Prime[Range[150]],PrimeQ] (* Harvey P. Dale, Oct 05 2018 *)
  • PARI
    list(lim)=my(v=List(),t); forprime(p=3,, t=((p-1)/2)^3 + ((p+1)/2)^2; if(t>lim, break); if(isprime(t), listput(v,t))); Vec(v) \\ Charles R Greathouse IV, Dec 23 2016

A163425 Primes p such that (p-1)^3/8+(p+1)^2/4 is also prime.

Original entry on oeis.org

3, 5, 7, 17, 19, 29, 31, 47, 61, 71, 79, 101, 131, 167, 181, 197, 199, 227, 251, 269, 281, 307, 359, 397, 421, 449, 461, 467, 509, 569, 659, 691, 709, 811, 859, 919, 937, 997, 1031, 1087, 1151, 1217, 1231, 1249, 1277, 1279, 1301, 1307, 1361, 1409, 1447, 1451
Offset: 1

Views

Author

Keywords

Comments

The associated (p-1)^3/8+(p+1)^2/4 are in A163424.

Examples

			p=3 is in the sequence because (3-1)^3/8+(3+1)^2/4=1+4=5 is also prime.
p=5 is in the sequence because (5-1)^3/8+(5+1)^2/4=17 is also prime.
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesInInterval(3, 2000) | IsPrime((p-1)^3 div 8 + (p+1)^2 div 4)]; // Vincenzo Librandi, Apr 08 2013
  • Mathematica
    f[n_]:=((p-1)/2)^3+((p+1)/2)^2; lst={};Do[p=Prime[n];If[PrimeQ[f[p]], AppendTo[lst,p]],{n,7!}];lst
    Select[Prime[Range[1500]], PrimeQ[(# - 1)^3 / 8 + (# + 1)^2 / 4]&] (* Vincenzo Librandi, Apr 08 2013 *)

Extensions

Comment turned into examples by R. J. Mathar, Sep 02 2009

A163426 Primes of the form ((p+1)/2)^3 + ((p-1)/2), p is prime.

Original entry on oeis.org

29, 67, 349, 1009, 3389, 4111, 9281, 19709, 46691, 132701, 140659, 166429, 658589, 884831, 1000099, 1405039, 1520989, 1601729, 1728119, 2146817, 2460509, 2685757, 4574461, 7078079, 7880797, 10077911, 14887181, 23149409, 23393941, 27000299
Offset: 1

Views

Author

Keywords

Examples

			((5+1)/2)^3 + ((5-1)/2) = 27 + 2 = 29;
((7+1)/2)^3 + ((7-1)/2) = 64 + 3 = 67.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=((p+1)/2)^3+((p-1)/2); lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst,f[p]]],{n,6!}];lst

Extensions

Checked by Charles R Greathouse IV, Aug 11 2009

A163427 Primes p such that (p+1)^3/8+(p-1)/2 is also prime.

Original entry on oeis.org

5, 7, 13, 19, 29, 31, 41, 53, 71, 101, 103, 109, 173, 191, 199, 223, 229, 233, 239, 257, 269, 277, 331, 383, 397, 431, 491, 569, 571, 599, 619, 631, 719, 733, 751, 757, 761, 823, 857, 859, 863, 887, 907, 937, 967, 971, 977, 1009, 1019, 1063, 1069, 1123, 1163
Offset: 1

Views

Author

Keywords

Comments

Primes A000040(k) such that (A006254(k-1))^3+ A005097(k-1) is also prime.

Examples

			For p=5, (5+1)^3/8+(5-1)/2=27+2=29, prime, which adds p=5 to the sequence.
For p=7, (7+1)^3/8+(7-1)/2=67, prime, which adds p=7 to the sequence.
		

Crossrefs

Programs

  • Magma
    [p: p in PrimesInInterval(3, 1200) | IsPrime((p+1)^3 div 8+(p-1) div 2)]; // Vincenzo Librandi, Apr 09 2013
  • Mathematica
    f[n_]:=((p+1)/2)^3+((p-1)/2); lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst, p]],{n,6!}];lst
    Select[Prime[Range[100]], PrimeQ[(# + 1)^3 / 8 + (# - 1) / 2]&] (* Vincenzo Librandi, Apr 09 2013 *)

Formula

(a(n)+1)^3/8+(a(n)-1)/2 = A163426(n).

Extensions

Edited by R. J. Mathar, Aug 24 2009

A163428 Primes of the form ((p+1)/2)^3 + ((p-1)/2)^2 where p is prime.

Original entry on oeis.org

31, 73, 241, 379, 3571, 9661, 20359, 47881, 51949, 65521, 119953, 135151, 291721, 427351, 736921, 761671, 921889, 1202041, 1494313, 1533871, 1742161, 1785961, 2478331, 2533681, 3197839, 3820441, 3894229, 4044643, 4855033, 6573799
Offset: 1

Views

Author

Keywords

Comments

Primes of the form k^3 + k^2 - 2k + 1 where 2k-1 is prime.

Examples

			((5+1)/2)^3 + ((5-1)/2)^2 = 27 + 4 = 31, ((7+1)/2)^3 + ((7-1)/2)^2 = 64 + 9 = 73
		

Crossrefs

Programs

  • Maple
    res:= NULL:
    count:= 0:
    p:= 2
    while count < 100 do
      p:= nextprime(p);
      r:=  ((p+1)/2)^3 + ((p-1)/2)^2;
      if isprime(r) then
         res:= res, r;
         count:= count+1;
      fi
    od:
    res; # Robert Israel, Oct 10 2016
  • Mathematica
    f[n_]:=((p+1)/2)^3+((p-1)/2)^2; lst={}; Do[p=Prime[n]; If[PrimeQ[f[p]],AppendTo[lst,f[p]]],{n,6!}]; lst
  • PARI
    lista(nn) = forprime(p=3, nn, if (isprime(q=((p+1)/2)^3 + ((p-1)/2)^2), print1(q, ", "))); \\ Michel Marcus, Oct 11 2016

Extensions

Description and edits by Charles R Greathouse IV, Oct 05 2009
Showing 1-10 of 12 results. Next