Recently, considering how algebraic numbers may be defined by the algebraic properties that they satisfy (and in particular, the polynomials of which they are roots), I started to wonder about, for algebraic $x$ and $y$, how one might go about learning about algebraic properties of $x+y$ or $xy$. A question which arose in my thoughts was the following:
Suppose we are given some polynomial $P$ of $n$ variables and $n$ polynomials $f_1,f_2,\ldots,f_n$ of a single variable. Is it always possible to find some non-constant polynomial of one variable, $\tilde{f}$, and a polynomial of $n$ variables, $\tilde{P}$, such that the following holds for all $a_i$: $$\tilde{f}(P(a_1,a_2,\ldots,a_n))=\tilde{P}(f_1(a_1),f_2(a_2),\ldots,f_n(a_n))$$
For instance, in two variables, if we were given that $$P(a_1,a_2)=a_1a_2$$ $$f_1(a_1)=a_1^2$$ $$f_2(a_2)=a_2^3$$ we could solve the desired equations by setting $$\tilde{P}(x,y)=x^3y^2$$ $$\tilde{f}(x)=x^6$$ which, after substitution, would give $$(a_1a_2)^6=(a_1^2)^3\cdot (a_2^3)^2$$ which is clearly true. However, I have no idea how one might prove that, for any $P$ and $f_i$, such $\tilde{P}$ and $\tilde{f}$ must exist and moreover little idea of how to construct them if they do. I am not certain that this statement must be true either, but I doubt that proving a counterexample would be trivial. (Currently, I'm wondering about $P(a_1,a_2)=a_1a_2$ and $f_1(a_1)=a_1^2+a_1$ and $f_2(a_2)=a_2$)
For simplicity I'll work over $\mathbb R$.
If $P(x,y)=x+y$, $f_1(x)=x^2$ and $f_2(y)=y^2$, there are no polynomial $\tilde f$ of one variable and $\tilde P$ of two such that $\tilde f$ is non-constant and $\tilde f(P(x,y))=\tilde P(f_1(x),f_2(y))$, that is, such that $$\tilde f(x+y)=\tilde P(x^2,y^2).$$ Differentiating with respect to $x$ on both sides we see that $$\tilde f'(x+y)=\tilde P_1(x^2,y^2)2x$$ with $\tilde P_1$ denoting the derivative of $\tilde P$ with respect to its first argument. Letting $x=0$ in this equation we see that $\tilde f'(y)=0$ for all $y\in\mathbb R$. This implies that $\tilde f$ is constant.