Music
A few years I ago I had briefly experimented with the Screamer library in the context of automatic test case generation from specification. I felt it was a useful utility for doing simple constraint programming tasks. Recently while going through some of the past articles in the Opusmodus forum, I was pleasantly surprised to find references to constraint programming […]
There are two common approaches to composing music. One involves synthesizing a suitable chord progression first and then layering melody over it. The other is to start with melody and then harmonize it by applying chords. Of course, you can mix both approaches – use one technique for a portion of the song and then […]
Sometimes it can be interesting to take a MIDI file and transform the score it represents. For example, you can change the tempo, alter the instruments, or even modify the pitches and rhythm. To do something like this, it is helpful to build a convenient framework. In today’s post, I am outlining one approach that […]
One of the creative approaches to synthesizing music is to start with a short melodic motif and then apply various transformations on it. The motif is usually (but not necessarily) of 1 bar duration. What are some possible transformations? This depends on one’s creativity, but here is a simple list: 1) Identity transformation: Do nothing […]
In the excellent book The Geometry of Musical Rhythm – What Makes a ‘Good’ Rhythm Good? by Godfried T.Toussaint, there is an interesting discussion of Rhythmic Oddity in Chapter 15. A rhythm has this property if no two of its onsets divide the rhythmic cycle into two half-cycles, that is, two segments of equal duration. […]
C++11 introduced user-defined literals, allowing programmers to define special suffixes that can be associated with the built-in literal types: character, integer, float, boolean, and pointer. When designed and used properly, these provide nice syntactic sugar facilitating readability and at the same time, increasing type safety. For example, I can define an operator _kg that can be […]
Converting text to music can be fun. Opusmodus has a few built-in functions to work with text. Look up the description of text-to-pitch, for example. As described in its documentation, (text-to-pitch ‘(“To be, or not to be, that is the question”)) => (((g5 d5) (cs4 e4) (d5 f5) (cs5 d5 g5) (g5 d5) (cs4 […]
In my last post, I explained how we can use Cellular Automata (CA) in Opusmodus to create music. For today’s post, I wanted to build a simple UI to control the parameters used in the CA example. This posed a practical difficulty. Opusmodus does not yet provide a GUI library. Even Clozure CL, on which Opusmodus […]
Cellular automata are a powerful computational formalism. Stephen Wolfram’s book A New Kind of Science provides a thorough study of these devices. Not surprisingly, Wolfram Mathematica has great support for working with them. For example, the following figure shows the evolution of Rule 30 over 50 steps, plotted using ArrayPlot function (in Mathematica): Using cellular automata for […]
When two or more voices in a song follow the same rhythm and move by the same interval, thus causing a parallel motion of the voices, it is referred to as Organum. Depending on the intervals between the voices, this can give rise to a rich and interesting effect. For today’s experiment, I decided to […]
Recent Comments