### Instruction: There are numbers $A$ and $B$ for which  \[\frac A{x-1}+\frac B{x+1}=\frac{x+2}{x^2-1}\]for every number $x\neq\pm1$.  Find $A-B$.### Response: I notice that the denominator of the right-hand side, $x^2-1$, can be factored as $(x-1)(x+1)$. So I can rewrite the equation as \[\frac A{x-1}+\frac B{x+1}=\frac{x+2}{(x-1)(x+1)}.\]
Now, to eliminate the fractions, I can multiply both sides by $(x-1)(x+1)$, as long as $x\neq\pm1$. This gives me \[A(x+1)+B(x-1)=x+2.\]
This is a linear equation in $x$, and it must hold for every $x\neq\pm1$. So the coefficients of $x$ on both sides must be equal, and the constant terms on both sides must be equal.
This means that \[A+B=1\quad\text{and}\quad A-B=2.\]
I can add these two equations and get \[2A=3,\] so \[A=\frac32.\]
Then, using $A+B=1$, I can find \[B=1-\frac32=-\frac12.\]
Therefore, \[A-B=\frac32-(-\frac12)=\frac32+\frac12=2.\]