# How many melodies are there?



## beetzart (Dec 30, 2009)

I've often wondered if there is a finite amount of tunes available to us in the major and minor modes. Did the likes of Haydn, Mozart, Beethoven, and Schubert live in the best period in time for finding new melodies like kids in a sweet shop? I regard a melody as a single part. Personally I think there is still plenty of low hanging fruit even if it is a bit hybrid with the aforementioned composers' melodies.


----------



## MarkW (Feb 16, 2015)

Mathematically, the combinations and permutations of X notes taken N at a time, even forgetting rhythm and repeated notes, is eassily calculable and far exceeds what's been written so far. (And even Schoenberg once said that there was still good music to be written in C major.)


----------



## Phil loves classical (Feb 8, 2017)

Limited number of permutations, although still a very large number. Also depends if you include chromaticism. There are 12 notes in an octave. So including chromaticism, in a melody of 4 notes only, there are P(12,4)= 11880 combinations. But much less (still a large number) if you don't include chromaticism. It is not only melody, but rhythm has a lot to define a line. Imagine Elvira Madigan with each note the same length...


----------



## beetzart (Dec 30, 2009)

So you could say the axiom is that a melody is objective and contains at least 2 notes. If you add in rhythm then surely it is infinite? There could be a limitless amount of dotted notes, say. Sorry, what I mean is a dotted note could in theory have an infinite number of dots


----------



## Phil loves classical (Feb 8, 2017)

beetzart said:


> So you could say the axiom is that a melody is objective and contains at least 2 notes. If you add in rhythm then surely it is infinite? There could be a limitless amount of dotted notes, say. Sorry, what I mean is a dotted note could in theory have an infinite number of dots


As long as the piece of music has an end, then it is still finite. You are getting me into a philosophical mode again. Maybe Life itself is an unending piece of music....

Anyway, back to my mathematic model, I'll try to add rhythm into the math formula, which gets more complex, and I might miss a few things. Including rests, stoccatos, grace notes, eighth, sixteenth, quarter, half notes, slurs, triplets, I'm getting P(109,4)= in the order of *133 million* possibilities on 4 notes only. I didn't take into account some minor things like you can't have slurs on staccato notes, etc. There are probably a few things I missed, but you get the idea that it's a high number, but still very finite.


----------



## hpowders (Dec 23, 2013)

1137 at last count. I'm counting on President Trump's FBI to update me daily on any new melodies, as they come along.


----------



## beetzart (Dec 30, 2009)

Phil loves classical said:


> As long as the piece of music has an end, then it is still finite. You are getting me into a philosophical mode again. Maybe Life itself is an unending piece of music....
> 
> Anyway, back to my mathematic model, I'll try to add rhythm into the math formula, which gets more complex, and I might miss a few things. Including rests, stoccatos, grace notes, eighth, sixteenth, quarter, half notes, slurs, triplets, I'm getting P(109,4)= in the order of *133 million* possibilities on 4 notes only. I didn't take into account some minor things like you can't have slurs on staccato notes, etc. There are probably a few things I missed, but you get the idea that it's a high number, but still very finite.


Blimey, yes it is quite something when you take into account all those variables. Do you think it is possible to decode each major composer's style? Like finding some formula that gives you an expression from which you can write more Beethoven pieces. Bit abstract I know but a trained ear can nearly always tell the difference between Haydn, Mozart, Beethoven, and Schubert. Yet they are all using the same parameters but they all have a distinct unique sound. Why?


----------



## BabyGiraffe (Feb 24, 2017)

beetzart said:


> Blimey, yes it is quite something when you take into account all those variables. Do you think it is possible to decode each major composer's style? Like finding some formula that gives you an expression from which you can write more Beethoven pieces. Bit abstract I know but a trained ear can nearly always tell the difference between Haydn, Mozart, Beethoven, and Schubert. Yet they are all using the same parameters but they all have a distinct unique sound. Why?


You can decode composer's style. They would sound all the same, if they were using the same "parameters" in the same way.

Here you list of parameters and some analyses.
http://solomonsmusic.net/paramet.htm

http://solomonsmusic.net/Brahmsara.htm
http://solomonsmusic.net/Scriabin.htm
http://solomonsmusic.net/schenker.htm


----------



## jailhouse (Sep 2, 2016)

Theres a great vsauce video about this lemme find it





The answer is no.


----------



## kyf (Feb 1, 2017)

beetzart said:


> Do you think it is possible to decode each major composer's style?... a trained ear can nearly always tell the difference between Haydn, Mozart, Beethoven, and Schubert.


It is being done all the time: some (bored?) musicians' favorite game is to make, for example, Schubert sound like Beethoven or Mozart.

But before "authentic or period instruments" or "historically informed performances (HIP)", it was easy to hear Mozart, Beethoven, & even Bach sounding like Brahms or even Wagner.


----------



## Phil loves classical (Feb 8, 2017)

beetzart said:


> Blimey, yes it is quite something when you take into account all those variables. Do you think it is possible to decode each major composer's style? Like finding some formula that gives you an expression from which you can write more Beethoven pieces. Bit abstract I know but a trained ear can nearly always tell the difference between Haydn, Mozart, Beethoven, and Schubert. Yet they are all using the same parameters but they all have a distinct unique sound. Why?


Our brains are the equivalent of super computer processors. I heard from somewhere that by learned instinct we can skip a lot of redundant processing and can find certain things quicker than computers, so something like finding similarity of style in different works of a certain Composer is more natural to us Homo Sapiens, at least for now before computers and robots take over the world. But it is very possible for a computer to find similarities in works, I believe. I would refine your last statement, that the composers use the same basic elements, but it is those particular settings of the parameters, and certain mannerisms which creates each of their unique style.


----------



## kyf (Feb 1, 2017)

Phil loves classical said:


> Our brains are the equivalent of super computer processors. I heard from somewhere that by learned instinct we can skip a lot of redundant processing and can find certain things quicker than computers, so something like finding similarity of style in different works of a certain Composer is more natural to us Homo Sapiens, at least for now before computers and robots take over the world. But it is very possible for a computer to find similarities in works, I believe. I would refine your last statement, that the composers use the same basic elements, but it is those particular settings of the parameters, and certain mannerisms which creates each of their unique style.


When Mozart was younger, he was basically a supercomputer processor like you're describing that churned out many similar works. The hard thing to do is to innovate or go deeper like he later did & still produce works that resonate with a human audience.

If human composers don't care about resonating with a human audience, then why will they be necessary? Computers/robots will program themselves to write music ...


----------



## BabyGiraffe (Feb 24, 2017)

kyf said:


> Computers/robots will program themselves to write music ...


Computers can already compose in a certain style, if you feed them enough data, but they can't decide is it good or not.


----------



## Tristan (Jan 5, 2013)

I don't know, but according to some, they've all been used up


----------



## beetzart (Dec 30, 2009)

How did Beethoven's supercomputer of a brain manage to compose the Late Quartets? It astonishes me over and over.


----------



## kyf (Feb 1, 2017)

BabyGiraffe said:


> Computers can already compose in a certain style, if you feed them enough data, but they can't decide is it good or not.


 What if some human composer can't decide either when they try to come up with some new pattern of data?


----------



## Strange Magic (Sep 14, 2015)

Prokofiev answered this question in 1939, replying to a question addressed to the editor of a Soviet journal, _The Pioneer._ Proko worked out that, for an 8-note melody, there were more than 6 billion possible combinations. To quote: "We begin a melody wth a certain note; for the second note, we can choose any note in the octave above or below; in the octave above, we have twelve notes, and the same number in the octave below; if one adds to this the original note (for we can repeat the same note in a melody) there will be at our disposal, for the second note in the melody, twenty-five variants, and for the third, twenty-five multiplied by twenty-five, that is six hundred and twenty-five variants." He goes on to show that the answer is 25 to the 7th power. He then points out, "But this is not all, for the notes have a different duration and the rhythm completely changes the shape of a melody. Moreover, the harmony and the accompaniment give the melody a totally different character. These six milliard (billion) have to be multiplied several times to obtain all the possibilities."

That's Proko for you--chess player, bridge player, worker of puzzles, interested in science and engineering issues. He hardly had time to compose.


----------



## JAS (Mar 6, 2013)

And yet the standard defense from composers whose melody may sound a bit too familiar is that there are only so many notes.


----------



## Woodduck (Mar 17, 2014)

beetzart said:


> How did Beethoven's supercomputer of a brain manage to compose the Late Quartets? It astonishes me over and over.


By being a human being as well as a supercomputer. The former will always be much more astonishing.


----------



## BabyGiraffe (Feb 24, 2017)

JAS said:


> And yet the standard defense from composers whose melody may sound a bit too familiar is that there are only so many notes.


Subsconscious imitation of something that you have heard.
Today I woke up with a melody in my head that I haven't heard in the last 10 or more years (old reggae pop song from the 90s).


----------



## JAS (Mar 6, 2013)

BabyGiraffe said:


> Subsconscious imitation of something that you have heard.
> Today I woke up with a melody in my head that I haven't heard in the last 10 or more years (old reggae pop song from the 90s).


In some cases, it is certainly possible. I vaguely remember having to write a humorous poem for an assignment in class, and thinking that one or two sections were particularly good. When I moved some years ago, I stumbled across a book that I had not seen for ages, and in looking it over found that my lines had been stolen before I even wrote them! (I do remember buying that book at a book fair in elementary school, which was probably the last time I had read it. Obviously, those lines made enough of an impression on me that I remembered them, but not the larger context. Poetry, especially traditional forms of poetry, like music, tend to be memorable for their own qualities.)


----------



## Bettina (Sep 29, 2016)

JAS said:


> In some cases, it is certainly possible. I vaguely remember having to write a humorous poem for an assignment in class, and thinking that one or two sections were particularly good. When I moved some years ago, I stumbled across a book that I had not seen for ages, and in looking it over found that my lines had been stolen before I even wrote them! (I do remember buying that book at a book fair in elementary school, which was probably the last time I had read it. Obviously, those lines made enough of an impression on me that I remembered them, but not the larger context. Poetry, especially traditional forms of poetry, like music, tend to be memorable for their own qualities.)


That actually happens to me on TC from time to time. Sometimes, while I'm in the middle of writing a post, I realize that I'm unconsciously plagiarizing someone else's post! My apologies to any victims of my post-theft.


----------



## kyf (Feb 1, 2017)

BabyGiraffe said:


> Subsconscious imitation of something that you have heard.





JAS said:


> In some cases, it is certainly possible.


This could certainly be a problem. I remember reading that Schubert's musical memory is so extraordinarily good that he can't get good tunes out of his head. It's like an overload. And any forced/deliberate attempt to negate such influences may end in something artificial ...


----------



## Phil loves classical (Feb 8, 2017)

Bettina said:


> That actually happens to me on TC from time to time. Sometimes, while I'm in the middle of writing a post, I realize that I'm unconsciously plagiarizing someone else's post! My apologies to any victims of my post-theft.


All is forgiven...


----------



## pcnog11 (Nov 14, 2016)

beetzart said:


> How did Beethoven's supercomputer of a brain manage to compose the Late Quartets? It astonishes me over and over.


If this is the case and Mozart composed Requiem on his death bed (according to Amadeus), so many melodies, parts and counterpoints, I think the number of melodies can only be bounded by one's imagination.


----------



## kyf (Feb 1, 2017)

OK, in the same vein, "music is in the silence between the notes". Who said that?

I would also add that the length of each note matters too.


----------



## kyf (Feb 1, 2017)

... and the relative loudness of the notes : dynamics matters ...


----------



## amfortas (Jun 15, 2011)

Bettina said:


> That actually happens to me on TC from time to time. Sometimes, while I'm in the middle of writing a post, I realize that I'm unconsciously plagiarizing someone else's post! My apologies to any victims of my post-theft.


That actually happens to me on TC from time to time. Sometimes, while I'm in the middle of writing a post, I realize that I'm unconsciously plagiarizing someone else's post! My apologies to any victims of my post-theft.


----------



## Francis Poulenc (Nov 6, 2016)

There is an infinte amount of melodies, but there isn't an infinite amount of good melodies.


----------



## Barelytenor (Nov 19, 2011)

There are _exactly_ as many possible melodies as there are twin primes. _Exactly._

:tiphat:

Kind regards,

George


----------



## Dim7 (Apr 24, 2009)

98774321567832579.


----------



## pokeefe0001 (Jan 15, 2017)

How many melodies are there?

As many as there needs to be. And maybe a few more.


----------

