Generator

thirty-two-bar AABA, every bar against every other bar

A self-similarity matrix of 32 bars of thirty-two-bar AABA. Each cell is the cosine similarity of two bars' pitch-class vectors, with the chord's own notes weighted 1 and the rest of the key 0.5. Similarity is quantised into four bands for drawing and anything under 0.35 is left as paper. Nothing in the computation knows what a section is; the blocks and stripes are what the arithmetic returns.
thirty-two-bar AABA, every bar against every other bar. A self-similarity matrix of 32 bars of thirty-two-bar AABA. Each cell is the cosine similarity of two bars' pitch-class vectors, with the chord's own notes weighted 1 and the rest of the key 0.5. Similarity is quantised into four bands for drawing and anything under 0.35 is left as paper. Nothing in the computation knows what a section is; the blocks and stripes are what the arithmetic returns.

Drawn above with its standard settings, which is almost never how an essay draws it: an essay states the numbers it is arguing about, so the figure a reader meets there is about that argument rather than about the drawing in general. Every option a placement passes is checked against the ones this function actually reads, because an option it does not read is silently ignored and the figure quietly draws what is above instead.

It makes a noise. 24 of its 24 placements carry sound, built from the same numbers as the drawing, offering these buttons: Bars 17 to 24, The first eight bars, twelve-bar blues, as chords, verse and chorus, as chords.

Called by 6 essays

the blast radius of changing it

thirty-two-bar AABA, every bar against every other bar. A self-similarity matrix of 32 bars of thirty-two-bar AABA. Each cell is the cosine similarity of two bars' pitch-class vectors, with the chord's own notes weighted 1 and the rest of the key 0.5. Similarity is quantised into four bands for drawing and anything under 0.35 is left as paper. Nothing in the computation knows what a section is; the blocks and stripes are what the arithmetic returns.

A piece is mostly itself again

Take a piece of music, encode each bar as the notes sounding in it, and compare every bar with every other bar. The picture that comes out has blocks and stripes in it, and those blocks and stripes are the form — arrived at by arithmetic that has never heard of an exposition, a chorus or a refrain.

form · Repetition
Boundaries found by a local operator, at three kernel widths. Foote's checkerboard novelty computed on the self-similarity matrix of thirty-two-bar AABA, at kernel widths of 2, 4, 8 bars. The dashed verticals are where the encoding's sections actually change; nothing about them enters the computation. A peak is a place where the bars before resemble each other, the bars after resemble each other, and the two groups do not resemble each other.

The boundary is where the neighbourhood changes

A section boundary can be found by an operator that never sees a section. It walks the diagonal of a similarity matrix asking one local question — do the bars behind me resemble each other, do the bars ahead resemble each other, and do the two groups resemble each other — and where the answer is yes, yes, no, there is an edge. What it cannot find turns out to say more than what it can.

form · Repetition
How long until it comes back. Mean similarity along each diagonal of the self-similarity matrix, minus the matrix's own mean off-diagonal similarity, against lag in bars, for 1 case. Lags run to half the length of each scheme, because a longer diagonal holds too few pairs to average. All rows share one vertical scale and the spread of each is printed beside it; the largest is 0.427 and the smallest 0.427. 1 of 1 cases with any spread at all put their strongest lag at the scheme's own repeat unit or a multiple of it.

How long until it comes back

A self-similarity matrix has a second reading that nobody looks for. Add up each diagonal instead of walking along one, and out falls repetition as a function of how long ago — a period, in bars, with no segmentation, no kernel width and no bar numbers anywhere in the answer. Five of the six schemes here report the length a listener would have named. The sixth reports something better.

form · Repetition
The ranking is settled either side of one narrow band. Remembered repetition — each bar's best match to an earlier bar, discounted by exp(−Δt/τ) with Δt in seconds — for 6 schemes at 108 beats a minute, against the decay constant τ on a logarithmic axis. The order of the schemes changes only between 8 and 13 seconds; outside that band it is fixed, so an estimate of τ wrong by any amount that stays outside it leaves the ranking alone.

A return has to be remembered

A stripe four bars off the diagonal and a stripe twenty-four bars off it are the same ink and are not the same experience. Convert the lag axis to seconds, discount every comparison by how long ago it was, and the ranking of these six schemes by how repetitive they are changes — and the decay constant and the tempo turn out to enter the arithmetic as one number rather than two.

perception · Repetition
The boundary operator run over only what has been heard. Foote's checkerboard novelty on thirty-two-bar AABA at a kernel width of 4 bars, computed twice: once with the whole piece available, and once using only the bars heard up to and including each bar. The kernel reaches 4 bars forward, so every cell it needs has been heard 3 bars after its centre — the retrospective curve replotted 3 bars to the right lands on the causal one, and the operator turns out to be causal at a fixed delay rather than blind. The dashed verticals are the encoding's real section boundaries and are not an input.

An ending that can be heard coming

Two measurements are both called hearing an ending coming and they point in opposite directions. By the halfway mark of an ordinary form almost nothing new arrives — and the cost of coding each bar has not fallen at all. Neither statistic says anything is about to stop, because no statistic over content can: predicting the next event well is not predicting that there will not be one.

form · Closure
What survives a change of encoding: verse and chorus. The same 32 bars of verse and chorus under five encodings, scored on the three things measured here measures. Mean off-diagonal similarity says how alike the piece looks to the arithmetic. Recall and precision are the novelty operator's boundaries against the 3 the section plan has, at a kernel of four bars. The period is the strongest peak of the lag profile, in bars. Under the bag of pitch classes every other figure uses, the piece is 90 per cent self-similar and the operator finds 0 per cent of the boundaries; under how far the root moved it finds 100 per cent. The period is the quantity that does not move.

The repeat that is not in the notes

Eight earlier essays compare bars by writing each one as a bag of pitch classes and taking a cosine. Nothing chose that encoding — the first used it and the other seven inherited it. Encode the same six schemes four other ways and one of the three findings survives untouched, one survives with different numbers, and one turns out to have been a statement about the encoding all along: the boundary operator finds none of the section edges in three schemes as a bag of pitch classes and every one of them as tonic, subdominant and dominant.

form · Repetition

All figures · What can be heard