<div dir="ltr">OK, that's clear, thanks. Still when using [tabread4~] or [tabosc4~] you still need a copy of the last element in the first index and copies of the first two elements in the last two indices, right? Even if you're not using sinesum or cosinesum but some other mathematical function..<br>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Sep 5, 2013 at 1:56 PM, IOhannes m zmoelnig <span dir="ltr"><<a href="mailto:zmoelnig@iem.at" target="_blank">zmoelnig@iem.at</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">-----BEGIN PGP SIGNED MESSAGE-----<br>
Hash: SHA1<br>
<div class="im"><br>
On 2013-09-05 09:45, Alexandros Drymonitis wrote:<br>
> OK, index 0 is the negative of index 2,<br>
<br>
</div>no not really, they just happen to be the same.<br>
<div class="im"><br>
> which can again make sense as it's a sine (supposing that index 0<br>
> is a copy of the table's last element), but index 512 doesn't have<br>
> that value, why? And why do indices 1 and 513 have different values<br>
> too?<br>
<br>
</div>do they?<br>
<br>
when it comes to floating point, "equality" becomes a little bit fuzzy.<br>
e.g. "0.1" is really the 'same' as "0.100000001490116119384765625" [1].<br>
<br>
comparing the values, you can see that they are not *very* wrong:<br>
<br>
array[512]-array[0] = -5.30668e-6 = -0.0000053<br>
array[513]-array[1] = -5.30718e-6 = -0.0000053<br>
array[514]-array[2] = -5.30668e-6 = -0.0000053<br>
<br>
so the errors are really rather small, and hopefully don't matter so<br>
much in the interpolation (which is another approximation anyhow).<br>
<br>
the reason why the error is not smaller, is that Pd internally<br>
(src/g_array.c:896) deals with a PI value of 3.14159, which is a<br>
rather rough estimate and is the reason why the cycle is not exactly<br>
512 points long.<br>
<br>
<br>
fgamsdr<br>
IOhannes<br>
<br>
[1]<br>
<a href="http://en.wikipedia.org/wiki/Floating_point#Representable_numbers.2C_conversion_and_rounding" target="_blank">http://en.wikipedia.org/wiki/Floating_point#Representable_numbers.2C_conversion_and_rounding</a><br>
-----BEGIN PGP SIGNATURE-----<br>
Version: GnuPG v1.4.14 (GNU/Linux)<br>
Comment: Using GnuPG with Icedove - <a href="http://www.enigmail.net/" target="_blank">http://www.enigmail.net/</a><br>
<br>
iEYEARECAAYFAlIoY3UACgkQkX2Xpv6ydvTY1wCcDCyH8kY50snbVOv5AxwspIAB<br>
jwQAoLJOrVoESvzyqrZyvWKky0ec1eUT<br>
=YqkS<br>
-----END PGP SIGNATURE-----<br>
<br>
_______________________________________________<br>
<a href="mailto:Pd-list@iem.at">Pd-list@iem.at</a> mailing list<br>
UNSUBSCRIBE and account-management -> <a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/listinfo/pd-list</a><br>
</blockquote></div><br></div>