Is my general formula for polynomial multiplication right?

$\begingroup$

Is the following equation for polynomial multiplication correct?

$ p(x)=p_{0} + \dots + p_{m}x^m \\ q(x)=q_{0} + \dots + q_{n}x^n \\ $

If $m \geq n$ then $i := m$. If $n \gt m$ then $i := n$.

$ p(x)q(x)=\sum_{j=0}^i p_{j} q_{i-j} x^j $

$\endgroup$ 2

3 Answers

$\begingroup$

Using your notation, we know that the product $p(x)q(x)$ is a polynomial of degree $n+m$.

Hence one has $$p(x)q(x) = \sum_{k=0}^{n+m} c_k x^k,$$with coefficients $c_k$ to be determined.

Let $k \in \{ 0, \cdots, n+m \}$. Now the question is: how do you obtain terms in $x^k$ in the multiplication? Here are the ways to get some $x^k$, and we'll just have to add them altogether.

  • multiply the constant term of $p$ by the term of degree $k$ of $q$ ;
  • multiply the term of degree $1$ of $p$ by the term of degree $k-1$ of $q$ ;
  • ...
  • multiply the term of degree $j$ of $p$ by the term of degree $k-j$ of $q$ ;
  • ...
  • multiply the term of degree $k$ of $p$ by the constant term of $q$.

Therefore, one has

$$c_k = \sum_{i=0}^k p_i q_{k-i}$$where $p_i$ (resp. $q_i$) denotes the $i$-th coefficient of $p$ (resp. $q$).

That gives us the general formula you're looking for:

$$ \bbox[lightgreen,5px,border:2px solid green]{\left( \sum_{i=0}^{\deg p} p_i x^i\right) \cdot \left( \sum_{j=0}^{\deg q} q_j x^j\right) = \sum_{k=0}^{\deg p + \deg q} \sum_{l=0}^k p_l q_{k-l} x^k}.$$

$\endgroup$ 1 $\begingroup$

It is close.

$p(x)q(x)=\sum_\limits{i=0}^{m+n}\sum_\limits{j=0}^i p_{j} q_{i-j} x^i$

$\endgroup$ 4 $\begingroup$

It is close.

$p(x)q(x)=\sum_\limits{k=0}^{m+n}x^k \sum_\limits{i=0...m, j=0...n}^{i+j=k} p_{i} q_{j} $

$\endgroup$

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like