# Dual list

This page gives a more mathematical take on this topic. For a basic introduction, see comma basis.

## Definition

If A is an integral matrix, denote by Saturate (A) the integral matrix which is the saturation of A, defined in terms of the right reducing matrix to Smith normal form. We may clean the result up a little by LLL reduction, so let Sat (A) = LLL (Saturate (A)). The square matrix with rational coefficients A^{+}A, where A^{+} is the pseudoinverse of A, is an *n*×*n* projection matrix, where *n* is the number of columns of A. Let us also define Clear (P) to be the rational number matrix P cleared of denominators by multiplying through the rows by the LCM of the denominators, and Hrm (A) to be the Hermite reduction of A, with any rows consisting of zeros removed. We may combine these into the dual list function: Dulist (A) = Sat (Hrm (Clear (I - A^{+}A))), where I is the *n*×*n* identity matrix.

The interest of the dual list stems from the fact that if A is a list of vals defining a temperament, then Dulist (A) is a list of monzos defining the same temperament, and conversely – Dulist applied to a list of monzos defining a temperament gives a list of vals defining the same temperament.

## Examples

Dulist ([⟨31 49 72 87 107], ⟨41 65 95 115 142], ⟨72 114 167 202 249]]) = [[-3 2 -1 2 -1⟩, [-2 -3 -1 2 1⟩, [-2 0 3 -3 1⟩]

In this first example, the mapping contains a redundant row; the third row is a linear combination of the other two (31 + 41 = 72, 49 + 65 = 114, etc.). Therefore, the dual list operation returns a comma basis with nullity 3, because the rank is truly 2 (and the rank and nullity must sum to the dimensionality, which is 5 here, because there are 5 terms in each map and comma, i.e. it is 11-limit).

Dulist ([[-3 2 -1 2 -1⟩, [-2 -3 -1 2 1⟩, [-2 0 3 -3 1⟩]) = [⟨1 1 3 3 2], ⟨0 6 -7 -2 15]]

Dulist ([⟨1 1 3 3 2], ⟨0 6 -7 -2 15]]) = [[-3 2 -1 2 -1⟩, [-2 -3 -1 2 1⟩, [-2 0 3 -3 1⟩]