Twelve Tone Matrix Generator

12-Tone Matrix Generator

This free twelve tone matrix generator turns any tone row into the complete 12×12 matrix in one click, laying out all 48 row forms at once — every prime, retrograde, inversion and retrograde-inversion. Type a row, click it in on the keyboard, or load a famous one to get started.

1. Enter a row

Note names (Bb, F#, Cx) or numbers 0–11 with C = 0 (t/e also work for 10/11).

… or click the keys in order

2. Matrix

Twelve-tone matrix

P reads left → right  •  R right → left  •  I top → bottom  •  RI bottom → top. The outlined diagonal is the first pitch of the row.

All 48 row forms

How to use the Twelve Tone Matrix Generator

Enter a twelve tone row and the tool builds the complete 12×12 matrix, giving you all 48 forms of the row at once: 12 primes, 12 retrogrades, 12 inversions and 12 retrograde-inversions.

Entering a row

Type it. The input accepts note names or numbers:

  • Note names — E F G C# F# D# G# D B C A A#. Flats (Bb), double sharps (Cx or C##) and double flats (Dbb) all work.
  • Numbers — 4 5 7 1 6 3 8 2 11 0 9 10, counting semitones up from C, so C = 0 and B = 11. You can write 10 and 11 as t and e (or a and b), and you can run it all together: 45716382e09t.

Separate the pitches with spaces, commas, semicolons, slashes or dashes — whatever you have to hand. Press Enter or click Generate.

One rule worth knowing: the tool decides which notation you’re using by looking for digits. In a row of numbers, e means 11; in a row of note names, e means E natural. Note that typed numbers always count from C = 0, regardless of the Numbering option described below.

Or click it in. Click the piano keys in the order you want them. Each key shows its order position as you go, and the chips underneath track the row taking shape. Undo last removes the most recent pitch, Clear starts over, and Use this row builds the matrix once all twelve are in. You can also click a key you’ve already chosen to remove it from the middle; the remaining pitches keep their order.

Or don’t write one at all. Random row generates a valid row instantly, and the dropdown loads Schoenberg’s Suite Op. 25, Webern’s Variations Op. 27, the Berg Violin Concerto row, an all-interval row, or the plain chromatic scale.

A tone row must contain all twelve pitch classes exactly once, so a duplicate pitch or a row of the wrong length is rejected with an explanation of what’s wrong. Your existing matrix stays on screen while you fix it.

Reading the matrix

The four row forms read outward from the labels on all four sides:

  • P (prime) — read a row left to right
  • R (retrograde) — read the same row right to left
  • I (inversion) — read a column top to bottom
  • RI (retrograde-inversion) — read the same column bottom to top

The subscript on each label is the pitch the form begins on. The top-left cell is your original row’s first note, and the whole top row is the row exactly as you entered it.

The outlined diagonal running corner to corner is a built-in correctness check: in any valid twelve tone matrix, every cell along it holds the same pitch — the first pitch of your row.

Hover any cell to highlight its row and column at once, which is how you find the two forms that share a pitch at a given order position. Click any P, R, I or RI label to lock that form; it stays highlighted and is spelled out in full underneath the matrix. Click it again to release.

Display options

Show switches between note names and integers. Accidentals switches between sharps and flats, which is purely a spelling preference — in twelve tone music, D♯ and E♭ are the same pitch class.

Numbering deserves a word, because textbooks genuinely disagree here and it changes every label on the matrix:

  • C = 0 (fixed) numbers each form by its actual starting pitch class. Schoenberg’s Op. 25 row starts on E, so it’s P4.
  • First note = 0 (relative) numbers each form by its distance from your row’s starting pitch, so your original row is always P0 and everything else is measured from it.

Neither is more correct. Pick whichever your course, textbook or collaborator uses. The setting applies to the cells, the labels and the list of all 48 forms together, so the matrix stays internally consistent.

The interval succession

Under the row you’ll see its interval succession — the ascending semitone distance between each adjacent pair. For the Op. 25 row it reads 1 2 6 5 9 5 6 9 1 9 1. This is the row’s fingerprint: every prime and retrograde form shares it, so it tells you at a glance whether two rows are transpositions of each other, and it’s where you look for the internal symmetries and recurring intervals a composer builds on.

Getting the results out

Expand All 48 row forms for the complete list written out, grouped by transformation. Copy as text gives you the matrix as aligned columns for pasting into notes or a document, Copy as CSV and Download CSV give you a spreadsheet, and Print opens a clean printable copy in a new window.

A short primer

Skip this if you already work with rows.

A tone row is an ordering of all twelve pitch classes, each used exactly once, and it’s the basic material of twelve tone composition. “Pitch class” means the note regardless of octave — every C is the same pitch class — so a row fixes the order of the twelve notes, not their register, rhythm or dynamics. All twelve sounded once through is called an aggregate.

A row can be transformed four ways, and all four count as the same row:

  • Prime (P) — the row as written.
  • Retrograde (R) — the row backwards.
  • Inversion (I) — every interval flipped in direction. Where the row rises a semitone, the inversion falls a semitone.
  • Retrograde-inversion (RI) — the inversion, backwards.

Each of the four can start on any of the twelve pitch classes, which gives 48 forms in total. The matrix is simply all 48 arranged so you can read any of them off a single grid — that’s its entire purpose, and it’s why one sheet of paper can serve an entire piece.

In practice you use it to answer questions that come up while composing. I need a form that starts on G♯ so it continues from the note I just wrote — scan the labels for the pitch you want. Which inversion shares its first three notes with my prime? — lock a form and compare, since shared segments between forms are what let you move between rows smoothly, and finding them is most of the craft. Composers also check for combinatoriality: whether the first six notes of one form and the first six of another together complete all twelve pitch classes, letting two forms sound at once without doubling a pitch. To test it, lock a P form and an I form and compare their opening hexachords for overlap.

The default row is from Schoenberg’s Suite Op. 25, the first piece composed entirely with the method. Its last four pitch classes are A, B♭, B and C — the BACH motive, spelling B♭-A-C-B♮ in German notation.

What is a twelve tone matrix?

A twelve tone matrix is a 12×12 grid that lays out all 48 forms of a tone
row on a single sheet — the 12 primes, 12 retrogrades, 12 inversions and 12
retrograde-inversions. Composers use it to read off any form of the row at a
glance while writing.

How do I use this twelve tone matrix generator?

Enter a tone row as note names (E F G C♯ …) or numbers (0–11, with C = 0),
or click the piano keys in order. Press Generate and the tool builds the full
matrix, with every prime, retrograde, inversion and retrograde-inversion
labelled around the edges.

How do I read the matrix?

Read prime forms left to right, retrogrades right to left, inversions down a
column, and retrograde-inversions up a column. Each label’s subscript is the
pitch the form starts on, and the diagonal from corner to corner always holds
your row’s first pitch — a built-in check that the matrix is valid.

Can I enter a row as numbers instead of note names?

Yes. Type integers 0–11 counting semitones up from C (C = 0, B = 11). You can
write 10 and 11 as t and e, and run the whole row together, e.g. 45716382e09t.

Help keep these tools free

StudioManager

Cloud-based studio management software for recording studios, engineers, and music producers.

Excerpt from
Key Mo Therapy
Brother Grinn
Before After
Before
0:00 0:00

What do you think of the Twelve Tone Matrix Generator?

Leave a Reply

Your email address will not be published. Required fields are marked *

I’m just a music maker helping others out.

I’ve made these tools free to use. If you find them valuable, consider supporting the site with a small “thank you” coffee. You choose how much. It will help cover costs.