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.

A138479 a(n) = smallest prime p such that 2*n + p^2 is another prime, or 0 if no such prime exists.

Original entry on oeis.org

3, 3, 5, 3, 3, 5, 3, 5, 5, 3, 3, 7, 0, 3, 7, 3, 3, 5, 3, 7, 5, 3, 5, 5, 3, 3, 5, 0, 3, 7, 3, 3, 29, 0, 3, 5, 3, 5, 5, 3, 5, 5, 0, 3, 7, 3, 3, 19, 3, 3, 5, 3, 5, 7, 0, 5, 5, 0, 3, 11, 3, 5, 5, 3, 3, 5, 0, 11, 5, 3, 3, 7, 0, 3, 7, 0, 3, 5, 3, 11, 7, 3, 5, 5, 3, 3, 5, 0, 7, 7, 3, 3, 5, 3, 3, 7, 0, 11, 5, 0
Offset: 1

Views

Author

Philippe LALLOUET (philip.lallouet(AT)orange.fr), Mar 20 2008

Keywords

Comments

For numbers k such that a(k) = 0 see A138685.

Examples

			11=2+3^2 hence a(1)=3,
13=4+3^2 hence a(2)=3,
31=6+5^2 hence a(3)=5.
		

Crossrefs

Programs

  • Maple
    a:= proc(n) local p;
          if irem(n, 3)=1 and not isprime(2*n+9) then 0
        else p:=2;
             do p:= nextprime(p);
                if isprime(2*n+p^2) then return p fi
             od
          fi
        end:
    seq(a(n), n=1..100);  # Alois P. Heinz, Jun 16 2014
  • Mathematica
    a = {}; Do[ p = 0; While[ (! PrimeQ[ 2*n + Prime[ p + 1 ]2 ]) && (p < 1000), p++ ]; If[ p < 1000, AppendTo[ a, Prime[ p + 1 ] ], AppendTo[ a, 0 ] ], {n, 1, 150} ]; a (* Artur Jasinski, Mar 26 2008 *)
    a[n_]:=If[Mod[n,3]!=1,(For[m=1,!PrimeQ[2n+Prime[m]^2],m++ ]; Prime[m]),If[ !PrimeQ[2n+9],0,3]];Table[a[n],{n,100}] (* Farideh Firoozbakht, Mar 28 2008 *)

Extensions

More terms from Artur Jasinski and Farideh Firoozbakht, Mar 26 2008

A059325 Numbers n such that 6n + 5 is prime.

Original entry on oeis.org

0, 1, 2, 3, 4, 6, 7, 8, 9, 11, 13, 14, 16, 17, 18, 21, 22, 24, 27, 28, 29, 31, 32, 37, 38, 39, 41, 42, 43, 44, 46, 48, 51, 52, 57, 58, 59, 63, 64, 66, 69, 71, 73, 74, 76, 77, 79, 81, 83, 84, 86, 92, 93, 94, 97, 98, 99, 102, 106, 107, 108, 109, 112, 113, 116, 119, 123, 126
Offset: 1

Views

Author

Anton Joha, Jan 26 2001

Keywords

Examples

			a(4)=3 because 6*3 + 1 = 19 is prime.
		

Crossrefs

Complement of A059324.

Programs

Extensions

More terms from Henry Bottomley, Jan 29 2001

A153170 Numbers k such that 3*k + 2 is not prime.

Original entry on oeis.org

2, 4, 6, 8, 10, 11, 12, 14, 16, 18, 20, 21, 22, 24, 25, 26, 28, 30, 31, 32, 34, 36, 38, 39, 40, 41, 42, 44, 46, 47, 48, 50, 51, 52, 53, 54, 56, 58, 60, 61, 62, 64, 66, 67, 68, 69, 70, 71, 72, 73, 74, 76, 78, 80, 81, 82, 84, 86, 88, 90, 91, 92, 94, 95, 96, 98, 99, 100, 101, 102
Offset: 1

Views

Author

Vincenzo Librandi, Dec 20 2008

Keywords

Comments

Contains the positive even numbers (A005843) and the odd numbers of the form 2*A059324(.) + 1. - R. J. Mathar, Nov 27 2010
Numbers k such that (3*k)!/(3*k + 2) is an integer. - Peter Bala, Jan 25 2017

Examples

			Distribution of the odd terms in the following triangular array:
  *;
  *,   *;
  *,  11,   *;
  *,   *,   *,   *;
  *,   *,  25,   *,   *;
  *,  21,   *,   *,  47,   *;
  *,   *,   *,   *,   *,   *,   *;
  *,   *,  39,   *,   *,  73,   *,   *;
  *,  31,   *,   *,  69,   *,   *, 107,   *;
  *,   *,   *,   *,   *,   *,   *,   *,   *,   *;
  *,   *,  53,   *,   *,  99,   *,   *, 145,   *,   *;
  *,  41,   *,   *,  91,   *,   *, 141,   *,   *, 191,   *;
etc., where * marks the noninteger values of (4*h*k + 2*k + 2*h - 1)/3 with h >= k >= 1. - _Vincenzo Librandi_, Jan 15 2013
		

Crossrefs

Programs

  • Magma
    [n: n in [1..110] | not IsPrime(3*n + 2)]; // Vincenzo Librandi, Oct 11 2012
  • Maple
    for n from 0 to 100 do
    if irem(factorial(3*n), 3*n+2) = 0 then print(n); end if;
    end do: # Peter Bala, Jan 25 2017
  • Mathematica
    Select[Range[1, 200], !PrimeQ[3*# + 2] &] (* Vincenzo Librandi, Oct 11 2012 *)
  • PARI
    for(n=1,200,if(!isprime(3*n+2), print1(n,", "))) \\  Joerg Arndt, Nov 27 2010
    

Extensions

Edited by N. J. A. Sloane, Jun 23 2010

A094517 Primes p such that 6p+11 is not a prime.

Original entry on oeis.org

11, 19, 29, 53, 59, 61, 67, 71, 79, 89, 103, 109, 113, 137, 139, 149, 151, 163, 179, 191, 193, 199, 223, 229, 239, 241, 251, 263, 269, 277, 293, 307, 337, 347, 349, 359, 373, 379, 389, 409, 419, 421, 431, 439, 443, 449, 467, 479, 487, 499, 503, 509, 523, 547, 557, 569
Offset: 1

Views

Author

N. J. A. Sloane, following a suggestion by R. K. Guy, Jun 05 2004

Keywords

Comments

Primes of the form A059324(.)-1. - R. J. Mathar, Jan 30 2011

Crossrefs

Complement in primes of A089438.

Programs

  • Magma
    [p: p in PrimesUpTo(5000)|not IsPrime(6*p+11)]; // Vincenzo Librandi, Jan 30 2011
  • Mathematica
    Select[Prime[Range[150]],CompositeQ[6#+11]&] (* Harvey P. Dale, Aug 02 2021 *)

A275237 Smallest number k > 0 such that sigma(x) and sigma(x)+2 are both prime, where x = (6k+1)^(6n+4), or -1 if no such k exists.

Original entry on oeis.org

1, 348, 436, 6018, 5880, -1, 4612, 26921, 16166, 81111, -1, 426260, -1, 181876, 227180, -1, 12836, 287388, 2317, -1, -1, 1128403, 668927, -1, 5295, -1, -1, 490118, 2217967, 1607226, -1, 1212183, 100728, -1, -1, -1, -1, 1191713, 43475567, 165965, -1, 2915491, 361885, 4159496, 3398061, -1, 88930, -1, 10451327, -1, -1
Offset: 0

Views

Author

Chai Wah Wu, Jul 20 2016

Keywords

Comments

If x is a number such that sigma(x) and sigma(x)+2 are both prime (A274962), then x = 2 or x is of the form (6k+1)^(6r+4) where 6k+1 is prime.
For p = 6*k+1, sigma(p^34) = (46656*k^6 + 54432*k^5 + 27216*k^4 + 7560*k^3 + 1260*k^2 + 126*k + 7) * (1296*k^4 + 1080*k^3 + 360*k^2 + 60*k + 5) * c(k), thus a(5) = -1. - Altug Alkan , Jul 21 2016
Similarly a(12) = a(19) = a(23) = a(26) = a(33) = a(34) = -1. Furthermore, for all r > 0, a(5*r) = -1 since sigma((6k+1)^(30r+4)) = ((6*k+1)^(6*r) + ((6*k+1)^(6*r) -1)/(6*k))*(1296*k^4*(6*k + 1)^(24*r) + 864*k^3*(6*k + 1)^(24*r) + 216*k^3*(6*k + 1)^(18*r) + 216*k^2*(6*k + 1)^(24*r) + 108*k^2*(6*k + 1)^(18*r) + 36*k^2*(6*k + 1)^(12*r) + 24*k*(6*k + 1)^(24*r) + 18*k*(6*k + 1)^(18*r) + 12*k*(6*k + 1)^(12*r) + 6*k*(6*k + 1)^(6*r) + (6*k + 1)^(24*r) + (6*k + 1)^(18*r) + (6*k + 1)^(12*r) + (6*k + 1)^(6*r) + 1). - Chai Wah Wu, Jul 21 2016

Examples

			For n = 0, x = 7^4 is the smallest fourth power such that sigma(x) and sigma(x)+2 are both prime, thus a(0) = 1.
		

Crossrefs

Formula

a(A059324(n)) = -1. - Altug Alkan, Aug 13 2016

Extensions

a(31)-a(37) from Chai Wah Wu, Aug 01 2016
a(38)-a(50) from Chai Wah Wu, Aug 18 2016
Showing 1-5 of 5 results.