Polymetric structures

Polymetric expres­sions are the basic rep­re­sen­ta­tion mod­el for the tim­ing of musi­cal data in the Bol Processor. The word is a mix­ture of polypho­ny and polyrhythm, the for­mer evok­ing super­im­posed streams of musi­cal events, and the lat­ter a met­ric adjust­ment of their durations.

This page illus­trates the syn­tax of sim­ple expres­sions and their inter­pre­ta­tion by the poly­met­ric expan­sion algo­rithm described in Two algo­rithms for the instan­ti­a­tion of struc­tures of musi­cal objects (Bel 1992). This process can be extreme­ly com­plex, since an entire musi­cal work — e.g. Beethoven's Fugue in B flat major — is treat­ed by the Bol Processor as a sin­gle poly­met­ric struc­ture: see exam­ple.

In this tuto­r­i­al, sim­ple notes ("C4", "D4" etc.) are used fol­low­ing the "English" con­ven­tion. All time-setting process­es could be illus­trat­ed using sound-objects or sim­ple notes in oth­er con­ven­tions: "Italian/Spanish/French" or "Indian".

Symbolic versus physical duration

Music nota­tion sys­tems (for humans) make use of sym­bol­ic rather than phys­i­cal dura­tions. Their units are beats rather than (milli)seconds.

Three quar­ter notes on a score
in west­ern con­ven­tion­al music notation

In west­ern con­ven­tion­al music nota­tion, notes and paus­es are rep­re­sent­ed by spe­cial signs indi­cat­ing their rel­a­tive durations.

For exam­ple, if the time sig­na­ture is 3/4, we will have 3 quar­ter notes (crotch­ets) in a bar (see pic­ture). A half note (min­im) lasts twice as long as a quar­ter note in the same con­text. Other rel­a­tive dura­tions are expressed in the same way.

To get the phys­i­cal dura­tion of a note we need an addi­tion­al piece of infor­ma­tion: the metronome val­ue, for exam­ple "mm = 100", which means 100 beats (quar­ter notes) per minute.

A metronome val­ue (60 bpm by default ) is declared in the set­tings file of a Grammar or Data page. With this set­ting, note "E4" on a Bol Processor score rep­re­sents an "E" of the 4th octave played in 1 beat with a phys­i­cal dura­tion of 1 second.

This con­ven­tion extends to arbi­trar­i­ly named sound-objects whose default dura­tions are set by the streams of MIDI events or sequences of Csound instruc­tions from which they are com­posed. The map­ping of sym­bol­ic to phys­i­cal time for the per­for­mance of sound-object struc­tures (with their met­ric and topo­log­i­cal prop­er­ties) is a sophis­ti­cat­ed process per­formed by a time-setting algo­rithm. A prac­ti­cal exam­ple is dis­cussed on the page Interactive impro­vi­sa­tion with sound-objects.

Polymetric expression

Typical forms of poly­met­ric expres­sions are:

  • field 1, field2 or {field 1, field2} indi­cates that field1 and field2 should be super­im­posed and the total sym­bol­ic dura­tion should be adjust­ed to that of field1;
  • field1 • field2 or {field1 • field2} indi­cates that field1 and field2 should be con­sec­u­tive and the sym­bol­ic dura­tion of each field should be adjust­ed to that of field1;
  • {expression} is equiv­a­lent to expression.

Curly braces '{' and '}' are used to cre­ate multi-level expressions.

Periods writ­ten as bul­lets '' in the Data and Grammar win­dows are con­vert­ed to plain peri­ods before being sent to the con­sole, as the con­sole rejects some Unicode characters.

For exam­ple, {C4 D4, E4 F4 G4, E5} pro­duces the fol­low­ing time struc­ture with a metronome set to 60 beats per minute:

Item {C4 D4, E4 F4 G4, E5} on a sound-object graph
The dura­tion is 2 beats, as set by the first field "C4 D4"

The use of the first field to set the total dura­tion is high­light­ed by the fol­low­ing exam­ples where the fields appear in a reverse order:

{C4 D4 E4, F4 G4}
Duration of 3 beats
{F4 G4, C4 D4 E4}
Duration of 2 beats

Rests (silences) can be notat­ed with "-" for sin­gle unit rests, or with inte­ger num­bers and ratios. The fol­low­ing shows a sin­gle unit rest and a more com­plex rest of 2.5 beats:

{F4 - G4, C4 D4}
Duration of 3 beats
{F4 2 1/2 G4, C4 D4}
Duration of 4.5 beats
Fields in reverse order: {C4 D4, F4 2 1/2 G4}
Duration of 2 beats

Polymetric struc­tures can be multi-level, for example:

Multi-level poly­met­ric struc­ture:
{C4 D4, {E4 F4 G4, E5} B4}

The same time-setting rules apply to sequences where com­mas are replaced by peri­ods. For example:

Sequence F4 2 1/2 G4 • C4 D4 or {F4 2 1/2 G4 • C4 D4}
Duration is set by that of the first field "F4 2 1/2 G4"
= 4.5 beats applied to the sec­ond field

Superpositions and sequences can be com­bined (even in multi-level expres­sions), such as:

{F4 2 1/2 G4 • C4 D4, A4 B4, G4 A4 • F4}
Duration of 9 beats = twice that of "F4 2 1/2 G4"

Undetermined rests

Undetermined rests are a pow­er­ful fea­ture of poly­met­ric expres­sions, sav­ing humans from the incon­ve­nience of com­pli­cat­ed time com­pu­ta­tions. This is an impor­tant step towards min­imis­ing the amount of numerical/symbolic infor­ma­tion need­ed to cre­ate a pre­cise tem­po­ral struc­tures in music.

The poly­met­ric expan­sion algo­rithm cal­cu­lates (sym­bol­ic) dura­tions that pro­duce the least com­plex expression.

Undetermined rests are notat­ed as "" or "_rest" in Data or Grammars.

👉  Since the Bol Processor con­sole does not recog­nise the "" Unicode sym­bol, the PHP inter­face rewrites it as"_rest".

The exam­ples below are based on super­im­posed struc­tures, in which fields are sep­a­rat­ed by com­mas. The same expan­sion algo­rithm applies to sequen­tial struc­tures, where fields are sep­a­rat­ed by peri­ods. All exam­ples can be checked on the "-da.tryRests" page.

The same process is applied to struc­tures con­tain­ing sound-objects and/or sim­ple notes. Here, we use sim­ple notes for the sake of clarity.

Let us start with a triv­ial exam­ple. In {C4 D4 E4, … F4 G4}, the unde­ter­mined rest "" is replaced by a sin­gle unit rest:

{C4 D4 E4, … F4 G4}
= {C4 D4 E4, _rest F4 G4}

Thus, the expres­sion {C4 D4 E4, … F4 G4} is equiv­a­lent to {C4 D4 E4, - F4 G4} or {C4 D4 E4, 1 F4 G4}.

A sim­i­lar sequen­tial struc­ture {C4 D4 E4 • … F4 G4} yields the fol­low­ing solution:

C4 D4 E4 • … F4 G4 = C4 D4 E4 • _rest F4 G4

This solu­tion gives the sim­plest poly­met­ric expres­sion. The same sim­ple case is that of {… C4 D4 E4, F4 G4}:

{… C4 D4 E4, F4 G4}
= {_rest C4 D4 E4, F4 G4}

If a field of the poly­met­ric expres­sion con­tains sev­er­al unde­ter­mined rests, these are assigned equal dura­tions — in such a way that the com­plex­i­ty of the struc­ture remains min­i­mal.

For exam­ple, con­sid­er {… C4 D4 … E4, A4 F4 G4}:

{… C4 D4 … E4, A4 F4 G4}
= {_rest C4 D4 _rest E4, A4 F4 G4}

Thus, this struc­ture is equiv­a­lent to {1/2 C4 D4 1/2 E4, A4 F4 G4}.

An unde­ter­mined rest can­not be assigned dura­tion 0, even when this would result in a sim­pler expres­sion. For exam­ple, in {… C4 D4 … E4, F4 G4} dura­tion 0 would result in a "three in two" polyrhythm, where­as dura­tion 1/2 results in "five in two":

{… C4 D4 … E4, F4 G4}

👉 The rejec­tion of null dura­tions has been imple­ment­ed in December 2025 (ver­sion 3.3.6).

Each field of a poly­met­ric expres­sion can con­tain unde­ter­mined rests. Consider for exam­ple {… C4 D4 E4, A4 B4 F4 … G4}. Once again, assign­ing a dura­tion of zero to each unde­ter­mined would result in the sim­plest struc­ture, since "four in three" (LCM = 12) is a bet­ter trade-off than "five in four" (LCM = 20). However, but this null dura­tion is not accepted:

{… C4 D4 E4, A4 B4 F4 … G4}

A more com­plex struc­ture is assigned to {C4 D4 E4, A4 B4 F4 … G4 A4, C5 … D5} with rests of 1 unit in the sec­ond and third fields. The LCM of 3 and 6 is 6, which is the low­est val­ue pos­si­ble for this structure.

{C4 D4 E4, A4 B4 F4 … G4 A4, C5 … D5}

A sim­i­lar case is {C4 D4 E4, A4 B4 F4 … G4 A4, C5 … D5 E5}:

{C4 D4 E4, A4 B4 F4 … G4 A4, C5 … D5 E5}

Here, the first rest has been assigned 1 unit and the sec­ond one 3 units. This gives the LCM of 3 and 6 = 6.

Replacing com­mas with peri­ods gives the same struc­ture in a sequen­tial form:

"C4 D4 E4 • A4 B4 F4 … G4 A4 • C5 … D5 E5"
= {C4 D4 E4 • A4 B4 F4 _rest G4 A4 • C5 _rest D5 E5}
Duration of the first field "C4 D4 E4" is applied to the 2nd and 3d ones
which results in a final count of 3 x 3 = 9 beats

Remember that the first field of a poly­met­ric struc­ture is the one that sets up its tem­po (and glob­al dura­tion). Thus, replac­ing {C4 D4 E4, A4 B4 F4 … G4 A4, C5 … D5 E5} with {C5 … D5 E5, C4 D4 E4, A4 B4 F4 … G4 A4} sets the dura­tion to 6 beats instead of 3, even though rel­a­tive dura­tions are unchanged:

{C5 … D5 E5, C4 D4 E4, A4 B4 F4 … G4 A4}
= {C5 _rest D5 E5, C4 D4 E4, A4 B4 F4 _rest G4 A4}

A more com­pli­cat­ed case is {C4 D4 E4, A4 B4 F4 … G4 … A4 …, C5 … D5 … E5 …} in which the gaps are divid­ed into 3 equal time periods:

Structure {C4 D4 E4, A4 B4 F4 … G4 … A4 …, C5 … D5 … E5 …}
= {C4 D4 E4, A4 B4 F4 _rest G4 _rest A4 _rest, C5 _rest D5 _rest E5 _rest}

A nota­tion of the for­mer struc­ture with explic­it dura­tion rests would be:
{C4 D4 E4, A4 B4 F4 1/3 G4 1/3 A4 1/3, C5 - D5 - E5 -}

Undermined rests can be processed in mul­ti­lay­er struc­tures, for exam­ple {A3 … B3 C3, {C4 D4 E4, … F4 … G4}} which yields:

A two-layer struc­ture {A3 … B3 C3, {C4 D4 E4, … F4 … G4}}
= {A3 _rest B3 C3, {C4 D4 E4, _rest F4 _rest G4}}

These struc­tures can be a mixed of super­im­posed and sequen­tial struc­tures. For exam­ple, {A3 … • B3 C3, {C4 D4 E4, … F4 … G4}} yields:

A sim­i­lar two-layer struc­ture con­tain­ing a sequen­tial struc­ture:
{A3 … • B3 C3, {C4 D4 E4, … F4 … G4}}
= {A3 _rest • B3 C3, {C4 D4 E4, _rest F4 _rest G4}}

Minimised polymetric expression

A poly­met­ric expres­sion is min­imised by replac­ing quan­ti­fied rests with unde­ter­mined rests wher­ev­er pos­si­ble, with­out los­ing accu­ra­cy. An algo­rithm has been imple­ment­ed (ver­sion 3.3.6 of December 2025) to min­imise the sam­ples used for train­ing an AI to trans­late a MIDI stream into its equiv­a­lent poly­met­ric expres­sion (read this page).

The process is shown in detail on project "-da.tryMinimise". Click the MINIMIZE but­ton to min­i­mize all struc­tures on this page, and Undo MINIMISE to delete the min­imised ver­sion. Items can be played and dis­played to ver­i­fy that they are iden­ti­cal to their min­imised versions.

👉 As of today (2025-12-11), the algo­rithm is being fixed for a rare error. Version 3.3.6 will be released as soon as this issue has been resolved.

Tied notes, tied sound-objects

Sound-objects or sim­ple notes can be con­cate­nat­ed ("tied"). Consider, for example:

"C4 D4 C4 E4 C4 F4 E4"

and its vari­a­tion with ties notat­ed "&":

"C4& D4 &C4& E4& &C4 F4 &E4"

The time inter­val of a tied note/sound-object may cross the lim­its of (tree-shaped) poly­met­ric struc­tures. For example:

{C4 D4}{E4{2,E4,C4,G4}}
{C4& D4}{E4 {2,E4,&C4,G4}}

The chal­lenge of deal­ing with tied events is dis­cussed on the Tied notes page.

Real music is “polymetric”

The rules and heuris­tics asso­ci­at­ed with poly­met­ric expres­sions make sense when deal­ing with real musi­cal items. In par­tic­u­lar, they made it pos­si­ble to import MusicXML scores and inter­pret them as Bol Processor data (read page).

For exam­ple, check out Mozart’s musi­cal dice game, this "Charles Ames" exam­ple and Harm Visser's demos.

Further reading

Bel, Bernard. Rationalizing musi­cal time: syn­tac­tic and symbolic-numeric approach­es. In Barlow, Clarence (ed.) The Ratio Book. Den Haag: Royal Conservatory - Institute of Sonology. 2001: 86-101.

Bol Processor shares a few fea­tures, with respect to pat­tern rep­re­sen­ta­tion, with the TIDAL Pattern Language for the Live Encoding of Music (Alex McLean & Geraint Wiggins, 2010):

An Indian con­cep­tion of time can be seen most clear­ly in the ven­er­a­ble Bol Processor sys­tem for algo­rith­mic music, cre­at­ed by com­put­er sci­en­tist Bernard Bel from work on notat­ing tabla rhythms and devel­oped over forty years. Drawing from Indian clas­si­cal music, it includes an expres­sive approach to time set­ting that seems unique to the algo­rith­mic music field, in which sound events are orga­nized in terms of inter­re­la­tion­ships before being mapped to phys­i­cal time. Although not a live cod­ing sys­tem itself, it has been heav­i­ly influ­en­tial on the design of the TidalCycles sys­tem, par­tic­u­lar­ly its embed­ded “minino­ta­tion” lan­guage for describ­ing rhythm in the Bol Processor and more gen­er­al­ly its rep­re­sen­ta­tion of music based not on the dura­tion of events (as in staff nota­tion) but on the dura­tion of cycles.

Alan Blackwell, Emma Cocker, Geoff Cox, Thor Magnusson, Alex McLean, Live Coding: A User's Manual, MIT 2022, page 195.

Leave a Reply

Your email address will not be published. Required fields are marked *