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.

Previous Showing 11-20 of 21 results. Next

A078597 Primes of the form p*(p+4)+2 where p and p+4 are primes.

Original entry on oeis.org

23, 79, 223, 439, 4759, 53359, 77839, 95479, 99223, 159199, 194479, 239119, 378223, 416023, 680623, 2223079, 2595319, 2873023, 3186223, 3515623, 4003999, 5022079, 6456679, 6859159, 8732023, 9235519, 9492559, 10017223, 10595023
Offset: 1

Views

Author

Cino Hilliard, Dec 08 2002

Keywords

Comments

More generally, if a and b are even numbers, let Seq(a,b) be the sequence of primes of the form p*(p+a)+b where p and p+a are primes. Seq(a,b) is finite if either a^2+b == 2 (mod 3) or a^2-4*b is a square. Is it infinite in all other cases?

Crossrefs

Except for the term 23, this is a subsequence of A048880. A051779 is Seq(2, 2). A049002 is Seq(0, -2). A045637 is Seq(0, 4).

Programs

  • Mathematica
    Select[ #(#+4)+2&/@Select[Prime/@Range[500], PrimeQ[ #+4]&], PrimeQ]
  • PARI
    prodtp(n1,n2,a,b)=local(f,x); f=0; forprime(x=n1,n2,if(isprime(x+a),f=x*(x+a)+b; if(isprime(f),print(x" "x+a" "f" "); ); ); ); \ Computes that part of Seq(a,b) with n1<=p<=n2.

Extensions

Edited by Dean Hickerson, Dec 10 2002

A107312 Primes p such that p + 2 and p^2 + 2^2 are primes.

Original entry on oeis.org

3, 5, 17, 137, 347, 827, 2087, 2687, 3557, 3917, 4517, 4967, 5477, 5657, 5867, 6827, 7457, 7547, 7877, 8087, 8537, 8597, 10037, 10427, 10937, 12107, 12377, 13397, 13877, 16067, 17837, 17987, 19427, 19697, 20507, 20717, 20807, 22367, 22637
Offset: 1

Views

Author

Zak Seidov, May 21 2005

Keywords

Comments

Primes are lesser twins. Except a(1) and a(2), all a(n) == 7(mod 10).

Crossrefs

Cf. A045637.

Programs

  • Magma
    [p: p in PrimesUpTo(25000)|  IsPrime(p+2) and IsPrime(p^2+4)]; // Vincenzo Librandi, Jan 29 2011
    
  • Maple
    select(p -> isprime(p) and isprime(p+2) and isprime(p^2+4), [seq(2*i+1,i=1..10000)]); # Robert Israel, Aug 11 2014
  • Mathematica
    Select[Prime[Range[3000]], PrimeQ[ #+2]&&PrimeQ[ #^2+4]&]
  • PARI
    a(n)=isprime(n) && isprime(n+2) && isprime(n^2+4) \\ Edward Jiang, Aug 08 2014

A174050 Primes of the form x^2 + y^2 such that L(x)* L(y) = 1, where L is the Liouville lambda-function A008836.

Original entry on oeis.org

2, 13, 17, 29, 37, 53, 73, 89, 97, 101, 113, 173, 181, 193, 197, 233, 241, 257, 277, 293, 313, 337, 349, 353, 373, 409, 421, 433, 449, 457, 521, 541, 569, 577, 593, 613, 641, 661, 673, 677, 709, 733, 757, 761, 809, 821, 853, 881, 929, 1021, 1033, 1049, 1069
Offset: 1

Views

Author

Michel Lagneau, Mar 06 2010

Keywords

Comments

One contribution to the set of solutions is from (x,y) where x and y are both prime, see A045637.
Another set of solutions is contributed if (x,y) are both in A026424.

Examples

			2 is in the sequence because 2 = 1 + 1 and L(1)*L(1)= (1) *(1) = 1.
13 is in the sequence because 13 = 2^2 + 3^2 and L(2)*L(3)= (-1)*(-1) = 1.
193 is in the sequence because 193 = 12^2 + 7^2 and L(12)*L(7)= (-1)*(-1) = 1.
		

Crossrefs

Programs

  • Maple
    isA174050 := proc(n)
            local x,y ;
            if not isprime(n) then
                    return false;
            end if;
            for x from 1 do
                    if x^2 > n then
                            return false;
                    end if;
                    if issqr(n-x^2) then
                            y := sqrt(n-x^2) ;
                            if A008836(x) * A008836(y) = 1 then
                                    return true;
                            end if;
                    end if;
            end do:
    end proc:
    for n from 1 to 1100 do
            if isA174050(n) then
                    printf("%d,\n",n) ;
            end if;
    end do: # R. J. Mathar, Jul 09 2012
  • Mathematica
    lambdaQ[{x_, y_}] := LiouvilleLambda[x]*LiouvilleLambda[y] == 1; Select[ Prime /@ Range[200], Or @@ lambdaQ /@ PowersRepresentations[#, 2, 2] &] (* Jean-François Alcover, Jul 30 2013 *)

A182476 Primes of the form p^2+100, where p is prime.

Original entry on oeis.org

109, 149, 269, 389, 461, 941, 1061, 1949, 2309, 2909, 3581, 3821, 10301, 10709, 11549, 11981, 16229, 18869, 19421, 22901, 24749, 26669, 30029, 32141, 44621, 52541, 57221, 72461, 76829, 94349, 96821, 109661, 128981, 134789, 167381, 201701, 214469, 253109
Offset: 1

Views

Author

Alex Ratushnyak, May 01 2012

Keywords

Crossrefs

Cf. A045637 (p^2 + 4 is prime), A079141 (p^2 + 6 is prime), A182475.

Programs

  • Mathematica
    Select[Table[p^2 + 100, {p, Prime[Range[200]]}], PrimeQ] (* T. D. Noe, May 01 2012 *)

A217717 Primes of the form x^2 + y^2 - 1, where x and y are primes.

Original entry on oeis.org

7, 17, 73, 97, 193, 241, 313, 337, 409, 457, 577, 1009, 1129, 1201, 1249, 1321, 1489, 1657, 1801, 1873, 2017, 2137, 2377, 2521, 2689, 2833, 2857, 3049, 3169, 3217, 3361, 3529, 3697, 3769, 3889, 4057, 4177, 4441, 4513, 4561, 4657, 5209, 5449, 5569, 5689, 5857
Offset: 1

Views

Author

Keywords

Comments

Unlike primes of the form x^2+y^2 (A045637) which can be redefined as x^2+4, and primes of the form x^2+y^2+1 (A182475) which can be redefined as primes of the form x^2+10, this sequence appears to have no one-variable analog. In the preceding, x and y are prime.

Examples

			457 is in the sequence because it is a prime number, and 457 = 13^2 + 17^2 - 1.
		

Crossrefs

Cf. A045637 (primes of the form p^2+4, where p is prime).
Cf. A182475 (primes of the form p^2+10, where p is prime).

Programs

  • Mathematica
    mx = 25; Union[Select[Flatten[Table[Prime[a]^2 + Prime[b]^2 - 1, {a, mx}, {b, a, mx}]], # < Prime[mx]^2 && PrimeQ[#] &]] (* T. D. Noe, Mar 29 2013 *)

A287924 Numbers k such that A287922(k) is a prime.

Original entry on oeis.org

2, 3, 4, 6, 7, 12, 15, 19, 21, 25, 27, 33, 38, 39, 44, 51, 59, 62, 63, 65, 66, 69, 74, 90, 93, 96, 101, 106, 108, 111, 112, 123, 132, 138, 143, 144, 147, 153, 162, 163, 166, 168, 181, 187, 188, 203, 219, 224, 229, 241, 243, 255, 258, 259, 269, 273, 300
Offset: 1

Views

Author

XU Pingya, Jun 02 2017

Keywords

Comments

Corresponding primes are in A045637.

Crossrefs

Programs

  • Mathematica
    Select[Table[n, {n, 300}], PrimeQ[Prime[#]^2 + 4] &]

A339692 Primes that can be expressed as p^k+2*k where p is prime and k >= 1.

Original entry on oeis.org

5, 7, 13, 19, 29, 31, 43, 53, 61, 73, 89, 103, 109, 131, 139, 151, 173, 181, 193, 199, 229, 241, 271, 283, 293, 313, 349, 421, 433, 463, 523, 571, 601, 619, 643, 661, 811, 823, 829, 859, 883, 1021, 1033, 1051, 1063, 1093, 1153, 1231, 1279, 1291, 1303, 1321, 1373, 1429, 1453, 1483, 1489, 1609
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Dec 13 2020

Keywords

Comments

Terms expressible in more than one way include
13 = 11^1 + 2*1 = 3^2 + 2*2
349 = 347^1 + 2*1 = 7^3 + 2*3
78139 = 78137^^1 + 2*1 = 5^7 + 2*7
1092733 = 1092731^1 + 2*1 = 103^3 + 2*3
22665193 = 22665191^1 + 2*1 = 283^3 + 2*3.

Examples

			a(5) = 29 is a term because 29 = 5^2 + 2*2. and 5 and 29 are primes.
		

Crossrefs

Includes A006512, A045637 and A201308.

Programs

  • Maple
    N:= 1000: # for terms <= N
    S:= {}:
    for n from 1 while 3^n + 2*n <= N do
      p:= 2:
      do
        p:= nextprime(p);
        q:=  p^n + 2*n;
        if q > N then break fi;
        if isprime(q) then S:= S union {q};
        fi
    od od:
    sort(convert(S,list));
  • Mathematica
    Block[{nn = 1610, a = {}}, Do[Do[Which[# > nn, Break[], PrimeQ[#], AppendTo[a, #]] &[(#^k) + 2 k], {k, Infinity}] &[Prime@ i], {i, 2, PrimePi@ nn}]; Union@ a] (* Michael De Vlieger, Dec 13 2020 *)
  • PARI
    isok(p) = {if (isprime(p), for(k=1, p\2, if (k==isprimepower(p-2*k), return(1));););} \\ Michel Marcus, Dec 13 2020

A129119 Numbers of the form 2*p (with p a prime number) such that p^2+4 is prime.

Original entry on oeis.org

6, 10, 14, 26, 34, 74, 94, 134, 146, 194, 206, 274, 326, 334, 386, 466, 554, 586, 614, 626, 634, 694, 746, 926, 974, 1006, 1094, 1154, 1186, 1214, 1226, 1354, 1486, 1574, 1646, 1654, 1706, 1766, 1906, 1934, 1966, 1994, 2174, 2234, 2246, 2474, 2734, 2846
Offset: 1

Views

Author

Giovanni Teofilatto, May 25 2007

Keywords

Examples

			7^2 + 4 = 53 which is a prime number. Therefore 2*7 is in the sequence.
		

Crossrefs

Programs

  • Mathematica
    2*Select[Prime@Range[250], PrimeQ[ #^2 + 4] &] (* Ray Chandler, May 27 2007 *)
    a={};For[n=1,n<300,n++,If[PrimeQ[Prime[n]^2 + 4], AppendTo[a, 2*Prime[n]]]]; a (* Stefan Steinerberger, May 27 2007 *)

Formula

a(n) = 2*A062324(n).

Extensions

Extended and edited by Ray Chandler and Stefan Steinerberger, May 27 2007

A162152 Numbers of the form x(x-1) + y(y-1) with x^2 + y^2 being a prime, x,y >= 0.

Original entry on oeis.org

0, 2, 8, 12, 22, 30, 32, 44, 50, 62, 76, 84, 90, 96, 98, 122, 132, 140, 158, 162, 174, 182, 212, 222, 240, 246, 254, 260, 274, 288, 292, 312, 326, 328, 348, 362, 372, 380, 386, 392, 404, 422, 432, 482, 490, 510, 524, 536, 552, 562, 572, 578, 582, 612, 618, 630, 638, 650
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jun 26 2009, Jul 29 2009

Keywords

Comments

Each term is the sum of two oblong numbers and therefore even.

Examples

			a(1)=0 from x=y=1, with 2 a prime.
a(2)=2 from x=1, y=2, with 5 a prime.
a(3)=8 from x=2, y=3, with 13 a prime.
a(4)=12 from x=1, y=4, with 17 a prime.
a(4)=22 from x=2, y=5, with 29 a prime.
a(.)=212 from x=2, y=15, with 229 a prime, or from x=8, y=13, with 233 a prime.
		

Crossrefs

Programs

  • Maple
    obl := proc(n) n*(n-1) ; end: lim := 800; L := {} ;
    for x from 0 to lim/2 do for y from x to lim/2 do if obl(x)+obl(y) <= lim then if isprime(x^2+y^2) then L := L union { obl(x)+obl(y) } ; fi; fi; od: od: sort(L) ; # R. J. Mathar, Sep 11 2009
  • Mathematica
    Take[#[[1]](#[[1]]-1)+#[[2]](#[[2]]-1)&/@Select[Tuples[ Range[ 0,40],2],PrimeQ[ Total[#^2]]&]//Union,60] (* Harvey P. Dale, Jun 07 2020 *)

Extensions

Duplicates of 212 and 432 removed, 500 removed by R. J. Mathar, Sep 11 2009

A177831 Values of q in A176983.

Original entry on oeis.org

5, 29, 53, 173, 293, 1373, 2213, 4493, 5333, 9413, 10613, 18773, 26573, 27893, 37253, 54293, 76733, 78977, 85853, 94253, 97973, 100493, 120413, 139133, 151337, 177257, 192737, 212557, 214373, 237173, 249017, 253013, 299213, 326057, 332933, 351653
Offset: 1

Views

Author

Zak Seidov, May 14 2010

Keywords

Comments

Includes all terms of A045637 beyond the first, since unless 3 | p either p^2 + 2 or p^2 + 4 must be divisible by 3.

Crossrefs

Formula

a(n) = nextprime(A176983(n)^2).
Previous Showing 11-20 of 21 results. Next