Is there a continuous $f(x,y)$ which is not of the form $f(x,y) = g_1(x) h_1(y) + \dots + g_n(x) h_n(y)$

For a continuous function $f : [0,1]^2 \to \mathbb{R}$, let us say $f$ is a sum of products (SOP) if there exist an integer $n > 0$ and continuous functions $g_1, \dots, g_n, h_1, \dots, h_n : [0,1] \to \mathbb{R}$ such that $$f(x,y) = g_1(x) h_1(y) + \dots + g_n(x) h_n(y)$$
for all $x,y \in [0,1]$.

How can I show there exists a continuous $f$ which is not an SOP?

I think this should be easy, but for some reason I don’t see how to proceed.

Note that the Stone-Weierstrass theorem says that every continuous function on $[0,1]^2$ is a uniform limit of SOPs. I want to see that you can’t drop the limit.

Is the same true if we replace $[0,1]$ by an arbitrary infinite compact Hausdorff space?

Solutions Collecting From Web of "Is there a continuous $f(x,y)$ which is not of the form $f(x,y) = g_1(x) h_1(y) + \dots + g_n(x) h_n(y)$"

Let’s call $f$ an $n$-SOP if we can write

$$f(x,y) = \sum_{k = 1}^n g_k(x)\cdot h_k(y)$$

with continuous functions $g_k, h_k \colon [0,1] \to \mathbb{R}$. If $f$ is an $n$-SOP, for every family $x_1 < x_2 < \dotsc < x_r$ of $r > n$ points in $[0,1]$, the set

$$\left\{ \begin{pmatrix} f(x_1,y) \\ f(x_2,y) \\ \vdots \\ f(x_r,y)\end{pmatrix} : y \in [0,1]\right\}$$

is contained in an $n$-dimensional linear subspace of $\mathbb{R}^r$.

But

$$\begin{pmatrix} \exp (x_1\cdot 0/r) & \exp (x_1\cdot 1/r) & \cdots & \exp (x_1 \cdot (r-1)/r) \\ \exp (x_2 \cdot 0/r) & \exp (x_2 \cdot 1/r) & \cdots & \exp (x_2 \cdot (r-1)/r) \\ \vdots & \vdots & & \vdots \\ \exp (x_r\cdot 0/r) & \exp (x_r\cdot 1/r) & \cdots & \exp (x_r \cdot (r-1)/r)\end{pmatrix}$$

is a Vandermonde matrix, hence has rank $r$. Therefore $(x,y) \mapsto e^{xy}$ is not an $n$-SOP.