Solve $x^n+y^n=2015$ Determine the natural numbers $x,y,n$ matching equality
$$x^n+y^n=2015.$$
I noticed for $n = 1$ the equation has solutions $(x, 2015-x), x$ integer.
For $n = 2$, given that $x$ and $y$ are different parities taking $x = 2k$ and $y=2m + 1$  we come to contradiction.
What must be done to $n\geq3$?
 A: Since $2015=5\cdot 13\cdot 31$, and the multiplicities of the primes congruent $3$ modulo $4$ are odd (only $p=31$ to consider here), it follows that $2015$ cannot be represented as the sum $x^2+y^2$, by Fermat's theorem. This does not only work for $2015$. Also, characterisation of two cubes is known, see here. Of course, $2015$ is still small enough to check all cases. For bigger numbers however, one would like to apply more number theory. 
Edit: In case we would like to have more positive integer solutions to $x^n+y^n=m$, then $m=4097$ is the smallest number (besides $2$) which is a sum of two squares and two positive cubes. Indeed, the equation $x^n+y^n=4097$ has integer solutions for $n=1,2,3,4,6,12$:
$$
4097=1+4096=1^2+64^2=1^3+16^3=1^4+8^4=1^6+4^6=1^{12}+2^{12}.
$$
A: Hint:  $n<12$ because $1^{12}+2^{12}>2015$
A: Piggybacking off user's answer that we need only concern ourselves with a few odd exponents, with $x\lt y$ also pretty small, let's use the fact that $x+y$ divides $x^n+y^n$ for odd $n$ and $x^p\equiv x$ mod $p$ for prime $p$.  
Note that $2014$ is not an $n$th power for any $n\gt1$, so we can assume $1\lt x\lt y$.  Note also that  $2015=5\cdot13\cdot31$. Finally, $\sqrt[3]{2015}\lt13$ means we don't have to worry about potential solutions with $x+y\ge25$, which means we need only consider solutions with $x+y=5$ or $x+y=13$.
For $n=3$, we have $x+y\equiv x^3+y^3=2015\equiv2$ mod $3$, so $x+y=5$ is the only possibility, which means $x=2,y=3$ is the only possibility, but $2^3+3^3$ is way smaller than $2015$.
For $n=5$, we have $x+y\equiv x^5+y^5=2015\equiv0$ mod $5$, so again $x+y=5$ is the only possibility, and again $2^5+3^5$ is too small.
For $n=7$, we have $x+y\equiv x^7+y^7=2015\equiv6$ mod $7$, so $x+y=13$ is the only possibility.  But $7^7$ is already way too big.  (Alternatively, note that $\sqrt[7]{2015}\approx2.965\lt3$ already rules out any solutions.)
For $n=9$, working mod $3$, we have $x+y\equiv x^9+y^9\equiv2$ mod $3$, so again $2^9+3^9$ is the only possibility, which is too large.  (Or, again, $\sqrt[9]{2015}\lt3$ rules out any solutions.)
A: Any solution with $n$ even can be used to give a solution with exponent $2$. So it suffices to study $n$ odd. Since $\log_2 2015 \approx 10.97 < 11$, we can ignore all exponents larger than $9$. This reduces it to $3, 5, 7, 9$.


*

*Exponent $9$: $2015 - 2^9 = 1503$ is not a ninth power and  $3^9$ is larger than $2015$, so no solutions.

*Exponent $7$: $2015 - 2^7 = 1887$ is not a seventh power and $3^7$ is larger than $2015$, so no solutions.

*Exponent $5$: Check directly that $x = 2, 3$ or $4$ leads to no solution, and $5^5$ is too large. No solutions.

*Exponent $3$: I'll leave it to you to check there are no solutions. You can check for $x \le 12$.
