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

A108604 Squares of the form prime(k)*prime(k+1) + 2*prime(k+1).

Original entry on oeis.org

25, 49, 169, 361, 961, 1849, 3721, 5329, 10609, 11881, 19321, 22801, 32761, 37249, 39601, 52441, 58081, 73441, 80089, 97969, 121801, 177241, 187489, 214369, 273529, 326041, 361201, 383161, 413449, 436921, 657721, 677329, 687241, 737881, 779689
Offset: 1

Views

Author

Giovanni Teofilatto, Jul 06 2005

Keywords

Comments

Squares of greater of twin primes.

Crossrefs

Programs

  • Maple
    ZL:=[]:for p from 1 to 950 do if (isprime(p) and isprime(p+2)) then ZL:=[op(ZL),((p+2)^2)]; fi; od; print(ZL); # Zerinvary Lajos, Mar 08 2007
  • Mathematica
    Select[Sqrt/@Table[Prime[k]*Prime[k+1]+2Prime[k+1],{k,160}],IntegerQ]^2 (* James C. McMahon, Jan 27 2024 *)

Formula

a(n) = A006512(n)^2.

Extensions

Corrected and extended by Ray Chandler, Jul 10 2005

A111046 Difference between squares of twin prime pairs.

Original entry on oeis.org

16, 24, 48, 72, 120, 168, 240, 288, 408, 432, 552, 600, 720, 768, 792, 912, 960, 1080, 1128, 1248, 1392, 1680, 1728, 1848, 2088, 2280, 2400, 2472, 2568, 2640, 3240, 3288, 3312, 3432, 3528, 4080, 4128, 4200, 4248, 4368, 4608, 4920, 5112, 5160, 5208, 5280
Offset: 1

Views

Author

Giovanni Teofilatto, Oct 06 2005

Keywords

Comments

Except for the first term 16 = 4^2, a(n) is never a square.

Crossrefs

Programs

  • Haskell
    a111046 = (* 2) . a054735  -- Reinhard Zumkeller, Feb 10 2015
  • Maple
    ZL:=[]:for p from 1 to 1400 do if (isprime(p) and isprime(p+2)) then ZL:=[op(ZL),(((p+2)^2)-p^2)]; fi; od; print(ZL); # Zerinvary Lajos, Mar 08 2007
  • Mathematica
    Select[Table[Prime[n] + 1, {n, 220}], PrimeQ[ # + 1] &] *4 (* Ray Chandler, Oct 12 2005 *)
    4+4#&/@Select[Partition[Prime[Range[300]],2,1],#[[2]]-#[[1]]==2&] [[All,1]] (* Harvey P. Dale, Apr 12 2018 *)

Formula

a(n) = A006512(n)^2 - A001359(n)^2 = A108604(n) - A108570(n) = 2*A054735(n) = 4*A014574(n) = 8*A040040(n).

Extensions

Edited and extended by Ray Chandler, Oct 12 2005

A171727 The number of twin prime pairs in the interval (p^2,p*q), where (p,q) runs over the twin prime pairs (A001359(n),A006512(n)).

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 4, 1, 3, 2, 2, 4, 7, 3, 3, 5, 7, 4, 4, 7, 6, 11, 9, 5, 11, 9, 9, 11, 10, 11, 9, 11, 11, 12, 11, 12, 18, 12, 12, 16, 11, 16, 20, 14, 16, 15, 20, 16, 22, 13, 22, 16, 17, 21, 20, 20, 23, 22, 23, 20, 21, 21, 26, 20, 28, 24, 24, 23, 24, 25, 21, 24, 37, 27, 21, 28, 24, 31
Offset: 1

Views

Author

Jaspal Singh Cheema, Dec 16 2009

Keywords

Comments

If you graph the order of the twin primes along the x-axis (i.e., first twin, second, third, ...) and the number of twins in the sequence given above along the y-axis, a clear pattern emerges. As you go farther along the x-axis, the number of twin primes, on average, within the interval increases. The pattern appears to be nonlinear. If one could prove that there's at least one twin prime within each interval, the twin prime conjecture would be proved since the n-th twin produces larger intervals with more twin primes. The evidence seems overwhelming.

Examples

			The first twin prime pair (3,5) corresponds to the interval (9,15), which contains one twin prime pair (11,13), so a(1) = 1.
The fifth twin prime pair (29,31) corresponds to the interval (841,899), which contains the twin prime pairs (857,859) and (881,883), so a(5) = 2.
		

References

  • C. C. Clawson, Mathematical Mysteries: The Beauty and Magic of Numbers, Perseus Books, 1999.
  • J. Derbyshire, Prime Obsession: Bernhard Riemann and the Greatest Unsolved Problem in Mathematics, Penguin Books Canada Ltd., 2004.
  • M. du Sautoy, The Music of the Primes: Searching to Solve the Greatest Mystery in Mathematics, HarperCollins Publishers Inc., 2004.

Crossrefs

Programs

  • PARI
    {for(k=1, 300, if(prime(k+1)-prime(k)==2, my(c=0); forprime(m=prime(k)^2, prime(k)*prime(k+1), c+=isprime(m+2)); print1(c, ", ")))} \\ Zhandos Mambetaliyev, Mar 28 2021

Extensions

Partially edited by Michel Marcus, Mar 19 2013
Edited by Charlie Neder, Feb 12 2019

A330477 Semiprimes (A001358) p*q such that p*q+p+q is also a semiprime.

Original entry on oeis.org

9, 22, 25, 39, 62, 69, 77, 87, 91, 94, 95, 106, 115, 119, 121, 122, 133, 134, 142, 146, 159, 183, 187, 202, 213, 214, 218, 219, 226, 235, 237, 249, 253, 259, 262, 265, 274, 287, 289, 291, 299, 303, 305, 309, 314, 335, 362, 381, 386, 393, 403, 411, 417, 422, 446, 458, 469, 473, 489, 501, 502, 505
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Dec 15 2019

Keywords

Examples

			a(3) = 25 is a member because 25 = 5*5 and 25+5+5 = 5*7 is also a semiprime.
		

Crossrefs

Cf. A001358.
Contains A108570.

Programs

  • Maple
    N:= 1000:
    Primes:= select(isprime, [2,seq(i,i=3..N)]):
    SP:= sort([seq(seq([p,q],q=select(t -> t >= p and p*t<=N, Primes)),p=Primes)],(a,b) -> a[1]*a[2] t[1]*t[2], select(t -> numtheory:-bigomega(t[1]*t[2]+t[1]+t[2])=2, SP));
  • Mathematica
    Select[Union@ Apply[Join, Table[Flatten@{p #, Sort[{p, #}]} & /@ Prime@ Range@ PrimePi@ Floor[Max[#]/p], {p, #}]] &@ Prime@ Range@ 97, PrimeOmega[Total@ #] == 2 &][[All, 1]] (* Michael De Vlieger, Dec 15 2019 *)
  • PARI
    issemi(n)=bigomega(n)==2
    list(lim)=my(v=List()); forprime(p=2, sqrtint(lim\=1), forprime(q=p, lim\p, if(issemi(p*q+p+q), listput(v,p*q)))); Set(v) \\ Charles R Greathouse IV, Dec 16 2019
    
  • Python
    from sympy import factorint
    def is_semiprime(n): return sum(e for e in factorint(n).values()) == 2
    def ok(n):
        f = factorint(n, multiple=True)
        if len(f) != 2: return False
        p, q = f
        return len(factorint(p*q + p + q, multiple=True)) == 2
    print(list(filter(ok, range(506)))) # Michael S. Branicky, Sep 22 2021

A110487 Squares of the form p*q - p - q + 2, where p and q are primes.

Original entry on oeis.org

9, 25, 49, 81, 121, 169, 225, 289, 361, 529, 625, 841, 961, 1225, 1369, 1521, 1681, 1849, 2025, 2209, 2401, 2601, 2809, 3025, 3481, 3721, 4225, 4489, 4761, 5041, 5329, 5929, 6241, 6889, 7225, 7921, 8281, 9025, 9409, 10201, 10609, 11449, 11881, 12769
Offset: 1

Views

Author

Giovanni Teofilatto, Sep 11 2005

Keywords

Comments

Includes A108570 squares of lesser twin primes and A110284 squares of form 4p-3 where p is prime (q=5).

Crossrefs

Programs

  • Mathematica
    Lim=13000;f[{p_,q_}]:=p*q-p-q+2;Union[Select[f/@Subsets[Prime[Range[PrimePi[Lim]]], {2}],#James C. McMahon, Apr 20 2024 *)

Extensions

Corrected and extended by Ray Chandler, Sep 13 2005
Showing 1-5 of 5 results.