<s>[INST] Given that $ x + \frac 1 x = r $ what is the value of: $ x^3 + \frac 1 {x^2}$ in terms of $r$? Given that $$ x + \cfrac 1 x = r $$
what is the value of: $$ x^3 + \cfrac 1 {x^2}$$ in terms of $r$?
NOTE: it is $\cfrac 1 {x^2}$ and not $ \cfrac 1 {x^3} $
Where I reached so far:
$$ \Big(x^3 + \cfrac 1 {x^2}\Big) + \cfrac 1 x \cdot\Big(x^3 + \cfrac 1 {x^2}\Big) = r^3 - r^2 -3r - 2 $$
Any hints??
 [/INST] The answer could be found by direct calculation:
$$ x = \frac{r \pm \sqrt{r^2-4}}{2}$$
$$x^3+\frac{1}{x^2} = -\frac{(- r^2 + r + 1)(r + \sqrt{r^2 - 4} + 2)}{2} \tag{$+$}$$
$$x^3+\frac{1}{x^2} = \frac{4}{(r - \sqrt{r^2 - 4})^2 + (r - \sqrt{r^2 - 4})^{\frac{3}{8}}}\tag{$-$}$$
Edit1 Please note that the domain of $r$ is
$$r\in \{\mathbb{R}-(-2,+2)\}$$
for example, if $r=\cfrac{5}{2}$, then $x=2,\cfrac{1}{2}$ and
$$x^3+\frac{1}{x^2}=\frac{33}{4}, \frac{33}{8}$$
</s>