0
$\begingroup$

I have a set of signals consisting of impulses at different instant of time i.e. its not a continuous signal. What I want is a mathematically intuitive way to distinguish between any two such signals?

I understand that the time of occurrence of impulses can be used to differentiate between the impulses. But what I need is like a single number that gives a measure of how different two impulse signals are for instance it could be some property of the signal that would be different for any two signals.

Just an additional info the signals are defined on finite duration. I don't know if that info is needed or redundant.

I don't come from a signal processing background so this question could be wrong. Also if I have tagged it wrongly please modify it.

An example of 2 signals would be:

[0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0 0 0 1 0 0 1 0 0 1 0 1 0 1 1 1 1 1]
[0 0 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0 0 0 1 0 0 1 0 0 1 0 1 0 1 1 1 1 1 1]
$\endgroup$
  • 1
    $\begingroup$ Are the signals discrete or continuous in time? Are they given as mathematical expressions or as vectors of floats/integers? If they are discrete-time signals, are their samples equidistant? $\endgroup$ – Matt L. Jun 25 '13 at 13:53
  • $\begingroup$ Is it possible for signals consisting of impulses to be continuous? They are not mathematical functions. they are given as vectors of integers and the amplitude of these impulses is same everywhere, only difference is in their time of occurrence. What do you mean when you say they are samples equidistant? $\endgroup$ – Shaun Jun 25 '13 at 13:58
  • $\begingroup$ Is it only 1s and 0s? What is your application? What kind of semantics do these 1s and 0s carry? Depending on your application, good metrics could be: the edit distance between the sequences, the distribution of 1s and 0s, the cross-correlation, the euclidean distance between the autocorrelation functions, the total number of 1s... $\endgroup$ – pichenettes Jun 25 '13 at 14:05
  • $\begingroup$ Yeah it consist of only ones and zeros. The application would be neuroscience. Lets say these ones and zeros are how we convert an analog signal to a set of impulses. What would be the most relevant measure in such a case? $\endgroup$ – Shaun Jun 25 '13 at 14:08
  • $\begingroup$ @Shaun: yes, impulses can be continuous-time or discrete-time, depending on how you define 'impulse'. As for being equidistant, the question was if they are on a grid of equidistant points. $\endgroup$ – Matt L. Jun 25 '13 at 14:21
0
$\begingroup$

You may search for the Morphological Gradient. In addition, if you have some marked data, i.e. you've known the types of these signals, then you can simply train a system using the logistic regression, neural network etc, to differentiate these two types. The advantage of these machine learning methods is that you can encode whatever information that you are interested in the system as an additional feature.

$\endgroup$
  • $\begingroup$ Can you elaborate how can I use morphological gradient as some property of an impulse signal? What would be my structuring element? $\endgroup$ – Shaun Jul 28 '13 at 11:41
1
$\begingroup$

If you are looking at vectors $\mathbf x$ and $\mathbf y$ (presumably of the same length) in which the entries are mostly $0$s and

  • with occasional $1$s (unit impulses), a good measure of the difference between the vectors is the Hamming distance between them, that is, the number of samples in which $\mathbf x$ and $\mathbf y$ differ

  • with occasional non-zero entries (impulses of different amplitudes), then we need to distinguish between impulses of different amplitudes but the same location. If we use Hamming distance, then the measure of the difference between $$\cdots \quad 0\quad 0 \quad 0 \quad 1 \quad 0 \quad 0\quad 0\quad \cdots$$ $$\cdots \quad 0\quad 0 \quad 0 \quad 2 \quad 0 \quad 0\quad 0\quad \cdots$$ and $$\cdots \quad 0\quad 0 \quad 0 \quad 1 \quad 0 \quad 0\quad 0\quad \cdots$$ $$\cdots \quad 0\quad 0 \quad 0 \quad 9 \quad 0 \quad 0\quad 0\quad \cdots$$ is the same which is not quite capturing our intuition that the two pairs are more different than the Hamming distance is telling us. Possibilities to consider in this case are $$\sum_{i=1}^n |x_i - y_i|,\quad \sum_{i=1}^n |x_i - y_i|^2,\quad \mathrm{or}\quad \sqrt{\sum_{i=1}^n |x_i - y_i|^2}.$$ The last quantity is the Euclidean distance between the vectors. Which measure you want to use depends on how much the measure captures the features relevant to your application.

$\endgroup$
  • $\begingroup$ Thanks for responding. What if the signals i would have start with 1's and then the frequency of ones keeps on decreasing. Please have a look the examples I have provided above. What I am doing is I start with an analog signal, convert it to a signal consisting of impulses and then try to differentiate between them. The initial analog signal has a constant amplitude. Now the question would be how do I convert. Actually that's another thing I am working on. I need a good way for the conversion such that fewest possible impulses can convey information about amplitude of analog signal $\endgroup$ – Shaun Jun 25 '13 at 14:29
  • $\begingroup$ And thereafter I have some measure that I can use to calculate the difference between impulses $\endgroup$ – Shaun Jun 25 '13 at 14:31
  • $\begingroup$ EDIT: There is no restriction on the number of impulses in the converted signal but they should be finite. $\endgroup$ – Shaun Jun 25 '13 at 14:37

Your Answer

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

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