# Instantaneous phase detection between two low frequency sine waves

I am looking for a non-microcontroller based solution for detecting the instantaneous phase change between two sine waves with frequency 25 Hz.

I have tried using zero crossing detector, but I have to wait longer to detect a change in phase. Phase changes within 200us and I have to capture this event. Please suggest a method to do so. Resolution required is 0.1 degrees

• Do you need a constant readout of the phase difference, or do you just need to know when one of the two signals changes phase?
– JRE
Commented Oct 6, 2023 at 14:59
• Whenever signals change phase, I need to detect at that instant. It is like continuous sampling the waves and checking if the phase has changed
– gari
Commented Oct 6, 2023 at 15:48
• @gari I know it may be an annoying question, but define "phase" and "instantaneous phase" for me (in your context.) Do it exactly and not with hands waving in the air. The reason I ask is because we all seem to know what momentum is (mass times velocity.) Yet light has momentum and has zero mass. How can that be? Well, it can be if and only if you spend a great deal of thought on exactly your meaning for "momentum." Definitions matter!!! So what do you mean by "comparing phase?" Exactly, I mean. Commented Oct 6, 2023 at 16:25
• I'm not sure that what you're asking for is even theoretically possible, let alone practical without a serious amount of DSP. If a small phase change occurs while the sine wave is near its peak value, it's extremely difficult to detect the change within the time window you've specified. 200 µs is only 1.8° of phase change in a 25 Hz signal to begin with. The signals will need to be extremely clean (very high SNR) for this to have any chance of meeting your requirements. Commented Oct 6, 2023 at 19:26
• It's possible that this is an XY problem. Can you give us any clues at all about the application? Commented Oct 6, 2023 at 19:28

I am looking for a non microcontroller based solution for detecting instantaneous phase change between two sine waves with frequency 25 Hz

Look for a harmonic disturbance that isn't reflected in the other sinewave. That's what will happen with an instantaneous or even any reasonably sudden phase change.

Or, use a phase-locked loop and look for glitching in the control signal. Glitching would imply a sudden phase change.

Or, use a notch filter on the sinewave to filter it out completely. Any glitchy signal being present would imply a change in the sinewave due to a non-regular phase change.

• Not an answer within the parameters of the question. How could any of these approaches react within the specified 200 µs? Commented Oct 7, 2023 at 3:11

Update: With one PLL, one could do the job (with "some" difficulties).

The blue curve is the n=0 (no added phase).

And here is a zoomed view ...
If one could sample and save, response time could be in 100th of us.
The blue curve is the n=0 (no added phase), the continuation of the red at the left of point 1.00.

Old:
I should use two PLL (with 3600x multiplier) synchronized by the two signals (this can be "very" difficult ...) and measure difference of phase at the two outputs.