Are two $f, g \in \mathbb{C}[x_1, \ldots, x_n]$ equal if $f(\mathbf{a}) = g(\mathbf{a})$ for all $\mathbf{a} \in \mathbb{R}^n$? Suppose I have two polynomials of equal degree $f, g \in \mathbb{C}[x_1, \ldots, x_n]$  that satisfy  $f(\mathbf{a}) = g(\mathbf{a})$ for all $\mathbf{a}  \in \mathbb{R}^n$. Does this imply $f = g$? I know this is true if the values are equal for all $\mathbb{C}^n$, but was not sure about this case. Thank you!
 A: Yes, this is true. For simplicity, let's study the polynomial $h=f-g$, as a function $\Bbb R^n\to\Bbb C$. It is constantly equal to $0$.
The function $h$ may be Taylor expanded at, say, the origin. As it is the zero function, the Taylor expansion is trivial. But any polynomial is equal to its finite Taylor expansion. Thus $h$ must be given by the zero polynomial.
One might object and say "But expanding $h$ to a polynomial function $\Bbb C^n\to \Bbb C$ might give you more room to manoeuvre and make other polynomials". To address this, note that the real partial derivatives of $h$ as a function $\Bbb R^n\to\Bbb C$ are always equal to the partial derivatives of $h$ as a function $\Bbb C^n\to\Bbb C$. So expanding the domain of $h$ in this way cannot change the Taylor expansion.
A: I realized this after reading Arthur's answer.
Let us write $f = f_1 + i f_2$ and $g = g_1 + i g_2$ where $f_1, f_2, g_1, g_2 \in \mathbb{R}[x_1, \ldots, x_n]$. Then for any $\mathbf{a} \in \mathbb{R}^n$
the real part of $f(\mathbf{a})$ is $f_1(\mathbf{a})$ and the imaginary part $f_2(\mathbf{a})$ and similarly for $g$. Therefore
$f_1 - g_1$ and $f_2 - g_2$ are real polynomials which vanish at all values of $\mathbb{R}^n$, hence they are the zero polynomials. Thus $f = g$.
