7. Let $a$ be a non-zero real number, in the Cartesian coordinate system $x O y$, the focal distance of the quadratic curve $x^{2}+a y^{2}+a^{2}=0$ is 4, then the value of $a$ is $\qquad$
Answer: $\frac{1-\sqrt{17}}{2}$.
Solution: The equation of the quadratic curve can be written as $-\frac{x^{2}}{a^{2}}-\frac{y^{2}}{a}=1$. Clearly, $-a>0$ must hold, so the quadratic curve is a hyperbola, and its standard equation is $\frac{y^{2}}{(\sqrt{-a})^{2}}-\frac{x^{2}}{(-a)^{2}}=1$. Then $c^{2}=(\sqrt{-a})^{2}+(-a)^{2}=a^{2}-a$, noting that the focal distance $2c=4$, we know $a^{2}-a=4$, and since $a<0$, we have $a=\frac{1-\sqrt{17}}{2}$.