I am interested in the product
$$ z = f(x) \cdot g(y) = \left( a_0 + a_1 x + a_2 x^2 + \cdots + a_n x^n \right) \cdot \left( b_0 + b_1 y + b_2 y^2 + \cdots + b_m y^m \right) $$
With $n = 1$, $m = 2$ when calculating and renaming the regrouped factors with coefficients $c$ this leads to
$$ z = c_0 + c_1 x + c_2 y + c_3 x y + c_4 y^2 + c_5 x y^2 $$
since I want to approximate k data points I express this in the following matrix notation
$$\begin{bmatrix} z_1 \\ z_2 \\ \vdots \\ z_k \end{bmatrix} = \begin{bmatrix} 1 & x_1 & y_1 & x_1 y_1 & y_1^2 & x_1 y_1^2 \\ 1 & x_2 & y_2 & x_2 y_2 & y_2^2 & x_2 y_2^2 \\ \vdots & \vdots & \vdots & \vdots & \vdots & \vdots \\ 1 & x_k & y_k & x_k y_k & y_k^2 & x_k y_k^2 \\ \end{bmatrix} \cdot \begin{bmatrix} c_0 \\ c_1 \\ c_2 \\ c_3 \\ c_4 \\ c_5 \end{bmatrix}$$
Starting from
$$z = \left( \sum_{k=0}^{n} a_k x^k \right) \cdot \left( \sum_{l=0}^{m} b_l y^l \right)$$
Is there an equivalent representation to express this matrices in general that means without assuming $n = 1$, $m = 2$. I would be very grateful about your help and remarks!
Looking at the expression of $z$ in the special case $n=1, m=2$ we see \begin{align*} z &= c_0 + c_1 x + c_2 y + c_3 x y + c_4 y^2 + c_5 x y^2\\ &=\left(c_0 + c_1 x\right)+\left(c_2 + c_3 x \right)y+\left(c_4 + c_5 x \right)y^2\tag{1} \end{align*} We have in (1) a sum of terms ordered in increasing powers of $y^j, 0\leq j\leq 2$ and within $y^j$ we have an order in increasing powers of $x^i, 0\leq i\leq 1$.
Comment:
In (2.1) we rearrange the sums in increasing powers of $y$.
In (2.2) we write the inner sum to easily see the coefficients $a_ib_j=c_t$ with $0\leq i\leq n, 0\leq j\leq m$ or equivalently $0\leq t\leq mn+m+n$.
Comment:
In (3.1) we have a product of a row vector (i.e. a transposed column vector) with a column vector and take a bijective mapping between the sets \begin{align*} \{(j,i):0\leq j\leq n, 0\leq i\leq m\}\qquad\text{and}\qquad \{t:0\leq t\leq (n+1)(m+1)-1=nm+m+n\} \end{align*} We consider the pair $(i,j)=(i(t),j(t))$ dependent on $t$ via the relation \begin{align*} t=(n+1)j+i\qquad &0\leq j\leq m\\ &0\leq i\leq n \end{align*}
In (3.2) we set $c_t:=a_{i(t)}b_{j(t)}$ and have a representation of (2.2) in matrix form of order \begin{align*} \left(1\times 1\right)\quad\text{equal to}\quad\left(1\times (nm+m+n+1)\right)\times\left((nm+m+n+1)\times 1\right) \end{align*}