# Differentiation in integer solutions

What would you suggest as examples to demonstrate as applications of differentiation in finding integer solutions of an equation for advanced level students?
Here you have one example which I have come across so far relevant to the mentioned issue.
To prove that there is only one positive integer pair $$( n,m )$$ satisfying $$n^m = m^n$$ we can use the knowledge of stationary points of the graph $$y = (ln x)/x$$ . Since the only stationary point is at $$x = e (>2)$$ and it is a maximum we can say that one value of the pair $$(n,m)$$ is $$2$$. Hence we can find the other value of the pair.
Edit ; $$n , m$$ are distinct values
Here is the generalized version which I could able to construct,
How can you prove that there is only one triplet $$(n,m,p)$$ of positive integers satisfying the equation $$n^{m^p} = m^{n^p}$$ given that $$m ≠ n$$. I would like to know different types of examples.

• What about $n=m=1$? Apr 23 at 3:28
• Or, more interestingly, $n=2, m=4$? Apr 23 at 3:37
• @MahdiMajidi-Zolbanin thanks for pointing, I had distinct values in my mind, I will edit. Apr 23 at 3:40
• Well, the general idea you seem to try to utilize here is that if it is possible to rewrite some equation for positive integers as $F(m)=F(n)$ (with $F(t)=\frac{\log t}{t}$ in your particular example) and $F$ is eventually monotone, then the starting point of the monotonicity interval is an upper bound for $\min(m,n)$. That is, indeed, often useful, and one can play with it more, but I'm not sure how to design something radically different from this scheme that would help solving an equation for integers by invoking one variable calculus. Well, perhaps I'm just missing something :-) Apr 23 at 4:20
• Just a nitpick, but there are of course two pairs of positive integers that satisfy your requirements, namely $(2, 4)$ and $(4,2)$. Apr 23 at 8:00

I think the scope of your question is too narrow. If you ask more broadly about the use of calculus in number theory (not just differentiation for solving Diophantine equations) then books on analytic number theory will provide lots of examples. For instance, there is an easy upper bound $$\log(n!) < n\log n$$ for $$n \geq 2$$, and with calculus we can derive a related lower bound $$\log(n!) > n\log n - n$$: see Theorem 2.1 here.

In a different direction, if we want to solve a Diophantine equations in polynomials rather than in integers, then we can use differentiation to prove things that are far more difficult in the setting of integers. Consider the polynomial analogue of Fermat's Last Theorem: for $$n \geq 3$$, the only polynomial solutions to the equation $$f(x)^n + g(x)^n = h(x)^n$$ for $$f(x), g(x)$$, and $$h(x)$$ in $$\mathbf R[x]$$ or $$\mathbf C[x]$$ are constant solutions. This can be proved by differentiating both sides of the Fermat equation. See the first two pages of a paper by Granville and Tucker here.

• Thank you very much for your suggestion, I raised the issue in that way according to what we have here in my country for advanced level mathematics.. May 5 at 5:10

Here is a similar but slightly different example:

Show that there are no distinct integers $$m$$ and $$n$$ satisfying $$e^n-n=e^m-m$$.

Solution: Suppose there are such integral solutions $$m. Then applying the Mean Value Theorem to the function $$e^x$$ on the interval $$[m,n]$$, we see that there exists a number $$c$$ between $$m$$ and $$n$$ such that $$e^c=1$$. But then we must have $$c=0$$. This shows that $$m<0. Now, from $$e^n-n=e^m-m$$ it follows $$e^n-e^m=n-m$$. Multiplying both sides by $$e^{-m}$$ we obtain: $$e^{n-m}-1=(n-m)e^{-m}\ \ \mathrm{or}\ \ e^{n-m}-(n-m)e^{-m}-1=0.$$ In other words, $$e$$ satisfies the algebraic equation $$x^{n-m}-(n-m)x^{-m}-1=0$$, which is a contradiction, as $$e$$ is not algebraic. Note that since $$m<0$$, the exponent of $$x$$ in $$x^{-m}$$ is positive.

More generally: The equation $$p^n-n=p^m-m$$ does not have any integral solutions in $$p,m,n$$ satisfying $$p>2$$ and $$m\neq n$$. (For $$p=2$$ there is a solution $$m=0, n=1$$.)

The original equation $$e^n-n=e^m-m$$ could be solved without using any calculus, as pointed out by fedja in a comment, only using the fact that $$e$$ is not algebraic. To show that the equation $$p^n-n=p^m-m$$ does not have any integral solutions in $$p,m,n$$ satisfying $$p>2$$ and $$m\neq n$$, suppose there are such integral solutions $$p>2$$ and $$m. As $$p>2$$, it is easy to see that $$m\neq0$$. Then applying the Mean Value Theorem to the function $$p^x$$ on the interval $$[m,n]$$, we see that there exists a number $$c$$ between $$m$$ and $$n$$ such that $$p^c=1$$. But then we must have $$c=0$$. This shows that $$m<0. Now, from $$p^n-n=p^m-m$$ it follows $$p^n-p^m=n-m$$. Multiplying both sides by $$p^{-m}$$ we obtain: $$p^{n-m}-1=(n-m)p^{-m}\ \ \mathrm{or}\ \ p^{n-m}-(n-m)p^{-m}=1.$$ This means $$p^{n-m}$$ and $$p^{-m}$$ are coprime, which is absurd, as $$n-m>0$$ and $$-m>0$$.

• "In other words, $e$ satisfies the algebraic equation..." Uh-oh. Isn't the original equation algebraic with respect to $e$? Apr 24 at 2:50
• @fedja Only if we knew $m$ and $n$ were both positive. Apr 24 at 3:04
• Why???? $\phantom{uuuuuuu}$ Apr 24 at 12:42
• If $x$ has a negative exponent, then you do not have a polynomial. Of course, you can multiply an appropriate power of $x$ on both sides of the equation to make all exponents of $x$ non-negative, and then consider three cases ($m,n>0$, $m,n<0$, $m<0<n$) and avoid using the Mean Value Theorem, but that can't be done for the equation $3^n-n=3^m-m$ or more generally $a^n-n=a^m-m$, where $a$ is algebraic. Apr 24 at 14:24
• @MahdiMajidi-Zolbanin as fedja already pointed out why can't you apply same argument in the very beginning and say there can not exist not only integers but also any pair of rational numbers for( n,m) because e is irrational. But I have issue here regarding the powers of e , can we say any rational power of e is also irrational? Apr 25 at 10:46