Bol Processor BP2 -- a 'QuickStart' 4. Producing items 5. Non-stop improvisation Title Page Index Contents

4. Producing items

There is a window called the "Data" window accessed from the "Windows" menu or by typing cmd-d. We will use it now. In addition, we will display the Control panel (see the "Windows" menu or type cmd-=).

fig.14

Fig.14 "Data" window and Control panel.
Grammar and glossary are visible behind these windows.


4.1 Listen to this one!

Click button "Produce items..." or type cmd-r. (Old-timers will remember the "Run" command in Basic!). You see messages indicating that BP2 is computing the item. (Don't hurry to read messages: there is a command in the "Windows" menu recalling the latest 30 messages.) Eventually an item will be displayed.

Produce more items in the same way. The sequence shown below is dependent on the random sequence generator, and may not be the same on different machines.


Fig.15 Four items have been produced by "-gr.koto3"


These items are in text format, not conventional musical score notation, but BP2 will later manage to convert them to sounds on the basis of information contained in the "-mi.abc1" sound-object file.

While BP2 is at work it may be interrupted by keeping the mouse button down. A small window appears with "Resume" and "Stop" buttons allowing to continue the job or abort it. "Resume" and "Stop" commands appear in the "Action" menu as well. You may also type cmd-r or cmd-<period>. During the interruption you are allowed to do almost anything, for example edit the alphabet and grammar, change options, etc. This may be necessary if the computation has become too slow and you want to understand why it is taking such a long time: select for instance "Step-by-step produce" and then click "Resume" or type cmd-r . (Note that options are related, therefore if you select "Step-by-step produce" then "Display production" will also be selected.) If the computation is looping you may modify the subgrammar to find your way out. Understandably, BP2 might decide to recompile the current grammar before resuming computation.

Because of this possibility of "doing almost anything" while a process is interrupted, you may sometimes enter into unpredicted situations in which BP2 is not able to resume the process properly. Many unusual situations have already been encountered and are handled by BP2, but it is virtually impossible to check all possible combinations. Therefore if you are in the course of an important process it is safe to start afresh before making radical changes.

Let us assume that a few items have been produced in the "Data" window, as shown on Fig.15. Each item is actually displayed as a single line, more precisely a "paragraph" terminated with a carriage return. You may of course type items yourself if you know the alphabet of terminal symbols recognised by the "-mi." sound-object file.

For the next experiments it will be more practical to use the Control panel (see Fig.14) than to pull down menus. Type cmd-= or select "Control panel" in the "Windows" menu.

Select one or several item(s) with the mouse. Click button "Play selection" or type cmd-p. First, BP2 loads the "-mi." sound-object file whose name is specified on top of the "Alphabet" window. The "-mi.abc1" file is loaded forever except if you make changes in the alphabet, in which case BP2 must look for definitions of new sound-objects which the modified alphabet might be refering to.

After a short while you see the sound-object structure (the musical item) displayed in the graphic window while the resulting sound is played on the MIDI output.

Below is the graphic display of item

_vel(127) _volume(40) b b <<f>> {5,a c b,f - f} a <<chik>> b <<sync>>

which was produced by this grammar.



Fig.16 Graphic representation of sound-object structure:
_vel(127) _volume(40) b b <<f>> {5,a c b,f - f} a <<chik>> b <<sync>>


This graphic is a kind of musical score with objects represented as rectangles. Background blue lines are streaks of the time structure and red arrows mark the pivots of sound-objects. (See §2.1 or §3 of the reference manual; read Bel 1992a for a detailed presentation) A tail-less arrow denotes a relocatable object, i.e. one whose pivot may not coincide with a time streak. If a sound-object is truncated the deleted part is displayed with dotted lines.

Simple notes (see §1.3, §1.11) are also represented with rectangles and with no pivot since they are relocatable.

Note that you can modify colours by selecting "Change colours" in the "Layout" menu, and save the new options along with "-se.koto3" settings. Again, users of black and white monitors should uncheck the "Use color" option in the same menu.

A scale of physical time appears on top of the window. Here the tempo was 400 beats per minute, therefore 400/60 = 6.66 beats per second.

You may change the graphic scale of graphics by selecting "Graphic scale" in the "Misc" menu. You must play the item again so that the effect of colour or graphic scale changes become visible.

4.2 What's in a polymetric expression?

May be you liked the way this item sounded (on a "Koto" patch of the D-50, or vibraphone in QuickTime music) and want to understand its time structure. Click the "Data" window (or type cmd-d) and select the item with the mouse. Then click button "Expand display ". You get this:



Fig.17 Expanding a polymetric expression


Expressions with curled brackets {} and commas are called polymetric expressions and represent polyphonic sound-object structures. These expressions are incomplete descriptions of the actual precedence relationships between sound-objects and/or notes in the structure. BP2 is able to construct a complete polymetric expression by adapting tempos in superimposed sequences. (This process is explained in great detail in Bel 1990a-b,1991,1992.) The expanded display shown Fig.17 is an outcome of the expansion algorithm.

BP2 expands any polymetric expression (including a simple sequence) before making sounds. Once the expression has been expanded, the following score-like phase diagram is constructed:

in which it is clear, for instance, that the first occurrence of 'f' begins with the first occurrence of 'a'.

Symbols '_' prolongate sound-objects or notes. For instance, the symbolic duration of the first occurrence of 'b' is three time units whereas the last occurrence of 'f' is five time units. (In this particular example, a time unit is one third of a beat.)

Symbols <<f>>, <<chik>> and <<sync>> represent out-time sound-objects, i.e. objects with no duration. Here for instance (from the information found in the "-mi.abc1" file), <<f>> will be a NoteOn on key F4 followed immediately with a NoteOff. <<chik>> is a chord plucked in the same way. It is only audible if the NoteOff instruction does not suppress sound immediately. Therefore we used a "plucked string" patch.

Out-time sound-object <<sync>> produces a C5 on MIDI channel 15 that does not make any sound but may be used to synchronise another BP2 running on the same MIDI network (see §6.4).

Performance controls _vel(127) and _volume(40) are attached to the next object or silence appearing in the same sequence, and are not displayed on graphics. Remember that you can attach very subtle variations of all MIDI parameters, notably pitchbend, modulation, aftertouch, to any structure of sound-object or/and simple notes. (See §1.4-10 regarding performance controls.)

Many polymetric expressions are found in project "-gr.polyphony1".

You may select only part of the item (even a single terminal symbol) and listen to the way it sounds (type cmd-p). Try to figure out the difference between "striated" and "smooth" time by carefully looking at the graphics these different settings generate. (See §9 regarding smooth time.)

4.3 The "Time base" dialog

To change the metronome value, type cmd-t. The " Time base " and " Metronome" dialogs are displayed (see Fig.18).



Fig.18 "Time base"and "Metronom" dialogs


There are two ways of adjusting the clock. The " Metronom" dialog deals with conventional metronome settings, i.e. "mm = 400" means 400 ticks per minute. You may change this value, for instance, to 345.08. Changes are reflected in the " Time base " dialog. Now it tells "8627 ticks in 1500 seconds", which actually means the same as "mm = 345.08". If you need to set the time base accurately, type directly the numbers of ticks and/or seconds. Whenever you change values, BP2 finds the simplest integer numbers yielding the expected integer ratio. The "Metronom" dialog may display a rounded value which will not affect accuracy since BP2 actually uses the integer ratio displayed on the "Time base" dialog.

A very accurate clock is needed to superimpose BP2 items on a given (digitized) sound track. In addition, synchronisation tags (see §6.6) or Apple Events (§6.7) make it possible to start items on precise dates determined by the environment.

The "Time base" dialog contains boxes allowing the definition of three independent cycles that produce ticks on marked beats. When "Play ticks" is checked, ticks become audible. Ticks may be mapped to any MIDI key, channel and velocity. For each cycle, first adjust the cycle duration (1 to 40 beats), then check the boxes of all beats that need to be stressed by a tick. Each cycle may run at a speed differing from that of the basic clock if its speed ratio is not 1/1. A typical example is given in the time base saved as "-tb.slowshift" which may be opened (cmd-o) when the "Time base" dialog is in front.

It is possible to define each tick of the time base individually. Click any square of a tick cycle with the 'option' key down to display the " Tick settings " dialog (Fig.19).


Fig.19 "Tick settings" dialog


The ON/OFF button determines whether the beat should be audible. If "Use default settings" is checked then the tick will be heard on the default channel, key and velocity of its cycle. If "Use special settings" is checked, then these parameters are specified individually as shown Fig.19. The "Capture settings" button makes it possible to pick up these parameters from a MIDI device. It's a good idea to send ticks to a MIDI sampler with percussive or fancy sounds.

A tick cycle may be captured as a MIDI stream and pasted to a sound-object prototype (see §2.3.3). Ultimately, if the sound-object is played alone it can further be saved to a MIDI file (see §14.1). This is a good trick to use tick cycles created by BP2 with other MIDI software.

The time base continues ticking, if instructed to do so, while BP2 is improvising items. You may check this with examples contained in "-da.tryTicks". Note that in smooth time (see §9) beats may become irregular, depending on time streaks created by the musical item. Try "-gr.tryTimePatterns" to hear the difference. These superimposed ticks are neither saved in MIDI files nor interpreted as Csound events.

Different settings of the time base have been saved as -tb.<name> files representing the most popular talas of North Indian classical music.

The time base allows an accurate transcription of durations when notes are entered from the MIDI keyboard (typing cmd-j, see §1.5). When "Play ticks" is checked, durations are transcribed following the period notation (see §1.12.1).

4.4 Blowing memory on fractals...

Instead of listening to a selected item, you may copy and paste parts of it. For instance, select the whole item shown on Fig.16, type cmd-c or select "Copy" in the "Edit" menu, then select the first occurrence of 'a' and type cmd-v or select "Paste". In this way, you replace 'a' with the whole item "b b <<f>> {5, a c b, f - f} ...". The resulting performance is the following:



Fig.20 A "fractal" musical item


You can hear (and see) that the overall duration of the item is unchanged although it has become more complex. Now, time units (for the desired accuracy) have become so small that streaks appear as a grey background. Fractal fanatics may repeat the operation several times or figure out a self-imbedding grammar doing it automatically. Indeed, you'll end up blowing the computer's memory, so be careful to save windows before producing items and try to set a computation limit using dynamic weights (§4.6 of reference manual), flags in programmed grammars (§11 infra) or limited buffer size (§4.7 infra). Quantization (see §6 of reference manual) is also strongly recommended in this context.

You can type cmd-p while a string containing terminal symbols and variables is selected in any window. For instance, bring to front the alphabet window and listen to sound-objects 'a', 'b', 'c', etc., separately. Then bring the grammar window to front and select any string containing terminal symbols. If variables are found, the selection is taken as a start string in production mode.

4.5 Victor Hugo against Darius Milhaud

You will appreciate BP2's ability to produce intricate polyrhythmic patterns by playing item produced by "-gr.Djinns" with percussive sounds (e.g. Roland's "C-54 percussion set 1"). The piece was created to synchronise the recitation of Victor Hugo's poem " Les Djinns " with the opening section of " La Création du Monde " by Darius Milhaud (EMI CDC-7 47845 2) in Andréine Bel's choreographic work for Collège des Prêcheurs and Conservatoire Darius Milhaud (Aix-en-Provence, 1992). We found that the meaning of the poem would coincide with particular events in the musical piece. Then we calculated a time-base value fitting the two tracks together: setting 1000 beats in exactly 1578 seconds was possible since BP2 does not round integer ratios.

Poem " Les Djinns " is built on verses with variable meters: 2/2/2/2/3/3/3/3/4/4/4/4 ...up to 10/10/10/10 --except 9/9/9/9-- and then decreasing (see appendix).

We decided that every verse should have the same duration marked by 16 beats with a stronger first beat. The result is a polyrhythmic piece with one instrument showing beats at a fixed speed and another one playing ticks at variable speeds. Listening to variable parts made it possible for children to recite the poem at the expected tempi.

The grammar below shows how the piece was produced. It has 15 sections labelled "A2", "A3", etc. Each section puts together a fixed motive "M" and a variable motive "T16", "T24", etc. Here, "T16" stands for 16 ticks played as note "do4". Fixed motive "M" is a string of alternated "do2" and "do3" with a stronger beat in the beginning, where "sib5" is played together with "do2".

-se.Djinns
ORD
S --> A2 A3 A4 A5 A6 A7 A8 A10 A8 A7 A6 A5 A4 A3 A2
-------------------------
SUB1
A2 --> {M,T16}
A3 --> {M,T24}
A4 --> {M,T32}
A5 --> {M,T40}
A6 --> {M,T48}
A7 --> {M,T56}
A8 --> {M,T64}
A10 --> {M,T80}
-------------------------
ORD
T16 --> T8 T8
T24 --> T16 T8
T32 --> T16 T16
T40 --> T32 T8
T48 --> T32 T16
T56 --> T48 T8
T64 --> T32 T32
T80 --> T40 T40
T8 --> Tik Tik Tik Tik Tik Tik Tik Tik
-------------------------
SUB1
M --> {1,do2,sib5} do3 do2 do3 do2 do3 do2 do3 do2 do3 do2 do3 do2 do3 do2 do3
Tik --> do4

Fig.21 A grammar for reciting poem "Les Djinns"


Below is a graphic example of the output of "A6 A7".


Fig.22 The "A6 A7" tick pattern in "Les Djinns"


If only variable parts must be heard then regular beats "do2" and "do3" may be replaced with silences.

It is easy to figure out that the full piece would require an excessively large phase diagram (more than 200,000 columns) because it is based on the lowest common multiple of 2, 3, 4, ... 10. Therefore it can played only if quantization is set to a reasonable value (see §6 of reference manual). We found that musicians were be satisfied with a 50 millisecond quantization even though deviations of ±50ms were still noticeable in the "A7" part. With this setting, computation requires a 2 Mbyte memory partition for BP2 and it takes a couple of minutes on a Mac IIci, so be patient if you can't borrow your rich neighbour's PowerMac...

You may use almost the same grammar with syllabi of the poem stored on a sampler and triggered by appropriate keys. I prefer live children's voices...

4.6 Graphic scale and time accuracy

Fig.23 shows a few dialogs activated by the "Misc" menu.



Fig.23 Graphic scale, time accuracy, etc.


Time accuracy is set in the "Accuracy" dialog. Time resolution is the shortest significant time interval, i.e. the resolution of the in-built MIDI driver. Its default value is 10 milliseconds, but you might want to change it (down to 1 millisecond). Because of the inaccuracy of MIDI devices, however, time resolution less than 10ms is rather illusory.

Note that timings in the Csound output (see §17) are not influenced by the time resolution.

Internal computations use 1ms resolution. BP2's clock uses long integer numbers in range 0..2 31. This allows you to handle items lasting up to:

0.001 x 2 31 = 2,147,483 seconds = about 24 days...

The "Accuracy" dialog also displays the setting of quantization (see reference manual §6). " MIDI set-up time" is an estimation of the time needed by MIDI codes to transit through the MIDI driver. A 100ms value is safe. Small values sometimes lead to incorrect timings in the beginning of items.

4.7 Buffer size

Normally BP2 takes care of the size of the work string (the item being computed) and expands its work space when necessary. You may want to control it, notably when using a length-increasing grammar. Dialog "Buffer size" (see Fig.23) displays the current buffer size and the default one assigned when computation starts. Suppose that you do not want to produce a string longer than 750 symbols. Type "750" in the upper field and any equal or smaller value in the default field, then select "use". Now BP2 computes items until the length of the work string reaches 750 symbols, then it prompts you to decide whether you want to stop or continue (expanding the current work space).

In the "-gr.Mozart" project (see §5.4 infra), default buffer size is set to 500 symbols but all items need more space. Therefore, BP2 is forced to expand its space for the work string the first time it produces an item. It does so without asking any permission because the "Don't stop" option is on. The new value is stored into dialog "Buffer size". (Buffer expansion is done stepwise: size is recurrently multiplied by 3/2.)

Setting a very high default value reduces the memory available for other operations. Setting a too small one reduces speed during the first computation, as BP2 needs to resize the work string buffer more often.

A typical application of buffer size limitation is project "-gr.cloches1", an extension of project "-gr.bells" described in §4.12 of the reference manual. Here, computation will not stop unless the buffer size limit is reached, or the mouse is clicked.

Incidentally, project "-gr.cloches1" uses a homomorphism labelled "TR" (see the alphabet window) similar to a transposition, although more complex. This may give you ideas for homomorphisms generating tonal transformations in a more complex way than the "_transpose()" performance control. (Keep in mind that the same note may be played by different sound-objects.)

4.8 The "Tuning" dialog

Fig.23 displays a dialog named "Tuning" accessible from the "Misc" menu. By default, the middle C note ("C4" in English, "do3" in French, "sa4" in Indian notation) is assigned key 60, and the "A4" frequency is 440Hz.

See §1.11 the convention on octave numbering.

There was a confusion in previous versions of BP2 (until 2.6.2). Middle C had been assigned to C5 because of an error inherited from another music software, which went unnoticed until the Csound interface was checked. Therefore old projects may play one octave too high. To compensate this, assign middle C to key 48, and set A4 to 220Hz if you are using Csound. Change values in the "Tuning" dialog and save the project settings.

In a forthcoming version a transposition tool will be available to modify otave numbers in grammar, data and alphabet windows.

The diapason frequency of BP2 is used only for producing Csound scores with instruments that take the "cps (Hz)" format as a pitch parameter.


Bol Processor BP2 -- a 'QuickStart' 4. Producing items 5. Non-stop improvisation Title Page Index Contents