CYBERNETICS AND CONTROL THEORY
Unknown
Submitted 1960-01-01 | RussiaRxiv: ru-196001.54503 | Translated from Russian

Full Text

CYBERNETICS AND CONTROL THEORY

R. Kh. Zaripov

ON AN ALGORITHMIC DESCRIPTION OF THE PROCESS OF COMPOSING MUSIC

(Presented by Academician S. L. Sobolev, 30 I 1960)

The advent of electronic digital machines has led to an expansion of the range of nonmathematical problems that admit algorithmic description and machine modeling, in particular processes connected with human creative activity. Undoubtedly, an attempt to create an algorithm that imitates to some extent the process of composing music is very attractive.

The composition of music is a very complex process which, of course, cannot be completely formalized. However, it is possible to single out certain general propositions and principles of composition by which a person is (often intuitively) guided when composing music. In addition, for example, in the theory of music of the classical style there exist definite laws that must not be violated (the prohibition of parallel fifths and octaves in harmonization, the resolution of intervals, etc.) and that can be taken into account in creating the algorithm under consideration.

Human thinking in composing music may be regarded as a peculiar control system, and, because the functioning of this control system has not been sufficiently studied, the present algorithm, which takes into account only a small number of general propositions of the process, is a mathematical experiment for studying the process of creating music itself, as well as for determining the logical capabilities of the machine. In implementing the algorithm on a machine, other regularities of the process under consideration are also revealed, which can be used in improving the algorithm.

The present work is devoted to describing an algorithm that imitates the process of composing a single-voice instrumental musical piece. As an illustration, a piece composed by the “Ural” machine according to a program implementing the algorithm described is given (see below).

§ 1. In accordance with the general principles of the structure of a musical work, the algorithm provides for the following propositions:

1) The piece is a three-part musical form ABA, as the most widespread structure of an instrumental work. A and B are contrasting in music. More will be said about the structure of the piece in § 2.

2) Each phrase of the piece ends on one of the three principal degrees of the scale (I, III, V) \((A_{77})\) *.

3) Two wide intervals of the melody in succession in one (ascending or descending) motion are not permitted (for example, a fifth and a sixth) \((p_{73})\).

4) The number of notes following one another in a single motion (ascending or descending) does not exceed six \((A_{70})\).

5) The pitch range is limited to two and a half octaves \((p_{72})\).

* In parentheses here and below is indicated the operator of the logical scheme given in § 3 that implements the given proposition.

6) Syncopations across the bar line are allowed only from the machine’s control panel \((p_{4i})\).

7) In a melody, a larger number of notes proceed consecutively in one direction when the intervals between them are narrower, i.e., we have a smoother melodic pattern with a rarer change in the direction of motion. Conversely, fewer notes proceed consecutively in one direction when the intervals between them are wide, i.e., with larger leaps in the melodic pattern there is a more frequent change in the direction of motion. This principle is implemented by the group of operators \(A_{70} \div p_{73}\), which constitute a self-regulating system, and by others (see the description of the logical circuit, § 3).

musical example

According to the algorithm, the melody of the piece is obtained in the following way. The durations of the notes, the intervals* and the number of notes proceeding consecutively in one direction are selected by means of random numbers \((A_{45})\). This selection is subject to the rules set forth above. The process of obtaining such a melody also imitates the process of composing a melody by a human being.

§ 2. The resulting monophonic musical piece has a three-part ABA form with the following structure

\[ \alpha_1\beta_1\alpha_2\beta_2\gamma_1\gamma_2\gamma_1\gamma_3\delta\beta_3 \tag{*} \]

The combination \(\alpha_1\beta_1\) (and likewise \(\alpha_2\beta_2\), \(\gamma_1\gamma_i\) \((i = 2, 3)\), or \(\delta\beta_3\)) will be called a period. A period is divided into two phrases \(\alpha_1\), \(\beta_1\), and so on. A phrase consists of 4 bars.

Here different letters (regardless of the index) define the different rhythmic and melodic character of the corresponding phrase; moreover, the character of the \(\alpha\) and \(\beta\) phrases is similar in rhythm and melody, while \(\gamma\) is contrasting with respect to \(\alpha\) and \(\beta\) (in accordance with the ABA form). The same letter, regardless of the index, defines the same rhythmic pattern and melodic character of the phrase. The indices attached to one and the same letter define different variants of the melody. The program provides for four different characters of phrases, both in rhythm and in melody. For example, \(\beta_1\), \(\beta_2\), \(\beta_3\) are phrases identical in rhythm and of one and the same melodic character, differing only in their melodic pattern (see the musical example).

* The pitch \(W_k\) of the \(k\)-th note is formed by the formula \(W_k = W_{k-1} + \varphi_k\), where \(\varphi_k\) is the interval taken with its sign: \(+\) for ascending motion, \(-\) for descending.

The process being described is divided into two stages: I — selection of the rhythm of the piece (selection of the rhythmic pattern for \(\alpha, \beta, \gamma, \delta\)); II — melodic processing of the rhythm in accordance with \((*)\) and printing of the melody in encoded form.

The program, compiled in accordance with the logical scheme of § 3 for the “Ural” computer, occupies about \(2/3\) of the operative memory. The composition and printing of a piece are carried out in 2–2.5 min.

The piece is written in C major, in the range from F of the small octave to the third octave \((p_{72})\). The setting of the meter (\(3/4\) or \(4/4\)) is carried out from the control panel.

§ 3. Logical scheme

\[ \begin{gathered} A_0\, A_1 \begin{array}{c} 2i\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 2i\quad 46 \end{array} A_{2i} \begin{array}{c} 3j\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 3j\quad 41,43 \end{array} A_{30} \begin{array}{c} 44\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 44 \end{array} A_{31}p_{41} \begin{array}{c} 44\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 30 \end{array} A_{32} \begin{array}{c} 44\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 44 \end{array} A_{33}p_{43} \begin{array}{c} 44\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 30 \end{array} \\[14pt] A_{44} \begin{array}{c} \\[-6pt] \left|\\[-6pt] 71 \end{array} A_{45}q_{46} \frac{2i_k;\,5k,\,6i_m;\,8m;\,88}{2i_k;\,5k,\,6i_m;\,8m;\,88} A_{50} \begin{array}{c} 2i_\beta\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 2i_\beta \end{array} A_{51} \begin{array}{c} 2i_\gamma\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 2i_\gamma \end{array} \\[14pt] A_{52} \begin{array}{c} 2i_\delta\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 2i_\delta \end{array} A_{53} \begin{array}{c} 77\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 77 \end{array} A_{54} \begin{array}{c} 6i\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i\quad 73 \end{array} A_{60} \begin{array}{c} 70\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 70 \end{array} A_{61} \begin{array}{c} 70\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 70 \end{array} A_{62} \begin{array}{c} 70\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 70 \end{array} A_{63} \\[18pt] A_{70}\, A_{71}\, p_{72} \begin{array}{c} \\[-6pt] \left|\\[-6pt] 45 \end{array} p_{73} \begin{array}{c} \\[-6pt] \left|\\[-6pt] 60 \end{array} p_{74} \begin{array}{c} 78\\[-2pt] \Gamma \end{array} A_{75}\, p_{76} \begin{array}{c} 78\quad 53\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 53 \end{array} A_{77} \begin{array}{c} 74,76\\[-2pt] \longrightarrow \end{array} A_{78} \\[18pt] \begin{array}{c} 46\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 46 \end{array} \left( A_{80} \begin{array}{c} 6i_\beta\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\beta \end{array} A_{81} \begin{array}{c} 6i_\alpha\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\alpha \end{array} A_{82} \begin{array}{c} 6i_\beta\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\beta \end{array} A_{83} \begin{array}{c} 6i_\gamma\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\gamma \end{array} A_{84} \begin{array}{c} 6i_\gamma\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\gamma \end{array} \\[14pt] A_{85} \begin{array}{c} 6i_\gamma\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\gamma \end{array} A_{86} \begin{array}{c} 6i_\delta\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\delta \end{array} A_{87} \begin{array}{c} 6i_\beta\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 6i_\beta \end{array} \right) q_{88} \begin{array}{c} \circ\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] \circ \end{array} * \end{gathered} \]

Description of the logical scheme

\(A_0\) — formation of the program depending on the meter \(3/4\) or \(4/4\).

\(A_1\) — random (or specified from the control panel) selection, for \(\alpha\), of the character of the rhythmic pattern, depending on the number \(i\) (in our case \(i = 0, 1, 2, 3\)).

\(A_{2i}\) — selection of the \(j\)-th rhythmic combination, where \(j = 0, 1, 2, 3\) corresponds to the combinations ♪♪, ♫♪♩, permissible in the program.

\(A_{2j}p_{4j}\) — elimination of syncopations for \(j = 1\) and \(3\). In the case of syncopation, control is transferred to \(A_{30}\). At the end of the phrase, a dispatch to \(q_{46}\) of unconditional transfer.

\(A_{44}\) — recording of the rhythmic combination.

\(A_{45}\) — random-number generator.

\(q_{46}\) — operator of unconditional transfer of control (UT). At the end of a rhythmic phrase, UT to \(A_{5k}\); at the end of a melodic phrase, UT to \(A_{8m}\). Within a phrase, UT to \(A_{2i_k}\), \(A_{6i_m}\). Here \(i_k\) and \(i_m\) assume (depending on \(k = 0, 1, 2, 3\) and \(m = 0, 1, \ldots, 7\)) one of the values \(i = 0, 1, 2, 3\).

\(A_{50,51,52}\) — preparation of the program for the rhythmic processing of the phrases \(\beta, \gamma, \delta\), respectively.

\(A_{53}\) — preparation for obtaining the melody \(\alpha_1\) according to rhythm \(\alpha\).

\[ {}^{*}\ \text{The bracket } \begin{array}{c} 46\\[-2pt] \left[\vphantom{\dfrac{}{}}\right.\\[-6pt] 46 \end{array} \text{ applies to each of the operators situated inside the parentheses.} \]

$A_{54}$ — random (or specified from the console) choice for $\alpha$ of the character of the melodic pattern (depending on $i = 0, 1, 2, 3$).

$A_{6i}$ — choice of the interval for the next note.

$A_{70,71}$ — formation of the sign of the interval, obtaining the pitch of the next note. Choice of the number of notes proceeding in succession in one motion (ascending or descending).

$p_{72}$ — limiter of the pitch range (between F of the small octave and up to the 3rd octave). If the condition is not fulfilled, control is transferred to obtain another interval.

$p_{73}$ — exclusion of wide intervals proceeding in succession in one motion, by transferring control to obtain a less wide interval.

$p_{74}$ — check for the end of the phrase. Within the phrase, print the note ($A_{78}$).

$A_{75}$ — at the end of the phrase, send the BP to $A_{8m}$ at $q_{46}$.

$p_{76}, A_{77}$ — test for the end of the period and assignment to the final note of the period of scale degree I, III, or V. If we have not the end of a period (but the end of a phrase), then transition to $A_{78}$.

$A_{78}$ — print the note (in encoded form).

$A_{8m}$ ($m = 0, 1, 2, \ldots, 7$) — preparation of the program for melodic processing of the phrase following $\alpha_1$ (*).

$q_{88}$ — stop, or (by control from the console) automatic transition to the beginning of the program ($A_0$) without stopping.

Rostov-on-Don
State University

Received
29 I 1960

Submission history

CYBERNETICS AND CONTROL THEORY