# Matched filter - do I need to know the signal I am trying to find?

I need to identify a matched filter, and so have gone through the mathematics to do this as listed here https://en.wikipedia.org/wiki/Matched_filter which derives the optimal filter $$h$$ to apply to a time series $$x$$, where that time series is assumed to comprise a desirable signal $$s$$ and some noise $$v$$. This suggests the optimal matched filter is: $$$$h = \frac{1}{\sqrt{s^{\mathrm{H}}\mathbf{\mathrm{R}}_v^{-1}s}} \mathbf{\mathrm{R}}_v^{-1}s$$$$ and this should be applied to produce the filtered series $$y$$ thus: $$$$y\left(n\right) = \sum_{k=-\infty}^{\infty} h\left(n-k\right)x\left(k\right)$$$$ however, I don't know $$s$$. How, therefore, do I use this method (if at all)?

• Matched filters are based on the assumption that the signal is known (else there is nothing to match to in designing the matched filter). Jul 6 '20 at 12:35
• Depending on the problem, if $s$ has some known structure but the parameters are unknown, you can think about first estimating the signal parameters then you can generate an "estimated/approximate" matched filter Jul 6 '20 at 14:14
• @Engineer Yes, I have a time series ($x$) for which I have a decomposition: it has three structural components (plus noise) and I have an autocovariance matrix for each component. The series ($x$) is measured river flows and comprises a sinusoidal (seasonal) cycle $s$, a river flow contribution from groundwater (known as "baseflow", $b$ and a contribution to river flow from storm runoff events, $r$, and some random fluctuations $n$. So, $x = s+b+r+n$. I want to filter $x$ such that I am left with $s+b$. I know the autocovariance functions for $s+b$ - does this help? Jul 6 '20 at 14:27
• Oh I see, there is multiple things going on. So you know that $s$ is periodic, $b$ must be constant (?), $r$ is periodic (?), and $n$ is not periodic. Is this right? Jul 7 '20 at 14:43
• @Engineer Yes. I have just written an updated post, having done some extra reading - its here... dsp.stackexchange.com/questions/68900/… Jul 7 '20 at 14:46

As stated by others, the signal $$s[n]$$ has to be known to calculate the corresponding matched filter.
Dilip Sarwate's comment, as usual, is correct. hydrologist, are you making this problem overly complicated? If you know the finite-duration samples of the signal $$s[n]$$ you want to detect then the finite-duration impulse response of your matched filter should be the "reversed-in-time" conjugate of $$s[n]$$.