Originally posted on 20 December 2012.
Last year our eldest daughter (then 3, now 4), The Frogger, fell in love with the song “Rudolph the Red-Nosed Reindeer”. This year she is obsessed with “A Holly Jolly Christmas”. It is no coincidence that both songs are performed by Burl Ives in the Rankin/Bass classic Rudolph the Red-Nosed Reindeer.
Cut to me, in the car, frantically pushing buttons to cycle through CDs and play Burl Ives singing “A Holly Jolly Christmas” in order to fulfill the heartfelt request of my child. Experienced parents will know that there are a variety of potential motivations for such behavior beyond simply avoiding a tantrum, for example cutting short a half-hour of repeatedly yelling the same three lines of the song with 73.21% accuracy.
Having found the correct CD and as I pushed buttons to get to the right track, I began to wonder if I was taking the shortest route to my song of choice. There are three possible routes to any given track on my car’s CD player.
- x+1, in which I push the “next track” button repeatedly until I cycle forward to the song you want (eg, Track 1, Track 2, Track 3…).
- x-1, in which I push the “previous track” button repeatedly until I cycle backward to the song I want (eg, Track 1, Track 13, Track 12…).
- random, in which activate the “shuffle” function and push the “next track” button until it lands on my song (eg, Track 11, Track 4, Track 9…).
“A Holly Jolly Christmas” is the seventh track (i=7) of thirteen (N=13) on the first disc of the two-disc The Best of Christmas set (festooned with the delightful art of Thomas Kinkade).
Using the x+1 strategy, it takes six button pushes (n=6) to get to “A Holly Jolly Christmas” (CD automatically goes to Track 1), after I find the right CD (taking approximately 351 pushes). Using the x-1 strategy, it takes seven button pushes (n=7) to get there. In my case, the x+1 strategy is clearly superior to the x-1 strategy. This is true for all tracks before Track 8 (“Rockin’ Around the Christmas Tree” by Brenda Lee; i<8).
The “shuffle” function on my car’s CD player selects tracks from the album at random without replacement. This means that it picks tracks randomly from the set of tracks that it hasn’t played yet, until all the tracks on the album have been played. This is called What it does after that depends on the state of the “repeat” function.
The first song randomly chosen has a 1:13 chance of landing on the right song*. Assuming that the first song is not the right song, as is quite likely (ρ=92%), and I push the “next track” button, the next song has a 1:12 chance of being the right song. Cumulatively, I have a 15% chance that one of the first two songs was the right song. If I keep going to the six button pushes of the x+1 strategy, I have a 54% chance that one of the first seven songs played was the right song.
Indeed, the average number of button pushes need to get to Track 7 (or any track) on The Best of Christmas Disc One using the random strategy is six with substantial variation (n=6±3.9), whereas the x+1 and x-1 strategies always produce the same answer for a given track.
At this point, it is very important to consider what the initial state of your CD player’s “shuffle” function was. I generally keep mine “on”, because I like to be surprised by the next song. If the “shuffle” function is “off”, implementing the random strategy will require an additional button push, bringing the average value to seven (n=7). Conversely, if the “shuffle” function is “on”, implementing the x+1 will require an additional button push, bringing it to seven also (n=7).
Your results will vary depending on which track you want to listen to and how many tracks are on the album. For the song in the middle of an album (assuming your CD player’s “shuffle” function is “on”), the performance of the random strategy decreases as the number of songs on the album increases and appears to be converging on a 50% probability (again with huge variation between independent replications).
So for me (“shuffle” function “on”), the random strategy out-performs the x+1 strategy on average. I will have to tolerate a lot of variation in “time to song”, but, over the many repetitions I am guaranteed by my toddlers, I’ll come out ahead.
*This analysis is assuming that the “shuffle” function is truly random, which it is not. The fine distinctions are largely irrelevant for this particular example.