Ⅰ. When is an odd prime
Let be an odd prime, and be odd integers and be a non-zero even integer. We suppose , and do not include a same prime and holds.
...(1)
Let be an even integer. We suppose holds.
...(2)
Let be an integer.
...(3)
By the equation (1) and Fermat's little theorem,
holds. Let be in integer.
...(4)
Dividing the equation (2) by , we obtain the following equation.
Let be an integer and be a rational number and holds.
If and have a same prime as a factor, then includes the prime and it is inconsistent with the condition that and are relatively prime. Let be an integer and is one of 's prime factors. Let be an integer and holds. We suppose two equations as below.
By the equations (2),
...(5)
holds.
ⅰ. When holds for all
In this case, for all and is a multiple of . However, it becomes a contradiction since is an even contrary to the definition of .
ⅱ. When holds for some
By the congruent expression (5), holds in this case. Let and be integers and these are the numbers of prime factor in and respectively. If holds, then the number of prime factor in is by the equation (4). At this time, the number in is and equals to . It becomes inconsistent when holds. Therefore, must hold. By the equations (3) and (4),
holds. However, it becomes a contradiction since and must hold.
From the above, Fermat's Last Theorem is true in the case Ⅰ. When and are odd integers and is an even, it can be proven by changing the definitions of and mutually and by converting variables from to and to when n is an odd. If n is an even, converting odd n to even.
Ⅱ. When is an even and holds
We take account of two cases depending on the order as follows.
ⅰ. When the order includes an odd prime
Let , and be positive integers. We suppose is an odd, holds and is one of 's prime factors. Let , and be integers. We suppose the following equation holds when the order is .
However, there are no non-zero solutions to this equation since this is the equation (1) when , , and hold.
ⅱ. When the order does not include an odd prime
We consider this case by reducing it to the case as proven by Fermat. Let be an integer and holds. Let , and be integers. We suppose the following equation holds when the order is .
Though, no non-zero solutions exist to this equation since this is the equation (1) when , , and hold.
Therefore, there are no non-zero solutions to the equation (1) in the case Ⅱ.
From the above, it is proved that Fermat's Last Theorem is true. (Q.E.D.)