suppose that we have a wave which has some peaks in some indexes like 2,12,25,... and otherwise zero.

I want to extract the time lag or lags between peaks of a signal. could anyone help me ?

enter image description here

  • $\begingroup$ Do you know the sample rate? $\endgroup$ – Jim Clay Apr 15 '13 at 14:15
  • 2
    $\begingroup$ Can u put a picture up? $\endgroup$ – Spacey Apr 15 '13 at 14:54
  • $\begingroup$ the sampling rate is 16000 you can see pic in following link: researchgate.net/… $\endgroup$ – Ali Bodaghi Apr 16 '13 at 1:07
  • $\begingroup$ @AliBodaghi: do you want to find the peaks on the image, or in the sequence of numbers? could you provide the sequence in simple text form? $\endgroup$ – mbaitoff May 19 '13 at 8:25
  • $\begingroup$ I want to find time lag to remove other spurious peaks. you can suppose some high peaks with special distance from each other with some other random and weak peaks between 2 high peaks. $\endgroup$ – Ali Bodaghi May 20 '13 at 3:03

The time lag is equal to the index difference times the sample period. The sample period is: $$ T_s = \frac{1}{f_s} = \frac{1}{16000} = 62.5\mu s $$ Thus, the time lag from the first peak to the second is $(12 - 2) * T_s = 625\mu s$. The time lag from the second peak to the third is $(25 - 12) * T_s = 812.5\mu s$.

| improve this answer | |
  • $\begingroup$ Thanks for your respond. However, my question is removing the spurious peaks as you seen in Figure part B by using time lag between peaks. $\endgroup$ – Ali Bodaghi Apr 18 '13 at 1:13

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.