Conflicting situations arising while solving for $x$ Given $$x^{1/4}+\frac{1}{x^{1/4}}=1$$
find $$x^{1024}+\frac{1}{x^{1024}}=?$$
My approach let $a=x^{1/4}$
$$a+\frac{1}{a}=1$$
$$a^2+1-a=0 $$
multiplying by $(a+1)$
$$(a+1)(a^2+1-a)=0 $$
$$a^3+1=0, a^3=-1$$
by solving we get value of $x$
$$x^3=1$$
Now the answer to the should be 2. 
$$x^{1024}+\frac{1}{x^{1024}}=2$$
But if we square the equation $$x^{1/4}+\frac{1}{x^{1/4}}=1$$
we will get $-1$ as the recurring digit on the RHS as we square on both the sides. Thus it will result in $-1$ as the answer.
Can anyone help me to figure out where I am wrong 

Since $a^3=-1$, one has $a^6=1$ and
$$ x=(x^\frac14)^4=a^4=-a. $$
So
$$ x^{1024}+\frac{1}{x^{1024}}=a^{1024}+\frac{1}{a^{1024}}=a^{6\cdot17+4}+\frac{1}{a^{6\cdot17+4}}=a^4+\frac{1}{a^4}=-a-\frac{1}{a}=-1$$
