How to do phase compensation from the different phases of a waveform?

9 views (last 30 days)
Hello everyone, I would have a question related to phase compensation.
Generally, we have an original complex form as cmpVector = 10.^(Mag_dB/20).*exp(1j*phase_radian). And to find phase, I used the formula Phase = angle(cmpVector).
From the vector form of phase_radian, I have two different phase as the following graph.
My question is, how could we compensate or shift the phase 2 to close to the phase 1 from the formula above?

Answers (1)

Angelo Yeo
Angelo Yeo on 17 Jul 2023
Hi Chrek,
I believe what you want is similar to the concept of All Pass Filter. You can filter the signal 2 with an allpass filter and only shift phase.
See a theoretical reference in Wikipedia: All Pass Filter(Wikipedia.org)
In MATLAB you can use dfilt.allpass.
https://kr.mathworks.com/help/dsp/ref/dfilt.allpass.html

Products


Release

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!