# Separate two measured combinations of two signals with different time delays

I have two signal s1(t) and s2(t) that I want to extract but I can only measure:

y1(t) = s1(t) + s2(t-d1)

y2(t) = s1(t-d2) + s2(t-d3)

The time delays d1, d2 and d3 are unknown, though I have a rough estimate for d2.

Maybe (but only if necessary) I could approximate this by shifting y2 so that

y1(t) = s1(t) + s2(t-d1)

y2(t) = s1(t) + s2(t-d3)

Is there any way to separate the signals? What happens if I have three measurements and three signals?

• I would use cross-correlation between $y1$ and $y2$ to try to estimate the offset $d1-d3$ (whether this works depends a lot on the structure of $s1$ and $s2$ - do they look similar or different; are they equally strong or can one be much stronger?). Once you have that, subtracting $y1$ and a suitably delayed version of $y2$ should eliminate $s2$, so that you are left with something like $s1(t)-s1(t-\Delta)$. From this you can get back $s1$ except for its DC, which is lost in the process. Jul 12 '19 at 8:43
• How can I get back s1 from s1(t)−s1(t−Δ)? Jul 12 '19 at 10:19
• Are the time delays constant for the duration you are interested in?
– A_A
Jul 12 '19 at 10:20
• Yes, the time delays are constant Jul 12 '19 at 10:21
• Well, $s_1(t)-s_1(t-\Delta)$ is nothing but $s_1(t)$ convolved with $\delta(t)-\delta(t-\Delta)$. Many ways to deconvolve, e.g., dividing in frequency domain. Depends on your signals, I guess we're talking about discrete/sampled signals? Then it's a difference equation which you can solve sample by sample algebraically. Jul 12 '19 at 11:01

Elaborating a little bit on what I discussed in the comments: Let's assume the delays $$d_1$$, $$d_2$$ and $$d_3$$ are integer multiples of the sampling time interval $$t_0$$ so that we can treat it as an integer problem.
Then, as a first step, I would try to use the cross correlation between $$y_1$$ and $$y_2$$ to determine the delays. Ideally, it should have a peak at an offset of $$d_2$$ (when the shifted copies of $$s_1(t)$$ and $$s_1(t-d_2)$$ align) and another one at $$d_3-d_1$$ (when the shifted copies of $$s_2(t-d_1)$$ and $$s_2(t-d_3)$$ align).
Now compute $$z[n] = y_1[n] - y_2[n-(d_3-d_1)]$$ (using $$[n]$$ as a discrete time / sample index for clarity). If your estimate was correct, this cancels $$s_2(t)$$ and we are left with $$z[n] = s_1[n] - s_1[n-\Delta]$$ where $$\Delta = d_3-d_1-d_2$$.
Now, your signals ought to start somewhere (causality) so that we can assume $$s_1[n]=0$$ for $$n<0$$ (if you have different initial conditions, you need to work them in here). Then, we have $$z[n] = s_1[n]-s_1[n-\Delta] = s_1[n]\quad \forall n<\Delta.$$ Therefore $$s_1[n] = \begin{cases} 0 & n<0 \\ z[n] & n<\Delta \\ z[n]+s_1[n-\Delta] & \mbox{otherwise}\end{cases}.$$ This allows you to reconstruct $$s_1[n]$$ sample by sample.