Skip to main content

Work in progress - RITE

I'm working on three pieces of music at the moment. Well, that is, I'm supposed to be working on three pieces of music at the moment – today I actually managed to get some work done on two of them, at any rate.

The big project I have on the go is Why Scotland, Why East Kilbride, a music theatre piece for Cryptic Nights, CCA Glasgow 4 & 5 July next year. It's for double rock band with video projection, including, I've just decided today, a 'digital video mellotron', which I'm going to use to deliver the 16 French horn parts needed for the piece. However, the work I've done on that piece today is boring and administrative…

More interestingly, I've turned this evening to a new work in progress called RITE, for four performers, four pianos, and four effects units. The centenary of the Rite of Spring is coming up next year, and I've been invited to write a piece, hence the deliberately-dodgy all caps title. To quote my current draft of the programme note:

The title of the piece is an acronym: it might also be spelled R.I.T.E. Perhaps it stands for this:

Recursive Invariant Transform (Electronic) = RITE

Or possibly:

RITE is terrible ecronym.

The four effects units are going to be used as feeding-back no-input noise-makers, operated by the pianists themselves. I've spent some happy hours surfing eBay for obsolete fx units and mixers: my latest purchase is a lovely old ART FXR Elite II which you can hear on the clip below. For the pianistic material, I'm mulling over those little bits of the piece which have always stuck in my ear, and kind of rewriting them as if from memory. Today I've been reworking the little scale for two flutes at the very end of the piece, just eighteen notes, which have already generated several minutes of material.

This clip is a kind of meditative recomposition of the initial two chords from the 'Mystic Circles of the Young Girls', combined with recursive fx stuff:

rite_sketch_01.mp3

Sonifying IR spectroscopy data – rhythm

For today's exciting episode, I'm using the simplified spectrum data from glycine to generate a sound, and then looping round the same data to play the sound in a kind of 'rhythm':


(
~name = "glycine";
~path = Document.current.dir.asString++"/"++ ~name ++".csv";
f = CSVFileReader.readInterpret(~path);

f = ((f.flop[1] * -1) + 1).normalize;

f = (f*100).asInteger;
f = f.differentiate.removeEvery([0]).integrate;
f = f/100;

~peaksIndices = f.differentiate.sign.findAll([1,-1]);

g = Array.fill(f.size, 0);

~peaksIndices.do { |i| g[i] = f[i] }; // Daniel's line

~amps = g;

// [f,~amps].plot(~name, Rect(840,0,600,450));

~freqs = (36..128).resamp1(f.size).midicps;

SynthDef(\glycine, { | gate=1, amp |
var env, sig;
sig = Klank.ar(`[~freqs, ~amps, nil], PinkNoise.ar(amp/100));
env = EnvGen.kr(Env.perc, gate, doneAction: 2);
Out.ar(0, Pan2.ar(sig, 0, env))
}).add;

Pbind( \instrument, \glycine,
\amp, Pseq(~amps, 4).collect { |amp| if(amp > 0) {amp} {Rest}},
\dur, 0.02,
).play;
)

glycinerhythm.mp3

In other news, my collaborator Steve has been having Ideas. Watch this space.

Sonifying IR spectroscopy data - finding peaks

Emperor Joseph II: Well, I mean occasionally it seems to have, how shall one say? [he stops in difficulty; turning to Orsini-Rosenberg] How shall one say, Director? Orsini-Rosenberg: Too many notes, Your Majesty? Emperor Joseph II: [to Mozart] Exactly. Very well put. Too many notes. From Amadeus (1984)

It occured to me after a while that my previous attempts at dealing with these sets of data were running into a 'too many notes' problem: 784 resonators at once is always likely to sound like noise! What one would like to be able to do would be to focus in on the visible 'peaks':

This is something a human can do quite intuitively: in fact, I seem to dimly remember that, many years ago, when I worked with HPLC (High Performance Liquid Chromatography) data at Schweppes, there was a pencil and paper method we used to estimate the height and width of a peak, and thus determine the concentration of a compound by calculating the area under the graph.

A little research into the problem of doing this algorithmically rapidly took me far out of my mathematical depth:

Chao Yang, Zengyou He, Weichuan Yu Comparison of public peak detection algorithms for MALDI mass spectrometry data analysis BMC Bioinformatics. 2009; 10: 4. Published online 2009 January 6. doi: 10.1186/1471-2105-10-4 http://www.ncbi.nlm.nih.gov/pmc/articles/PMC2631518/

Instead, I got some hints on a rather simpler approach from Daniel Mayer by asking a question on the SuperCollider mailing list.

Here's the code I eventually came up with:


(
~name = "glycine";
~path = Document.current.dir.asString++"/"++ ~name ++".csv";
f = CSVFileReader.readInterpret(~path);

f = ((f.flop[1] * -1) + 1).normalize;

f = (f*100).asInteger;
f = f.differentiate.removeEvery([0]).integrate;
f = f/100;

~peaksIndices = f.differentiate.sign.findAll([1,-1]);

g = Array.fill(f.size, 0);

~peaksIndices.do { |i| g[i] = f[i] }; // Daniel's line

~amps = g;

// [f,~amps].plot(~name, Rect(840,0,600,450));

~freqs = (36..128).resamp1(f.size).midicps;

SynthDef(\glycine, { | gate=1, amp |
var env, sig;
sig = Klank.ar(`[~freqs, ~amps, nil], PinkNoise.ar(amp/100));
env = EnvGen.kr(Env.perc, gate, doneAction: 2);
Out.ar(0, Pan2.ar(sig, 0, env))
}).add;

Pbind( \instrument, \glycine,
\amp, Pseq(~amps, 4).collect { |amp| if(amp > 0) {amp} {Rest}},
\dur, 0.02,
).play;
)


At the very end of the plot you can see one of the problems: this method finds any and all local peaks, including ones which to the eye look unimportant:

I think what would be needed here would be some low-pass filtering to get rid of small glitches. However, the musical results so far are quite good: once again, here's a short gesture made by crossfading from one compound to another:

Sonifying IR spectroscopy data - automating pitch

Going off in a bit of a different direction here, using the data as automation to drive the pitch of a synth:


( f = CSVFileReader.readInterpret(Document.current.dir.asString++"/water.csv");

f = ((f.flop\[1\] \* -1) + 1).normalize(48,84); //midinotes

Pmono( \default, \midinote, Pseq(f, inf), \dur, 0.005).play )

In this recording, looping up the three chemicals one by one. Kind of cute - early days for this approach.

pmono01.mp3

Sonifying IR spectroscopy data - 'chords'

Finding the .resamp1 method in SuperCollider gave me an idea for reducing this rather large set of data into something perhaps more musically useful. Could I make something more like a tonal chord, with pitches repeated in every octave?

I first drastically resampled my data into just twelve points:

f = ((f.flop[1] * -1) + 1).resamp1(12);

These would then be the probabilities of those twelve pitch classes appearing across a range of eight and a half octaves:

f = (f++f++f++f++f++f++f++f++f[..7]); // 104 notes

Then what I did was to multiply this chordal structure by the original data, so that my final sound is the 'glycine chord' amplitude modulated (sort of) by the absorbtion data.

Here's the final code:


( ~name = "glycine"; ~path = Document.current.dir.asString++"/"++ ~name ++".csv"; f = CSVFileReader.readInterpret(~path);
g = f;

f = ((f.flop[1] * -1) + 1).resamp1(12);
f = (f++f++f++f++f++f++f++f++f[..7]);
// 104 notes g = ((g.flop[1] * -1) + 1).resamp1(104);
// 104 samples of orig graph ~amps = f.cubed * g;
// combining two approaches ~amps = ~amps.normalize;
~amps.plot(~name, Rect(840,0,600,450));
~freqs = (25..128).midicps;

{ Splay.ar(Klank.ar(`[~freqs, ~amps, nil], PinkNoise.ar(0.01))) }.play; )

I used this approach to make the sound below, which crossfades from glycine to tyrosine to water, then back to glycine again.

Sonifying IR spectroscopy data

I'm in the very early stages of a collaborative project with Dr Steven Ford, Senior Research Fellow and QC Manager at the Cancer Research UK Formulation Unit of Strathclyde University. Steve came to me with an idea about sonifying IR spectroscopy data, with a view to perhaps drawing some creative parallels between vibrations at the atomic scale and musical sound.

Steve sent me some IR data relating to three compounds, water, glycine and tyrosine, and I've been trying some things out in SuperCollider. Here's a plot of the data which Steve sent me:

Thinking in terms of sound, my immediate thought was to try to scale those resonances into the audio region. Here's one of my first attempts:

( ~name = "water"; ~path = Document.current.dir.asString++"/"++ ~name ++".csv";
f = CSVFileReader.readInterpret(~path);

~amps = f.flop\[1\]; // array of amplitudes ~amps.plot(~name, Rect(840,0,600,450));

~freqs = Array.series(f.size, 40, 100); // size, start, step

{ Klank.ar(`[~freqs, ~amps, nil], PinkNoise.ar(0.01)) }.play; )

water01.mp3

There are 784 points of data here, and I've just mapped those arbitrarily to a bank of 784 resonators, spaced 100 Hz apart, starting at 40Hz. It sounds pretty nasty. Then it occured to me that Steve's data is for transmittance, not absorbance: the points of interest are the troughs, not the peaks, the graph is upside down for what I wanted to do. So:

( ~name = "tyrosine"; ~path = Document.current.dir.asString++"/"++ ~name ++".csv";

f = CSVFileReader.readInterpret(~path);

~amps = ((f.flop\[1\] \* -1) + 1).cubed; // invert, massage ~amps.plot(~name, Rect(840,0,600,450));

~freqs = (64..128).resamp1(f.size).midicps;

{ Klank.ar(`[~freqs, ~amps, nil], PinkNoise.ar(0.01)) }.play; )

Here I was also starting to think about how to bring out the peaks in the data, hence the .cubed. This does make the data 'pointier', but at the expense of the smaller peaks. A slightly different strategy with the frequencies here also, 784 microtonal pitches between midi notes 64 and 128. It still sounds really pretty nasty:

tyrosine01.mp3

Gathering of the Gamelans, Saturday, Wayang Lokananta

At last, we get to the piece we have all been working towards for so many months:

Kanda Buwana is the company name of dhalang Matthew Isaac Cohen. I have known Matthew for a number of years, most notably during the period when he was at Glasgow University. Matthew was responsible for bringing dhalang Ki Joko Susilo to Scotland, and Mas Joko, as we called him, was in turn reponsible for a transformation in the approach of Gamelan Naga Mas. He brought to us a great chunk of highly distinctive repertoire, most of it derived from the wayang, which we still play today: a talu, unusual srepeg and sampak, and Joko's arrangements of such pieces as Caping Gunung, Gambang Suling and Wong Donya. Our musical director Signy Jakobsdottir soaked up a year's worth of wayang drumming from Joko: Matthew was always around, playing peking devising wayang in English with Joko, with his then young daughter Hannah climbing all over him in rehearsal. Happy days.

To commemorate 30th anniversary of York's Gamelan Sekar Petak, Matthew created 'Lokananta, or the Playerless Gamelan', interweaving a number of different oral and literary sources with music which John Pawson had garnered from gamelan groups across the UK. Each section of the wayang was accompanied by a different group: in order, Cardiff Gamelan, Gamelan Midwest (comprising Cheltenham and Oxford), Gamelan Scotland (Aberdeen University, Gado-gado and Naga Mas), Gamelan Sekar Petak (York), Gamelan South East (Cambridge, Siswa Sukra, Southbank Gamelan Players), Gamelan South West (Bath Spa, Bristol), and Gamelan North (Chopwell, Dwi Gambira Sari, Durham.)

A full DVD of the show is in preparation, and I'm not going to attempt to describe the whole thing. The high point of the show for me was John Pawson's arrangement of Subakastawa Nyamat. Arrangement is too small a word for it: this was a unique artistic creation, bringing together all of the tunings, players and gamelans in a melding of Kodok Ngorek and Subakastawa. A great wave of building emotion as the first gamelan descended from the heavens, and all the musicians spread around the room gradually joined in singing 'Mideringrat…':

A moment I will never forget.

Though I say so myself, Gamelan Scotland acquitted themselves extremely well: 'blown away' was the response we seemed to get from everyone, not least for the dramatic entrance of our piper Hazen Metro on Margaret Smith's piece Iron Pipes. Another emotional moment for me as Mags sang her arrangement of Ca' the Yowes, and a scary moment for me when I had to lead the entire audience in a brief kecak! I also played Gamelunk, of course, which came off pretty well.

As to the wayang itself: the amplifiation of Matthew's voice was not entirely satisfactory on the musician's side of the screen, and there was much I could not follow. Matthew has a wicked sense of humour, and can be very good at the interplay and in-jokes between the musicians and the puppeteer: again, some of this seemed to get lost. I was impressed with Matthew's puppet technique, including a great trick of catching the limbs of one puppet between another and the screen, used to great effect in some of the fight scenes.

Gathering of the Gamelans, Saturday sessions

Today's conference activities were somewhat disrupted by a revised schedule of wayang rehersals, which also caused our Scottish group a certain amount of last minute phone calls to try to get everyone there in time. I was fortunately able to make Helen Loth's paper session '"Why gamelan, couldn't we just use steel-pans?": The use of gamelan with special needs groups and populations'. Helen is engaged on doctoral research in this area, and presented an illuminating account of her findings so far. Her application of the term 'special needs groups' is very broad: in effect she is surveying pretty much the a full range of what I would might have called 'community music' with gamelan in the UK. After a literature review, she presented a series of tables full of interesting nuggets of information: for instance, the most common timescale for this kind of work seems to be the (often criticised) one-off workshop, followed by the 1-2 week residency. I was particularly interested in a diagram which laid out people's perceived feelings about the different tunings one could potentialy use, slendro, pelog, Sundanese and two Balinese tunings. I was also fascinated by some of the negative perceptions of gamelan music which she had identified in her study. With the rescheduled day there was little time for discussion: this would have been an interesting area to probe further.

I've now been to two really excellent workshops by Jonathan Roberts. A number of years ago I participated in an illuminating session on wayang puppets and puppetry, and this morning he gave us a great section on gerongan, the unison (mostly male) singing which accompanies Javanese gamelan. In a brave but completely correct move, I think, Jonathan had us do hardly any singing, but spent the majority of the time on Javanese pronunciation. There are a number of sounds in the language which are not found in English, which we worked through in some detail: at times the session almost turned into – bilabial fricative?! – a lecture on phonetics. I still struggle to hear the difference between those d and t sounds, but I think I have clearer idea how to make them.

After the pronunciation, Jonathan took us through some techniques in Javanese vocal production. He started off by busting the myth that it is 'nasal'. Instead, we were to try yawning, to start to feel the action of the pharynx and how that could be brought into action to produce a kind of vocal resonance which he called 'twang'. I can't do it yet, but at least I'm going to stop singing through my nose!

Gathering of the Gamelans, Saturday rehearsals

Substantial chunks of the day were taken up by a series of rehearsals for the wayang. The venue was a modern dining hall, with a kind of semicircular shape. Spacially this allowed for a very good arrangement, with room for audience all around, and a separate staging area off to one side for dance and video. The ceiling was perhaps a little low, and the sound less resonant than might have been ideal.

There were seven amalgamated gamelan groups from over the UK who needed to rehearse: around 170 musicians in total! Coordinating all of this was musical director John Pawson, and by and large we got to do what we needed to do, albeit not without a certain amount of last minute stress. A day of hurry up and wait, mostly, with the Scottish group almost missing out on our final fifteen minute run-through.

Now, an interesting aside, but I want to tread carefully, as this concerns an overheard remark. One of the groups was about to rehearse a piece which incorporated clarinet, and someone from one of the other groups was apparently heard to say 'Here comes the sacrilege'. Maybe this was a joke: probably it was a joke. I entirely respect the conservative impulse in traditional musics, but 'sacrilege' seems a very strong word. Of course we were all thinking, 'Wait till he hears the bagpipes!'.

An excellent Indonesian meal was provided for the participants: I had the rendang, always a favourite!

Gathering of the Gamelans - Day 2, afternoon

After lunch today we had a joint session, with three people presenting their experience of teaching gamelan in schools and universities. I am presently engaged on a project to attempt to establish a gamelan at Stevenson College Edinburgh (soon to be Edinburgh College), so this area is of particular interest to me.

Ruth Andrews runs a gamelan programme for 12-17 year olds at the International School of Amsterdam, which sounds like it would be a model to aim for. The gamelan is permanently installed in a large room, and all the students have gamelan activity in every year of their studies. Links are made between the cultural and historical perspectives offered by the gamelan and other areas of the curriculum. The gamelan seems to have become a central, shared experience for everyone at the school: a musical ensemble where everyone takes part on an equal level, with no soloists or stars.

Andy Gleadhill is a music officer in Bristol, where gamelan is firmly established as a whole-class music activity within the primary curriculum. There are 66 (!) specially designed sets of gamelan instruments in their schools. Andy presented some material from a particular project which combined Digital Audio Workstation technology – loops and recording in GarageBand – with gamelan, the students working to put together a hybrid version of a Black Eyed Peas song.

Maria Mendonça outlined a degung programme which she runs at Kenyon College in the States. I don't fully understand the American system, but this seems to be one-semester class which can be taken by either music students or students on other degrees. She works largely by ear rather than using notation, and spoke very positively about the level playing field which can be established between trained and untrained musicians. She described a teaching model where the students have a two-hour class, followed by an hour to work as a group on their own. She seems to use peer teaching extensively, on the very simple model of having students swap around and teach each other the parts: a practice I have also employed.

This was an informative and inspirational setting. Particularly impressive was the roster of visiting artists which Maria had managed to get, which included, wait for it, Euis Komariah, Nano S and Balawan! (Ok, perhaps these names may not mean much to non-gamelan specialists… I was about as impressed as I would have been if she said she had got Ella Fitzgerald, Duke Ellington, and Charlie Christian :)

Later in the afternoon, Charlotte Pugh and John Jacobs gathered a large group of us together for a session billed as a gamelan 'improvisation' workshop, although it seems to me it was more like a session on group devising. Charlotte played to us the outline of a medium length phrase in slendro, which we kind of copied back as a group, or in small teams, in an approximate fashion. John then gave us a similar phrase on the pelog instruments which we also worked on in small teams, and then both pieces of material were combined. A very chaotic sound resulted, but with some definite sense of shape. A short discussion ensued as to what we might then do if this was the first week of an eight-week project. Would the work crystalise into a composition, or would one seek to open up the process to a much more free and unpredictable form of improvisation?

An interesting point of practice which I will file away for future use: they had a couple of mics up, and a dedicated engineer who was able to play back to us instantly the short chunk we had just put together. This instant feedback was a great way for the group to be aware of the whole picture, not just what each subgroup was doing.