{"id":1652,"date":"2023-10-04T18:08:06","date_gmt":"2023-10-04T16:08:06","guid":{"rendered":"https:\/\/michael-edwards.org\/wp\/?p=1652"},"modified":"2024-03-26T14:04:24","modified_gmt":"2024-03-26T13:04:24","slug":"in-competence-algorithms","status":"publish","type":"post","link":"https:\/\/michael-edwards.org\/wp\/?p=1652","title":{"rendered":"in competence: algorithms"},"content":{"rendered":"<p>Anyone who knows my work can guess that <em>in competence<\/em>\u00a0was substantially made with my<em><a href=\"https:\/\/www.michael-edwards.org\/sc\" target=\"_blank\" rel=\"noopener\"> slippery chicken<\/a><\/em> algorithmic composition software. A lot of free-form editing and development of score materials were made in<em> <a href=\"https:\/\/www.steinberg.net\/dorico\/\" target=\"_blank\" rel=\"noopener\">Dorico<\/a>.<\/em> The <a href=\"https:\/\/www.ssa-plugins.com\/blog\/2017\/07\/18\/what-is-higher-order-ambisonics\/\" target=\"_blank\" rel=\"noopener\">5th-order Ambisonics<\/a> sound files were made, collated, and mixed in <em><a href=\"https:\/\/reaper.fm\" target=\"_blank\" rel=\"noopener\">Reaper<\/a><\/em> using<a href=\"https:\/\/plugins.iem.at\" target=\"_blank\" rel=\"noopener\"> IEM&#8217;s plugins.<\/a> My <a href=\"https:\/\/michael-edwards.org\/wp\/?p=1531\" target=\"_blank\" rel=\"noopener\">image-to-sound<\/a> algorithms were the main new synthesis development for the project. Featured alongside this, right at the beginning, is a significant and highly processed recording of a speech from <em>Richard II<\/em> (some of it through my trusty old workhorse the <a href=\"https:\/\/www.tcelectronic.com\/product.html?modelCode=HE063\" target=\"_blank\" rel=\"noopener\"><em>TC Electronic Fireworx<\/em><\/a>), as detailed below, along with my own reading of this. See the <a href=\"https:\/\/michael-edwards.org\/prog-note.php?workid=468\" target=\"_blank\" rel=\"noopener\">programme notes<\/a> and my <a href=\"https:\/\/michael-edwards.org\/wp\/?p=1632\" target=\"_blank\" rel=\"noopener\">post<\/a> on the recording for the general background to the work and note that the complete score is freely available <a href=\"https:\/\/michael-edwards.org\/stopen\/michael\/in-competence.pdf\">online<\/a>.<\/p>\n<h2 id=\"org9bf3f8c\"><span class=\"section-number-2\">form, Shakespeare&#8217;s <\/span>lines, recording proportions<\/h2>\n<div id=\"text-7\" class=\"outline-text-2\">\n<p>The structure of this work is derived from an old recording (cleaned up by yours truly) of the <em>Captain&#8217;s Speech<\/em> in <i>Act II Scene IV<\/i> of Shakespeare&#8217;s <i>Richard II:<\/i><\/p>\n<!--[if lt IE 9]><script>document.createElement('audio');<\/script><![endif]-->\n<audio class=\"wp-audio-shortcode\" id=\"audio-1652-1\" preload=\"none\" style=\"width: 100%;\" controls=\"controls\"><source type=\"audio\/mpeg\" src=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/richard2youtube.mp3?_=1\" \/><a href=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/richard2youtube.mp3\">https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/richard2youtube.mp3<\/a><\/audio>\n<p>&nbsp;<\/p>\n<p>Most lines in the recording are followed by pauses. Correspondingly, this work mostly alternates instrumental plus electronics sections (speech) with sound files alone (pauses). There are some exceptions of course, e.g. the very first section is an electronics-only introduction where the bass drum enters, unobserved, during the <i>pause<\/i>; between lines 7 and 8, where the speech becomes more emphatic, there is no pause; there are also dramatic, mid-line pauses in the last two lines.<\/p>\n<p>The durations of the lines and pauses were analysed and scaled from the old recording&#8217;s c. 42 seconds duration onto the intended hour-long duration of <em>in competence<\/em>. Details are given in the following table, though of course some timings were modified here and there during the composition process&#8212;in particular L2, L7, and L8 became significantly longer than the duration indicated below:<\/p>\n<table border=\"2\" frame=\"hsides\" rules=\"groups\" cellspacing=\"0\" cellpadding=\"6\">\n<colgroup>\n<col class=\"org-right\" \/>\n<col class=\"org-left\" \/><\/colgroup>\n<tbody>\n<tr>\n<td class=\"org-right\">Line<\/td>\n<td class=\"org-left\">Info<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">1:<\/td>\n<td class=\"org-left\">start: 0.000, duration: 4:07.752<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 4:07.752, duration: 3:19.051, (total 7:26.804)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>Tis thought the king is dead; we will not stay.<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">2:<\/td>\n<td class=\"org-left\">start: 7:26.804, duration: 3:30.346<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 10:57.149, duration: 1:03.519, (total 4:33.865)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>The bay-trees in our country are all wither&#8217;d<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">3:<\/td>\n<td class=\"org-left\">start: 12:00.669, duration: 4:26.185<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 16:26.853, duration: 1:52.853, (total 6:19.038<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>And meteors fright the fixed stars of heaven;<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">4:<\/td>\n<td class=\"org-left\">start: 18:19.706, duration: 3:45.164<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 22:04.870, duration: 41.563, (total 4:26.727)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>The pale-faced moon looks bloody on the earth<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">5:<\/td>\n<td class=\"org-left\">start: 22:46.433, duration: 4:09.379<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 26:55.812, duration: 1:18.066, (total 5:27.445)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>And lean-look&#8217;d prophets whisper fearful change;<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">6:<\/td>\n<td class=\"org-left\">start: 28:13.878, duration: 3:43.447<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 31:57.325, duration: 59.363, (total 4:42.810)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>Rich men look sad and ruffians dance and leap,<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">7:<\/td>\n<td class=\"org-left\">start: 32:56.688, duration: 2:38.663<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><b>no pause<\/b><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>The one in fear to lose what they enjoy,<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">8:<\/td>\n<td class=\"org-left\">start: 35:35.351, duration: 3:00.077<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 38:35.428, duration: 1:01.803, (total 4:01.879)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>The other to enjoy by rage and war:<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">9:<\/td>\n<td class=\"org-left\">start: 39:37.231, duration: 4:52.749<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 44:29.980, duration: 1:48.155, (total 6:40.904)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>These signs forerun the death or fall of kings.<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">10A:<\/td>\n<td class=\"org-left\">start: 46:18.134, duration: 45.087<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><b>mid-line pause<\/b>: start: 47:03.221, duration: 2:19.056, (total 3:04.143)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>Farewell:<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">10B:<\/td>\n<td class=\"org-left\">start: 49:22.277, duration: 2:48.782<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\">pause: start: 52:11.059, duration: 1:49.329, (total 4:38.112)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>our countrymen are gone and fled,<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">11A:<\/td>\n<td class=\"org-left\">start: 54:00.388, duration: 1:33.246<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><b>mid-line pause<\/b>: start: 55:33.635, duration: 1:16.621, (total 2:49.867)<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>As well assured<\/i><\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\">11B:<\/td>\n<td class=\"org-left\">start: 56:50.255, duration: 3:09.745<\/td>\n<\/tr>\n<tr>\n<td class=\"org-right\"><\/td>\n<td class=\"org-left\"><i>Richard their king is dead.<\/i><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p>&nbsp;<\/p>\n<p>This can also be represented by the following screen shot of an auto-generated reaper file with markers (&#8216;L&#8217; stands for Line). This formed the meta-structural orientation blueprint for the project. Click the image to get the full-resolution graphic:<\/p>\n<p><a href=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/sections.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-1663\" src=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/sections-1024x670.png\" alt=\"\" width=\"620\" height=\"406\" srcset=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/sections-1024x670.png 1024w, https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/sections-300x196.png 300w, https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/sections-768x503.png 768w, https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/sections-1536x1006.png 1536w, https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/sections.png 1596w\" sizes=\"auto, (max-width: 620px) 100vw, 620px\" \/><\/a><\/p>\n<h2>snippets<\/h2>\n<p>Contrary to the general principle of <em>slippery-chicken<\/em>, where rhythm sequences and pitches have an abstracted relationship, <em>in competence<\/em>, makes significant use of a new object-oriented Common Lisp class called <em>snippets <\/em>(and related classes <em>snippet<\/em> and <em>snippet-vars<\/em>). s<em>nippets<\/em> are objects which define small musical ideas consisting merely of notes, i.e. specific pitches and rhythms. When a particular <em>snippet<\/em> is in use, then only the rhythms and pitches defined in the <em>snippet<\/em> are deployed, though they may well be transposed over the course of the main music-generation algorithm (<em>sequence<\/em>). This is specified by a transposition curve given to the <em>sequence<\/em> method. Variations of <em>snippets<\/em> are expected to be defined and these are automatically deployed by the <em>sequence<\/em> method.<\/p>\n<p>A good dose of <em>snippet<\/em> repetition is fundamental to the approach and software logic, as is a movement through the given <em>snippets<\/em> driven by the <a href=\"https:\/\/michael-edwards.org\/sc\/robodoc\/rthm-chain_lsp.html#robo449\" target=\"_blank\" rel=\"noopener\"><em>procession<\/em><\/a> algorithm or good old<em> <a href=\"https:\/\/michael-edwards.org\/sc\/robodoc\/l-for-lookup_lsp.html#robo275\" target=\"_blank\" rel=\"noopener\">fibonacci-transitions<\/a><\/em>. <em>Snippets<\/em> don&#8217;t have to fill whole bars but they may contain barline delineations. They will in any case be combined into bars in order to create the whole sequence and for incorporation into a <em>slippery-chicken<\/em> object, if so desired.<\/p>\n<p>The <em>snippets<\/em> classes and <em>sequence <\/em>algorithm was used in pieces 2 and 3, but also in 5 and 6. The latter are essentially rhythmically augmented and elaborated versions of the the <em>snippet<\/em> structures from no. 3.<\/p>\n<p>A good example of this algorithm in action is the &#8220;Virtual Super-Marlies&#8221; sound file which begins <em>10a. farewell: improvisation<\/em>:<\/p>\n<audio class=\"wp-audio-shortcode\" id=\"audio-1652-2\" preload=\"none\" style=\"width: 100%;\" controls=\"controls\"><source type=\"audio\/mpeg\" src=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/abstrakt.m4a?_=2\" \/><a href=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/abstrakt.m4a\">https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/abstrakt.m4a<\/a><\/audio>\n<h2>hockets<\/h2>\n<p>Audible as repeated lower notes in the above <em>snippets<\/em> example is a form of <a href=\"https:\/\/en.wikipedia.org\/wiki\/Hocket\" target=\"_blank\" rel=\"noopener\">hocketing<\/a>. This technique is fundamental to\u00a0<em>in competence\u00a0<\/em>and is particularly highlighted in piece 3 from Letter B onwards (page 28 of the <a href=\"https:\/\/michael-edwards.org\/stopen\/michael\/in-competence.pdf\">score<\/a> PDF). Essentially, an existing <em>slippery-chicken\u00a0<\/em>part is duplicated but instead of copying notes it is the rests that are filled in with newly-selected notes or chords, i.e. all notes are turned into rests and vice-versa:<\/p>\n<p><a href=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/in-competence-hocketing_Page_028.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-1695\" src=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/in-competence-hocketing_Page_028-1024x899.png\" alt=\"\" width=\"620\" height=\"544\" srcset=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/in-competence-hocketing_Page_028-1024x899.png 1024w, https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/in-competence-hocketing_Page_028-300x263.png 300w, https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/in-competence-hocketing_Page_028-768x674.png 768w, https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/in-competence-hocketing_Page_028.png 1479w\" sizes=\"auto, (max-width: 620px) 100vw, 620px\" \/><\/a><\/p>\n<p>In this particular case, the sopranino sax part is generated by sequenced <em>snippets<\/em> and the piano is created by hocketing, selecting chords from an algorithm based on the analysis, sequencing, and elaboration\/transformation of piano chords originally improvised by Karin Schistek.<\/p>\n<h2>layers<\/h2>\n<p>This new, quite simply algorithm makes its entrance in the very last piece of <em>in competence <\/em>(<em>11b. richard their king is dead<\/em>). It produces layers (aka voices, parts) that repeat permutations of a list of rhythms in a variety of different augmentations. The given rhythms are central to the algorithm whereas the pitches produced are merely rising chromatic in the first instance, in order to clarify the structure. The actual pitch structure is assumed to be obtained or sequenced <em>post hoc <\/em>via another method. The <em>layers<\/em> algorithm takes as its main arguments:<\/p>\n<ol>\n<li>a list of an arbitrary number of rthm symbols e.g. (e s e q) = 1\/8th note, 1\/16th, 1\/8th, 1\/4;<\/li>\n<li>a list of scalers to apply (circularly) to the layers; this can be of any length and the default list consists of the prime numbers 7, 11, 13, 17, 19, 23<\/li>\n<li>the number of layers\/voices to produce;<\/li>\n<li>the number of times the scaled rhythms should be repeated in each layer; implicit here is that the faster layers will end before the slower layers.<\/li>\n<\/ol>\n<p>There is also the possibility to <em>thin out<\/em> the notes in the layers via an envelope, with Y values ranging from 0 (all notes will be forced to rests) to 10 (all notes sound). This is not done randomly, rather deterministically, via an <a href=\"https:\/\/michael-edwards.org\/sc\/robodoc\/activity-levels-env_lsp.html\" target=\"_blank\" rel=\"noopener\"><em>activity-levels <\/em><\/a>object.<\/p>\n<h2><i>foreign material<\/i><\/h2>\n<p>Pieces 7 &amp; 8 come from algorithms developed ten years ago for <a href=\"https:\/\/michael-edwards.org\/work.php?workid=359\" target=\"_blank\" rel=\"noopener\"><em>a new precision mechanism is governing the city<\/em><\/a> (guitar and mandolin). This itself was based on a quite radical departure of the <a href=\"https:\/\/michael-edwards.org\/wp\/?cat=101\" target=\"_blank\" rel=\"noopener\"><em>hyperboles<\/em><\/a> algorithm I was developing around the same time. It involved the<em> <a href=\"https:\/\/michael-edwards.org\/sc\/manual\/rhythm-chains.html\" target=\"_blank\" rel=\"noopener\">rhythm-chains<\/a><\/em> algorithm that was not itself used in <em>hyperbole<\/em>: there was a point during the development cycle that things went haywire and something I wasn&#8217;t particularly aiming at appeared. I love these moments (usually). I couldn&#8217;t use it for the piece I was working on but I made a mental note and kept the code for some future piece. It was only when I was working on hocketing for <em>in<\/em> <em>competence<\/em> that I remembered all this. It had a similar feel and so I developed it in the context of <em>in competence\u00a0<\/em>for the <em>Trio Abstrakt<\/em> instrumentation. It&#8217;s quite nice, for me at least, to listen and compare the <em>in competence<\/em> version to the 2013 original, called <em>whoops my algorithm slipped,<\/em> as rendered here for synthesised flute and piano:<\/p>\n<audio class=\"wp-audio-shortcode\" id=\"audio-1652-3\" preload=\"none\" style=\"width: 100%;\" controls=\"controls\"><source type=\"audio\/mpeg\" src=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/whoops.mp3?_=3\" \/><a href=\"https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/whoops.mp3\">https:\/\/michael-edwards.org\/wp\/wp-content\/uploads\/whoops.mp3<\/a><\/audio>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Anyone who knows my work can guess that in competence\u00a0was substantially made with my slippery chicken algorithmic composition software. A lot of free-form editing and development of score materials were made in Dorico. The 5th-order Ambisonics sound files were made, collated, and mixed in Reaper using IEM&#8217;s plugins. My image-to-sound algorithms were the main new [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":1653,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,27,11,108],"tags":[3,4,240,241,6,239,237],"class_list":["post-1652","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-algorithmic-composition","category-composition","category-composition-documentation","category-slippery-chicken","tag-algorithms","tag-common-lisp","tag-hockets","tag-in-competence","tag-slippery-chicken","tag-snippets","tag-trio-abstract"],"_links":{"self":[{"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1652","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1652"}],"version-history":[{"count":31,"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1652\/revisions"}],"predecessor-version":[{"id":1715,"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1652\/revisions\/1715"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=\/wp\/v2\/media\/1653"}],"wp:attachment":[{"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1652"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1652"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/michael-edwards.org\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1652"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}