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-6 of 6 results.

A153213 Primes p such that both p-2 and p+2 are not squarefree.

Original entry on oeis.org

2, 47, 173, 277, 727, 839, 929, 1181, 1423, 1447, 1523, 1627, 1811, 1847, 1861, 1973, 2207, 2297, 2423, 2693, 3323, 3701, 3719, 3877, 4327, 4363, 4457, 4673, 4691, 4903, 5227, 5573, 5821, 5927, 6173, 6221, 6323, 6473, 6577, 6653, 7027, 7103, 7477, 7823
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=Prime[n];If[ !SquareFreeQ[p-2]&&!SquareFreeQ[p+2],AppendTo[lst,p]],{n,7!}];lst
  • PARI
    is(n)=isprime(n) && !issquarefree(n-2) && !issquarefree(n+2) \\ Charles R Greathouse IV, Nov 05 2017

A153208 Primes of the form 2*p-1 where p is prime and p-1 is not squarefree.

Original entry on oeis.org

37, 73, 193, 313, 397, 457, 541, 613, 673, 757, 1153, 1201, 1321, 1453, 1621, 1657, 1753, 1873, 1993, 2017, 2137, 2341, 2473, 2557, 2593, 2857, 2917, 3061, 3217, 3313, 4057, 4177, 4273, 4357, 4441, 4561, 4933, 5077, 5101, 5113, 5233, 5437, 5581, 5701
Offset: 1

Views

Author

Keywords

Comments

Subsequence of A005383.

Examples

			For p = 2 (the only case with p-1 odd), 2*p-1 = 3 is prime but p-1 = 1 is squarefree, so 3 is not in the sequence. For p = 19, 2*p-1 = 37 is prime and p-1 = 18 is not squarefree, so 37 is in the sequence.
		

Crossrefs

Cf. A013929 (nonsquarefree numbers), A005383 (numbers n such that both n and (n+1)/2 are primes), A153207, A153209, A153210.

Programs

  • Magma
    [ q: p in PrimesUpTo(2900) | not IsSquarefree(p-1) and IsPrime(q) where q is 2*p-1 ];
  • Maple
    R:= NULL; count:= 0: p:= 3:
    while count < 100 do
      p:= nextprime(p);
      if isprime(2*p-1) and not numtheory:-issqrfree(p-1) then
         R:= R, 2*p-1; count:= count+1;
      fi
    od:
    R; # Robert Israel, Nov 22 2023
  • Mathematica
    lst={}; Do[p = Prime[n]; If[ !SquareFreeQ[Floor[p/2]] && PrimeQ[Ceiling[p/2]], AppendTo[lst, p]], {n, 7!}]; lst
    Select[2#-1&/@Select[Prime[Range[1000]],!SquareFreeQ[#-1]&],PrimeQ] (* Harvey P. Dale, Aug 11 2024 *)

Extensions

Edited by Klaus Brockhaus, Dec 24 2008
Mathematica updated by Jean-François Alcover, Jul 04 2013

A153209 Primes of the form 2*p+1 where p is prime and p+1 is squarefree.

Original entry on oeis.org

5, 11, 59, 83, 227, 347, 563, 1019, 1283, 1307, 1523, 2459, 2579, 2819, 2963, 3803, 3947, 4259, 4547, 5387, 5483, 6779, 6827, 7187, 8147, 9587, 10667, 10883, 11003, 12107, 12227, 12539, 12659, 13043, 13163, 14243, 14387, 15683, 16139, 16187
Offset: 1

Views

Author

Keywords

Comments

Subsequence of A005385.

Examples

			For p = 2 (the only case with p+1 odd), 2*p+1 = 5 is prime and p+1 = 3 is squarefree, so 5 is in the sequence. For p = 3, 2*p+1 = 7 is prime and p+1 = 4 is not squarefree, so 7 is not in the sequence.
		

Crossrefs

Cf. A005117 (squarefree numbers), A005385 (safe primes p: (p-1)/2 is also prime), A153207, A153208, A153210.

Programs

  • Magma
    [ q: p in PrimesUpTo(8100) | IsSquarefree(p+1) and IsPrime(q) where q is 2*p+1 ];
  • Mathematica
    lst = {}; Do[p = Prime[n]; If[PrimeQ[Floor[p/2]] && SquareFreeQ[Ceiling[p/2]], AppendTo[lst, p]], {n, 7!}]; lst
    Select[2#+1&/@Select[Prime[Range[2000]],SquareFreeQ[#+1]&],PrimeQ] (* Harvey P. Dale, Aug 02 2024 *)

Extensions

Edited by Klaus Brockhaus, Dec 24 2008
Mathematica updated by Jean-François Alcover, Jul 04 2013

A153210 Primes of the form 2*p+1 where p is prime and p+1 is not squarefree.

Original entry on oeis.org

7, 23, 47, 107, 167, 179, 263, 359, 383, 467, 479, 503, 587, 719, 839, 863, 887, 983, 1187, 1319, 1367, 1439, 1487, 1619, 1823, 1907, 2027, 2039, 2063, 2099, 2207, 2447, 2879, 2903, 2999, 3023, 3119, 3167, 3203, 3467, 3623, 3779, 3863, 4007, 4079, 4127
Offset: 1

Views

Author

Keywords

Comments

Subsequence of A005385.

Examples

			For p = 2 (the only case with p+1 odd), 2*p+1 = 5 is prime but p+1 = 3 is squarefree, so 5 is not in the sequence. For p = 3, 2*p+1 = 7 is prime and p+1 = 4 is not squarefree, so 7 is in the sequence.
		

Crossrefs

Cf. A013929 (nonsquarefree numbers), A005385 (safe primes p: (p-1)/2 is also prime), A153207, A153208, A153209.

Programs

  • Magma
    [ q: p in PrimesUpTo(2100) | not IsSquarefree(p+1) and IsPrime(q) where q is 2*p+1 ];
  • Mathematica
    lst = {}; Do[p = Prime[n]; If[PrimeQ[Floor[p/2]] && !SquareFreeQ[Ceiling[p/2]], AppendTo[lst, p]], {n, 7!}]; lst
    2#+1&/@Select[Prime[Range[400]],!SquareFreeQ[#+1]&&PrimeQ[2#+1]&] (* Harvey P. Dale, Mar 17 2019 *)

Extensions

Edited by Klaus Brockhaus, Dec 24 2008
First Mathematica program updated by Jean-François Alcover, Jul 04 2013

A153215 Primes p such that none of p-2, p-1, p+1, and p+2 is squarefree.

Original entry on oeis.org

727, 1423, 1861, 3719, 6173, 9749, 11321, 13183, 19073, 20873, 23227, 23473, 23827, 26981, 27883, 34351, 35323, 41263, 42677, 44449, 45127, 45523, 47527, 48751, 49727, 52391, 53623, 53849, 68749, 71993, 72559, 78823, 83609, 89227, 92779
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    << NumberTheory`NumberTheoryFunctions` lst={}; Do[p=Prime[n];If[ !SquareFreeQ[p-1]&&!SquareFreeQ[p+1]&&!SquareFreeQ[p-2]&&!SquareFreeQ[p+2],AppendTo[lst,p]],{n,4*7!}]; lst

A153214 Primes p such that p+-2 and p+-3 are not squarefree.

Original entry on oeis.org

47, 1447, 1847, 3701, 6653, 11273, 14947, 15727, 17053, 18493, 21661, 24923, 26647, 29153, 32789, 33023, 38873, 39323, 42437, 42923, 44053, 47527, 47977, 49853, 52027, 52153, 56747, 56873, 59929, 71147, 74189, 79427, 80953, 99277, 99713
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    lst={};Do[p=Prime[n];If[ !SquareFreeQ[p-2]&&!SquareFreeQ[p+2]&&!SquareFreeQ[p-3]&&!SquareFreeQ[p+3],AppendTo[lst,p]],{n,3*7!}];lst
    Select[Prime[Range[10000]],NoneTrue[#+{-3,-2,2,3},SquareFreeQ]&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Aug 27 2019 *)
Showing 1-6 of 6 results.