«How to write a Pbind in a specific key (tonality) or mode» by Bruno Ruviaro

on 26 Nov'25 15:58 in minormodeskeysmajormixolydian

Modes, scales, keys (tonal music) inside Pbinds. How to write a Pbind for example G minor or mixolydian #4 sing \scale and \degree.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
// MODES, SCALES, KEYS inside Pbinds

// How to write Pbinds in a specific key, for example G minor
// (using \scale and \degree inside Pbind)

(
Pbind(
	\scale, Scale.minor, // natural minor scale
	\degree, Pseq([0, 1, 2, 3, 4, 5, 6s, 7, 8, 9, 10, 11]), // s for sharp, b for flats as needed
	\root, 7, // 0 is C, 1 is C#, etc. For G minor, we put the root at 7 (seven semitones above C)
	\dur, 1/2
).play
)

// \degree considers 0 to be the first scale degree.
// If you prefer to think of 1 as the first scale degree (like in "movable do" solfege), simply add -1 to the end of the line.
// The example below is in Eb Major
(
Pbind(
	\scale, Scale.major,
	\degree, Pseq([1, 2, 3, 4, 5, 6, 7, 8]) - 1,
	\root, 3, // Eb Major
	\dur, 1/2
).play
)

// F Mixolydian #4
(
Pbind(
	\scale, Scale.mixolydian,
	\degree, Pseq([1, 2, 3, 4s, 5, 6, 7, 8], 3) - 1,
	\root, 5, // F mixolydian with #4
	\dur, 1/4
).play
)

Scale.directory;
raw 960 chars (focus & ctrl+a+c to copy)
reception
comments