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

A075432 Primes with no squarefree neighbors.

Original entry on oeis.org

17, 19, 53, 89, 97, 127, 149, 151, 163, 197, 199, 233, 241, 251, 269, 271, 293, 307, 337, 349, 379, 449, 487, 491, 521, 523, 557, 577, 593, 631, 701, 727, 739, 751, 773, 809, 811, 881, 883, 919, 953, 991, 1013, 1049, 1051, 1061, 1063, 1097, 1151, 1171, 1249
Offset: 1

Views

Author

Reinhard Zumkeller, Sep 15 2002

Keywords

Comments

Complement of A075430 in A000040.
From Ludovicus (luiroto(AT)yahoo.com), Dec 07 2009: (Start)
I propose a shorter name: non-Euclidean primes. That is justified by the Euclid's demonstration of the infinitude of primes. It appears that the proportion of non-Euclidean primes respect to primes tend to the limit 1-2A where A = 0.37395581... is Artin's constant. This table calculated by Jens K. Andersen corroborates it:
10^5: 2421 / 9592 = 0.2523978315
10^6: 19812 / 78498 = 0.2523885958
10^7: 167489 / 664579 = 0.2520227091
10^8: 1452678 / 5761455 = 0.2521373507
10^9: 12817966 / 50847534 = 0.2520862860
10^10: 114713084 / 455052511 = 0.2520875750
10^11: 1038117249 / 4118054813 = 0.2520892256
It comes close to the expected 1-2A. (End)
This sequence is infinite by Dirichlet's theorem, since there are infinitely many primes == 17 or 19 (mod 36) and these have no squarefree neighbors. Ludovicus's conjecture about density is correct. Capsule proof: either p-1 or p+1 is divisible by 4, so it suffices to consider the other number (without loss of generality, p+1). For some fixed bound L, p is not divisible by any prime q < L (with finitely many exceptions) so there are q^2 - q possible residue classes for p. The primes in each are uniformly distributed so the probability that p+1 is divisible by q^2 is 1/(q^2 - q). The product of the complements goes to 2A as L increases without bound, and since 2A is an upper bound the limit is sandwiched between. - Charles R Greathouse IV, Aug 27 2014
Primes p such that both p-1 and p+1 are divisible by a square greater than 1. - N. J. A. Sloane, Jul 19 2024

Examples

			p = 17 is a term because 16 = 4^2 and 18=2*3^2 are divisible by squares > 1. - _N. J. A. Sloane_, Jul 19 2024
		

Crossrefs

Intersection of A000040 and A281192.

Programs

  • Haskell
    a075432 n = a075432_list !! (n-1)
    a075432_list = f [2, 4 ..] where
       f (u:vs@(v:ws)) | a008966 v == 1 = f ws
                       | a008966 u == 1 = f vs
                       | a010051' (u + 1) == 0 = f vs
                       | otherwise            = (u + 1) : f vs
    -- Reinhard Zumkeller, May 04 2013
    
  • Maple
    filter:= n -> isprime(n) and not numtheory:-issqrfree(n+1) and not numtheory:-issqrfree(n-1):
    select(filter, [seq(2*i+1, i=1..1000)]); # Robert Israel, Aug 27 2014
  • Mathematica
    lst={}; Do[p=Prime[n]; If[ !SquareFreeQ[Floor[p-1]] && !SquareFreeQ[Floor[p+1]], AppendTo[lst,p]], {n,6!}]; lst (* Vladimir Joseph Stephan Orlovsky, Dec 20 2008 *)
    Select[Prime[Range[300]],!SquareFreeQ[#-1]&&!SquareFreeQ[#+1]&] (* Harvey P. Dale, Apr 24 2014 *)
  • PARI
    is(n)=!issquarefree(if(n%4==1, n+1, n-1)) && isprime(n) \\ Charles R Greathouse IV, Aug 27 2014

Formula

a(n) ~ Cn log n, where C = 1/(1 - 2A) = 1/(1 - Product_{p>2 prime} (1 - 1/(p^2-p))), where A is the constant in A005596. - Charles R Greathouse IV, Aug 27 2014

Extensions

More terms (that were already in the b-file) from Jeppe Stig Nielsen, Apr 23 2020

A240475 Primes that are midway between the closest flanking squarefree numbers.

Original entry on oeis.org

2, 17, 19, 53, 89, 163, 197, 199, 233, 251, 269, 271, 293, 307, 337, 379, 449, 487, 491, 521, 557, 593, 631, 701, 739, 751, 809, 811, 881, 883, 919, 953, 991, 1013, 1049, 1061, 1063, 1097, 1151, 1171, 1279, 1459, 1471, 1493, 1531, 1549, 1567, 1601, 1637
Offset: 1

Views

Author

Chris Boyd, Apr 06 2014

Keywords

Comments

Primes for which the corresponding A240473(m) is equal to A240474(m).
Primes equal to the average of the closest flanking squarefree numbers.
Primes equal to the average of three consecutive squarefree numbers.
Most terms are such that a(n)+2 and a(n)-2 are the closest squarefree numbers. The first term > 2 for which this is not the case is a(880) = 47527.
494501773, 765921647, 930996623 are the terms < 10^9 that also belong to A176141.

Examples

			19 is a term because it is midway between the closest flanking squarefree numbers 17 and 21.
On the other hand, 29 is not a term because it is not midway between the closest flanking squarefree numbers 26 and 30.
		

Crossrefs

Programs

  • Mathematica
    Select[Mean/@Partition[Select[Range[2000],SquareFreeQ],3,1],PrimeQ] (* Harvey P. Dale, Jul 27 2024 *)
  • PARI
    forprime(p=1,1650,forstep(j=p-1,1,-1,if(issquarefree(j),L=j;break));for(j=p+1,2*p,if(issquarefree(j),G=j;break));if(G-p==p-L,print1(p", ")))

A240476 Primes that are not midway between the closest flanking squarefree numbers.

Original entry on oeis.org

3, 5, 7, 11, 13, 23, 29, 31, 37, 41, 43, 47, 59, 61, 67, 71, 73, 79, 83, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 167, 173, 179, 181, 191, 193, 211, 223, 227, 229, 239, 241, 257, 263, 277, 281, 283, 311, 313, 317, 331, 347, 349, 353
Offset: 1

Views

Author

Chris Boyd, Apr 06 2014

Keywords

Comments

Primes for which the corresponding A240473(m) is not equal to A240474(m).
Primes not equal to the average of the closest flanking squarefree numbers.
Primes not equal to the average of three consecutive squarefree numbers.
Complement of A240475 relative to A000040.

Examples

			29 is a term because it is not midway between the closest flanking squarefree numbers 26 and 30.
On the other hand, 19 is not a term because it is midway between the closest flanking squarefree numbers 17 and 21.
		

Crossrefs

Programs

  • PARI
    forprime(p=1,353,forstep(j=p-1,1,-1,if(issquarefree(j),L=j;break));for(j=p+1,2*p,if(issquarefree(j),G=j;break));if(G-p!=p-L,print1(p", ")))

A075431 Primes of the form n+mu(n), where mu is the Moebius function (A008683).

Original entry on oeis.org

2, 7, 11, 23, 29, 41, 47, 59, 83, 101, 107, 109, 113, 137, 167, 173, 179, 181, 211, 227, 229, 257, 263, 281, 317, 331, 347, 353, 359, 373, 383, 401, 409, 433, 463, 467, 479, 503, 547, 563, 571, 587, 601, 617, 641, 653, 677, 691, 709, 719, 761, 821, 829, 839, 853
Offset: 1

Views

Author

Reinhard Zumkeller, Sep 15 2002

Keywords

Comments

Subsequence of A075430.

Crossrefs

Programs

  • PARI
    isok(p)={isprime(p) && (moebius(p+1) == -1 || moebius(p-1) == 1)} \\ Andrew Howroyd, Apr 20 2021

Extensions

Terms a(41) and beyond from Andrew Howroyd, Apr 20 2021
Showing 1-4 of 4 results.