Mathematical Preliminaries for Music Analysis
Chapter 1: Mathematical Preliminaries for Music Analysis
The Fundamental Question: Why Mathematics for Music?
Music, at its essence, presents a profound paradox. It exists in time as a sequence of sonic events, yet we speak of it as if it were a spatial object—a architecture of sound with identifiable structures, recurring patterns, and systematic relationships. When we hear a dominant seventh chord resolve to the tonic, we recognize this transformation instantaneously, drawing upon internalized knowledge of tonal grammar. Yet this recognition, so natural to the trained ear, conceals an extraordinarily complex web of relationships that resist casual description. How many distinct pitch classes constitute the major scale? What transformation converts one chord into another? Which intervals are equivalent under inversion? These questions demand precision that ordinary language cannot provide.
This chapter confronts a foundational challenge: the development of rigorous mathematical formalisms capable of capturing musical phenomena with the precision required for serious analytical work. The question is not merely academic. Throughout the history of music theory, scholars have sought mathematical tools to illuminate structural relationships invisible to casual listening. From Euler's attempts to quantify harmonic relationships in the eighteenth century to the set-theoretic revolution of the late twentieth century, mathematics has served as both lens and language for understanding musical organization. Yet the choice of mathematical framework matters profoundly—a coarse tool obscures nuance, while an overly elaborate apparatus obscures the music itself in technical machinery.
The mathematical prerequisites for music analysis span several interconnected domains. Set theory provides the vocabulary for describing collections of pitches and their relationships. Group theory offers a framework for understanding transformations and symmetries that govern musical operations. Modular arithmetic captures the cyclic nature of pitch space, where octave equivalence creates identifications that would confound ordinary arithmetic. Topology supplies concepts for understanding continuity and proximity in abstract musical spaces. Together, these mathematical structures form a toolkit whose deployment throughout this book will illuminate phenomena ranging from simple interval relationships to the deepest architecture of tonal harmony.
Our approach proceeds systematically. First, we establish how musical objects—pitches, intervals, chords, scales—can be represented as mathematical sets. Second, we examine how the operations musicians perform on these objects correspond to group-theoretic structures. Third, we explore modular arithmetic as the arithmetic of pitch space, where addition and multiplication acquire musical meanings. Fourth, we introduce topological concepts that will prove essential for understanding voice-leading and smooth transitions between musical states. Throughout, we maintain explicit connection between mathematical formalism and musical interpretation, ensuring that abstraction serves understanding rather than replacing it.
---
Set Theory Fundamentals and Pitch Class Representation
From Continuous Pitch to Discrete Pitch Classes
Western music, despite its infinite expressive range, operates upon a surprisingly constrained collection of pitch materials. The piano keyboard presents us with eighty-eight keys, yet music theory typically reduces these to twelve pitch classes—the seven letter names (A through G) with five accidentals (sharps and flats), each spanning all octaves. This reduction, seemingly a crude simplification, actually captures something essential about musical perception: pitches separated by octaves sound fundamentally alike, differing in "brightness" or "register" rather than in qualitative character. A middle C and high C share an identity that C♯ does not share with either, and this identity matters musically. When a melody doubles at the octave, we hear reinforcement rather than duplication; when a bass line moves in parallel tenths with an upper voice, the relationship between those voices persists despite the register difference.
The pitch class concept formalizes this intuition. Formally, a pitch class is an equivalence class of pitches under octave equivalence. Each pitch class groups together all pitches separated by integer multiples of the octave—the interval of twelve semitones. The collection of all pitch classes forms a set with precisely twelve elements, which we index using the integers 0 through 11. This indexing scheme, widely adopted in post-tonal theory since its systematization by Allen Forte and others, provides a convenient computational representation:
$$PC = \{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11\}$$
In this scheme, the pitch class 0 corresponds to C (and all its enharmonic equivalents, including B♯ and D𝄫); pitch class 1 corresponds to C♯/D♭; continuing through pitch class 11, which corresponds to B. This mapping is entirely conventional—we could equally well begin with 0 as D or F♯—but once established, it provides a shared language for precise discussion.
Example 1.1: Translating Musical Objects into Pitch Class Sets
Consider the C major scale: C-D-E-F-G-A-B. In pitch class terms, this translates to the set {0, 2, 4, 5, 7, 9, 11}. The C minor scale (C-D♭-E♭-F-G♭-A♭-B♭) becomes {0, 1, 3, 5, 7, 8, 10}. The diminished chord built on C (C-E♭-G♭) maps to {0, 3, 6}. The dominant seventh chord on G (G-B-D-F) becomes {7, 11, 2, 5} or, expressed in normal order (discussed below), {2, 5, 7, 11}.
This translation from musical notation to numerical representation is the foundation upon which all subsequent analysis builds. It is not merely a notational convenience; it reveals structural relationships that transcend the particular key in which music is written. The set {0, 3, 7}—representing a C minor triad—has the same intervallic structure as {5, 8, 0}, representing an F minor triad. Set theory exposes this kinship, enabling comparisons across keys that notation cannot easily support.
Subsets, Power Sets, and the Universe of Possible Chords
Having established pitch classes as primitive elements, we can now construct more complex musical objects as sets of pitch classes. A chord, in this framework, is simply a set of pitch classes. A scale is a seven-element subset. An interval is a two-element subset. This representational scheme reveals its power when we consider the collection of all possible subsets—the power set.
The power set of the twelve-element pitch class universe contains $2^{12} = 4096$ distinct elements, ranging from the empty set (musically meaningless but mathematically necessary) through all singleton pitch classes, all possible dyads, triads, tetrads, and larger collections, up to the universal set {0, 1, 2, ..., 11} containing all twelve pitch classes. This 4096-element universe contains every possible chord, every possible scale, every possible collection of pitches that Western music might employ. While most of these subsets have never been musically significant, their existence as mathematical objects establishes a complete space within which we can situate actual musical structures and analyze their relationships.
The power set notation proves useful for cataloging collections. If $U$ denotes the universal set of all twelve pitch classes, then the power set $\mathcal{P}(U)$ denotes the set of all subsets of $U$. Every chord, every scale, every pitch collection in Western music belongs to $\mathcal{P}(U)$. This formal framing enables precise statements: we can say that a particular chord $C$ is an element of $\mathcal{P}(U)$, that one chord $C_1$ is a subset of another chord $C_2$, that two chords share a particular intersection, and so forth. These seemingly obvious observations become powerful analytical tools when systematically applie