DSPRelated.com
Forums

Problems with Sonogram

Started by Rock Lobster January 15, 2008
Or would it be the correct way to use the 23 bit amplitude data directly as
x values? Not rescaling them, just using them the way they are?
Rock Lobster wrote:
> Or would it be the correct way to use the 23 bit amplitude data directly as > x values? Not rescaling them, just using them the way they are?
Almost, but not quite. They are almost certainly signed numbers, which makes the most-significant bit a sign. (0; positive, 1; negative.) You need to learn a little math. For example, logarithms aren't hard to use, and you don't need much theoretical underpinning to manipulate them. Logarithms can have different bases. They are the inverse of numbers raised to fixed powers, and different powers correspond to different logarithmic bases. For the moment, consider only base 10. log10(x) = y is another way to write x = 10^y. It follows from that that if we know that y = 2.3, then x must have two digits to the left of the decimal point because 10^2 is 100 and 10^3 is 1000, and 10^2.3 is somewhere between. In fact it is very close to 200. And since (a^u)*(a^v) = a^(u+v), adding the logarithms of two numbers gives the logarithm of those numbers product. Play with it a bit, and you'll see that 1.3 is the logarithm of (about) 20 and .3 is the logarithm of (about) 2. The logarithm of 10 is by definition 1, so 1 - .3 = .7 is the logarithm of (about) 5. When that sits comfortably, you know logs. Frabjous joy! Scaling numbers is adding a constant to their logarithms. Jerry -- Engineering is the art of making what you want from things you can get. �����������������������������������������������������������������������