Bogosort Sheds Arabesque No. 1 Until it Sorts the List
Вставка
- Опубліковано 5 бер 2024
- Bogosort plays over the changes to Debussy's "Arabesque No. 1" until it sorts the list.
The chord changes are from the first 16 bars of Arabesque No. 1 (looped).
________
The Bogosort algorithm is as follows:
1. Randomly shuffle the list.
2. Check if the list is sorted.
3. If not, go back to 1.
For a list of n elements, there is a 1/n! chance that Bogosort successfully sorts the list on any given pass, since there are n! (n factorial) possible permutations of the list. So with six elements, the probability of the list being sorted on any given pass is 1/6! = 1/720 ≈ 0.00139.
In this instance, the algorithm took 1051 passes to sort the list.
The six elements of the list are mapped to notes of a specific scale or chord, depending on which chord is being played in the progression.
The shuffling algorithm used is the Fisher-Yates Shuffle, from lowest index to highest. The note played is the value of the element at the current index in the outer for-loop of the shuffle algorithm.
________
Interested in learning more about algorithms and how to program? Here are some useful and/or classic textbooks that I recommend (these are affiliate links, if you buy one, I get a small commission):
▶ “Algorithms” (4th Edition) by Robert Sedgewick & Kevin Wayne: amzn.to/3uo25xR
▶ “Effective Java” (3rd Edition) by Joshua Bloch: amzn.to/3HOnYJL
▶ “Python Crash Course, 3rd Edition: A Hands-On, Project-Based Introduction to Programming” by Eric Matthes: amzn.to/481jQ43
▶ “Design Patterns: Elements of Reusable Object-Oriented Software” by Erich Gamma, Richard Helm, Ralph Johnson, & John Vlissides: amzn.to/49fpr7R
▶ “Discrete Algorithmic Mathematics” by Stephen B. Maurer & Anthony Ralston: amzn.to/4bmsOvG
#debussy #algorithm #music #musictheory #piano #classical #impressionist #arabesque #meme #random #randomness #improvisation #bogosort #sortingalgorithm #sorting #visualization #computerscience #programming #code #satisfying #asmr #scrollingscore #transcription #hypnotic #lullaby #sleepmusic #sleepingmusic #studymusic #focusmusic
love these videos so much
Callate
If one listens closely and I mean really closely, one can hear, that's right, one can hear that the note that you hear, yes, that is right, you got it. Now aren't thou just amazed by that, that was the point and you got it, now isn't that just truly amazing!
Magic. At 75% speed this gets a little abstract. At 50%, With some rubato, it would sound like Part.
suggestion: bogosort plays the arpeggio in another medium by toby fox
Wow thats long
The Bach one was longer
@@majorse203 oh yeah
@@majorse203 One cannot mock Bach, otherwise there will be a block which may break the clock.
"debussy"