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

A209321 Indices k for which A209312(k) = 2.

Original entry on oeis.org

4, 5, 6, 7, 9, 11, 14, 19, 26, 38, 46, 62, 70, 74, 86, 94, 118, 134, 194, 206, 278, 286, 566, 598, 778, 842, 934, 1006, 1082, 1214, 1238, 1546, 1574, 1726, 1858, 2018, 2278, 2474, 2774, 3142, 3686
Offset: 1

Views

Author

M. F. Hasler, Jan 19 2013

Keywords

Comments

Many of these seem to be even semiprimes.
Is this sequence infinite, and if so, can someone exhibit an explicitly calculable subsequence?
a(42) > 10^5, if it exists. - Amiram Eldar, May 02 2024

Crossrefs

Cf. A209312.

Programs

  • Mathematica
    f[p_, e_] := (p^(e + 1) - 1)/(p - 1); pracQ[n_] := pracQ[n] = (ind = Position[(fct = FactorInteger[n])[[;; , 1]]/(1 + FoldList[Times, 1, f @@@ Most@fct]), ?(# > 1 &)]) == {}; q[n] := 2 == Sum[If[pracQ[p] && ((PrimeQ[n - p] && PrimeQ[n + p]) || (pracQ[n - p] && pracQ[n + p])), 1, 0], {p, 1, n - 1}]; Select[Range[4000], q] (* Amiram Eldar, May 02 2024 *)

Extensions

Data corrected by Amiram Eldar, May 02 2024

A209315 Number of ways to write 2n-1 = p+q with q practical, p and q-p both prime.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 1, 0, 1, 2, 1, 2, 1, 2, 3, 2, 2, 2, 3, 1, 3, 4, 2, 2, 2, 3, 4, 3, 1, 3, 3, 1, 4, 5, 3, 3, 3, 2, 5, 4, 1, 3, 5, 2, 5, 4, 3, 4, 5, 2, 5, 5, 2, 4, 5, 3, 6, 5, 5, 5, 2, 3, 6, 5, 2, 3, 4, 3, 6, 5, 4, 4, 4, 5, 6, 6, 4, 5, 4, 3, 6, 8, 2, 2, 5, 6, 7, 6, 2, 6, 2, 4, 7, 6, 4, 3, 6, 3, 5, 5
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 19 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>8.
This has been verified for n up to 10^7.
As p+q=2p+(q-p), the conjecture implies Lemoine's conjecture related to A046927.
Zhi-Wei Sun also conjectured that any integer n>2 can be written as p+q, where p is a prime, one of q and q+1 is prime and another of q and q+1 is practical.

Examples

			a(9)=1 since 2*9-1=5+12 with 12 practical, 5 and 12-5 both prime.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[PrimeQ[p]==True&&pr[2n-1-p]==True&&PrimeQ[2n-1-2p]==True,1,0],{p,1,n-1}]
    Do[Print[n," ",a[n]],{n,1,100}]

A209320 Number of ways to write 2n = p+q with p and q both prime, p+1 and q-1 both practical.

Original entry on oeis.org

0, 0, 1, 2, 3, 2, 2, 2, 2, 3, 4, 5, 3, 2, 3, 3, 5, 7, 3, 3, 4, 4, 5, 8, 4, 3, 5, 2, 4, 8, 3, 4, 6, 2, 4, 7, 3, 4, 7, 2, 4, 9, 4, 4, 9, 5, 3, 9, 3, 5, 8, 3, 4, 10, 4, 6, 8, 5, 4, 14, 2, 4, 8, 2, 6, 10, 4, 4, 7, 4, 4, 10, 5, 4, 8, 3, 4, 9, 5, 5, 7, 3, 3, 13, 6, 5, 7, 4, 2, 11, 5, 5, 9, 4, 2, 9, 3, 6, 10, 7
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 19 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>2.
As p+q=(p+1)+(q-1), this unifies Goldbach's conjecture and its analog involving practical numbers.
The conjecture has been verified for n up to 10^7.

Examples

			a(8) = 2 since 2*8 = 3+13 = 11+5 with 3, 5, 11, 13 all prime and 3+1, 13-1, 11+1, 5-1 all practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[PrimeQ[2n-Prime[k]]==True&&pr[Prime[k]+1]==True&&pr[2n-Prime[k]-1]==True,1,0],{k,1,PrimePi[2n-2]}]
    Do[Print[n," ",a[n]],{n,1,100}]

A210445 Least positive integer k with k*n practical.

Original entry on oeis.org

1, 1, 2, 1, 4, 1, 4, 1, 2, 2, 6, 1, 6, 2, 2, 1, 12, 1, 12, 1, 2, 3, 12, 1, 4, 3, 2, 1, 12, 1, 16, 1, 2, 6, 4, 1, 18, 6, 2, 1, 20, 1, 20, 2, 2, 6, 24, 1, 4, 2, 4, 2, 24, 1, 4, 1, 4, 6, 24, 1, 24, 8, 2, 1, 4, 1, 30, 3, 4, 2, 30, 1, 30, 9, 2, 3, 4, 1, 36, 1, 2, 10, 36, 1, 4, 10, 4, 1, 36, 1, 4, 3, 6, 12, 4, 1, 42, 2, 2, 1
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 20 2013

Keywords

Comments

Conjecture: a(n) < n for all n>1, and a(n) < n/2 for all n>47.
Large values are obtained for prime n: The corresponding subsequence is a(p(n)) = (1, 2, 4, 4, 6, 6, 12, 12, 12, 12, 16, 18, 20, 20, 24, 24, 24, 24, ...), while for composite indices, a(c(n)) = (1, 1, 1, 1, 2, 2, 1, 2, 2, 1, 1, 1, 2, 3, 1, 4, 3, 2, 1, 1, 1, 2, ...). - M. F. Hasler, Jan 21 2013

Examples

			a(10)=2 since 2*10=20 is practical but 1*10=10 is not.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    Do[Do[If[pr[k*n]==True,Print[n," ",k];Goto[aa]],{k,1,n}];
    Print[n," ",counterexample];Label[aa];Continue,{n,1,100}]
  • PARI
    A210445(n)={for(k=1,n,is_A005153(k*n)&&return(k))} \\ (Would return 0 if a(n)>n.) - M. F. Hasler, Jan 20 2013

Formula

a(n) = 1 iff n is in A005153, therefore a(n) > 1 for all odd n>1. - M. F. Hasler, Jan 21 2013

A210531 Number of nonnegative integers k

Original entry on oeis.org

1, 1, 1, 2, 2, 1, 2, 4, 2, 2, 2, 3, 2, 2, 4, 5, 4, 2, 3, 7, 5, 1, 2, 7, 4, 2, 7, 5, 6, 1, 5, 9, 4, 4, 6, 9, 9, 2, 5, 12, 9, 3, 5, 6, 8, 5, 6, 13, 4, 2, 8, 6, 11, 6, 11, 14, 8, 2, 4, 7, 4, 5, 7, 29, 8, 3, 5, 8, 11, 4, 13, 16, 13, 2, 7, 12, 13, 6, 10, 16, 10, 6, 15, 9, 13, 3, 9, 20, 11, 8, 11, 20, 9, 2, 8, 22, 14, 6, 15, 15
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 28 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>0. Moreover, if n>0 is different from 74, 138, 166, 542, then n+k^3 is practical for some 0<=k<=sqrt(n)*log(n); if n is not equal to 102, then n+k and n+k^3 are both practical for some k=0,...,n-1.
Zhi-Wei Sun also conjectured that any integer n>1 can be written as x^3+y (x,y>0) with 2x and 4xy both practical.

Examples

			a(22)=1 since 22+2^3=30 is practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[pr[n+k^3]==True,1,0],{k,0,n-1}]
    Do[Print[n," ",a[n]],{n,1,100}]

A210480 Number of primes p

Original entry on oeis.org

0, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 2, 2, 2, 2, 2, 1, 3, 3, 4, 4, 4, 5, 4, 4, 3, 3, 2, 2, 4, 4, 4, 5, 5, 7, 6, 6, 3, 4, 3, 3, 5, 5, 4, 5, 5, 7, 7, 6, 4, 3, 3, 4, 4, 3, 2, 4, 4, 7, 6, 6, 3, 3, 4, 4, 4, 4, 2, 4, 4, 6, 5, 5, 3, 2, 4, 4, 6, 3, 3, 4, 4, 7, 5, 6, 4, 4, 4, 4, 7, 6, 5, 4, 3, 8, 5, 7, 3, 3, 5
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 23 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>3.
This is stronger than Goldbach's conjecture and the author's conjecture that any odd number greater than one is the sum of a prime and a practical number. Also, it implies that there are infinitely many primes p with p-1 and p+1 both practical.
The author has verified this new conjecture for n up to 10^7.

Examples

			a(1846)=1 since 1846=1289+557 with 1289 and 557 both prime, and 1288 and 1290 both practical.
a(15675)=1 since 15675=919+14756 with 919 prime, and 918, 920, 14756 all practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[pr[Prime[k]-1]==True&&pr[Prime[k]+1]==True&&(PrimeQ[n-Prime[k]]==True||pr[n-Prime[k]]==True),1,0],{k,1,PrimePi[n-1]}]
    Do[Print[n," ",a[n]],{n,1,100}]

A210533 Number of ways to write 2n = x+y (x,y>0) with x-1 and x+1 both prime, and x and x^3+y^3 both practical.

Original entry on oeis.org

0, 0, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 4, 4, 4, 5, 1, 5, 3, 5, 5, 5, 3, 6, 5, 6, 6, 6, 3, 6, 2, 7, 7, 6, 6, 7, 1, 6, 8, 8, 3, 8, 4, 6, 8, 7, 4, 8, 4, 8, 8, 6, 5, 8, 5, 6, 9, 7, 3, 9, 6, 8, 9, 8, 5, 9, 3, 7, 9, 7, 5, 9, 2, 7, 9, 7, 4, 10, 4, 8, 10, 8, 5, 10, 8, 7, 10, 10, 6, 10, 4, 9, 11, 8, 7, 11, 6, 11, 12, 11
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 28 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>2. Moreover, for each m=2,3,4,... any sufficiently large even integer can be written as x+y (x,y>0) with x-1 and x+1 both prime, and x and x^m+y^m both practical.

Examples

			a(17)=1 since 2*17=12+22 with 11 and 13 both prime, and 12 and 12^3+22^3=12376 both practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[PrimeQ[2k-1]==True&&PrimeQ[2k+1]==True&&pr[2k]==True&&pr[(2k)^3+(2n-2k)^3]==True,1,0],{k,1,n-1}]
    Do[Print[n," ",a[n]],{n,1,100}]

A210681 Number of ways to write 2n = p+q+r (p<=q) with p, q, r-1, r+1 all prime and p-1, p+1, q-1, q+1, r all practical.

Original entry on oeis.org

0, 0, 0, 0, 1, 2, 3, 3, 3, 2, 2, 3, 5, 6, 4, 3, 2, 4, 7, 10, 8, 5, 3, 5, 8, 12, 10, 6, 2, 3, 6, 11, 12, 6, 4, 3, 5, 9, 10, 6, 5, 4, 5, 8, 8, 5, 7, 7, 6, 8, 7, 6, 6, 8, 6, 7, 8, 5, 7, 8, 6, 7, 7, 4, 6, 7, 5, 6, 8, 4, 8, 6, 4, 5, 7, 5, 5, 8, 5, 6, 8, 6, 4, 7, 6, 6, 7, 5, 3, 7, 3, 4, 8, 6, 8, 5, 4, 3, 7, 6
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 29 2013

Keywords

Comments

Conjecture: a(n) > 0 for all n > 4.
This conjecture involves two kinds of sandwiches introduced by the author, and it is much stronger than the Goldbach conjecture for odd numbers. We have verified the conjecture for n up to 10^7.
Zhi-Wei Sun also made the following conjectures:
(1) Any even number greater than 10 can be written as the sum of four elements in the set
S = {prime p: p-1 and p+1 are both practical}.
Also, every n=3,4,5,... can be represented as the sum of a prime in S and two triangular numbers.
(2) Each integer n>7 can be written as p + q + x^2 (or p + q + x(x+1)/2), where p is a prime with p-1 and p+1 both practical, and q is a practical number with q-1 and q+1 both prime.
(3) Every n=3,4,... can be written as the sum of three elements in the set
T = {x: 6x is practical with 6x-1 and 6x+1 both prime}.
(4) Any integer n>6 can be represented as the sum of two elements of the set S and one element of the set T.
(5) Each odd number greater than 11 can be written in the form 2p+q+r, where p and q belong to S, and r is a practical number with r-1 and r+1 both prime.

Examples

			a(5)=1 since 2*5=3+3+4 with 3 and 5 both prime, and 2 and 4 both practical.
a(6)=2 since 2*6=3+3+6=3+5+4 with 3,5,7 all prime and 2,4,6 all practical.
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    pp[k_]:=pp[k]=pr[Prime[k]-1]==True&&pr[Prime[k]+1]==True
    pq[n_]:=pq[n]=PrimeQ[n-1]==True&&PrimeQ[n+1]==True&&pr[n]==True
    a[n_]:=a[n]=Sum[If[pp[j]==True&&pp[k]==True&&pq[2n-Prime[j]-Prime[k]]==True,1,0],{j,1,PrimePi[n-1]},{k,j,PrimePi[2n-Prime[j]]}]
    Do[Print[n," ",a[n]],{n,1,100}]

A210444 a(n) = |{0

Original entry on oeis.org

0, 0, 1, 2, 0, 4, 1, 0, 2, 2, 0, 4, 0, 1, 4, 2, 0, 6, 1, 3, 2, 2, 0, 5, 2, 1, 3, 1, 2, 11, 0, 1, 4, 1, 2, 6, 0, 2, 4, 3, 1, 9, 2, 3, 4, 2, 0, 7, 1, 4, 4, 5, 0, 8, 4, 1, 3, 3, 0, 15, 0, 3, 4, 4, 4, 13, 2, 4, 2, 5, 2, 10, 0, 2, 11, 2, 3, 12, 0, 6, 6, 2, 2, 13, 3, 5, 7, 5, 1, 16, 4, 4, 6, 3, 2, 11, 0, 8, 6, 7
Offset: 1

Views

Author

Zhi-Wei Sun, Jan 20 2013

Keywords

Comments

Conjecture: a(n)>0 for all n>911.
This implies that for each n=2,3,4,... there is a positive integer k
The conjecture has been verified for n up to 10^6.

Examples

			a(7) = 1 since 6*7 = 42 is practical, and 41 and 43 are twin primes.
		

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    a[n_]:=a[n]=Sum[If[PrimeQ[k*n-1]==True&&PrimeQ[k*n+1]==True&&pr[k*n]==True,1,0],{k,1,n-1}]
    Do[Print[n," ",a[n]],{n,1,100}]

A210722 Number of ways to write n = (2-(n mod 2))p+q+2^k with p, q-1, q+1 all prime, and p-1, p+1, q all practical.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 3, 1, 4, 2, 4, 2, 4, 3, 4, 4, 3, 4, 5, 3, 8, 5, 8, 4, 5, 4, 5, 3, 5, 4, 4, 3, 9, 2, 12, 4, 9, 5, 7, 6, 7, 5, 5, 7, 10, 5, 13, 6, 10, 6, 8, 6, 7, 5, 1, 7, 7, 1, 10, 5, 8, 4, 9, 7, 8, 6, 3, 10, 6, 6, 10, 7, 7, 9, 11, 7, 10, 10, 5, 10, 7, 5, 10, 7, 4, 8, 8, 5, 11, 5, 8, 10, 7, 5, 12, 5
Offset: 1

Author

Zhi-Wei Sun, Jan 29 2013

Keywords

Comments

Conjecture: a(n)>0 except for n = 1,...,8, 10, 520, 689, 740.
Zhi-Wei Sun also guessed that any integer n>6 different from 407 can be written as p+q+F_k, where p is a prime with p-1 and p+1 practical, q is a practical number with q-1 and q+1 prime, and F_k (k>=0) is a Fibonacci number.

Examples

			a(1832)=1 since 1832=2*881+6+2^6 with 5, 7, 881 all prime and 6, 880, 882 all practical.
a(11969)=1 since 11969=127+11778+2^6 with 127, 11777, 11779 all prime and 126, 128, 11778 all practical.
		

Programs

  • Mathematica
    f[n_]:=f[n]=FactorInteger[n]
    Pow[n_, i_]:=Pow[n, i]=Part[Part[f[n], i], 1]^(Part[Part[f[n], i], 2])
    Con[n_]:=Con[n]=Sum[If[Part[Part[f[n], s+1], 1]<=DivisorSigma[1, Product[Pow[n, i], {i, 1, s}]]+1, 0, 1], {s, 1, Length[f[n]]-1}]
    pr[n_]:=pr[n]=n>0&&(n<3||Mod[n, 2]+Con[n]==0)
    pp[k_]:=pp[k]=pr[Prime[k]-1]==True&&pr[Prime[k]+1]==True
    pq[n_]:=pq[n]=PrimeQ[n-1]==True&&PrimeQ[n+1]==True&&pr[n]==True
    a[n_]:=a[n]=Sum[If[pp[j]==True&&pq[n-2^k-(2-Mod[n,2])Prime[j]]==True,1,0],{k,0,Log[2,n]},{j,1,PrimePi[(n-2^k)/(2-Mod[n,2])]}]
    Do[Print[n," ",a[n]],{n,1,100}]
Showing 1-10 of 13 results. Next