What are the integer coeffcients of a cubic polynomial having two particular properties? Let $f(x) = x^3 + a x^2 + b x + c$ and $g(x) = x^3 + b x^2 + c x  + a\,$ where $a, b, c$ are integers and $c\neq 0\,$. Suppose that the following conditions hold:


*

*$f(1)=0$ 

*The roots of $g(x)$ are squares of the roots of $f(x)$.


I'd like to find $a, b$ and $c$.
I tried solving equations made using condition 1. and relation between the roots, but couldn't solve. 
The equation which I got in $c$ is $c^4 + c^2 +3 c-1=0$ (edit: eqn is wrong). 
Also I was able to express $a$ and $b$ in terms of $c$. But the equation isn't solvable by hand. 

The conditions 1 and 2 imply that


*

*$\;c\,$ must be $\,0\,$ or $\,-1$,

*$\;a= -c^2$, and $\:b= c^2-c-1\,$.



Condition 1 gives $0=f(1)=1+a+b+c=g(1)\,.\,$ Hence both $f$ and $g$ have a zero at $1$ and factor as
$$f(x) \,=\, (x-1)\big(x^2 + (a+1)x -c\big)\\[1.5ex]
g(x) \,=\, (x-1)\big(x^2 -(a+c)x -a\big)\,.$$
Denote the roots of the quadratic factor of $f$ by $x_1$ and $x_2$. Condition 2 says that the roots of $g$ are contained in $\{1,x_1^2,x_2^2\}$. By Vieta's formula one gets
$$\,-a \,=\, x_1^2x_2^2=(-c)^2 \,=\, c^2\,,\;\text{thus}\;\;
b \,=\, -a-c-1 \,=\, c^2-c-1\,.\tag{1}$$
Note that condition 2 remains true when restricted to the quadratic factors of $f$ and $\,g$. These are
$$q_f \,=\,x^2 + \left(1-c^2\right)x -c\tag{2}\\
q_g \,=\,x^2 -c\,(1-c)x +c^2$$
when written in terms of $\,c$.
It is shown next that condition 2 cannot hold if $c\neq 0\,$ or $\,-1$.


*

*Assume $c\geqslant 1$. Then $q_f(0)=-c<0$, and the roots $x_1,x_2$ of $q_f$ are real and distinct. By Vieta's formula regarding $q_g$ one reaches  the contradiction $0<x_1^2+x_2^2=c(1-c)\leq 0\,$.

*Assume $c\leq -2\,$. Then the discriminant $\left(1-c^2\right)^2+4c$ in $(2)$ is positive, and we run into the same contradiction as before.
So we are left with the two solutions (with condition 2 obviously satisfied)


*

*$a=0,b=-1,c=0\:$ which was ruled out a priori
then $f(x)=x(x+1)(x-1)\:$ and $\:g(x)=x^2(x-1)$

*$a=-1,b=1,c=-1\:$
where $f(x)=\left(x^2+1\right)(x-1)\:$ and $\:g(x)=(x+1)^2(x-1)$
