Doubt on Signal Processing Stage

Thread Starter


Joined Aug 2, 2022
I am trying to implement some signal processing on sensor data for detecting tiny movement. the signal processing is doing on iq signals. In the source code I have some doubts that . Here I am adding the portion of Python Code . Can anyone please explain the following signal processing, and the significance of that, please describe what each term indicate

Envelope = np.abs(PresentSample)
Delta = PresentSample * np.conj(PreviousSample)
PhaseWeights = np.imag(Delta)
Weights = np.abs(PhaseWeights) * Envelope
DeltaDist =, np.angle(Delta))
DeltaDist *= 2.5 / (2.0 * pi * sum(Weights))

Present and prev samples are 1D array consisting of iq samples. For each processing . Is Delta is cross correlation ? Please give explanation for rest of the codes Why multiply the DetltaDist ?


Joined Aug 21, 2008
Maybe you will get more of a response if you explain in English what the process involves. Many electronics types don't know much about Python.


Joined Jun 5, 2013
These are apparently parameters for some algorithm. We know nothing about the algorithm, so how can you exoect us to know what they mean?

Thread Starter


Joined Aug 2, 2022
Ok I will explain the functions.
Present and Previous samples are the IQ data points from a sensor.
np.abs(PresentSample) : means taking the Amplitude of the Present Samples
np.conj(PreviousSample) : means taking the conjugate of PreviousSample
np.angle(Delta) : means taking the Imaginary part of Delta, which is a complex form
I want to know the signal processing logic behind thus, why we multiply with conjugate like that


Joined Feb 24, 2006
Multiplication of a complex value by its conjugate computes the square of the magnitude of the complex quantity by eliminating the imaginary part.

\( (a+jb)(a-jb)\;=\;a^2+jab-jab-j^2b^2\;=a^2+b^2 \)


\( M\;=\;\sqrt{a^2+b^2} \)