# [seqfan] Re: A sequence connected with Wilson theorem

Vladimir Shevelev shevelev at bgu.ac.il
Fri Feb 28 14:27:36 CET 2014

```Let us prove that all terms of A238460 are of the form 4*k+1. Indeed, using Wilson's theorem, for every p>3, p==3(mod 4) we have, at least, 3 solution in [1,p-2] of x! + (p-1)!/x!==0 (mod p): x = 1, x = (p-1)/2, x = p-2.
Consider now sequence "Primes p for which x! + (p-1)!/x!==0 (mod p) has only three solutions 1<=x<=p-2."
The sequence begins 7,11,19,31,...(I submitted A238501). A  proof that all terms here are of the form 4*k+3 is based on statement that, if x is a solution of the above comparison, then p-x-1 is  also solution.
However, one can prove that in case p=4*k+1, the solutions x and p-1-x are different. This means, that in case p=4*k+1 we have an even number of solutions.

Regards,

________________________________________
From: SeqFan [seqfan-bounces at list.seqfan.eu] on behalf of Vladimir Shevelev [shevelev at exchange.bgu.ac.il]
Sent: 27 February 2014 13:44
To: seqfan at list.seqfan.eu
Subject: [seqfan] A sequence connected with Wilson theorem

I have just submitted a sequence:"Primes p for which comparison x! + (p-1)!/x!==0 (mod p) has only two solutions 1<=x<=p-2 following from Wilson theorem: x = 1 and x = p-2" (A238460).
The sequence begins 5,13,37,41,101,113,157,...
Whether is another way to characterize these primes?

Regards,