Sign in

username or email:

password:



Not a member?
Forgot your password?

Search code



Search tips

Ads

See Also

Embedded SystemsFPGA

DSP Code Sharing > Average power of 1D signal

Average power of 1D signal

Language: Matlab

Processor: Not Relevant

Submitted by Senthilkumar R on Mar 24 2011

Licensed under a Creative Commons Attribution 3.0 Unported License

Average power of 1D signal


 

This program is used to calculate the average power of a voice signal

 
%Function to calculate the Average of a Voice signal
function [y] = pow_1(x)
N =  length(x);  % Length of voice signal 'x'
xold =0.0;       %initialize it to zero
for n = 1:N
    sumx = xold+(x(n)^2);
    xold = sumx;
end
y = sumx/N
 
Rate this code snippet:
0
Rating: 0 | Votes: 0
 
   
 
posted by Senthilkumar R



Comments


No comments yet for this code


Add a Comment
You need to login before you can post a comment (best way to prevent spam). ( Not a member? )