Higher-order Constraint applicators for Music Constraint Programming

This paper studies how constraints are applied to the score in a musical constraint satisfaction problem (CSP). How can we control which variable sets in the score are affected by a given constraint? Our overall objective is to produce a highly generic music constraint system, where users can define a wide range of musical CSPs, including rhythmic, harmonic, melodic and contrapuntal problems. Existing systems provide constraint application mechanisms which are convenient for specific cases, but lack generality and cannot be extended by users. As a result, complex sets of variables are hard to constrain in these systems. For example, constraining notes from different voices in a polyphonic setting (e.g., with harmonic constraints) is inconvenient or even impossible in most systems. We propose an approach which combines convenience with full user control: higher-order constraint applicators. A constraint is a first-class function, while a constraint applicator is a higher-order function which traverses the score in order to apply a given constraint to variable sets. This text presents constraint applicators suitable for a many musical CSPs, and reproduces important mechanisms of existing systems. Most importantly, users can define their own constraint applicators with this approach.

[1]  M.N. Sastry,et al.  Structure and interpretation of computer programs , 1986, Proceedings of the IEEE.

[2]  Peter Van Roy,et al.  Concepts, Techniques, and Models of Computer Programming , 2004 .

[3]  Stephen Travis Pope The SmOKE Music Representation, Description Language, and Interchange Format , 1992, ICMC.

[4]  William Shottstaedt,et al.  Automatic counterpoint , 1989 .

[5]  Camilo Rueda,et al.  Composition at IRCAM: From PatchWork to OpenMusic , 1999 .

[6]  Mikael Laurson,et al.  PatchWork : a visual programming language and some musical applications , 1996 .

[7]  Charlotte Truchet,et al.  Two Musical CSPs , 2001 .

[8]  Alan Smaill,et al.  Representing music symbolically , 1991 .

[9]  Torsten Anders Arno: Constraints Programming in Common Music , 2000, ICMC.

[10]  François Pachet,et al.  Musical Harmonization with Constraints: A Survey , 2004, Constraints.

[11]  Mika Kuuskankare,et al.  A Constraint Based Approach to Musical Textures and Instrumental Writing , 2007 .

[12]  Max V. Mathews,et al.  Current directions in computer music research , 1989 .

[13]  François Pachet Mixing Constraints and Objects: a Case Study in Automatic Harmonization , 2007 .

[14]  Mika Kuuskankare,et al.  PWGL: A Novel Visual Language based on Common Lisp, CLOS and OpenGL , 2002, ICMC.

[15]  P. J. Landin,et al.  The next 700 programming languages , 1966, CACM.

[16]  Camilo Rueda,et al.  Computer-Assisted Composition at IRCAM: From PatchWork to OpenMusic , 1999, Computer Music Journal.

[17]  Torsten Anders,et al.  Composing Music by Composing Rules: Design and Usage of a Generic Music Constraint System , 2007 .

[18]  François Pachet,et al.  Reifying Constraint Satisfaction in Smalltalk , 1997, J. Object Oriented Program..

[19]  Camilo Rueda,et al.  Integrating Constraint Programming in Visual Musical Composition Languages , 1998 .

[20]  Francis Courtot A Constraint-based Logic Program for Generating Polyphonies , 1990, ICMC.