<s>[INST] Given $f(x+1/x) = x^2 +1/x^2$, find $f(x)$ Given $f(x+1/x) = x^2 +1/x^2$, find $f(x)$. Please show me the way you find it.
The answer in my textbook is $f(x)=\frac{1+x^2+x^4}{x\cdot \sqrt{1-x^2}}$
 [/INST] Note that $(x+\frac1x)^2=x^2+2+\frac1{x^2}$.
Hence it looks like $f(x)=x^2-2$ is a good candidate.
Of course, $\left|x+\frac1x\right|\ge2$ implies that we cannot say anything about $f(x)$ if $|x|<2$.
But for $|x|\ge 2$, we can find a real number $t$ such that $t^2-xt+1=0$ (and hence $t+\frac1t=x$), namely $t=\frac{x\pm \sqrt{ x^2-4}}2$, and then see that indeed $f(x)=f(t+\frac1t)=t^2+\frac1{t^2}=x^2-2$. 
</s>