# Can we split/decompose a multivariable function into several single-variable functions?

If I have a multivariable function, can I split/decompose it into several single-variable functions?

For instance:

Given $f:\mathbb R^2 \rightarrow \mathbb R$, I introduce the functions $g:\mathbb R\rightarrow \mathbb R$ and $h:\mathbb R\rightarrow \mathbb R$ so $$f(x,y)=g(x)h(y)$$ Or $$f(x,y)=g(x)+h(y)$$

Is this mathematically correct?

Is function composition the right name?

Ex. 1:

The function $f:\mathbb R^2\rightarrow \mathbb R$ is given by $f(x,y)=2xy$. Introduce the functions $g,h:\mathbb R\rightarrow \mathbb R$ and write $$f(x,y)=2xy=g(x)h(y)$$ where $g(x)=2x$ and $h(y)=y$.

Ex. 2:

Or if $f(x,y)=2x+y$, we write $$f(x,y)=2x+y=g(x)+h(y)$$ where $g(x)=2x$ and $h(y)=y$.

• It depends on the function $f$, if this is possible. For example, the function $f(x,y) = sin(xy)$ can't be written as a product $g(x)h(y)$ or as a sum $g(x) + h(y)$, but there are plenty of functions where this works. – Tom Jun 14 '18 at 18:31
• $f(x,y)=\cos(x+y)$ won't fit into either of your two ideas. Neither is function composition, by the way. One is ordinary multiplication, and the other is ordinary addition. – Adrian Keister Jun 14 '18 at 18:31
• If the above were true, then for a twice differentiable $f$ we would have either ${\partial^2 f(x,y) \over \partial x^2} = 0$ or ${\partial^2 f(x,y) \over \partial x \partial y} = 0$. So, for a counterexample, pick any function for which both are not true. – copper.hat Jun 14 '18 at 18:35
• "Decomposition" is a good word for it, in my opinion. – Arthur Jun 14 '18 at 18:44
• @copper.hat The solutions to $f_{xx} = 0$ are $g(y) + x h(y)$ not $f(x) g(y)$. A possible PDE that has solutions $g(x) h(y)$ but not all functions as solutions would be: $f \cdot f_{xy} = f_x \cdot f_y$. – Daniel Schepler Jun 14 '18 at 19:08

Consider the values $x_1$, $y_1$, $x_2$ and $y_2$ and assume that $f(x_i, y_j)$ is defined for all four possible combinations. Then for functions that can be written as products, you have: $$f(x_1,y_1)f(x_2,y_2)=g(x_1)h(y_1)g(x_2)h(y_2)=f(x_1,y_2)f(x_2,y_1)$$ However in general this is not true. For example, consider $$f(x,y)=x^y$$ Then you have $$f(1,2)f(3,4) = 1^2\cdot 3^4 = 81 \ne 8 = 1^4\cdot 2^3 = f(1,4)f(2,3)$$ Which proves that $x^y$ cannot be written as $g(x)h(y)$ for any real functions $g$ and $h$.