Phase shift in frequency domain

AI Thread Summary
The discussion revolves around simulating phase shifts in the frequency domain using MATLAB. The user initially attempts to apply a phase shift formula directly, but encounters issues when needing to work with the real and imaginary parts of the FFT output. After clarification, it is revealed that the correct approach involves calculating the shifted real and imaginary parts using trigonometric functions. The user successfully implements the revised formulas, which correctly compute the phase shift. The solution resolves the initial problem, allowing for accurate results in the time domain.
Eng_Pat
Messages
2
Reaction score
0
Hello,

I'using Matlab to simulate phase shift in frequency domain (FD).
I have got real and imaginary parts of the signal after FFT.
I'd like to use phase shift in FD.

This works:
Y=fft(y);
YY=Y.exp(-i*2*pi*nk/N*samples_delay);
result=ifft(YY);

But in my DSP I can't use the formula above and I need to use real and imaginary parts from fft signal.

I supposed exp(-i*2*pi*nk/N*samples_delay) can be transferred to this:

Shifted real part = re*cos(2*pi*nk/N*samples_delay)
Shifted imaginary part = im*sin(-2*pi*nk/N*samples_delay)

Then I transferred it back to time domain but result is inccorect.

Could anybody help me?

Thank you
 
Physics news on Phys.org
Think about what you are doing. Is it true that(a + ib) (x + iy) = ax + iby?
 
  • Like
Likes sophiecentaur
Eng_Pat said:
Shifted real part = re*cos(2*pi*nk/N*samples_delay)
Shifted imaginary part = im*sin(-2*pi*nk/N*samples_delay)
From what I understand, you actually want to calculate the real and imaginary parts of YY, am I right? Then you have to calculate Re[Y.exp(-i*2*pi*nk/N*samples_delay)] and Im[Y.exp(-i*2*pi*nk/N*samples_delay)]. Consider this
$$ Ze^{i\theta} = (Re[Z] + i Im[Z])(\cos(\theta)+i\sin(\theta) ) $$
Calculate the last expression to see which are the right real and imaginary parts of ##Ze^{i\theta}##.
 
Thank you for your answers.
I din't reliaze that so the right code for MATLAB is this:

Shifted real part = re.*cos(2*pi*nk/N*samples_delay)+im.*sin(2*pi*nk/N*samples_delay)
Shifted imaginary part = re.*sin(2*pi*nk/N*samples_delay)+im.*cos(2*pi*nk/N*samples_delay)

It's working right now.

Thank you very much
 
Thread 'Motional EMF in Faraday disc, co-rotating magnet axial mean flux'
So here is the motional EMF formula. Now I understand the standard Faraday paradox that an axis symmetric field source (like a speaker motor ring magnet) has a magnetic field that is frame invariant under rotation around axis of symmetry. The field is static whether you rotate the magnet or not. So far so good. What puzzles me is this , there is a term average magnetic flux or "azimuthal mean" , this term describes the average magnetic field through the area swept by the rotating Faraday...
Back
Top