# What happens when we reconstruct a signal after its Fourier transform is done and some frequencies are altered? [closed]

Since we loose time information when we take a Fourier transform, what happens if we alter a few frequencies from the transform and then reconstruct the signal, do we get the altered frequency at the exact place the original frequency was(in time). Would it be beneficial if we use Wavelet transform or FFT? If yes, how?

## closed as unclear what you're asking by Marcus Müller, jojek♦Sep 9 '17 at 11:07

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

• You don't lose time information. The Fourier transform is bijective, there is zero information loss. Temporal characteristics of the signal might be harder to spot (hint: that is not even generally true, Fourier transform is even commonly used to estimate fine time shifts). Your question is unclear; what do you mean with "alter a few frequencies"? If we're taking about the continuous ft, then that would change nothing, because "a few" means "countably, even finite", and that means the energy change is zero. If we're talking about the DFT, then: can you please add formulas describing what you – Marcus Müller Sep 9 '17 at 8:09
• ... want to do? – Marcus Müller Sep 9 '17 at 8:09
• I was talking dft and i meant suppose i get 3 frequencies say 1,2 and 3 and i change 2 and make it 4 so does this mean that that time at which 4 occurs will be the same at which 2 occurred? – bababooty Sep 9 '17 at 8:17
• wait, do you mean "frequencies" or "values for a given frequency bin"? Precise wording makes a lot of difference here. Also, your sentence isn't clear to me. I meant it when I asked for formulas. – Marcus Müller Sep 9 '17 at 8:20
• What "benefit" are you looking for? – hotpaw2 Sep 9 '17 at 9:00

The spatial content is carried in the phase of the Fourier transform and not in magnitude. As Marcus pointed out, the difficulty with Fourier transform is that it doesn't allow us to immediately analyze the spatial information while still looking at the frequency. There are methods such as windowed FT which try to make that a bit better.

However, if you alter frequencies in the magnitude and reconstruct, you would get filtering effects. For instance, if we cut the low frequencies, than it would be a high-pass filter, and likewise, cutting high bands would cause a low-pass filter effect. This is analogous to applying, e.g. Mean/Gaussian filter to an image.

Regarding Wavelets, they try to address this time/frequency issue I mentioned above. Wavelets are limited in time and frequency. We slide the wavelets in time domain to construct the Wavelet domain. This provides resolution in the time domain.

On the application side, Wavelet denoising is shown to be superior to Fourier domain denoising. But, such superiority is application dependent, as for some applications one doesn't need that spatial analysis.

Here is an example, based on this one, where we do a low-pass filter by keeping only the low frequency values (both positive and negative):

% make our noisy function
t = linspace(1,5,1024);
x = -(t-2).^2  + 2;
y = awgn(x,0.5);
F = fft(y,1024);

freqRange = 20; % range of frequencies we want to preserve

rectangle = zeros(size(F));
rectangle(1:freqRange+1) = 1;       % preserve low positive frequencies
y_half = ifft(F.*rectangle,1024);   % +ve low-pass filtered signal
rectangle(end-freqRange+1:end) = 1; % preserve low negative frequencies
y_rect = ifft(F.*rectangle,1024);   % full low-pass filtered signal

figure;
plot(t,y,'g--');
hold on, plot(t,x,'k','LineWidth',2);
hold on, plot(t,y_half,'b','LineWidth',2);
hold on, plot(t,y_rect,'r','LineWidth',2);
legend('noisy signal','true signal','positive low-pass','full low-pass','Location','southwest');


The resulting signals look like this: You could see here that the altered frequencies effect the whole signal - wherever a high frequency existed gets smoothed. The spatial content is preserved in reconstructing the signal, because FT is a loss-less transformation, but we didn't get the chance to modify the exact spatial locations - the whole signal is effected by a change to the FT magnitude.

• Could you please elaborate on the spatial effect of filtering. – bababooty Sep 9 '17 at 8:24
• Which aspect would you like to hear more? Are you curious of what those filters are or how to do that operation? – Tolga Birdal Sep 9 '17 at 8:26

Time information is not lost by a DFT. The information about any one transient in time is spread out among ALL the phase information of every frequency bin of a DFT result. But it's still there, and returned by doing a IDFT.

Modifying a single bin can have unknown or arbitrary effects on any time localized transient, either making it bigger or smaller or earlier or later, etc., depending on exactly how the phase of that single frequency bin relates to and contributes to all the other frequency bins (magnitudes and phases) to represent that localized time event.

Different frequencies and phases have different effects, so moving them around is unlikely to generate the same signal in time. Filters change signals.