Problem: Let $X$ and $Y$ be compact spaces. Prove that for any real-valued function $f$ on $X \times Y$ and any $\epsilon > 0$ we can find continuous real-valued functions $g_1,g_2,g_3,\dots,g_n$ on $X$ and $h_1,h_2,h_3,\dots,h_n$ on $Y$ such that

$$ \left|f(x,y)-\sum_{i=1}^n g_i(x)h_i(y)\right| < \epsilon \quad (x,y) \in X \times Y $$

From what I understand I need to define $\mathcal{A} = \left\{\sum_{i=1}^ng_1(x)h_i(y) : g_i \in C(X) \text{ and } h_i \in C(Y) \right\}$. Then I need to prove that

  1. $\mathcal{A}$ is an algebra
  2. $1 \in \mathcal{A}$
  3. $\mathcal{A}$ separates points.

Work so far:

  1. Let $p(x,y) = \sum_{i=1}^n a_i(x)b_i(y)$ and $q(x,y) = \sum_{i=1}^n c_i(x)d_i(y)$ then we need to show that $p+q \in \mathcal{A}$ and $pq \in \mathcal{A}$. For the product of $p$ and $q$ I have that \begin{align*} p(x,y)q(x,y) = \sum_{i=1}^n\sum_{j=1}^n a_i(x)b_i(y)c_j(x)d_j(y) \end{align*} For each $i$ define $m_i(x) = \left(a_i(x)\left[\sum_{j=1}^n c_j(x)\right]\right)$ and $n_i(y)= \left(b_i(y)\left[\sum_{j=1}^n d_j(y)\right]\right)$ then both $m_i$ and $n_i$ are continuous since they are the sum and products of continuous functions and we get \begin{align*} p(x,y)q(x,y) = \sum_{i=1}^n m_i(x)n_i(y) \in \mathcal{A} \end{align*} As for the sum I cannot find a way to add them both up and get a summation of the form required in the algebra.
  2. To show $1 \in \mathcal{A}$ we just need to let $g_i(x) = 1 \; \forall \; i$ and $h_i(y) = \frac{1}{n} \; \forall \; i$ and the sum equals to 1 so $1 \in \mathcal{A}$
  3. We need to show to there exists functions $g \in C(X)$ and $h \in C(Y)$ such that if $(x_1,y_1) \neq (x_2,y_2)$ then there exist a $z(x,y) \in \mathcal{A}$ such that $z(x_1,y_1) \neq z(x_2,y_2)$ where $z(x,y) = \sum_{i=1}^n g_i(x)h_i(y)$. Would it be allowed to have $g(x_1) = 1$ and $g(x_2) = 0$ and $h(y) = 1 \; \forall \; y$ then $g(x_1)h(y_1) \neq g(x_2)h(y_2)$?

Let me know if any additional information that might be needed to complete the problem. Thank you.

  • $\begingroup$ $n$ isn't fixed. $\endgroup$ Nov 26, 2019 at 19:41
  • $\begingroup$ I am aware, thank you. $\endgroup$
    – FatFeynman
    Nov 26, 2019 at 19:57

1 Answer 1


You have the correct idea, but you missed an essential point (see Lord Shark the Unknown's comment):

In your definition of $\mathcal A$ you have a fixed $n$, but you have to take all finite sums $\sum_{i=1}^n g_i h_i$ with arbitrary $n$.

You will see that your proof works smoothly, it even becomes simpler for 2. (take $n =1$). Concerning 3. note that not necessarily $x_1 \ne x_2$. We only know that $x_1 \ne x_2$ or $y_1 \ne y_2$. Both cases can be treated as you did.

  • $\begingroup$ What about for the first part of the question, even for $n=1$ I can't get it right for $p(x,y)+q(x,y)$ to be in the desired form $\endgroup$
    – FatFeynman
    Nov 27, 2019 at 0:27
  • $\begingroup$ how do you get $a(x)b(y) + c(x)d(y) = \alpha(x)\beta(y)$ $\endgroup$
    – FatFeynman
    Nov 27, 2019 at 1:21
  • $\begingroup$ I think I got it, if $n=1$ and you take $p(x,y)+q(x,y)$ then using the $n=2$ version of the sum then the problem is trivial correct? $\endgroup$
    – FatFeynman
    Nov 27, 2019 at 1:42
  • $\begingroup$ Right, the sum of finite sums is again a finite sum. $\endgroup$
    – Paul Frost
    Nov 27, 2019 at 9:33

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .