Artificial Wasteland — what makes the major scale special, counted

Each Interval, a Different Number of Times

an instrument  ·  the deep-scale property  ·  and a count that turns out to be Euler's totient

Pick seven of the twelve notes the way the major scale does, and a strange bookkeeping falls out: every size of interval appears, and no two of them appear the same number of times. Almost no scale manages that.

I · The major scale keeps a unique tally

There are 212 = 4096 ways to choose a subset of the twelve pitch classes, and music has spent centuries circling a tiny handful of them. The major scale — the white keys, {0,2,4,5,7,9,11} — is the most circled of all. There are many ways to say why it's special; here is one that is purely combinatorial and that you can check by counting on your fingers.

Take the scale and tally its intervals by class: how many pairs of notes sit a semitone apart (class 1), how many a whole tone (class 2), and so on up to the tritone (class 6). For the major scale the tally is ⟨2, 5, 4, 3, 6, 1⟩ — two semitones, five whole tones, four minor thirds, three major thirds, six perfect fourths, one tritone. Look at those six numbers: 1, 2, 3, 4, 5, 6, each used exactly once. No interval class is as common as any other. A scale with this property — every interval class occurring a different number of times — is called deep (the term is Terry Winograd's, 1966; the theory is Carlton Gamer's, 1967). The major scale is the deep scale everyone knows. Here is the instrument; the major scale is loaded. Move the notes and watch the tally.

the instrument — click the ring to add or remove notes; the tally is recomputed live
interval-class vector — bar d counts the pairs an interval class d apart
common tones with itself, transposed by t semitones (the same numbers, read another way)
universe n

II · The same fact, read as common tones

There is a second way to see deepness, and the instrument shows it on the strip below the histogram. Slide the whole scale up by t semitones and ask how many of its notes land back on notes it already had: the common tones with its own transposition. For the major scale this count is 2 for a one-semitone shift, 5 for two, and so on: the very same numbers 2, 5, 4, 3, 6. That is no accident. Short of the tritone, the number of common tones under a shift of t is the interval-class tally at t (each shared pair of notes is exactly an interval of size t); at the tritone each pair is met from both ends, so the count is twice the tally. So a deep scale is one you can identify by its shadow: every shift short of the tritone overlaps it by a different amount (a shift down overlaps it just as the same shift up does). Gamer's word for it was deep; Richmond Browne (1981) called this the diatonic's position-finding power, the reason a few notes are enough to tell you what key you're in.

III · The pentatonic is not deep — evenness isn't the same thing

It is tempting to think deepness is just another name for the major scale being evenly spread. It isn't. The black keys — the pentatonic {0,2,4,7,9} — are spread as evenly as five notes in twelve can be (they are a maximally even set, the sibling fact this ground's Euclidean-rhythms layer turns into a drum). Yet their tally is ⟨0,3,2,1,4,0⟩: two classes tie at zero, so the pentatonic is not deep. The whole-tone scale {0,2,4,6,8,10}, more even still, tallies ⟨0,6,0,6,0,3⟩ — riddled with ties. Maximal evenness and deepness are different kinds of specialness, and the major scale is rare in holding both. (Load the presets and watch the bars: a tie turns a bar dark.)

IV · How many deep scales are there?

Once the property is stated for twelve notes it asks to be stated for any number. Work in Zn — n equally spaced slots on a circle — and call a subset deep when its ⌊n/2⌋ interval-class counts are all different. Now a flat combinatorial question: in each universe of size n, how many deep scales are there? We counted — exactly, by walking every one of the 2n subsets — and got the sequence below. The instrument will recompute any single term in front of you; then we will tell you what the sequence actually is, because the honest answer surprised us.

count the deep scales in the current universe — live, by exhaustive enumeration

Two sequences, depending on whether you count a scale and its transpositions as the same object. Counting every subset (sequence A), and counting up to transposition — i.e. as a necklace on the circle (sequence C):

deep scales in Zn, n = 2 … 34 (each term re-derivable above) — and Euler's totient φ(n) beneath, for comparison
read the bottom two rows together: C(n) and φ(n) agree at every n ≥ 7 — they part only at the shaded n = 4 and n = 6

We searched the On-Line Encyclopedia of Integer Sequences for both sequences, in several windows, and neither came back — so the first version of this page reported them as absent from OEIS, a small discovery. That was true to the letter and wrong to the spirit, and the bottom row of the table above is the giveaway.

V · The count is Euler's totient

Line up C(n) — the deep scales up to transposition — against φ(n), Euler's totient, the count of numbers below n that share no factor with it. From n = 7 on they are the same sequence, term for term, with no exception we can find or that the proof allows:

C(n) = φ(n)  (deep scales up to transposition)  ·  A(n) = n·φ(n)  (counting every subset),  for all n ≥ 7.

So the "uncatalogued" sequences are two of the most catalogued objects in mathematics wearing a disguise: C is OEIS A000010 (the totient) and A is A002618 (n·φ(n)). The search returned "no results" only because the verbatim strings carry odd small terms (in C, C(4)=4 where φ(4)=2, and C(6)=3 where φ(6)=2; in A, every term below n = 7 except A(5)), and those off-key heads were enough to slip past an exact-match search. The first pass even saw the totient flicker by in the fuzzy matches and waved it off: "C(4)=4 ≠ φ(4)=2, so C is not the totient." But two small exceptions are not a refutation; they are the two small exceptions. The rule is the totient.

VI · Why it has to be the totient

The reason is a theorem that was already in the literature — and that the first pass missed. Up to transposition, every deep scale is a "generated" scale (a chain of a single interval, the way the major scale is a chain of fifths F C G D A E B) with one lone exception: {0,1,2,4} ⊂ Z6, tally ⟨2,3,1⟩ — deep, yet built by stacking no single interval. This is not our observation; it is a proved classification (Winograd, 1966; independently Clough, Engebretsen & Kochavi, 1999; stated cleanly with the Z6 exception named by Demaine and colleagues, 2005). The non-generated deep scale isn't merely "a counterexample to a slogan" — it is the only one, in any universe, forever.

Granting that classification, the count falls out. A generated deep scale is a chain {0, g, 2g, …} of length ⌊n/2⌋ or ⌊n/2⌋+1 whose step g is coprime to n; there are φ(n) such steps, and two lengths, giving 2φ(n) chains. Each scale is counted twice: a chain and its mirror, g and n−g, are the same necklace. And nothing collapses them further, because the generator is recoverable from the scale: in a deep scale's tally the generator's interval class is the unique tallest bar (try it: load the major scale and the longest bar, the six perfect fourths, sits at interval class 5, the fifth that generates it). So 2φ(n) chains fold exactly in half: C(n) = φ(n). Every deep scale from n = 5 on turns out to be aperiodic, so each necklace stands for n distinct subsets, and A(n) = n·φ(n). The full argument, machine-checked over every deep scale through n = 34, is in research/deep-scales/census-theorem.md.

The old "prime law" is just this seen at a prime: for p ≥ 5 every nonzero step is coprime to p, so φ(p) = p − 1 deep scales up to transposition and p(p−1) in all — a special case of C = φ, not a separate fact.

VII · What the count was also hiding

Every deep scale is its own mirror. Reflect any deep scale — turn it inside out, the way inversion does in music — and you get back the same scale, up to transposition, always (checked for every deep scale through n = 34). This is why counting up to transposition already counts up to reflection too: the two columns would be identical. It also drives the proof above — the mirror of a chain on g is the chain on n−g, which is why the 2φ(n) chains fold cleanly to φ(n).

And the small print is worth keeping. The clean C = φ holds for n ≥ 7; the universes n = 4 and n = 6 are the only ones that break it, and they break it in opposite directions — n = 6 runs one over the totient, and that one extra is exactly the sporadic {0,1,2,4} (it is in the instrument as a preset); n = 4 runs over because two small scales there are deep without being coprime chains. Two anomalies, both named, both understood. The honest correction is the whole point: the sequence was never new — it was the totient, and saying so is truer than keeping the disguise.

◆

The check

Everything numeric on this page is recomputed here in your browser and, offline, by research/deep-scales/verify.mjs — 58000+ assertions, all passing. A scale S ⊆ Zn with |S| ≥ 2 is deep iff its interval-class vector ic[d] = #{ {x,y}⊆S : x−y ≡ ±d }, for d = 1 … ⌊n/2⌋, has all entries distinct. The verifier builds ic three independent ways (direct pair count; rotation-popcount; explicit circular autocorrelation) and ties it to common-tone counts |S ∩ (S+t)|; it confirms the diatonic's tally ⟨2,5,4,3,6,1⟩, that every deep set is inversionally symmetric and, from n = 5 on, aperiodic, and (the result of this second pass) that C(n) = φ(n) and A(n) = n·φ(n) for every n ≥ 7 (C deviating from n = 2 to 6 only at n = 4, 6), together with the generator-recovery lemma that forces it. A standalone proof-check, lemmas.mjs, verifies the classification and the totient identity over every deep scale through n = 24; an exact C census (census.c) confirms it through n = 34 with no new sporadic. The proof is written out in census-theorem.md.

Sources & honest scope

The deep-scale property: T. Winograd (1966, unpub.); Carlton Gamer, "Some Combinational Resources of Equal-Tempered Systems," Journal of Music Theory 11/1 (1967), 32–59. The classification of deep scales as the coprime-generated chains plus the lone exception {0,1,2,4}⊂Z6: Winograd (1966); independently J. Clough, N. Engebretsen & J. Kochavi, "Scales, Sets, and Interval Cycles: A Taxonomy," Music Theory Spectrum 21/1 (1999), 74–104; stated with the exception named in E. Demaine et al., "The Distance Geometry of Music," Comp. Geom. 42/5 (2009), 429–454. Common-tone / position-finding: R. Browne, In Theory Only 5 (1981). Maximal evenness: J. Clough & J. Douthett (1991); rhythm cousin, G. Toussaint. What is ours, and checked: the proof that the deep-scale count is the totient — C(n)=φ(n) (A000010), A(n)=n·φ(n) (A002618) for n ≥ 7 — derived from the cited classification, machine-checked through n = 34. The correction: an earlier version of this page reported A and C as "absent from OEIS." The verbatim strings are absent, but only because of the n ≤ 6 heads; the sequences are the totient and n·φ(n), and there is no new sequence here to catalogue. The deep property and its named theorems are the literature's, cited above.

← the maximally-even sibling: the algorithm that drums  ·  return to the ground

Corrections

Corrected 2026-11-01: This page said both sequences were off the totient pair only at n = 4 and n = 6. That holds for C from n = 2 on, but A, the count of every deep subset, also parts from n·φ(n) at n = 2 and n = 3 (A(2) = 1 against 2, A(3) = 4 against 6, by the page's own table; A(1) = 0 against 1 as well), so A's verbatim string differs from A002618 at every term below n = 7 except n = 5 (found by the assay sweep, 2026-11-01).

Corrected 2026-11-01: This page said every deep scale is aperiodic, and that its verifier confirms this for every deep set. The verifier checks it only from n = 5 on, and below that it fails: {0,2} in Z4 has tally ⟨0,1⟩, is deep, and repeats after two steps, which is why A(4) = 11 rather than 4·4. It now says every deep scale from n = 5 on is aperiodic (found by the assay sweep, 2026-11-01).

Corrected 2026-11-01: This page called A002618, n·φ(n), Pillai's function. Pillai's arithmetical function is a different sequence, the sum of gcd(k, n) for k = 1 to n, OEIS A018804 ("Pillai's arithmetical function: Sum_{k=1..n} gcd(k, n)"); A002618 is titled simply "a(n) = n*phi(n)" (found by the assay sweep, 2026-11-01).

Corrected 2026-11-01: This page said every transposition of a deep scale overlaps it by a different amount, so each of the eleven other keys is a different distance from home, and that the common tones under a shift of t are the interval-class tally at t. A shift up and the same shift down always overlap alike, and at the tritone the count is twice the tally: by the page's own common-tone strip the major scale shares 2 notes with the keys a semitone up, a semitone down and a tritone away, and 6 with the keys a fourth and a fifth away (found by the assay sweep, 2026-11-01).

Corrected 2026-11-01: This page's instrument offered {0,1,3} in Z7 as "a deep 7-universe scale". Its tally is ⟨1,1,1⟩, every class tied, so it is not deep, as the instrument's own verdict showed; the preset is now {0,1,2,3}, tally ⟨3,2,1⟩ (found by the assay sweep, 2026-11-01).