0
$\begingroup$

Is the convolution of two equal signals the same signal?

I have this system:

enter image description here

and i have to find $h_1[n]$ (which i've been struggling for a while), given

$$ h_2[n] = u[n] - u[n-2] $$

and $h[n] = h_1[n] \star h_2[n] \star h_2[n]$ given by:

enter image description here

I can find a solution if $h_2[n] \star h_2[n] = h_2[n]$, but I don't know if that holds.

$\endgroup$
11
  • 1
    $\begingroup$ "Is the convolution of two equal signals the same signal ?" not in general. only if the product of the spectra of both signals results in the spectrum of one. the only way for that to happen is if the spectrum takes on only the values of 0 or 1 because 0x0=0 and 1x1=1. $\endgroup$ Commented Jun 3, 2019 at 23:06
  • $\begingroup$ so in this case is the same signal ... , i think...... i got it , thanks $\endgroup$
    – Franker
    Commented Jun 3, 2019 at 23:09
  • $\begingroup$ No. your signal $h_2[n]$ is taking on the values of 0 and 1, not the spectrum $H_2(e^{j \omega})$. and you are convolving, not multiplying, $h_2[n]$ with itself. $\endgroup$ Commented Jun 3, 2019 at 23:10
  • $\begingroup$ what would you do to get h1? , im stuck $\endgroup$
    – Franker
    Commented Jun 3, 2019 at 23:17
  • $\begingroup$ so that second equation (that i $\LaTeX$ized) isn't $h_1[n]$? $\endgroup$ Commented Jun 3, 2019 at 23:18

2 Answers 2

1
$\begingroup$

First, we define $h_3[n] = h_2[n] \star h_2[n] = [1, 2, 1]$. From this result, we know that $h_1[n]$ must have 5 elements (so that $h[n]$ ends up with 7 elements).

Let's define $h_1[n] = [g_1, g_2, g_3, g_4, g_5]$. We can find these as follows, using the definition of discrete convolution.

First, we know that $g_1 h_3[0] = h[0] = 1$, so $g_1 = 1$.

Then, the next value of the convolution is $h[1] = g_2 h_3[0] + g_1 h_3[1] = 5$, from which we deduce that $g_2 = 3$.

Then, $h[2] = g_3 h_3[0] + g_2 h_3[1] + g_1 h_3[2] = 9$, or $g_3 = 2$.

You can stop here, since (by symmetry, in this particular example) $g_4 = g_2$ and $g_5 = g_1$.

In general, the problem can be seen as solving a system of linear equations. In this example, we need to solve the system:

$$\begin{bmatrix} h_3[0] & 0 & 0 & 0 & 0 \\ h_3[1] & h_3[0] & 0 & 0 & 0 \\ h_3[2] & h_3[1] & h_3[0] & 0 & 0 \\ 0 & h_3[2] & h_3[1] & h_3[0] & 0 \\ 0 & 0 & h_3[2] & h_3[1] & h_3[0] \\ 0 & 0 & 0 & h_3[2] & h_3[1] \\ 0 & 0 & 0 & 0 & h_3[2] \end{bmatrix} \begin{bmatrix} g_1 \\ g_2 \\ g_3 \\ g_4 \\ g_5 \end{bmatrix} = \begin{bmatrix} h[0] \\ h[1] \\ h[2] \\ h[3] \\ h[4] \\ h[5] \\ h[6] \end{bmatrix}$$

Thanks to @Hilmar for pointing out a boneheaded mistake in my original answer!

$\endgroup$
2
  • 2
    $\begingroup$ I think $h_2[n]$ is just [1 1] ,not [1 1 1] and this case we have $h_3$ = [ 1 2 1] and the problem has a perfectly nice integer value solution. $\endgroup$
    – Hilmar
    Commented Jun 4, 2019 at 1:46
  • $\begingroup$ @Hilmar Gee, you're right! I'll edit the answer.... $\endgroup$
    – MBaz
    Commented Jun 4, 2019 at 2:01
0
$\begingroup$

@MBaz solution is neat. Another vision is to use the idea that discrete convolutions turn into polynomial products in the $z$-transform domain: $$[1,1]\ast [1,1] = [1,2,1]$$ is equivalent to $$(1+z^{-1})(1+z^{-1})=(1+2z^{-1}+z^{-2})$$

So separating a long filter into short convolved filters is equivalent to factorizing a polynomial. To ease notations, I'll write $x= z^{-1}$. So you want to factorize $1+5x+9x^2+10x^3+9x^4+5x^5+x^6$. The lazy way is to use software or online polynomial factorization like dcode polynomial-factorization, and you get: $$(x+1)^2(x^2+1)(x^2+3x+1)$$ So you see the that the problem has indeed a solution, given by $(x^2+1)(x^2+3x+1)$. And for the whole problem, the entire system could be written as a cascade of four filters, two identical of length 2 ($[1,1]$, your $h_2$), and two others of length 3 ($[1,0,1]$ and $[1,3,1]$).

You can reach the result by the Euclidean division of polynomials or Polynomial Long division $1+5x+9x^2+10x^3+9x^4+5x^5+x^6$ by $1+2x+x^2$.

Let us be more witty, and (as shwo by @MBaz) find a degree 4 polynomial $D$ that gives $1+5x+9x^2+10x^3+9x^4+5x^5+x^6$ when multiplied by $(1+x)(1+x)$. Since the constant term and the highest-degree term are given in a unique way by the product of constant or highest degree terms, it is easy to see that the corresponding terms in $D$ are both $1$. So you just seek three coefficients such that:

$$(1+x)(1+x)(1+ax+bx^2+cx^3+x^4) = 1+5x+9x^2+10x^3+9x^4+5x^5+x^6$$

With a little more experience, you could tell that $a=c$ (for symmetry reasons), and this is useful to reduce the numbers of unknowns when the polynomials are much bigger. Here, you can resort to analysis. Replace $x$ by three values $x_k$ and equate:

$$(1+ax+bx^2+cx^3+x^4) = \frac{1+5x+9x^2+10x^3+9x^4+5x^5+x^6}{(1+x)(1+x)}$$ and you get a system of three linear equations that you can invert. For instance, with $x_1=1$, you have:

$$(1+a+b+c+1) = \frac{1+5+9+10+9+5+1}{(1+1)(1+1)}$$

or

$$a+b+c = 8$$

$\endgroup$
2
  • 1
    $\begingroup$ Surely $(x^2+1)(x^2+3x+1)$ cannot be expressed as the cascade of four filters, two of length 2 and two of length 3 as you claim; only the latter two of length 3 are needed? Did you mean $(x+1)^2(x^2+1)(x^2+3x+1)$ instead? $\endgroup$ Commented Jun 6, 2019 at 14:03
  • $\begingroup$ Of course, the "it" was the whole problem. I rephrased it $\endgroup$ Commented Jun 6, 2019 at 14:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.