a) \(\frac{x-1}{x+1}-\frac{x+1}{x-1}+\frac{4}{x^2-1}\left(ĐK:x\ne\pm1\right)\)
\(=\frac{\left(x-1\right)^2-\left(x+1\right)^2+4}{\left(x-1\right)\left(x+1\right)}\)
\(\frac{x^2-2x+1-x^2-2x-1+4}{\left(x-1\right)\left(x+1\right)}\)
\(=\frac{-4x+4}{\left(x-1\right)\left(x+1\right)}=\frac{-4\left(x-1\right)}{\left(x-1\right)\left(x+1\right)}=-\frac{4}{x+1}\)
b) \(\frac{x^3y+xy^3}{x^4y}:\left(x^2+y^2\right)\left(ĐK:x,y\ne0\right)\)
\(=\frac{xy\left(x^2+y^2\right)}{x^4y}\cdot\frac{1}{x^2+y^2}\)
\(=\frac{1}{x^3}\)