\(Q=\dfrac{x+y}{2\left(x-y\right)}-\dfrac{x-y}{2\left(x+y\right)}+\dfrac{x^2+y^2}{\left(x-y\right)\left(x+y\right)}\)
\(=\dfrac{x^2+2xy+y^2-x^2+2xy-y^2+2x^2+2y^2}{2\left(x-y\right)\left(x+y\right)}\)
\(=\dfrac{2x^2+2y^2+4xy}{2\left(x-y\right)\left(x+y\right)}=\dfrac{2\left(x+y\right)^2}{2\left(x-y\right)\left(x+y\right)}=\dfrac{x+y}{x-y}\)