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.

A172287 Primes p such that exactly one of 2p-3 and 3p-2 is prime.

This page as a plain text file.
%I A172287 #16 Jul 05 2015 14:49:38
%S A172287 17,31,41,47,61,83,97,101,103,107,157,163,223,233,241,257,271,277,283,
%T A172287 293,307,311,313,317,337,401,421,457,467,491,521,523,541,547,557,563,
%U A172287 577,593,601,613,617,631,641,643,647,653,661,673,677,701,743,761,773
%N A172287 Primes p such that exactly one of 2p-3 and 3p-2 is prime.
%C A172287 A010051(2*a(n)+3) + A010051(3*a(n)+2) = 1; each term is either a term of A063908 or of A088878. - _Reinhard Zumkeller_, Jul 02 2015
%C A172287 No terms end in 9.  Dickson's conjecture implies that there are infinitely many terms. - _Robert Israel_, Jul 02 2015
%H A172287 Reinhard Zumkeller, <a href="/A172287/b172287.txt">Table of n, a(n) for n = 1..10000</a>
%e A172287 a(1)=17 because 2*17-3=31 is prime and 3*17-2=49 is nonprime.
%e A172287 19 is not a term because neither 2*19-3=35 nor 3*19-2=55 is prime;
%e A172287 23 is not a term because both 2*23-3=43 and 3*23-2=67 are prime.
%p A172287 A172287:=n->`if`(isprime(n) and (isprime(2*n-3) xor isprime(3*n-2)), n, NULL): seq(A172287(n), n=1..1000); # _Wesley Ivan Hurt_, Jun 23 2015
%t A172287 Select[Prime@ Range@ 150, Xor[PrimeQ[2 # - 3], PrimeQ[3 # - 2]] &] (* _Michael De Vlieger_, Jul 01 2015 *)
%o A172287 (Haskell)
%o A172287 a172287 n = a172287_list !! (n-1)
%o A172287 a172287_list = filter
%o A172287    (\p -> a010051' (2 * p - 3) + a010051' (3 * p - 2) == 1) a000040_list
%o A172287 -- _Reinhard Zumkeller_, Jul 02 2015
%Y A172287 Cf. A000040, A010051, A063908, A088878, A259730.
%K A172287 nonn,easy
%O A172287 1,1
%A A172287 _Juri-Stepan Gerasimov_, Jan 30 2010
%E A172287 Extended by _Charles R Greathouse IV_, Mar 25 2010