An app to generate weird loops

A couple of weeks ago I announced my new project on Patreon. Three times a week, I record some new music and publish it on there, at exactly 7am (CET). I call these “Morning Sounds”.They’re a great way to keep the creativity flowing and to explore ideas for “larger” compositions as well, and I love the idea of being able to share this process with those who want to be a part of it. It’s a very vulnerable thing to share though so most of it is only available to paying patrons. How much you wanna pay is however up to you.

Anyway on February 19 I published Morning Sound #9, called “Dodge”, and made it public for all 3 days later. As I was improvising a bass line I found it was heading the direction of some kind of variation on Magic Malik‘s XP. The perfect occasion to finally use a little app I made.

While still studying at the Conservatory I made a research paper about techniques used to vary the balance between improvisation and composition in contemporary jazz (called “Composing freely improvised music: A paper on compositional systems used by Ellery Eskelin and Magic Malik.“). Behind this was mostly a pretext to get into and analyze Eskelin’s and Malik’s work, while satisfying my study requirement…


I like Malik’s XP. It’s such a simple little idea that you can use in so many different ways. Here’s the idea. You take a rhythmic pattern and a melodic pattern. Then you loop them through each other to generate your new loop. Let’s say my rhythmic pattern is ABC and my melodic pattern, 12. The XP would be A1 B2 C1 A2 B1 C2. Very simple idea, very interesting results.

Recently as I’ve been getting deeper and deeper into programming, I developed a little web app to generate loops in this way. The app is not exactly a finished product as it still has a bunch of bugs I should tend to (and it’s not mobile-friendly… shame on me) but it’s generally functional. Functional enough for me to use anyway. The app’s right HERE if you want to try it.

Input your patterns in the “MATRIX” tab and the XP will appear in the “RESULTING LOOP” tab. You can also change the title and tempo in the “INFO” tab. The resulting loop can be seen as a printed score, and can be downloaded in midi.

The patterns have to be inputted in simplified “ABC” notation. All you need to know:

  • Fgives you a middle F.
  • fgives you an octave higher.
  • _Agives you an Ab.
  • ^Fgives you an F#.
  • 4gives you a quarter note
  • 8gives you an 8th note
  • Try numbers that are not powers of 2 to get dotted notes
  • There is no support for triplets so far. I had made a command-line python app that did but I haven’t translated that to javascript with the use of ABC yet. Implementing that forced me to research tuplets in a way I hadn’t before by the way and I learned a bunch of interesting things here.

Check out “Dodge”, the Morning Sound on which I made use of that little app, and see the score it generated and what was my original input.

Leave a Reply