필터 지우기
필터 지우기

How to find energy of a signal for a given range.

조회 수: 1 (최근 30일)
SUBHAJIT KAR
SUBHAJIT KAR 2017년 10월 10일
편집: SUBHAJIT KAR 2017년 10월 10일
I have a binary sequence. I have applied IIR Butterworth bandpass filter to the signal and plot the output with respect to the index of the input sequence.The index vary from 0 to 8000. Now I want to calculate the energy of output for index range 500 to 800 and 1200 to 1500.The code for the problem is
if true
% code
end
R = 0.992;
theta = (2*pi)/3;
b = [1 0 -1];
a = [1 -2*R*cos(theta) R^2];
u = filtfilt(b,a,x);
Y = abs(u).^2;
window = 30;
h = gausswin(2*window+1)./window;
Z = filter(h,1,Y);
P = Z/max(Z);
hold on
plot(P);
axis([0 8000 0 1.05])
Now I want to find the total energy of P for the ranges 500 to 800, 1200 to 1500 and 5400 to 6000. Is it possible? please suggest.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Smoothing and Denoising에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by