# Removing noise from an audio file only in time domain?

Hello I am doing some work for a course and I need to take an audio file and remove the noise from it. So far I've removed the noisy signal which is a 1000Hz pure tone using the frequency domain. I did some fourier transforms, found the ranges for my filter and voila its done.

However part of my assignment asks me to do this in two ways, implying that this can also be done in the time-domain. I'm confused as I just can't understand how I would remove a tone completely in the time domain without using frequencies.

My question is are there ways to remove noise from an audio file without using the frequency domain?

Here's the audio file if you'd like to listen for yourself: https://drive.google.com/file/d/1OM4OI4egSE7E5M2-l2WypUwtJ0pqEhaB/view?usp=sharing

I think the lesson being taught in your assignment is that multiplication in the frequency domain (as you had done by masking an FFT) is convolution in the time domain. Taking the inverse FFT and convolving that with the signal would result in a similar filtering of the tone. To note that using the FFT and inverse FFT results in circular convolution, rather than linear convolution. Ultimately it is the impulse response of the filter in the time domain that is convolved with the signal, which is equivalent in the frequency domain to the product of the Fourier Transform of the filter’s impulse response with the Fourier Transform of the signal.

• I think I remember reading something along the lines of this. So if I am understanding correctly multiplying my original signal by the Inverse Fourier Transform of my filtered signal would result in a signal in the time domain that does not have the high pitch sound. Commented Dec 14, 2021 at 17:01
• @KaasimShaikh almost but not quite--- you need to CONVOLVE in the time domain, which is the same as MULTIPLY in the frequency domain. Convolving the time domain signal with the inverse FFT after shifting the DC bin to the center of the array, and putting the second half of the array to the beginning (fftshift in MATLAB/Octave or Python Scipy.signal) will do this filtering you describe (although it is suboptimal, but sufficient for your purposes I believe). Commented Dec 14, 2021 at 18:17
• Okay that actually makes a lot of sense now. You are a life saver! Thank you :). Commented Dec 15, 2021 at 14:39
• Hey @DanBoschen I have one more question. I did exactly what you said and I was able to remove the tone but my professor being the tough cookie he is added another tone later in the signal. So I have 1 tone at 1100Hz and another tone at 2700Hz. I used a bandstop filter to remove the first tone at 1100Hz and convoluted the bandstop and the original signal. But how would I remove the 2700Hz signal? Would I filter it separately and then combine both filtered signals? Commented Dec 15, 2021 at 15:08
• I cannot thank you enough for your help. You pointed me in to the right direction and I am very grateful. I've successfully removed the sound using the convolution method. Thank you and have a good day. Commented Dec 15, 2021 at 16:32

There is no separate time domain or frequency domain. At least not in the practical, physical world. Those are just two different ways of analyzing one single reality.

A simple notch filter consisting of a biquad or two could be thought of as «time domain» but it will have consequences in the frequency domain that may be what you want.

A PLL or an adaptive filter might also accomplish what you want.