back to list

HE with compact support

🔗genewardsmith <genewardsmith@sbcglobal.net>

10/1/2011 9:58:15 AM

I asked this on Facebook but didn't get an answer which made any sense to me. It's this: what happens if we replace F(x) = exp(-x^2) with bump functions such as

F1(x) = exp(-x^2-1/(1-x^2/9))

or

F2(x) = exp(-x^2-1/(1-x^4/81))

I would really like a sensible answer to why this is not a good idea, which neither Paul nor Mike has so far provided.

🔗genewardsmith <genewardsmith@sbcglobal.net>

10/1/2011 10:06:53 AM

--- In tuning-math@yahoogroups.com, "genewardsmith" <genewardsmith@...> wrote:
>
> I asked this on Facebook but didn't get an answer which made any sense to me. It's this: what happens if we replace F(x) = exp(-x^2) with bump functions such as
>
> F1(x) = exp(-x^2-1/(1-x^2/9))
>
> or
>
> F2(x) = exp(-x^2-1/(1-x^4/81))

I forgot to add that if |x|>3 then F1(x) = F2(x) = 0.

🔗Mike Battaglia <battaglia01@gmail.com>

10/1/2011 10:25:13 AM

On Sat, Oct 1, 2011 at 12:58 PM, genewardsmith
<genewardsmith@sbcglobal.net> wrote:
>
> I asked this on Facebook but didn't get an answer which made any sense to me. It's this: what happens if we replace F(x) = exp(-x^2) with bump functions such as
>
> F1(x) = exp(-x^2-1/(1-x^2/9))
>
> or
>
> F2(x) = exp(-x^2-1/(1-x^4/81))
>
> I would really like a sensible answer to why this is not a good idea, which neither Paul nor Mike has so far provided.

It's a fine idea. I was responding to your notion that infinite tails
are physically and auditorially meaningless.

But if you're going to do that, you can also just use a Gaussian
that's truncated two standard deviations away from the mean. If you
compute HE with this, and plot the results against a non-truncated
Gaussian version, you'll get something imperceptibly close to a line.

If you really want to speed up HE, here's an idea: for every real
number, try considering just the convergents to it. For example, 400
cents is 2^(400/1200) in linear frequency space, and the continued
fraction approximation to this is

1.2599210498948732 is approximated best by:
3/2=1, 2 = 1.5000000 err=0.2400789501051268
4/3=1, 3 = 1.3333333 err=0.07341228343846007
5/4=1, 4 = 1.2500000 err=-0.00992104989487319
19/15=1, 3, 1, 3 = 1.2666666 err=0.006745616771793417
24/19=1, 3, 1, 4 = 1.2631578 err=0.0032368448419688445
29/23=1, 3, 1, 5 = 1.2608695 err=0.000948515322518162
34/27=1, 3, 1, 6 = 1.2592592 err=-0.0006617906356138903
63/50=1, 3, 1, 5, 2 = 1.2600000 err=0.00007895010512681822
160/127=1, 3, 1, 5, 1, 1, 2 = 1.2598425 err=-0.00007853020983383807
223/177=1, 3, 1, 5, 1, 1, 3 = 1.2598870 err=-0.00003404424515562887
286/227=1, 3, 1, 5, 1, 1, 4 = 1.2599118 err=-0.000009155621745415843
349/277=1, 3, 1, 5, 1, 1, 5 = 1.2599277 err=0.000006747939061746422
635/504=1, 3, 1, 5, 1, 1, 4, 2 = 1.2599206 err=-4.149742383052768e-7
3524/2797=1, 3, 1, 5, 1, 1, 4, 1, 1, 5 = 1.2599213 err=2.944025883078183e-7
4159/3301=1, 3, 1, 5, 1, 1, 4, 1, 1, 6 = 1.2599212 err=1.8609422092197292e-7
4794/3805=1, 3, 1, 5, 1, 1, 4, 1, 1, 7 = 1.2599211 err=1.0647831993892964e-7
5429/4309=1, 3, 1, 5, 1, 1, 4, 1, 1, 8 = 1.2599210 err=4.548688581351712e-8
6064/4813=1, 3, 1, 5, 1, 1, 4, 1, 1, 9 = 1.2599210 err=-2.730942139095305e-9

I bet that'll yield indistinguishably close results to HE.

-Mike

🔗genewardsmith <genewardsmith@sbcglobal.net>

10/1/2011 10:38:42 AM

--- In tuning-math@yahoogroups.com, Mike Battaglia <battaglia01@...> wrote:

> I bet that'll yield indistinguishably close results to HE.

Could be. If it isn't, you could try the semiconvergents.

🔗Mike Battaglia <battaglia01@gmail.com>

10/1/2011 11:33:52 AM

OK, something else. Consider the continued fraction approximation for this:

6064/4813 = [1; 3, 1, 5, 1, 1, 4, 1, 1, 9]

Let's say that we wanted to derive some sort of measure of interval
complexity that has the following characteristics:
1) it works on the continued fraction representation of an interval
2) it's set up so that coefficients to the right of the matrix are
weighted less than intervals on the left

The obvious function that comes to mind is ?(x), which we already went
over. We found that it yielded ridiculous-looking results. This is
because ?(x), and any other function that works on continued fraction
denominators, are related to seeding HE with the Stern-Brocot tree.
This looks silly:

/tuning-math/files/MikeBattaglia/HE%20Optimizations%20test%202/HEsbtree.png

and here was ?(2^x) just convolved directly with a gaussian and differentiated

/tuning-math/files/MikeBattaglia/%3F(x)%20convolved%20with%20g(x)/questconvlins17.png

This behavior, which obviously doesn't reflect anyone's auditory
system at all, results because if you take all the rationals up to
some depth in the SB tree, small and complex ratios like are generated
at a faster pace than simple ratios.

This is what I basically don't like about HE as currently formulated:
it's hypersensitive to the way you seed it, so that using different
ways to subset the rationals ends up leading to completely different
looking curves. The biggest problem is that this holds true even as
you progressively extend the subsets to include all the rationals.

So another, unofficial "free parameter" in HE is whether or not you're
bounding the rationals by n*d < N, or d < N, or by a certain number of
levels in the SB tree, etc. And then, when you give each interval a
"domain", the way Paul does it with mediants ends up making it such
that you've just ended up giving each interval a complexity, after all
that hassle.

Each of these different ways to define subsets of the rationals turn,
in the limiting case, into different measures that you can integrate
with respect to
(http://en.wikipedia.org/wiki/Riemann%E2%80%93Stieltjes_integral). I
think that some better insight into how these measures are related to
interval complexity will make all of this a lot simpler, and could
pave the way towards getting a linear time calculation together for
HE.

-Mike