|
3.1 About composition problemsThe first point is the great diversity both of the musical structures used (which is a general fact in CAC), and of the resulting CSPs. The domains are always finite, usually integers, but the constraints cover a wide range of classical constraints : arithmetic, alldifferent, capacity, cardinality, optimization. Secondly, the goal of using CP techniques is also quite different from a problem to another. We have optimization problems, resolution problems (find one solution), and generation problems (find all the solutions). Concerning the modelling work itself, it was often complicated because of some >implicit< constraints, i.e. constraints that the composer find so evident that he/she does not write them explicitly. For instance, a rhythmical pattern is made of different onsets, a chord can be made of different notes, where sometimes the order does not matter (C-E-G can be considered equivalent as E-G-C in some cases), etc. While choosing the elements of these structures as variables (onsets, notes, etc), he forgets this implicit constraint and often doesn’t formalize it. Since the CSP are also often over constrained, the first attempt to solve the CSP can result in trivial solutions, for instance the same note everywhere in a chord, or a rhythmical pattern reduced to a single onset. So we have to add alldifferent constraints to respect the musical structures. Fourth point, most of these CSPs are over-constrained and have no solution. So they have to be considered, from a computer science point of view, as optimization problems. Other possibility, divide the constraints into two parts, the constraints and the preferences, leading to a constrained optimization problem. This is usually very well accepted by the composers : some of their constraints express the main musical idea of the CSP, they govern the general shape of the result, for instance the common note constraint in the chord with common notes problem. Others express just preferences, such as the upward or downward move in the same problem. Finally, maybe more surprising for the CP community, the goal is not really to solve the CSP, but to provide interesting instanciations to the composer. It happens that an approximate solution is musically more interesting than an exact one. We shall never forget the exact place of constraint solving in the compositional process : it is just a help, or a tool, for the composer. It is at the rough draft level of the composition, not only because it is CAC, but also because being a solution doesn’t guarantee beeing musically good. In particular, the solutions are nearly always re-written by hand. So the usual CSP paradigm >problem
3.2 About analysisIn some cases, the use of constraint programming for musical analysis is very natural (see Chemillier and Truchet, 2001, for more details). With regard to several approaches in music theory, the analysis of a score can be seen as a set of rules describing some interesting properties of the score. Translating the rules into constraints seems quite natural. |