I came across this in a discrete mathematics book, and i wonder if my solution is correct.
From looking at $ y = x + x^{-1} $
I see only 2 possibilities, x ={1;-1;}
Was this just so easy or am I missing something?
I came across this in a discrete mathematics book, and i wonder if my solution is correct.
From looking at $ y = x + x^{-1} $
I see only 2 possibilities, x ={1;-1;}
Was this just so easy or am I missing something?
On
Guide:
Let $$x+\frac{1}{x}=k$$
$$x^2+1=kx$$
This is a quadratic equation. For which values of $k$ does this has a real solution?
On
If you are allowing $x\in \mathbb R$, you get a lot more solutions, an infinite number in fact. Saying it is a whole number is saying that there exists an $m$, whole number, such that $$x+x^{-1}=m$$ Following this, we have $$m=x+\frac 1 x=\frac {x^2 +1} x$$
so $$x^2+1=mx$$ or $$x^2-mx+1=0$$ For this to have solutions, we can just turn to the quadratic formula
$$x=\frac {m \pm \sqrt {m^2 -4}} {2} $$ Thus, we get solutions whenever $$m^2\ge 4$$ restricting to whole numbers, this gives us when $$m\ge 2$$
For example, choosing $m=3$ and the $+$ solution gets us to
$$x=\frac {3+\sqrt 5} 2$$
so $$x+x^{-1}=\frac {3+\sqrt 5} 2+\frac 2 {3 +\sqrt 5}=\frac {9+6\sqrt 5+5+4}{6+2\sqrt 5}=\frac {18+6\sqrt 5}{6+2\sqrt 5}=3$$
This will work for the - as well, not to mention any whole number 2 or higher.
For any integer $n$ we want $n=x+\frac 1x\iff x^2-nx+1=0$
We need $\Delta=n^2-4\ge 0$ for the above equation to have solutions, so $|n|\ge 2$.
And the solutions are $x=\dfrac{n\pm\sqrt{n^2-4}}2$ (note that $x^{-1}=\dfrac{n\mp\sqrt{n^2-4}}2$ in that case).
For $n=2$ you get the $(1,1)$ solution
For $n=-2$ you get $(-1,-1)$ solution
For $n=4$ you get the nice $(2+\sqrt{3},2-\sqrt{3})$ solution
and so on ...