FPGA Central - World's 1st FPGA / CPLD Portal

FPGA Central

World's 1st FPGA Portal

 

Go Back   FPGA Groups > NewsGroup > DSP

DSP comp.dsp newsgroup, mailing list

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 02-25-2004, 11:04 PM
Martin
Guest
 
Posts: n/a
Default RMS Power of audio digital signal

Hi to all, I would like to compute the so called RMS Power but it's not
simple
how seems to be.
RMS= square root ( sum of square (signal[k])/N) (1)
First thing is :some programs like Cool Edit calculate the RMS with a
negative number ( or zero) and since the square root (and the square) are
always greater or equal to zero
I think I must change something here.
The " unit " for RMS is decibel FS (the maximum value possible for RMS is 0
dB FS).
My signal is a sine wave in the range -32767,32767 with theoric RMS equal
to zero
( min,max and average RMS are zero,too).
Cool Edit analysis obtains exactly these values for this signal.
To compute the RMS by myself,I transform the signal
normalizing it,that is for each sample k compute
signal[k]=signal[k]/32767
and then taking the logarithm of the absolute values :
signal[k] =20*log10(abs(signal[k]))-0.7458 (the last one is a reference
costant).
Now I apply the equation (1) but I'm not able to find what to subctrat to
the calculate RMS to match Cool Edit's results .
Someone know where I'm wrong?



Reply With Quote
  #2 (permalink)  
Old 02-25-2004, 11:19 PM
Jon Harris
Guest
 
Posts: n/a
Default Re: RMS Power of audio digital signal

You should be doing equation (1) before you do the log conversion. The
order should be 1) normalize signal, 2) take RMS, 3) convert to dB.

CoolEdit's RMS numbers are in dB relative to full scale, calibrated for a
sinusoidal input. If you create a full-scale sine wave, you will see an RMS
value of 0dB (or very nearly so). If you create a full scale square wave,
you will see a +3dBFS RMS. Because of this, you will need to add a
correction factor based on the RMS value of a sine wave to match CoolEdit.
I think just adding 3dB to your final result is all that is required.

"Martin" <[email protected]> wrote in message
news:OZ8%b.33204$[email protected]..
> Hi to all, I would like to compute the so called RMS Power but it's not
> simple
> how seems to be.
> RMS= square root ( sum of square (signal[k])/N) (1)
> First thing is :some programs like Cool Edit calculate the RMS with a
> negative number ( or zero) and since the square root (and the square)

are
> always greater or equal to zero
> I think I must change something here.
> The " unit " for RMS is decibel FS (the maximum value possible for RMS is

0
> dB FS).
> My signal is a sine wave in the range -32767,32767 with theoric RMS equal
> to zero
> ( min,max and average RMS are zero,too).
> Cool Edit analysis obtains exactly these values for this signal.
> To compute the RMS by myself,I transform the signal
> normalizing it,that is for each sample k compute
> signal[k]=signal[k]/32767
> and then taking the logarithm of the absolute values :
> signal[k] =20*log10(abs(signal[k]))-0.7458 (the last one is a

reference
> costant).
> Now I apply the equation (1) but I'm not able to find what to subctrat to
> the calculate RMS to match Cool Edit's results .
> Someone know where I'm wrong?
>
>
>



Reply With Quote
  #3 (permalink)  
Old 02-26-2004, 01:06 AM
Martin
Guest
 
Posts: n/a
Default Re: RMS Power of audio digital signal

Yes! It works fine! Thank you for your help.


"Jon Harris" <[email protected]> ha scritto nel messaggio
news:c1j6mo$1jq139$[email protected]..
> You should be doing equation (1) before you do the log conversion. The
> order should be 1) normalize signal, 2) take RMS, 3) convert to dB.
>
> CoolEdit's RMS numbers are in dB relative to full scale, calibrated for a
> sinusoidal input. If you create a full-scale sine wave, you will see an

RMS
> value of 0dB (or very nearly so). If you create a full scale square wave,
> you will see a +3dBFS RMS. Because of this, you will need to add a
> correction factor based on the RMS value of a sine wave to match CoolEdit.
> I think just adding 3dB to your final result is all that is required.





Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
IP-cores for digital audio Holger Blum FPGA 2 07-22-2005 09:43 PM
digital audio storage cat DSP 1 02-21-2004 07:51 PM
New Digital Audio Standard? Randy Yates DSP 134 01-26-2004 01:25 AM
Digital Audio Mixing Algorithms? Alexander J. Oss DSP 4 01-15-2004 12:34 AM
My own digital audio standard Dr. O DSP 2 12-25-2003 06:14 PM


All times are GMT +1. The time now is 02:33 AM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Copyright 2008 @ FPGA Central. All rights reserved