Preprint
Article

This version is not peer-reviewed.

A Note on Fermat's Last Theorem

Submitted:

21 January 2026

Posted:

23 January 2026

Read the latest preprint version here

Abstract
In 1637, Pierre de Fermat asserted that the equation an + bn = cn has no positive integer solutions for any exponent n>2, famously claiming to possess a proof too large for the margin. Although Andrew Wiles established the theorem in 1994 using deep methods from algebraic geometry and modular forms, the possibility of a more elementary argument has remained a topic of enduring interest. In this work we present a classical proof of Fermat's Last Theorem for all exponents n ≥ 3. The argument reduces the general case to an odd prime exponent and then applies a structural result—Barlow's Relations—together with p-adic valuation techniques. These tools force any hypothetical solution to satisfy rigid algebraic and prime-divisor constraints that are mutually incompatible. The contradiction holds uniformly in all cases, thereby eliminating every possible solution. The proof relies solely on elementary number theory, factorization identities, and valuation arguments, offering a conceptually simple route to Fermat's Last Theorem that remains close to the arithmetic framework available in Fermat's time.
Keywords: 
;  ;  ;  ;  ;  

1. Introduction

Fermat’s Last Theorem, first stated by Pierre de Fermat in the 17 th century, asserts that the Diophantine equation
a n + b n = c n
has no solutions in positive integers whenever n > 2 . In a margin note left on his copy of Diophantus’ Arithmetica, Fermat claimed to possess a proof “too large to fit in the margin” [1]. Over the centuries, mathematicians such as Euler [2], Sophie Germain [3], and Kummer [4] resolved important special cases, yet a complete proof remained elusive.
The modern breakthrough came in 1994, when Andrew Wiles established the full theorem using deep results from the theory of elliptic curves and modular forms [5]. His work, later strengthened by Ribet and others [6], revolutionized modern number theory and relied on sophisticated machinery far removed from the classical arithmetic methods available in Fermat’s time.
Despite this achievement, the search for an elementary proof—one relying only on classical number-theoretic tools—has persisted. Such a proof would illuminate the inherent arithmetic structure of the Fermat equation and provide insight into why the equation admits no nontrivial solutions.
In this article we present an elementary proof of Fermat’s Last Theorem for all exponents n 3 . The argument reduces the general case to an odd prime exponent and then applies a structural lemma—Barlow’s Relations—which describes the precise algebraic form that any hypothetical solution must satisfy. When combined with p-adic valuation techniques, these relations impose divisibility and size constraints that are mutually incompatible. The resulting contradiction eliminates all possible solutions, thereby establishing the theorem without recourse to modern analytic or geometric methods.

2. Background and Ancillary Results

As usual, we write d n to mean that the integer d divides the integer n, and d n to mean that n is not divisible by d. We denote by gcd ( a , b ) the greatest common divisor of a and b, and by a b ( mod n ) the congruence of a and b modulo n (that is, n ( a b ) ).
Definition 1 
(p-adic valuation). Let p be a prime and n Z { 0 } . Thep-adic valuation, denoted v p ( n ) , is the highest integer e 0 such that p e divides n. By convention, v p ( 0 ) = + .
Lemma 1 
(Lifting The Exponent Lemma (LTE) for odd primes [7]). Let p be an odd prime, a , b Z , and m 1 . Write v p ( · ) for the p-adic valuation.
1. 
Difference, coprime-to-p case.  If p ( a b ) and p a , p b , then
v p ( a m b m ) = v p ( a b ) + v p ( m ) .
2. 
Sum, coprime-to-p case (odd m).  If p ( a + b ) , p a , p b , and m is odd, then
v p ( a m + b m ) = v p ( a + b ) + v p ( m ) .
Lemma 2 
(Barlow’s Relations). Let p be an odd prime. Suppose there exist pairwise coprime positive integers a , b , c satisfying
a p + b p = c p .
Then the integers a , b , c must satisfy the following structural conditions:
  • Case 1 ( p c ):  There exist positive integers u , v , w such that
    c a = u p , c b = v p , a + b = w p .
  • Case 2 ( p c ):  There exist positive integers u , v , w and an integer k 1 such that
    c a = u p , c b = v p , a + b = p k p 1 w p ,
    with gcd ( w , p ) = 1 .
Furthermore, if for every prime q we have
q ( a + b ) q c , q ( c a ) q b , q ( c b ) q a ,
and with the structural relations
c a = u p , c b = v p , a + b = w p if p c , p k p 1 w p if p c ,
we prove the inequality
1 + 2 c 3 p < u v w .
Proof. 
We use your detailed structural analysis and split into the two cases according to whether p divides c or not.
1. 
Factorization of  a p + b p
Write
a p + b p = ( a + b ) Q ( a , b ) ,
where
Q ( a , b ) = k = 0 p 1 a p 1 k ( b ) k .
Modulo a + b , we have b a , hence
Q ( a , b ) k = 0 p 1 a p 1 = p a p 1 ( mod a + b ) .
Let
d = gcd ( a + b , Q ( a , b ) ) .
Then d p a p 1 . Since gcd ( a , b ) = 1 , we have gcd ( a + b , a ) = 1 , hence gcd ( a + b , a p 1 ) = 1 . Thus
d p .
Now we split into the two cases.
Case 1: 
p c
From a p + b p = c p and p c , we have p ( a p + b p ) . If p ( a + b ) , then from the congruence above we get p Q ( a , b ) , hence
p 2 ( a + b ) Q ( a , b ) = c p ,
so p c , contradiction. Therefore
p ( a + b ) , gcd ( a + b , Q ( a , b ) ) = 1 .
Since
( a + b ) Q ( a , b ) = c p
is a perfect p-th power and the two factors are coprime, the valuation argument applies:
For any prime q,
v q ( a + b ) + v q ( Q ( a , b ) ) = v q ( c p ) = p v q ( c ) .
Because gcd ( a + b , Q ) = 1 , at most one of v q ( a + b ) , v q ( Q ) is nonzero. Thus each nonzero valuation is a multiple of p. Hence there exist integers w , z 1 1 such that
a + b = w p , Q ( a , b ) = z 1 p ,
and then
c p = ( w z 1 ) p , c = w z 1 .
So in Case 1 we already have
a + b = w p .
We now show that c a and c b are also perfect p-th powers.
  • Factorizations of c p a p and c p b p
Write
c p a p = ( c a ) S ( c , a ) ,
where
S ( c , a ) = c p 1 + c p 2 a + + a p 1 .
Modulo c a , we have c a , hence
S ( c , a ) p a p 1 ( mod c a ) .
Let
d 1 = gcd ( c a , S ( c , a ) ) .
Then d 1 p a p 1 . Since gcd ( a , c ) = 1 , we have gcd ( c a , a ) = 1 , hence gcd ( c a , a p 1 ) = 1 . Thus
d 1 p .
From c p a p = b p and gcd ( a , b ) = gcd ( b , c ) = 1 , we have p b (otherwise p a p + b p = c p would force p a , b , c , contradicting coprimality). Hence p ( c p a p ) . If p ( c a ) , then by LTE (difference case),
v p ( c p a p ) = v p ( c a ) + v p ( p ) 2 ,
so p 2 b p , hence p b , contradiction. Thus
p ( c a ) , d 1 = 1 .
Since
( c a ) S ( c , a ) = b p
is a perfect p-th power and the factors are coprime, the same valuation argument yields
c a = u p , S ( c , a ) = z 2 p , b = u z 2 .
A parallel argument applied to
c p b p = ( c b ) T ( c , b ) = a p
gives
c b = v p , a = v z 3 .
Thus in Case 1 we have shown:
c a = u p , c b = v p , a + b = w p ,
as required.
Case 2: 
Case 2: p c
Now suppose p c . Since gcd ( a , c ) = gcd ( b , c ) = 1 , we must have p a and p b . From
a p + b p = c p
and p c , we have p a p + b p . Applying LTE (sum case) with exponent p gives
v p ( a p + b p ) = v p ( a + b ) + v p ( p ) = v p ( a + b ) + 1 .
But also
v p ( a p + b p ) = v p ( c p ) = p v p ( c ) .
Let v p ( c ) = k 1 . Then
p k = v p ( a + b ) + 1 v p ( a + b ) = p k 1 .
Write
a + b = p p k 1 M ,
with p M . From
( a + b ) Q ( a , b ) = c p = p p k C 0 p
for some integer C 0 with p C 0 , we get
p p k 1 M · Q ( a , b ) = p p k C 0 p M Q ( a , b ) = p C 0 p .
Since p M , we must have v p ( Q ( a , b ) ) = 1 , and then
Q ( a , b ) = p N , M N = C 0 p ,
with p N . Because gcd ( M , N ) = 1 and M N is a perfect p-th power, the valuation argument shows that both M and N are perfect p-th powers. Thus there exist integers w , z 1 1 such that
M = w p , N = z 1 p ,
with gcd ( w , p ) = 1 . Therefore
a + b = p p k 1 w p ,
as claimed in Case 2.
The analysis of c a and c b proceeds exactly as in Case 1. The previous computations did not use the assumption p c ; they only used:
  • gcd ( a , c ) = 1 to get gcd ( c a , a ) = 1 ,
  • and p b to rule out p ( c a ) via LTE.
In Case 2 we still have gcd ( a , c ) = 1 and p b (since p c and gcd ( b , c ) = 1 ), so the same argument applies and yields
c a = u p , c b = v p
for some positive integers u , v .
Thus in Case 2 we have shown:
c a = u p , c b = v p , a + b = p k p 1 w p , gcd ( w , p ) = 1 ,
with k = v p ( c ) 1 .
  • A Key Inequality
Recall that from the structural relations we have w c , u b , v a ; write c = w c ˜ with c ˜ N . Pairwise coprimality of ( a , b , c ) implies that u , v , w are pairwise coprime. Moreover, w 2 because a + b = w p (or a + b = p k p 1 w p ) and a , b 1 .
From the three structural relations we obtain the linear identity
2 c = u p + v p + w p .
We first establish the auxiliary inequality
u v w u + v + w 2 .
If u = v = 1 , then w 2 and u v w = w = 1 + 1 + w 2 = u + v + w 2 , so (2) holds with equality. But the case u = v = 1 is impossible under our hypotheses: it would imply a = c 1 and b = c 1 , hence a = b , contradicting gcd ( a , b ) = 1 . Thus in any admissible triple we have either u 2 or v 2 (or both). If both u 2 and v 2 , then u v w 4 w and u + v + w 2 2 w + w 2 = 3 w 2 ; since 4 w 3 w 2 for w 2 , inequality (2) holds. If one of u , v equals 1 and the other is at least 2, say u = 1 and v 2 , then u v w = v w . From the identity 2 v z 3 = w p + v p 1 (obtained during the proof of the structural relations) we deduce w p v p + 1 , hence w > v and consequently w v + 1 . Therefore
u v w = v w v ( v + 1 ) > v + 1 + v 2 = v + w 1 = u + v + w 2 ,
so (2) holds strictly. Thus in all admissible cases we have u v w u + v + w 2 , with equality only when u = v = 1 , which is excluded.
Next we use the elementary inequality x p p x ( p 1 ) for integers x 1 , which follows from Bernoulli’s inequality (or by induction). Applying it to u , v , w gives
u p + v p + w p p ( u + v + w ) 3 ( p 1 ) .
Combining (1), (2) and (3) we obtain
2 c = u p + v p + w p p ( u + v + w ) 3 ( p 1 ) p ( u v w + 2 ) 3 ( p 1 ) = p u v w + 2 p 3 p + 3 = p u v w p + 3 .
Hence
p u v w 2 c + p 3 u v w 2 c p + 1 3 p .
Since p 3 , we have 1 3 p 0 , and (4) can be rewritten as
u v w 1 + 2 c 3 p .
The equality case in (4) would require equality in both (2) and (3). Equality in (2) forces u = v = 1 , which is impossible as noted. Therefore the inequality is strict:
u v w > 1 + 2 c 3 p .
This completes the proof of the key inequality. □

3. Main Result

This is the main theorem.
Theorem 1 
(Fermat’s Last Theorem).  There exist no positive integers a, b, c, and n satisfying
a n + b n = c n
when n 3 is an integer.
Proof. 
Assume, for contradiction, that there exist positive integers a , b , c , n with n 3 such that
a n + b n = c n .
Step 1: 
Even exponents
Suppose first that n is even. If n is even but not divisible by 4, write n = 2 m with m odd. Then
( a 2 ) m + ( b 2 ) m = ( c 2 ) m .
Any prime divisor p m must be odd.
If instead m is even, say m = 2 k , then n = 4 k is divisible by 4. Fermat’s classical result for exponent 4 shows that
( a k ) 4 + ( b k ) 4 = ( c k ) 4
has no solutions in positive integers. Hence no solution exists for any exponent divisible by 4. Thus, after treating the case n = 4 , it suffices to consider exponents having an odd prime divisor.
Step 2: 
Reduction to an odd prime exponent
Let p be a prime divisor of n. By Step 1, we may assume p 2 , so p is an odd prime. Write n = p k with k 1 . Then
a n + b n = c n ( a k ) p + ( b k ) p = ( c k ) p .
Set
A = a k , B = b k , C = c k .
Then
A p + B p = C p .
Dividing A , B , C by their greatest common divisor, we may assume that A , B , C are pairwise coprime. Thus we have reduced to the situation
A p + B p = C p , A , B , C N pairwise coprime .
Step 3: 
Prime divisors of A + B , C A , and C B
Let q be any prime divisor of A + B , so q A + B . By coprimality of A and B, we have q B . Applying Lemma 1 (sum case) to ( x , y , m ) = ( A , B , p ) , we get
v q A p + B p = v q ( A + B ) + v q ( p ) .
Since A p + B p = C p , the left-hand side is v q ( C p ) = p v q ( C ) . Thus
p v q ( C ) = v q ( A + B ) + v q ( p ) .
If q p , then v q ( p ) = 0 , and hence
p v q ( C ) = v q ( A + B ) 1 , so v q ( C ) 1 ,
i.e. q C . If q = p , then p ( A + B ) , and
p v p ( C ) = v p ( A + B ) + 1 .
In any case, every odd prime divisor q of A + B divides C:
q odd prime , q ( A + B ) q C .
Similarly, let q be any odd prime divisor of C A , so q ( C A ) . Since A and C are coprime, q A and q C . From
C p A p = ( C A ) ( C p 1 + C p 2 A + + A p 1 ) = B p ,
and applying Lemma 1 (difference case) to ( a , b , m ) = ( C , A , p ) , we find
v q ( C p A p ) = v q ( C A ) + v q ( p ) = v q ( B p ) = p v q ( B ) ,
so v q ( B ) 1 , i.e. q B . Thus
q odd prime , q ( C A ) q B .
Exchanging the roles of A and B, the same argument applied to
C p B p = A p
gives
q odd prime , q ( C B ) q A .
Because the original equation preserves parity, these implications extend to the prime 2 as well (the parity of the three expressions is compatible). In particular, for all primes q we have
  • if q ( A + B ) then q C ;
  • if q ( C B ) then q A ;
  • if q ( C A ) then q B .
Step 4: 
Application of Barlow’s Relations and contradiction
We now apply Lemma 2 (Barlow’s Relations) to A , B , C with exponent p. The hypotheses of that lemma are satisfied.
Hence there exist positive integers u , v , w such that
C A = u p , C B = v p , A + B = α · w p , and α { 1 , p k p 1 } .
Summing the three linear relations gives
( C A ) + ( C B ) + ( A + B ) = u p + v p + α · w p 2 C = u p + v p + α · w p .
Since A , B , C > 0 , we have u , v , w 1 . Applying the Arithmetic Mean–Geometric Mean (AM–GM) inequality to the nonnegative reals u p , v p , α · w p :
u p + v p + α · w p 3 u p v p α w p 3 = ( u v α 1 / p w ) p / 3 .
Thus
u p + v p + α · w p 3 ( u v α 1 / p w ) p / 3 3 ( u v w ) p / 3 ,
since α 1 / p 1 whenever α { 1 , p k p 1 } . Combining this with (1):
2 C 3 ( u v w ) p / 3 2 C 3 ( u v w ) p / 3 C C 3 ( u v w ) p / 3 1 + ( C 1 ) C 3 ( u v w ) p / 3
When the exponent is r 1 , Bernoulli’s inequality takes its classical form. For any real number x 1 and any real exponent
r 1 ,
we have
( 1 + x ) r 1 + r x .
By Bernoulli’s inequality, we arrive at
1 + ( C 1 ) C 3 1 + 3 ( C 1 ) p C p p / 3 = 1 + 2 C 3 p p / 3 ,
since ( C 1 ) C 3 1 and p / 3 1 . Hence, it is enough to show that
1 + 2 C 3 p p / 3 ( u v w ) p / 3 1 + 2 C 3 p ( u v w )
By Lemma 2, we can further deduce that
1 + 2 C 3 p < ( u v w )
and therefore
( u v w ) > ( u v w ) ,
which is impossible. This contradiction shows that no such A , B , C (and hence no such a , b , c , n with an odd prime divisor p) can exist under the stated conditions.
Together with the classical case n = 4 and the analysis of even exponents, this establishes the theorem. □

4. Conclusions

We have given an elementary proof of Fermat’s Last Theorem for all integer exponents n 3 . After reducing to the case of an odd prime exponent, we applied Barlow’s Relations to any hypothetical solution. These relations force the quantities A + B , C A , and C B to be perfect p-th powers (up to an explicit power of p in the case p C ), and the prime-divisor implications derived from the original equation impose strict divisibility constraints among these quantities.
The resulting system of relations is incompatible: in both cases p C and p C , the structural conditions lead to inequalities that cannot be simultaneously satisfied. Lemma 2 therefore rules out the existence of any triple ( A , B , C ) satisfying A p + B p = C p under the required coprimality and prime-divisor conditions. Since every exponent n 3 reduces to such a prime exponent, no solution to a n + b n = c n can exist.
This proof relies solely on classical number-theoretic tools—factorization identities, p-adic valuations, and elementary divisibility arguments. It demonstrates that the Fermat equation contains within its own arithmetic structure the seeds of its impossibility, independent of the modern machinery used in Wiles’s proof. We hope that this approach contributes to a deeper understanding of the inherent rigidity of exponential Diophantine equations and encourages further exploration of classical methods in number theory.

Acknowledgments

The author would like to thank Iris, Marilin, Sonia, Yoselin, and Arelis for their support.

References

  1. Fermat, P.d. Oeuvres de Pierre de Fermat; Vol. 1, Gauthier-Villars: Paris, France, 1891.
  2. Euler, L. Elements of Algebra; Springer Science & Business Media: New York, United States, 2012. [CrossRef]
  3. Germain, S. Oeuvres philosophiques de Sophie Germain; Collection XIX: Paris, France, 2016.
  4. Kummer, E.E. Zur Theorie der complexen Zahlen 1847. [CrossRef]
  5. Wiles, A. Modular elliptic curves and Fermat’s Last Theorem. Annals of mathematics 1995, 141, 443–551. [CrossRef]
  6. Ribet, K.A. Galois representations and modular forms. Bulletin of the American Mathematical Society 1995, 32, 375–402. [CrossRef]
  7. Manea, M. Some an ± bn Problems in Number Theory. Mathematics Magazine 2006, 79, 140–145. [CrossRef]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.
Prerpints.org logo

Preprints.org is a free preprint server supported by MDPI in Basel, Switzerland.

Subscribe

Disclaimer

Terms of Use

Privacy Policy

Privacy Settings

© 2026 MDPI (Basel, Switzerland) unless otherwise stated