An algorithm to create a simple chord progression

蹲街弑〆低调 提交于 2019-12-05 04:06:12

Sounds like you need to break this into phases:

  • Firstly, generate a triad randomly from all the possibilities of this key
  • Secondly, apply one or more filters to eliminate ones that don't "sound decent"(*).
  • Keep going until you've got 4 triads that pass all the filters.

I think this solution might end up being pleasant to work on too - you can slowly build up a collection of filters, each which does one simple thing - but put together, you gradually work out what it is that defines "decent".

(*) The sounds decent is defined in terms of with reference to the previous triad(s) (if there are any), and this is where you could write filters like:

  • Does the root note of the triad fit on a logical pattern relative to the previous root notes?; examples:

    • Simple ascending
    • Simple descending
    • Ascending in thirds
    • etc
  • Do the notes of this triad have at least one common note with the previous triad?

    • this could find some pleasant-sounding inversions
  • Is the "jump" from the previous triad "less than" some given threshold?

    • to avoid jarring jumps all over the scale
    • simply achieved by summing the MIDI note values of the triad and comparing with previous

You could check these papers

Generating Music Using Concepts from Schenkerian Analysis and Chord Spaces

and A Probabilistic Model for Chord Progressions

But this subject is complex as you want it to be, for example, let us say that accurate and compact representation of music signals is a key component of large-scale content-based music applications such as music content management and near duplicate audio detection. In this case You are working on C major scale which goes like:

C - D - E - F - G - A - B

which has the intervals

C - STEP - D - STEP - E - HALF STEP - F - STEP - G - STEP - A - STEP - B - HALF STEP - C - 

Now a chord is formed by distance between notes for example

C major chord is formed by C-E-G
D minor chord is formed by D-F-A
E minor chord is formed by E-G-B
F major chord is formed by F-A-C
G major chord is formed by G-B-D
A minor chord is formed by A-C-E
B dim   chord is formed by B-D-F

The problem you describe is not well solved yet despite many research efforts in this field. So for instance take a look at other papers where they suggest mid-level summarization of music signals based on chord progressions. So chord progressions are recognized from music signals based on a supervised learning model, and recognition accuracy is improved by locally probing n-best candidates.

So you can investigate the properties of chord progressions, then calculate a histogram from the probed chord progressions as a summary of the music signal. Then with a chord progression-based summarization you can describe harmonic progressions and tonal structures of music signals.

But how to do it?, well you need music datasets ( > 70,000 songs ??) so you can retrieve relevant information...

Actually that's quite an interesting question.

I would say that one more thing needs to be considered and understood here: What would you like to say (i.e.: express) with your chord progression? I assume that you would like to express "something meaningful" with your melodies and with the supporting chord progression.

Now, "something meaningful" is not an exact term. Personally I would describe this term as something whole, something complete, as a short story. It can be as brief as 4 chords, but it should tell something and should add up to a full story. If we accept this then I would say that your 4 chord should "lead" from the beginning till the end, and we should "feel" the last chord as it was a satisfying ending (resolution) of the "story".

The hard part is that for every human, the terms "satisfying", "decent", etc. can mean quite different things, and what is satisfying for you maybe it is not satisfying for another person. Although in music theory there are some basic guidelines (linked above in the answers and comments), which were tested by great composers through hundreds of years of music, so I guess you should try some of those hints.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!