This is a question I am attempting. We are asked to use Fermat's Little Theorem to show that $x^2 = 7 + 13y^2$ has no integer solutions.
My attempt: I chose to work in modulo 13. Using Fermat's Little Theorem, I get $x^{12}=1(mod13)$ and from the question I got $x^2=7(mod13)$ and $7=-6(mod13)$. I think I need to get somewhere such that I get $x^2=a(mod13)$ for some $a$ and then notice how this has no solutions but I'm neither sure how to do this nor whether this would this imply there are no integer solutions for both $x$ and $y$?
I'm clearly struggling with this proof and would appreciate any directions.
Thanks
Your approach is good. As you have noted, working modulo $13$ shows that if a solution exists then $$x^2\equiv7\pmod{13}.$$ This implies that $7^6\equiv x^{12}\equiv1\pmod{13}$ by Fermat's Little Theorem. Now it suffices to check that $$7^6\not\equiv1\pmod{13},$$ to reach a contradiction. This allows you to conclude that no solution exists.