<s>[INST] Given that $T=\frac{x-iy}{x+iy}$, where $x, y, T \in\Bbb R$, show that $\frac{1+T^2}{2T}=\frac{x^2-y^2}{x^2+y^2}$ Given that $T=\frac{x-iy}{x+iy}$, where $x, y, T \in\Bbb R$, show that $$\frac{1+T^2}{2T}=\frac{x^2-y^2}{x^2+y^2}$$
I have got rid of $i$ in the denominator, leaving $$\frac{x^2-y^2-2ixy}{x^2+y^2}$$
but now I am stuck. What are the next steps please?
 [/INST] You made an error somewhere.
Writing $T = \frac{a}{b}$, the expression you are trying to simplify is
$$\frac{1+\frac{a^2}{b^2}}{2\frac{a}{b}}$$
which after clearing out the denominators is
$$\frac{b^2+a^2}{2ab}.$$
Plugging in $a$ and $b$ and using the fact that they are complex conjugates gives
$$\frac{x^2 +2ixy - y^2 + x^2 -2ixy - y^2}{2(x^2+y^2)}$$
which simplifies to the expression you want.
</s>