How to find energy of a signal for a given range.
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
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 commentaires
Réponses (0)
Voir également
Catégories
En savoir plus sur Multirate Signal Processing dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!