$x^2 + y^2 = -1$ is a weird equation because it has no solutions over $\Bbb R$. I want to count the number of solutions it has over $\Bbb Z / p$ where $p$ is prime.
If $p = 2$ then it has $p$ solutions. This is to do with the fact that squaring is a field automorphism.
If $p \equiv 1 \pmod{4}$ then there is an $i$ such that $i^2 = -1$ so $$x^2 + y^2 = -1 \implies \left({x \over i}\right)^2 + \left({y \over i}\right)^2 = 1 \implies \left({x \over i} + y \right)\left({x \over i} - y \right) = 1$$ which has $p - 1$ solutions.
If $p \equiv 3 \pmod{4}$ then the situation is more complicated. The thing I noticed is that $A = \{x \mid x^2 + y^2 = -1\}$ and $B = \{x \mid y^2 - x^2 = 1\}$ form a partition of $\Bbb Z/p$. Reason being that $x \not\in A \implies (-1 - x^2 \mid p) = -1 \implies (1 + x^2 \mid p) = 1 \implies (\exists y)\,1+x^2 = y^2 \implies x \in B$, and vice versa. Also notice that $A \cap B = \emptyset$. So we get $|A| = |\Bbb Z / p| - |B| = p - |B|$. To determine $|B|$, use the fact that for every $(x,y)$ for which $y^2 - x^2 = 1$, $(x,-y)$ also satisfies the equation, so $|B|$ is the number of solutions to $y^2 - x^2 = 1$ divided by $2$, which is $\frac{p-1}{2} \therefore \,|A| = {p + 1 \over 2}$. Now it's easy to see that the number of solutions to $x^2 + y^2 = -1$ is $2|A|$ which is $p+1$.
Any quicker method?