Re: [LAU] OT(ish): Strange coding problem (audio related)

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: linux-audio-user <linux-audio-user@...>
Date: Friday, January 28, 2011 - 1:02 pm

Excerpts from Peter Nelson's message of 2011-01-28 13:03:56 +0100:

Thanks Peter, this section was supposed to refer to the output of the
test program. cout printed 11 for both values but 4.80518e-16 for one
value minus the other, so this at least a very nasty inconsistency.

I still don't understand why this results in 11 on some machines and
something else on others. 32/64 bit? Compiler differences? Luck?

rant_begin
Why can't log mean the same thing everywhere? Why does it need to be
base e here and base 10 there? Why is there no consistency?
And why is there no proper logarithmus dualis function? Because you
can simply do log(n)/log(2)? We've just seen how well this works.
How about:
log() - base 10
ln() - base e - logarithmus naturalis
ld() - base 2 - logarithmus dualis
rant_end

The next obvious question is: Does the inaccuracy reliably result in
values bigger than 11?

_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@lists.linuxaudio.org
http://lists.linuxaudio.org/listinfo/linux-audio-user

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[LAU] OT(ish): Strange coding problem (audio related), James Stone, (Fri Jan 28, 12:35 am)
Re: [LAU] OT(ish): Strange coding problem (audio related), Gabriel M. Beddingfield, (Fri Jan 28, 3:01 am)
Re: [LAU] OT(ish): Strange coding problem (audio related), Philipp Überbacher, (Fri Jan 28, 11:29 am)
Re: [LAU] OT(ish): Strange coding problem (audio related), Peter Nelson, (Fri Jan 28, 12:04 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Philipp Überbacher, (Fri Jan 28, 1:02 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Philipp Überbacher, (Sat Jan 29, 11:07 am)
Re: [LAU] OT(ish): Strange coding problem (audio related), Peter Nelson, (Sat Jan 29, 12:47 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Philipp Überbacher, (Sun Jan 30, 1:29 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Philipp Überbacher, (Sun Feb 13, 3:30 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Philipp Überbacher, (Sat Jan 29, 12:22 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Peter Nelson, (Sat Jan 29, 12:54 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Philipp Überbacher, (Sun Jan 30, 1:46 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Gabriel M. Beddingfield, (Fri Jan 28, 2:40 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Gabriel Beddingfield, (Fri Jan 28, 12:28 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Peter Nelson, (Fri Jan 28, 12:41 pm)
Re: [LAU] OT(ish): Strange coding problem (audio related), Gabriel M. Beddingfield, (Fri Jan 28, 2:31 pm)