TITLE: Find equation for hyperbola
QUESTION [6 upvotes]: Just taking (failing) a simple algebra class, can't figure this one out and no one can explain it to me and the book just tells me to do it.

Find an equation for the hyperbola described:
foci at $(-4,0)$ and $(4,0)$; asymptote the line $y=-x$.

So I know that since the numbers on the $x$ axis are changing it will be a horizontal hyperbola. That means $0$ is the center and $c$ is $4$.
I know the slope is $b/a$ for horizontal equations so I know that $b/a = -1$
From that I can get $b = -a$.
This is as far as I can get, my book basically does these steps in the solution manual except they get $-b/a = -1$,   $b=a$   I don't even know why. I can't work past this point without graphing and I know there is suppose to be a way just by working out the algebra but I don't see a solution. 
I might not be prepared for this test but I am prepared to fail the test.

REPLY [3 votes]: As the foci are on the $x$-axis and symmetric with respect to the $y$-axis,
the equation of the hyperbola is
$$\frac{x^{2}}{a^{2}}-\frac{y^{2}}{b^{2}}=1.$$
Such an hyperbola has two asymptotes: 
$$y=\frac{b}{a}x\qquad\text{and}\qquad y=-\frac{b}{a}x,$$ where both $a$ and $b$ are positive. The given asymptote is $y=-x$ and the
other one is $y=x$. The equation $y=-\frac{b}{a}x$ should be equivalent to $
y=-x$, which implies that $-\frac{b}{a}=-1$. Hence $b=a$. Now you use the
information on the foci to find $a$. The distance from each focus to the
origin is $c=4$. These numbers are related by the equation $$a^{2}+b^{2}=c^{2}
.$$ For $b=a$ and $c=4$, we have $a^{2}+a^{2}=16$, thus $a=2\sqrt{2}$ (the
other solution is negative), and the equation of the hyperbola is
$$\frac{x^{2}}{8}-\frac{y^{2}}{8}=1.$$