Prove that there exist infinitely pairs $(m,n)$ such that $m+n$ divides $(m!)^n+(n!)^m+1$
Problem
Source: izho2018
Tags: number theory
14.02.2018 08:02
$(m,n) = (p-1, (p-1)!-p+2)$ where $p\ge 5$ be a prime works. Will post proof later.
14.02.2018 11:38
qweDota wrote: Prove that there exist infinitely pairs $(m,n)$ such that $m+n$ divides $(m!)^n+(n!)^m+1$ https://artofproblemsolving.com/community/c6h1573800p9677835
13.01.2019 22:57
Different construction Take m prime n = (largest prime divisor of $(m-1)!m!^{m-1}+-m^{m-1 } + (m-1)!$ ) - m works
27.12.2019 08:07
MarkBcc168 wrote: $(m,n) = (p-1, (p-1)!-p+2)$ where $p\ge 5$ be a prime works. Will post proof later. We can right (m,n)=(p-1,(p-1)!+1-(p-1)). So putting in the problem we get ((p-1)!)^((p-1)!-(p-1)!-(p-1)+1)+((p-1)!-(p-1)+1)^(p-1)+1/((p-1)!+1)=>((p-1)!-(p-1)+1)^(p-1)/((p-1)!+1)=>(((p-1)!+1)-(p-1))^(p-1)/((p-1)!+1)=>(p-1)^(p-1)/((p-1)!+1) by Wilson's theorem (p-1)!+1 is divisible by p or i.e it has p as its divisor, but the numerator doesn 't have such property.
07.01.2022 01:02
Take $n\geq 2$ and $n=p-m$ where $p$ is (an odd) prime - then we want $p$ to divide $((p-n)!)^n + (n!)^{p-n} + 1$. As $p>n$, we have $(p,(n!)^n) = 1$ and so equivalently we want $p$ to divide $(n!(p-n)!)^n + (n!)^p + (n!)^n$. As $(n!)^p \equiv n! \pmod p$ by Fermat's Little Theorem and $n!(p-n)! \equiv 1\cdot 2\cdots n \cdot (-1)^{p-n} \cdot n \cdot (n+1) \cdots (p-1) \equiv (-1)^{p-n}n(p-1)! \equiv (-1)^{n}n$ by Wilson's Theorem, we reduce to $p$ dividing $(-1)^{n^2}n^n + n! + (n!)^n$. So it now suffices to show for $n\geq 2$ that the integer $N = (-1)^{n^2}n^n + n! + (n!)^n = n^n((n-1)!^n + (-1)^{n^2}) + n!$ has a prime divisor greater than $n$. If $q\leq n$ is a prime divisor of $N$ then $q$ must divide $n^n$ and hence $n$. The power of $q$ in $N$ is less than $n$, since $n^n((n-1)!^n + (-1)^{n^2})$ is divisible by $q^n$ (as $q$ divides $n$) while the power of $q$ in $n!$ is at most $\sum_{i=1}^{\infty} \left\lfloor \frac{n}{q^i} \right\rfloor < n \sum_{i=1}^{\infty} \frac{1}{2^i} = n$. As the product of all prime factors of $n$ is less than $n$ we conclude that if all prime factors of $N$ are at most $n$, then $N \leq n^n$ - but this is clearly a contradiction, which completes the proof.
17.12.2023 23:11
Let $n=p-m$ where $p$ is a prime dividing $(m-1)!+(-m)^m+(m!)^m$; it's easy to see that $p>m$.