A problem regarding implicit differentiation 
Given
  $$x^2 = \frac{x-y}{x+y},$$ calculate the derivative $y'$.

So I found the derivative by applying quotient rule on the right side, and power rule on the left and separated $dy/dx$.
The answer was: $$y'(x) = -x^2 - 2 x y + \frac{y}{x} - y^2.$$
But, if I multiply $x+y$ on both sides, then calculate derivative, the answer was: $$y'(x) = -\frac{3 x^2 + 2 x y - 1}{x^2 + 1}.$$
Which answer is correct?
 A: $$\frac{d}{dx}x^2=\frac{d}{dx}\left((x-y)(x+y)^{-1}\right)$$
$$2 x=\frac{(x-y(x)) \left(y'(x)+1\right)}{(y(x)+x)^2}-\frac{1-y'(x)}{y(x)+x}$$
$$y'(x)= -x^2-y^2(x)+\left(\frac{1}{x}-2 x\right) y(x).$$
$(*)$ The other one is also correct.
A: Both results aren't really different. The explicit form for $y$ would be $$y=\frac{2x}{x^2+1}-x.$$ If you substitute this into your two seemingly different expressions and simplify, you'll see they're identical... if you don't make a mistake. To avoid that, you can use GP, say:
? y=2*x/(x^2+1)-x
%1 = (-x^3 + x)/(x^2 + 1)
? d1=-x^2-2*x*y+y/x-y^2
%2 = (-x^4 - 4*x^2 + 1)/(x^4 + 2*x^2 + 1)
? d2=-(3*x^2+2*x*y-1)/(x^2+1)
%3 = (-x^4 - 4*x^2 + 1)/(x^4 + 2*x^2 + 1)
? d1-d2
%4 = 0

Since there were questions: GP is free software, able to calculate various expressions, but not just with numbers (integers of arbitrary length, fractions, floats, imaginary numbers, p-adic numbers), but also with elements of quadratic fields, of finite fields, polynomials,... It's rather handy at times.
A: $$x^3+x^2y=x-y,$$ which gives
$$3x^2+2xy+x^2y'=1-y'$$ or
$$y'=\frac{1-3x^2-2xy}{1+x^2}.$$
