필터 지우기
필터 지우기

Computing Sliding Window DFT on a digital sequece

조회 수: 2 (최근 30일)
SUBHAJIT KAR
SUBHAJIT KAR 2019년 6월 3일
Hi all,
I want to compute sliding window DFT of a numeric sequence. Hence I have written the code. Running the code showing an error as "Index exceeds matrix dimentions" error in x1 = x(i:i+351-1); x is the given sequence.
n = length(x);
n =1;
for i =1:1:n-1
x1 = x(i:i+351-1);
A = abs(fft(x1));
S = A.^2;
snr = max(S)/mean(S);
y(ceil(i/h)) = snr;
end
plot(y)
I want plot the snr values for every window length with respect to the index values. Any help will be appreciated. How to correct it?

답변 (0개)

카테고리

Help CenterFile Exchange에서 Correlation and Convolution에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by