The Music Goes Round And Round


So. The really big flaw in my analysis of an “Infinite Jukebox” tune — one in which the song is free to jump between two points, with a probability of \frac13 of jumping from the one-minute mark to the two-minute mark, and an equal likelihood of jumping from the two-minute mark to the one-minute mark — and my conclusion that, on average, the song would lose a minute just as often as it gained one and so we could expect the song to be just as long as the original, is that I made allowance for only the one jump. The three-minute song with two points at which it could jump, which I used for the model, can play straight through with no cuts or jumps (three minutes long), or it can play jumping from the one-minute to the two-minute mark (a two minute version), or it can play from the start to the second minute, jump back to the first, and continue to the end (a four minute version). But if you play any song on the Infinite Jukebox you see that more can happen.

Most importantly, the song can jump back every time it hits the two-minute mark. So we need to consider not just the cases where the song skips forward and where it skips back one minute, but also the chance where it skips back a minute, plays, and then skips back a minute again; or where it skips back twice, or skips back three times, or, in theory, infinitely many times. It’s not very likely it’ll loop ten thousand times from the second minute back to the first, but it’s possible. We have, once again, an expectation value problem.

There’s a chance of \frac13 the song is shortened by one minute, the jump from the one-minute to the two-minute mark. There’s a chance of \frac13 the song is lengthened by one minute, jumping from the two-minute to the one-minute mark. There’s a chance of \frac13^2 that the song jumps back twice, if it’s always the same probability of jumping back at all; this adds two minutes to the playing time. There’s a chance of \frac13^3 of the song jumping back three times, adding three minutes to the play time. There’s a chance of \frac13^4 of adding four minutes, and so on. We can write this up as an infinite series:

(-1)\frac13 + \frac13 + \frac13^2 + \frac13^3 + \frac13^4 + \frac13^5 + \frac13^6 + \cdots

After that first term, the one with the minus one, what’s left is a nice and familiar pattern called a geometric series. It’s an infinite series and since each term is one-third of the one before it, we know it converges. The easiest way to deal with this is to figure out the sum of that infinite series first, and then subtract that (-1)\frac13 afterwards.

The sum of a geometric series is the first term in the series (here, that’s one-third again) divided by the difference between one and the ratio between terms (here, that’s one minus one-third, or, two-thirds). So the sum of all those terms after the first is going to be one-third divided by two-thirds, or one-half. One-half plus that nagging little minus one-third gives us one-sixth. This suggests that we could expect, on average, this Infinite Jukebox model to give us a song that’s one-sixth of a minute longer than the original. Ten seconds doesn’t seem very infinite, but it’s a start.

One smaller flaw in my analysis might be considered nitpicking: how do we know that it’s just as likely to jump backward as to jump forward? If we’re looking for a routine that makes the song play much longer than average, it’s to our benefit to make jumping backwards more likely than jumping forward is. I started out with the chance of jumping forward equal to the chance of jumping backward, but there’s no reason that has to be. Suppose the chance of jumping forward stays at one-third, but that we increase the chance of jumping back to four-fifths, that is, at the two-minute mark there’s always an 80 percent chance of jumping back.

Well, then we have a one-third chance of losing a minute; but we have a four-fifths chance of gaining a minute, and then a four-fifths-squared chance of gaining two minutes, a four-fifths-cubed chance of gaining three minutes, and so on. The expected value of the addition to the song’s length becomes:

(-1)\frac13 + \frac45 + \frac45^2 + \frac45^3 + \frac45^4 + \frac45^5 + \frac45^6 + \cdots

That’s another oddball term plus a geometric series. The sum of the geometric series is the first term, four-fifths, divided by the difference between one and the ratio between terms, one minus four-fifths or simply one-fifth. So that geometric series works out to be four-fifths divided by one-fifth, or four. Subtract the oddball term and this case, where jumping back is so much more likely, can be expected to play three and two-thirds minutes longer than the original. That’s doing better.

There’s at least one more nagging oversight, though, that has to be considered before we can really say we understand how the jukebox might play with just the two possible jumps, and before we can start thinking about actual songs and their tangled maze of jumps.

Advertisements

Author: Joseph Nebus

I was born 198 years to the day after Johnny Appleseed. The differences between us do not end there.

One thought on “The Music Goes Round And Round”

Please Write Something Good

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s