Reply by Antoine Bruguier January 22, 20082008-01-22
Hello all,

Thanks for your replies. Indeed, there are some stringent conditions.
The number of equations scales as ~n^2 but the number of unknowns
(size of h1 and h2) scales as ~n.

h1[n]h2[n] = h[n]
h1[n]h2[p] + h1[p]h2[n] = 0 (for n != p)

I was wondering if this problem has been studied before, otherwise,
I'll try to create a solution from scratch.

Going into Fourier does not seem to help.

On Jan 22, 5:02 am, "sarw...@YouEyeYouSee.edu" <dvsarw...@gmail.com>
wrote:
> On Jan 22, 1:16 am, Laurent Schmalen <lo...@gmx.de> wrote: > > > > > sarw...@YouEyeYouSee.edu wrote: > > > On Jan 18, 2:41 pm, Antoine Bruguier <tony.brugu...@gmail.com> wrote: > > > >> I was looking for conditions on h such that we can find h1 and h2 such > > >> that for every s: > > >> (s^2) * h = (s*h1) . (s*h2) > > > > If the condition is required to hold for *every* input s, then > > > it must hold when the input is the unit pulse function given > > > by p[n] = 1 for n = 0 and p[n] = 0 otherwise. Since p^2 = p, > > > and p is the identity for convolution, it must be that > > > (p^2) * h = p * h = h, and p*h1 = h1, p*h2 = h2. Hence, > > > h = h1.h2, that is, > > > > h[n] = h1[n]h2[n] for all n. > > > > Since multiplication in the time domain corresponds to convolution > > > inn the frequency domain, perhaps you need to look at spectral > > > convolution H = (H1) * (H2) rather than spectral factorization > > > H = (H1)(H2). > > > Wrong. > > Squaring is a non-linear operation and thus your condition does NOT > > hold. Take this little example: > > > h1 = [1 2 3 4]; > > h2 = [-1 -2 -3 -4]; > > s = [0 -0.1 0.2 -0.3 0.4]; > > h = h1.*h2; > > conv(s.^2,h) > > conv(s,h1) .* conv(s,h2) > > > and compare the outputs. > > > Regards, > > Laurent > > The condition h[n] = h1[n]h2[n] for all n is NECESSARY > if it is desired that (s^2) * h = (s*h1) . (s*h2) hold for ALL > signals s; it is by no means SUFFICIENT. I very much > doubt that the decomposition sought by the OP is possible > for all h; indeed the OP was looking for conditions on h > that would allow for the decomposition that he wanted
Reply by sarw...@YouEyeYouSee.edu January 22, 20082008-01-22
On Jan 22, 1:16 am, Laurent Schmalen <lo...@gmx.de> wrote:
> sarw...@YouEyeYouSee.edu wrote: > > On Jan 18, 2:41 pm, Antoine Bruguier <tony.brugu...@gmail.com> wrote: > > >> I was looking for conditions on h such that we can find h1 and h2 such > >> that for every s: > >> (s^2) * h = (s*h1) . (s*h2) > > > If the condition is required to hold for *every* input s, then > > it must hold when the input is the unit pulse function given > > by p[n] = 1 for n = 0 and p[n] = 0 otherwise. Since p^2 = p, > > and p is the identity for convolution, it must be that > > (p^2) * h = p * h = h, and p*h1 = h1, p*h2 = h2. Hence, > > h = h1.h2, that is, > > > h[n] = h1[n]h2[n] for all n. > > > Since multiplication in the time domain corresponds to convolution > > inn the frequency domain, perhaps you need to look at spectral > > convolution H = (H1) * (H2) rather than spectral factorization > > H = (H1)(H2). >
> Wrong. > Squaring is a non-linear operation and thus your condition does NOT > hold. Take this little example: > > h1 = [1 2 3 4]; > h2 = [-1 -2 -3 -4]; > s = [0 -0.1 0.2 -0.3 0.4]; > h = h1.*h2; > conv(s.^2,h) > conv(s,h1) .* conv(s,h2) > > and compare the outputs. > > Regards, > Laurent
The condition h[n] = h1[n]h2[n] for all n is NECESSARY if it is desired that (s^2) * h = (s*h1) . (s*h2) hold for ALL signals s; it is by no means SUFFICIENT. I very much doubt that the decomposition sought by the OP is possible for all h; indeed the OP was looking for conditions on h that would allow for the decomposition that he wanted
Reply by Laurent Schmalen January 22, 20082008-01-22
sarwate@YouEyeYouSee.edu wrote:
> On Jan 18, 2:41 pm, Antoine Bruguier <tony.brugu...@gmail.com> wrote: > >> I was looking for conditions on h such that we can find h1 and h2 such >> that for every s: >> (s^2) * h = (s*h1) . (s*h2) > > If the condition is required to hold for *every* input s, then > it must hold when the input is the unit pulse function given > by p[n] = 1 for n = 0 and p[n] = 0 otherwise. Since p^2 = p, > and p is the identity for convolution, it must be that > (p^2) * h = p * h = h, and p*h1 = h1, p*h2 = h2. Hence, > h = h1.h2, that is, > > h[n] = h1[n]h2[n] for all n. > > Since multiplication in the time domain corresponds to convolution > inn the frequency domain, perhaps you need to look at spectral > convolution H = (H1) * (H2) rather than spectral factorization > H = (H1)(H2).
Wrong. Squaring is a non-linear operation and thus your condition does NOT hold. Take this little example: h1 = [1 2 3 4]; h2 = [-1 -2 -3 -4]; s = [0 -0.1 0.2 -0.3 0.4]; h = h1.*h2; conv(s.^2,h) conv(s,h1) .* conv(s,h2) and compare the outputs. Regards, Laurent
Reply by sarw...@YouEyeYouSee.edu January 21, 20082008-01-21
On Jan 18, 2:41 pm, Antoine  Bruguier <tony.brugu...@gmail.com> wrote:

> I was looking for conditions on h such that we can find h1 and h2 such > that for every s: > (s^2) * h = (s*h1) . (s*h2)
If the condition is required to hold for *every* input s, then it must hold when the input is the unit pulse function given by p[n] = 1 for n = 0 and p[n] = 0 otherwise. Since p^2 = p, and p is the identity for convolution, it must be that (p^2) * h = p * h = h, and p*h1 = h1, p*h2 = h2. Hence, h = h1.h2, that is, h[n] = h1[n]h2[n] for all n. Since multiplication in the time domain corresponds to convolution inn the frequency domain, perhaps you need to look at spectral convolution H = (H1) * (H2) rather than spectral factorization H = (H1)(H2).
Reply by Juha January 19, 20082008-01-19
Antoine Bruguier wrote:
> Hi Juha, > > Thanks for your reply. However, I am not sure this is what I am > looking for. > > The spectral factorization finds h1 and h2 such that for every s: > s*h = s*h1*h2 > > I was looking for conditions on h such that we can find h1 and h2 such > that for every s: > (s^2) * h = (s*h1) . (s*h2) > > Let me know if I was confused and did not really understand spectral > factorization.
Sorry, I misunderstood you question. -- Juha
Reply by Andor January 19, 20082008-01-19
On 19 Jan., 08:26, Andor <andor.bari...@gmail.com> wrote:
> On 18 Jan., 19:08, Antoine &#4294967295;Bruguier <tony.brugu...@gmail.com> wrote: > > > Hello, > > > This is probably a classic problem, but after much Googling, I can't > > come up with the right keywords. > > > In the following, * is a convolution (conv in Matlab) ^2 means squared > > ( .^2 in Matlab) and a dot . means multiply (.* in Matlab). > > > I would like to be able to "factor" a filter h into two filters h1 and > > h2 in such a way that for any signal s: > > > (s^2) * h = (s*h1) . (s*h2) > > > Any good pointers? > > Thanks in advance > > The problem is underspecified. You can take h1=1 and h2 = h, for > example.
Scratch that ...
Reply by Andor January 19, 20082008-01-19
On 18 Jan., 19:08, Antoine  Bruguier <tony.brugu...@gmail.com> wrote:
> Hello, > > This is probably a classic problem, but after much Googling, I can't > come up with the right keywords. > > In the following, * is a convolution (conv in Matlab) ^2 means squared > ( .^2 in Matlab) and a dot . means multiply (.* in Matlab). > > I would like to be able to "factor" a filter h into two filters h1 and > h2 in such a way that for any signal s: > > (s^2) * h = (s*h1) . (s*h2) > > Any good pointers? > Thanks in advance
The problem is underspecified. You can take h1=1 and h2 = h, for example.
Reply by Antoine Bruguier January 18, 20082008-01-18
Hi Juha,

Thanks for your reply. However, I am not sure this is what I am
looking for.

The spectral factorization finds h1 and h2 such that for every s:
s*h = s*h1*h2

I was looking for conditions on h such that we can find h1 and h2 such
that for every s:
(s^2) * h = (s*h1) . (s*h2)

Let me know if I was confused and did not really understand spectral
factorization.
Reply by Juha January 18, 20082008-01-18
Antoine Bruguier wrote:
> Hello, > > This is probably a classic problem, but after much Googling, I can't > come up with the right keywords. > > In the following, * is a convolution (conv in Matlab) ^2 means squared > ( .^2 in Matlab) and a dot . means multiply (.* in Matlab). > > I would like to be able to "factor" a filter h into two filters h1 and > h2 in such a way that for any signal s: > > (s^2) * h = (s*h1) . (s*h2) > > Any good pointers? > Thanks in advance
Hi, I think that the right keyword is spectral factorization or in the case of FIR filters you simply find the zeros of the transfer function and construct the subfilters by choosing some of the zeros of the overall filter to the H_1(z) and the remaining to the H_2(z). -- Juha >> h = [1 2 2 2 1]; >> allRoots = roots(h) allRoots = 0 + 1.0000i 0 - 1.0000i -1.0000 -1.0000 >> h1 = poly([allRoots(1); allRoots(2)]) h1 = 1.0000 0 1.0000 >> h2 = poly([allRoots(3); allRoots(4)]) h2 = 1.0000 2.0000 1.0000 >> conv(h1, h2) ans = 1.0000 2.0000 2.0000 2.0000 1.0000
Reply by Antoine Bruguier January 18, 20082008-01-18
I forgot to add that from the math I've done, it seems that if the
length of h is 4 or greater, the solutions does not always exist. I'm
also looking for conditions on h when it's possible, etc...