# Find Next Integer

• Jan 24th 2007, 10:54 AM
Ideasman
Find Next Integer
Hi;

I am given the following:

1! + 1 = 2
2! + 1 = 3
4! + 1 = 25
6! + 1 ...
10! + ...
12! + ...
??! + 1 = ...

Find ??. Find the next 5 in the sequence.

Thanks.
• Jan 24th 2007, 11:05 AM
AfterShock
Quote:

Originally Posted by Ideasman
Hi;

I am given the following:

1! + 1 = 2
2! + 1 = 3
4! + 1 = 25
6! + 1 ...
10! + ...
12! + ...
??! + 1 = ...

Find ??. Find the next 5 in the sequence.

Thanks.

Quite ironic- we were mentioning this in my number theory class.

Are you familiar with Wilson's Theorem?

16!
18!
22!
28!
30!
36!

And so forth.

The theorem states:

(p - 1)! + 1 is divisible by p, where p is prime. It can proven with minimal effort, too, should you want me to give a proof.
• Jan 24th 2007, 11:16 AM
ThePerfectHacker
I do not think it is a question about Wilson's theorem it is about just finding the next number.
• Jan 24th 2007, 11:26 AM
AfterShock
Quote:

Originally Posted by ThePerfectHacker
I do not think it is a question about Wilson's theorem it is about just finding the next number.

It's clearly related to Wilson's theorem.

Quote:

Originally Posted by ThePerfectHacker
it is about just finding the next number.

You think the "+ 1" is there arbitrarily? If they were just looking for the primes (plus 1), they would just have given 1, 2, 4, 6, 10, 12, ..., p + 1.