Set cells in matrix equal to sqrt(10^-7), when the cells of the fft of the matrix obey 20.log10(abs(mat_tau))<=-20
조회 수: 1 (최근 30일)
이전 댓글 표시
I have a complex matrix mat_tau. I want for the cells of mat_tau which obey 20.log10(abs(mat_tau))<=-20 to equal to -70, and the same cells in ifft (mat_tau) to equal sqrt(10^-7). How can I do that?
댓글 수: 4
dpb
2022년 10월 23일
Doesn't matter what the value is, destroying the symmetry and values of the FFT will muck up the IFFT drastically.
Unless the input signal is composed of simple sinusoids at the precise frequencies of the FFT bins, then zero-ing out bins in the frequency domain is equivalent to convolving the signal in the time domain with a series of overlapping rectangular windows at those frequencies. This will end up causing "ringing" in the inverse FFT.
Another way to think of it is that removing a given frequency bin is the same as adding the component at that frequency but with opposite phase. This also can be seen to be a bad idea in the time domain.
답변 (1개)
Nikhil
2022년 10월 27일
You can use logical indexing.
mat_tau(20.*log10(abs(mat_tau))<=-20) = -70
Similarly for any matrix.
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Fourier Analysis and Filtering에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!