My new novel, Eternal Sonata (publication date October 4, 2016), imagines a future global struggle to control the science of extreme human life extension. In the novel, a brilliant scientist working to honor the memory of his late wife by curing cancer develops a process for cellular reversion that unlocks the key to immortality. While he works tirelessly on his research, he fills his lab with a fictional Bach “eternal sonata,” a metaphor for both his enduring love for his scientist/musician wife and for the human quest to live forever. Here is how the scientist describes an “eternal sonata” to the person visiting his lab:
“It’s not a pure Bach sonata. It’s an eternal sonata, a variation on all of the Sonatas de Chiesa, using Bach’s same fractal formulas but extending the mathematical variation ad infinitum. If Bach had written his sonatas to go on forever, each melody embedded with the mathematical formula guiding the whole, this is probably what they would have sounded like, all thanks to the miracle of quantum computing.”
In the run-up to the launch of the book, I wanted to see if it might be possible to actually create an eternal sonata and reached out to a Brilliant Bach professor at Julliard who, in turn, connected me with one of his students. The student, both a composer and a coder, volunteered enthusiastically and threw himself into the project.
A couple of months later, I received the following note from him:
I’ve been working on this a lot, and am starting to think the goal is less practical than expected (shocker, I know…). Not sure if you have leads on other musicians, but I might not be able to do this.
In any case, this is what I have as of now; maybe it’s possible to imagine the result:
– It is most practical to write in three voices, rather like Bach’s organ sonatas.
– The higher two voices imitate each other, with the lowest developing its own accompanimental motifs, and referencing the “head-motif” of the higher voices (this is tricky to implement).
– The movements alternate fast and slow tempos. The first movement is fast. All fast movements are in the home key. Slow movements are in the relative major/minor, or in major or minor V (the choice can be random).
– Not every movement ends in the home key. Maybe every other slow movement and every third fast movement ends in either V or V of the next movement’s tonality.
– Slow movements are all of the same form, with the first and second half repeated. If the ending is not in I, there should be a second ending. Ornamentation follows the model of CPE Bach (this is also tricky to analyze and implement).
– Fast movements are in one of these two forms (chosen randomly): Same as the slow movements, though with less ornamentation; similarly bisectional, but without repeat, and not stopping after the modulation.
– There are some numerological items Bach was fascinated in, and they can be interpolated into the list of requirements (mostly, they concern the number of measures).
– What makes this piece a single sonata then, rather than a bunch of movements? There is a second layer of development, featuring the continuous variation and obscuration of a hymn-tune (perhaps the tune from Gottes Zeit ist die allerbeste Zeit—God’s time is the very best time, in which the tune is In you have I hoped, Lord). This provides seriousness, and links the whole as an outpouring of thoughts on death and time passing (this is very tricky to implement).
– As well, there is a sense of continuous development over the whole piece, which might be motivic.
Beyond these guidelines, I wanted to let the computer do the composing, which would take place bit by bit as sections are needed. The biggest problems as of now are:
– Getting the “composer” to work correctly. It’s really a coding problem more than a musical problem, and as such is buggy. Because I don’t code professionally, the code is clunky and inefficient, more about that in number 3.
– Getting the large-scale structure to “work”. It would be nice if the piece sounded right at the end…
– Producing music quickly enough. This is the real trick; as of now, individual measures come laboriously. Eventually, I would need to produce music quicker than one listens to the music. I think this is impossible; with a long piece, one could simply push back a deadline, but I would need to push it back infinitely.
– Eventually getting the program to run itself, producing music forever, including once we’re dead. I have no ideas.
Not sure if you have any ideas about these problems? I’m starting to run out of solutions.
Not to be deterred, I send the student’s note to a friend who works in one of the world’s most high profile artificial intelligence projects in one of the world’s most famous companies and asked for his suggestions. Here is what he replied:
I believe you and your Julliard colleague should think about the endless sonata use case as follows:
Input A: Julliard student’s observations of each composition (structured and/or unstructured data sets)
Input B: Listener favorability of each composition (e.g., “who likes what”)
Output A: Mathematical pattern/compatibility ranking of all possible combinations of compositions
Output B: Auditory quality ranking of all possible combinations of compositions
Insight #1: An endless sonata mathematically looks like….
Insight #2: An endless sonata sounds like….
Insight #3: A combined sonata ceases to become favorable when….
Insight #4: A combined sonata remains favorable if….
Armed with this additional information, I went back to the student and asked him to take another crack. Two months later, I received the following message:
Hi, I spent the weekend (more like a whole week, actually) with a small team of slave-laboring CS students at Columbia, trying to work out the code. We came to a few conclusions:
– The project is definitely possible, because we managed to get the computer to “play itself”, and to write code without intervention (most people get really excited when a computer can write code itself, because artificial intelligence and all, but this is a very idiosyncratic intelligence, if in fact it has any. If you ever want to write a book about a robot takeover, this is probably not the droid you’re looking for).
– We’d need maybe five years of nearly full-time work. This is really non-negotiable, because there is a lot of grunt work involved in defining musical parameters (musicians are taught in school “don’t write with parallel fifths”, “don’t double a leading tone”, et cetera. If you want to teach a computer those, you first need to find a mathematical way of defining the transformation, then codify all the manifestations, then allow for exceptions—you now need to define a stochastic tool for producing weighted random numbers, and “calibrate” it experimentally—and then pray that the computer doesn’t get too smart and make an unpredictable blunder that a human wouldn’t… which of course you can’t check for until the end. There doesn’t seem to be a simple way around this piecemeal work—if someone found one, they’d be making celebrity-professor-money at a big university. If the best classical music sounds “simple” or “logical”, it’s because human learning and music are so intimately connected; in the arts, the last person you want as a student is a completely logical robot, not because the field is illogical, but because defining it logically will break your head needlessly).
– The amount of code needed for a simple bit (few seconds maybe) of music is distressingly large. The demand on the RAM would be similarly distressing, and the practicalities of bandwidth and linking to the internet would provide a less than pleasant listening experience (the quality of sound would have to be lowered, and there would still be clipping, skipping, whole moments of silence, etc.)
In so many words, the killer really is the practicality, not the possibility, much like the individual steps are deceptively possible when you chase the moon around. So I need to apologize, and say it can’t be done, at least for now.
It was very enjoyable to work with you! Very sorry we couldn’t make something work,
PS, you might be happy to know that several people have adopted the tool to help them with their own pieces, so this work has served some use (though I have yet to hear those pieces). We have also developed a rather strange, yet practical tool for managing the load on the CPU during the playing phase; it has been named “Sonata”, of course, and might be handy in other people’s projects. Furthermore, we seem to have produced 10 new fans of your books! Thanks again for offering the opportunity to work with you, it’s been a lot of fun, even as I pull my hair out.
So now, dear Internet, I am throwing out this challenge to you.
Can anyone create a real-world Eternal Sonata? If you do, fame, fortune, and glory will be yours and we will spread it to the world.