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

A086709 Primes p such that p-1 and p+1 are both divisible by fourth powers.

Original entry on oeis.org

1249, 2753, 3727, 4049, 4801, 5023, 7937, 10529, 11503, 12799, 13121, 15391, 20897, 21871, 22193, 23167, 25759, 28351, 28751, 31249, 32561, 33857, 35153, 37423, 39041, 42929, 46817, 47791, 48751, 49409, 50383, 51679, 55889, 58481, 62047
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_]:=Max[Last/@FactorInteger[n]]; lst={};Do[p=Prime[n];If[f[p-1]>=4&&f[p+1]>=4,AppendTo[lst,p]],{n,8!}];lst (* Vladimir Joseph Stephan Orlovsky, Oct 03 2009 *)
    dfpQ[n_]:=Max[Transpose[FactorInteger[n]][[2]]]>3; Select[Prime[Range[ 6500]], dfpQ[#-1]&&dfpQ[#+1]&] (* Harvey P. Dale, May 11 2012 *)

A162870 Primes p such that p-1 and p+1 each contain at least one cubed prime in their prime factorization.

Original entry on oeis.org

919, 1999, 2647, 2663, 2969, 3511, 3833, 3943, 4751, 6857, 9127, 10313, 11287, 11719, 12041, 12583, 13033, 13337, 13879, 14249, 14633, 15497, 15607, 16903, 18089, 18199, 18251, 18521, 19751, 20249, 20359, 20681, 21751, 21977, 22409
Offset: 1

Views

Author

Keywords

Comments

The selection criterion is that p-1 and p+1 are in the subsequence 8=2^3, 24=2^3*3, 27=3^3, 40=2^3*5, 54=2*3^3,... of cubeful numbers (A046099) which actually display at least one cube in their standard prime factorization (A176297).
So at least one of the e_i in p-1=product p_i^e_i, and at least one of the e_j in p+1=product p_j^e_j must equal 3. This is more restrictive than being cubeful, so the sequence becomes a subsequence of A086708.

Examples

			271 is not in the sequence although 271 - 1 = 2*3^3*5 contains a third cube in the prime factorization, because 271 + 1 = 2^4*17 does not.
919 is in the sequence because 919 - 1 = 2*3^3*17 contains a third cube in the prime factorization and so does 919 + 1 = 2^3*5*23.
		

Crossrefs

Programs

  • Maple
    isA162870 := proc(n)
        if isprime(n) then
            isA176297(n-1) and isA176297(n+1) ;
        else
            false;
        end if;
    end proc:
    for n from 1 to 40000 do
        if isA162870(n) then
            printf("%d,",n) ;
        end if;
    end do: # R. J. Mathar, Dec 08 2015
    N:= 10^6: # to get all terms < N, where N is even
    V:= Vector(N/2):
    for i from 1 do
      p:= ithprime(i);
      if p^3 > N+1 then break fi;
      if p = 2 then inds:= 4*[seq(i,i=1..floor(N/8),2)]
      else inds:= p^3*select(t -> t mod p <> 0, [$1..floor(N/2/p^3)])
      fi;
      V[inds]:= 1;
    od:
    select(t -> V[(t-1)/2] = 1 and V[(t+1)/2] = 1 and isprime(t), [seq(t,t=3..N,2)]); # Robert Israel, Dec 08 2015
  • Mathematica
    f[n_]:=Module[{a=m=0},Do[If[FactorInteger[n][[m,2]]==3,a=1],{m,Length[FactorInteger[n]]}]; a]; lst={};Do[p=Prime[n];If[f[p-1]==1&&f[p+1]==1,AppendTo[lst,p]], {n,7!}];lst

Extensions

Role of cubefree numbers clarified by R. J. Mathar, Jul 31 2007

A089212 Primes p such that p-1 and p+1 are divisible by a fifth power.

Original entry on oeis.org

13121, 20897, 25759, 75329, 80191, 106433, 118751, 137537, 153089, 157951, 176417, 191969, 196831, 207521, 212383, 215297, 230849, 243487, 251263, 274591, 281249, 285281, 313471, 318751, 321247, 324161, 331937, 336799, 347489, 378593
Offset: 1

Views

Author

Cino Hilliard, Dec 09 2003

Keywords

Examples

			13121 is a term since 13121 - 1 = 2^6 * 5 * 41, 13121 + 1 = 2 * 3^8.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=Max[Last/@FactorInteger[n]]; lst={};Do[p=Prime[n];If[f[p-1]>=5&&f[p+1]>=5,AppendTo[lst,p]],{n,8!}];lst (* Vladimir Joseph Stephan Orlovsky, Oct 03 2009 *)
  • PARI
    \\ Input no. of iterations n, power p and number to subtract and add k.
    ispowerfree(m,p1) = { flag=1; y=component(factor(m),2); for(i=1,length(y), if(y[i] >= p1,flag=0;break); ); return(flag) }
    powerfreep4(n,p,k) = { c=0; pc=0; forprime(x=2,n, pc++; if(!ispowerfree(x-k,p) && !ispowerfree(x+k,p), c++; print1(x","); ) ); print(); print(c","pc","c/pc+.0) }

A166003 Primes p such that p+-1, p+-2 and p+-3 are not squarefree.

Original entry on oeis.org

47527, 186247, 218527, 245149, 269953, 377543, 390449, 432277, 447823, 453053, 469649, 518123, 568177, 584911, 589273, 606323, 632347, 661547, 761347, 831751, 848213, 897577, 913327, 925949, 952253, 1172351, 1205647, 1220347, 1241477
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_]:=Max[Last/@FactorInteger[n]]; q=2;lst={};Do[p=Prime[n];If[f[p-3]>=q&&f[p-2]>=q&&f[p-1]>=q&&f[p+1]>=q&&f[p+2]>=q&&f[p+3]>=q,AppendTo[lst,p]],{n,6*8!}];lst
    Select[Prime[Range[100000]],NoneTrue[#+{-3,-2,-1,1,2,3},SquareFreeQ]&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Apr 17 2018 *)

Extensions

Edited by N. J. A. Sloane, Oct 04 2009

A166000 Primes p such that p-5, p-3, p+3, and p+5 are divisible by cubes.

Original entry on oeis.org

12253, 14747, 65173, 83003, 93253, 95747, 109139, 147253, 176747, 213349, 255253, 282253, 284747, 287437, 305267, 311747, 315517, 336253, 338747, 364699, 365747, 444253, 452579, 471253, 525253, 554747, 583789, 633253, 716747, 741253, 743747
Offset: 1

Views

Author

Keywords

Comments

Subsequence of A089201. - R. J. Mathar, Dec 08 2015
Contains all primes == 12253 (mod 27000), and therefore the sequence is infinite. - Robert Israel, Apr 21 2016

Crossrefs

Programs

  • Maple
    filter:= proc(p) local d;
      if not isprime(p) then return false fi;
      for d in [-5,-3,3,5] do
         if max(map(t -> t[2], ifactors(p+d)[2])) < 3 then return false fi;
      od;
      true
    end proc:
    select(filter, [seq(t,t=7..10^6,2)]); # Robert Israel, Apr 21 2016
    # alternative
    isA166000 := proc(n)
        if isprime(n) then
                isA046099(n-3) and isA046099(n+3) and isA046099(n-5) and isA046099(n+5) ;
        else
                false;
        end if;
    end proc: # R. J. Mathar, Aug 14 2024
  • Mathematica
    f[n_]:=Max[Last/@FactorInteger[n]]; q=3;lst={};Do[p=Prime[n];If[f[p-5]>=q&&f[p-3]>=q&&f[p+3]>=q&&f[p+5]>=q,AppendTo[lst,p]],{n,4*8!}];lst
  • PARI
    ncf(n)={vecmax(factor(n)[,2])>2};forprime(p=5,1e7,if(ncf(p+5)&&ncf(p+3)&&ncf(p-3)&&ncf(p-5),print1(p","))) /* Charles R Greathouse IV, Oct 05 2009 */

A166001 Primes p such that p-5, p-4, p+4, and p+5 are each divisible by a cube > 1.

Original entry on oeis.org

751379, 2414507, 2839621, 3170371, 4469629, 5736371, 21154909, 22556371, 22991629, 23313371, 23748629, 24338371, 28372621, 31628371, 32079757, 33009629, 41078371, 42270629, 43465307, 44446621, 49746667, 50579339
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_]:=Max[Last/@FactorInteger[n]]; q=3;lst={};Do[p=Prime[n];If[f[p-5]>=q&&f[p-4]>=q&&f[p+4]>=q&&f[p+5]>=q,AppendTo[lst,p]],{n,4*8!}];lst

Extensions

Extended by Charles R Greathouse IV, Oct 09 2009

A166002 Primes p such that p-6, p-5, p+5, and p+6 are each divisible by a cube greater than 1.

Original entry on oeis.org

1934869, 6136619, 11195869, 11845499, 12385381, 33919619, 39139381, 39790381, 52937869, 53209381, 53631131, 54601619, 58690381, 62892131, 67951381, 77212381, 80224619, 88874869, 94544869, 95734381, 99936131, 103805869, 108827869
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_]:=Max[Last/@FactorInteger[n]]; q=3;lst={};Do[p=Prime[n];If[f[p-6]>=q&&f[p-5]>=q&&f[p+5]>=q&&f[p+6]>=q,AppendTo[lst,p]],{n,5*9!}];lst

Extensions

Edited by N. J. A. Sloane, Oct 04 2009
Extended and edited by Charles R Greathouse IV, May 12 2010

A086534 Smallest prime p sandwiched between two numbers that are divisible by n-th powers.

Original entry on oeis.org

2, 17, 271, 1249, 13121, 13121, 153089, 1272833, 28146689, 193562623, 652963841, 1378557953, 29096394751, 316431663103, 2191221587969, 15356401156097, 128200797454337, 314394051346433, 314394051346433, 28344942091829249, 201993039632138239, 267803891553271807
Offset: 1

Views

Author

Amarnath Murthy, Aug 17 2003

Keywords

Comments

Conjecture: sequence is finite.

Examples

			a(3) = 271, 270 = 3^3*10 and 272 = 2^3*34. 271 is the smallest such number.
a(4) = 1249, 1248 =2^4*78, 1250 = 5^4*2. 1250 is the smallest such number.
		

Crossrefs

Programs

  • Mathematica
    PrimeExponents[n_] := Max[ Flatten[ Table[ # [[2]], {1}] & /@ FactorInteger[n]]]; NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; a = Table[0, {15}]; p = 1; Do[p = NextPrim[p]; b = Min[ PrimeExponents[p - 1], PrimeExponents[p + 1]]; If[ a[[b]] == 0, a[[b]] = p; Print[b, " ", p]], {n, 1, 70000000}]; a

Extensions

Edited and extended by Robert G. Wilson v, Aug 18 2003
a(5) corrected. a(13)-a(22) from Donovan Johnson, Sep 02 2008
Showing 1-8 of 8 results.