Forums

how I measure the phase btween two signals in frquencie domain

Started by signal June 24, 2005
Hi,
I have two signals
s1(t)=sin(w*t)
s2(t)=sin(w*t+phi),
I want to measure phi in frequencie domain.
I know some technics in temporal domain like cross correlation, ....
please can you help me to find method to calculate the phase phi in
frequencie domain.

thank you.


		
This message was sent using the Comp.DSP web interface on
www.DSPRelated.com
relative phase = arctan((sin(w*t)*sin(w*t+phi))/(sin(w*t)*cos(w*t+phi)))

"signal" <monirov@hotmail.com> wrote in message 
news:BrGdnUyWv8ix_SHfRVn-jw@giganews.com...
> Hi, > I have two signals > s1(t)=sin(w*t) > s2(t)=sin(w*t+phi), > I want to measure phi in frequencie domain. > I know some technics in temporal domain like cross correlation, .... > please can you help me to find method to calculate the phase phi in > frequencie domain. > > thank you. > > > > This message was sent using the Comp.DSP web interface on > www.DSPRelated.com
"signal" <monirov@hotmail.com> wrote in message 
news:BrGdnUyWv8ix_SHfRVn-jw@giganews.com...
> Hi, > I have two signals > s1(t)=sin(w*t) > s2(t)=sin(w*t+phi), > I want to measure phi in frequencie domain. > I know some technics in temporal domain like cross correlation, .... > please can you help me to find method to calculate the phase phi in > frequencie domain. >
Assuming that you have a reasonably long record, compute a Finite Fourier Transform of each. Each will have a peak amplitude at w. Each will have a phase value at w. Take the difference between the phase values. You may have to unwrap the phase to do this in a meaningful way.... that is, you may need to add k*2*pi radians to the phases (where k is an integer) in order to assure there are no "jumps" of 2*pi radians in the results you are working with. If you know w, then you might make the length of the finite time record an integer multiple of 1/w. I didn't mention sampling yet... If the time record is of N samples with sampling interval T, then the finite time record will be NT seconds long (assuming an interval of T seconds exists beyond the last sample). This will result in a Discrete Fourier Transform with frequency sample interval of 1/NT. You might like a frequency sample to occur at w. If so, you make w=k/NT and NT=k/w as above. Then the Finite, Discrete Fourier Transform will result in a frequency sample at exactly w. You might even compute just that one sample using the Goertzel algorithm or some such thing. Fred