Weeklybeats is a 52 week long music project in which artists compose and publicly release 1 song a week for the entire year.
Starting January 1st 2024 GMT each participant will have one week to upload one finished composition. Any style of music or selection of instruments are welcomed and encouraged. Sign up or Login to get started or check our FAQ for any help or questions you may have.

WeeklyBeats.com / Music / Devieus's music / Mr. Markov I Presume

Mr. Markov I Presume

By Devieus on April 18, 2018 9:02 am

Markov chains, named after mathematician Andrey Andreyevich Markov, is a form of finite state machine that has no terminators and weighted connections. Read all about it here if you're so inclined, it's fun for comp-sci nerds but otherwise you needn't bother.

Basically it's a system of weighted decisions depending on the current state, or choosing an option based on the previous decision's outcome, which is basically the definition of procedural generation. And I used it for note lengths in the lead track, as it was always destined to be.

Say the note length of the current note is a half note, there'll be a 10% chance of the next note being a sixteenth, but if the current note's length is an eighth there'll be a 20% chance instead. That's the basic gist of it.

So that should settle the note length issue, maybe next time I'll bring back the harmony.

Audio works licensed by author under:
CC Attribution Share Alike (BY-SA)

Woah, loving how you're bringing logic-based systems into music, interesting study!

Mortistar wrote:

Woah, loving how you're bringing logic-based systems into music, interesting study!

Music theory can get quite intense.

Love that MML sound :>

cool, Did you write code to generate the note outcome or did you compose it yourself?

gpsychosis wrote:

Love that MML sound :>

MML is just a notation, Macrotune is providing the sounds.

yobkiss wrote:

cool, Did you write code to generate the note outcome or did you compose it yourself?

Composing is all the code does actually.

I am always puzzled that math can sound so beautyfull...

Eyyy, markov chains. Nifty outcome!

theGuen wrote:

I am always puzzled that math can sound so beautyfull...

Music in any form is math at the end of the day.

scottux wrote:

Eyyy, markov chains. Nifty outcome!

onezero suggested it. I'm sorta opposed to the idea, but note lengths are starting to require a binding in chains.

I like how music can be approached from a really analytical direction or a really intuitive one and awesome results can be achieved either way. 

Really smooth interlocking of the melodic and percussion lines. Kudos!

CosmicCairns wrote:

I like how music can be approached from a really analytical direction or a really intuitive one and awesome results can be achieved either way.

I imagine there're at least a few approaches more, but at least with analytical, you know what you're going to get.

Jim Wood wrote:

Really smooth interlocking of the melodic and percussion lines. Kudos!

Thanks, next time I'll be adding some manner of harmony.

It's very interesting to read about the theory behind the generation, thanks for including it in the description! If I understand correctly, does it also mean that the song will be different every time that it is composed?

Gab Manette wrote:

It's very interesting to read about the theory behind the generation, thanks for including it in the description! If I understand correctly, does it also mean that the song will be different every time that it is composed?

Yes. Such is the nature of all procedural generation, not just Markov chains.

Devieus wrote:
Gab Manette wrote:

It's very interesting to read about the theory behind the generation, thanks for including it in the description! If I understand correctly, does it also mean that the song will be different every time that it is composed?

Yes. Such is the nature of all procedural generation, not just Markov chains.

Very cool smile Do you take the first one out or do you run it a few times and pick one?

Gab Manette wrote:
Devieus wrote:
Gab Manette wrote:

It's very interesting to read about the theory behind the generation, thanks for including it in the description! If I understand correctly, does it also mean that the song will be different every time that it is composed?

Yes. Such is the nature of all procedural generation, not just Markov chains.

Very cool smile Do you take the first one out or do you run it a few times and pick one?

The program is still very much a work in progress, so I set up some goals and put those in. I then run the program and debug it until it outputs something that meets the goals. That's the one I go for. The output I put into Macrotune, process that output in Magix Video Sound Cleaning Lab for some effects and call it a day.

But the program itself I run as little as needed, running it a second time won't reliably produce better results, just different results.

I'm not sure if I'm doing something wrong but this is the second track I've had trouble getting to play.  It plays 3 notes then goes to silence and if I shuffle around the track it plays the same buffered 3 notes.  I tried in Safari & Firefox and even my phone.  Downloading the track also didn't allow me to hear it.  yikes Last week's track I heard with no problem but 'a timely matter' was the other track I couldn't get to play past the first note also. Me confusededed

Tone Matrix wrote:

I'm not sure if I'm doing something wrong but this is the second track I've had trouble getting to play.  It plays 3 notes then goes to silence and if I shuffle around the track it plays the same buffered 3 notes.  I tried in Safari & Firefox and even my phone.  Downloading the track also didn't allow me to hear it.  yikes Last week's track I heard with no problem but 'a timely matter' was the other track I couldn't get to play past the first note also. Me confusededed

Those times I used the same exporter with the same settings. It should work in Vivaldi.

Tone Matrix wrote:

I'm not sure if I'm doing something wrong but this is the second track I've had trouble getting to play.  It plays 3 notes then goes to silence and if I shuffle around the track it plays the same buffered 3 notes.  I tried in Safari & Firefox and even my phone.  Downloading the track also didn't allow me to hear it.  yikes Last week's track I heard with no problem but 'a timely matter' was the other track I couldn't get to play past the first note also. Me confusededed

Exact same for me too.

Yes, I can't get it to play.  Also, second one of your tracks this happened with.  The first was on April 1st so I thought it was an April Fools prank. 

Ryan wrote:
Tone Matrix wrote:

I'm not sure if I'm doing something wrong but this is the second track I've had trouble getting to play.  It plays 3 notes then goes to silence and if I shuffle around the track it plays the same buffered 3 notes.  I tried in Safari & Firefox and even my phone.  Downloading the track also didn't allow me to hear it.  yikes Last week's track I heard with no problem but 'a timely matter' was the other track I couldn't get to play past the first note also. Me confusededed

Exact same for me too.

NWSPR wrote:

Yes, I can't get it to play.  Also, second one of your tracks this happened with.  The first was on April 1st so I thought it was an April Fools prank.


Maybe it's time to set T80 on the case.

You need to login to leave a comment.
Login Sign-up