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.

A285888 Numbers n such that (1 + n)^n + (-n)^n is prime.

This page as a plain text file.
%I A285888 #21 Dec 23 2024 14:53:45
%S A285888 0,2,3,4,5,7,167
%N A285888 Numbers n such that (1 + n)^n + (-n)^n is prime.
%C A285888 The next term, if it exists, is > 10000. - _Hugo Pfoertner_, Jan 06 2020
%C A285888 The associated primes are: 13, 37, 881, 4651, 1273609, ...
%C A285888 From _Robert Israel_, Apr 28 2017: (Start)
%C A285888 All terms other than 0 are primes or powers of 2.
%C A285888 Heuristically, this sequence might be expected to be finite. (End)
%H A285888 J. S. Gerasimov, <a href="https://web.archive.org/web/*/http://list.seqfan.eu/oldermail/seqfan/2014-August/013480.html">x^(y + 1) - y^x</a>, SeqFan list, Aug 18 2014.
%e A285888 4 is in this sequence because (1 + 4)^4 + (-4)^4 = 881 is prime.
%p A285888 N:= 1000: # to get all terms <= N
%p A285888 cands:= select(isprime, {seq(i,i=3..N,2)}) union {0, seq(2^k, k=1..ilog2(N))}:
%p A285888 select(n -> isprime((1+n)^n + (-n)^n), cands); # _Robert Israel_, Apr 28 2017
%o A285888 (Magma) [n: n in [0..170]| IsPrime((n+1)^n + (-n)^n)];
%o A285888 (PARI) is(n)=ispseudoprime((n+1)^n+(-n)^n) \\ _Charles R Greathouse IV_, Apr 28 2017
%Y A285888 Supersequence of A098463.
%Y A285888 Cf. A243100, A285886, A285887.
%K A285888 nonn,more
%O A285888 1,2
%A A285888 _Juri-Stepan Gerasimov_, Apr 27 2017