Tenney–Euclidean metrics: Difference between revisions
m Improve readability |
m Improve readability |
||
| Line 1: | Line 1: | ||
__FORCETOC__ | __FORCETOC__ | ||
==The weighting matrix== | == The weighting matrix == | ||
Let us define the val weighting matrix W to be the [[wikipedia:diagonal matrix|diagonal matrix]] with values 1, 1/log<sub>2</sub>3, 1/log<sub>2</sub>5 … 1/log<sub>2</sub>p along the diagonal. Given a val "a" expressed as a row vector, the corresponding vector in weighted coordinates is aW, with transpose Wa<sup>T</sup> where the <sup>T</sup> denotes the transpose. Then the dot product of weighted vals is aW<sup>2</sup>a<sup>T</sup>, which makes the Euclidean metric on vals, a measure of complexity, to be || <a<sub>2</sub> a<sub>3</sub> … a<sub>''p''</sub>| ||<sub>2</sub> = sqrt (a<sub>2</sub><sup>2</sup> + a<sub>3</sub><sup>2</sup>/(log<sub>2</sub>3)<sup>2</sup> + … + a<sub>p</sub><sup>2</sup>/(log<sub>2</sub>''p'')<sup>2</sup>); dividing this by sqrt (''n''), where ''n'' = π(''p'') is the number of primes to ''p'' gives the Tenney-Euclidean, or TE, norm. Similarly, if b is a monzo, then in weighted coordinates the monzo becomes bW<sup>-1</sup>, and the dot product is bW<sup>-2</sup>b<sup>T</sup>, leading to sqrt (b<sub>2</sub><sup>2</sup> + (log<sub>2</sub>3)<sup>2</sup>b<sub>3</sub><sup>2</sup> + … + (log<sub>2</sub>''p'')<sup>2</sup>b<sub>''p''</sub><sup>2</sup>); multiplying this by sqrt (''n'') gives the dual RMS norm on monzos, a measure of complexity we may call the Tenney-Euclidean, or TE, complexity. | Let us define the val weighting matrix W to be the [[wikipedia:diagonal matrix|diagonal matrix]] with values 1, 1/log<sub>2</sub>3, 1/log<sub>2</sub>5 … 1/log<sub>2</sub>p along the diagonal. Given a val "a" expressed as a row vector, the corresponding vector in weighted coordinates is aW, with transpose Wa<sup>T</sup> where the <sup>T</sup> denotes the transpose. Then the dot product of weighted vals is aW<sup>2</sup>a<sup>T</sup>, which makes the Euclidean metric on vals, a measure of complexity, to be || <a<sub>2</sub> a<sub>3</sub> … a<sub>''p''</sub>| ||<sub>2</sub> = sqrt (a<sub>2</sub><sup>2</sup> + a<sub>3</sub><sup>2</sup>/(log<sub>2</sub>3)<sup>2</sup> + … + a<sub>p</sub><sup>2</sup>/(log<sub>2</sub>''p'')<sup>2</sup>); dividing this by sqrt (''n''), where ''n'' = π(''p'') is the number of primes to ''p'' gives the Tenney-Euclidean, or TE, norm. Similarly, if b is a monzo, then in weighted coordinates the monzo becomes bW<sup>-1</sup>, and the dot product is bW<sup>-2</sup>b<sup>T</sup>, leading to sqrt (b<sub>2</sub><sup>2</sup> + (log<sub>2</sub>3)<sup>2</sup>b<sub>3</sub><sup>2</sup> + … + (log<sub>2</sub>''p'')<sup>2</sup>b<sub>''p''</sub><sup>2</sup>); multiplying this by sqrt (''n'') gives the dual RMS norm on monzos, a measure of complexity we may call the Tenney-Euclidean, or TE, complexity. | ||
==Temperamental complexity== | == Temperamental complexity == | ||
Suppose now A is a matrix whose rows are vals defining a ''p''-limit regular temperament. Then the corresponding weighted matrix is V = AW. The [[Tenney-Euclidean_Tuning|TE tuning]] projection matrix is then V<sup>+</sup>V, where V<sup>+</sup> is the [[Tenney-Euclidean_Tuning|pseudoinverse]]. If the rows of V (or equivalently, A) are linearly independent, then we have V<sup>+</sup> = V<sup>T</sup>(VV<sup>T</sup>)<sup>-1</sup>, where V<sup>T</sup> denotes the transpose. In terms of vals, the tuning projection matrix is P = V<sup>+</sup>V = V<sup>T</sup>(VV<sup>T</sup>)<sup>-1</sup>V = WA<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>AW. P is a [http://en.wikipedia.org/wiki/Positive-definite_matrix positive semidefinite matrix], so it defines a [http://en.wikipedia.org/wiki/Definite_bilinear_form positive semidefinite bilinear form]. In terms of weighted monzos m<sub>1</sub> and m<sub>2</sub>, m<sub>1</sub><sup>T</sup>Pm<sub>2</sub> defines the semidefinite form on weighted monzos, and hence b<sub>1</sub><sup>T</sup>W<sup>-1</sup>PW<sup>-1</sup>b<sub>2</sub> defines a semidefinite form on unweighted monzos, in terms of the matrix W<sup>-1</sup>WA<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>AWW<sup>-1</sup> = A<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>A = '''P'''. From the semidefinite form we obtain an associated [http://en.wikipedia.org/wiki/Definite_quadratic_form semidefinite quadratic form] b<sup>T</sup>'''P'''b and from this the [http://en.wikipedia.org/wiki/Norm_%28mathematics%29 seminorm] sqrt (b<sup>T</sup>'''P'''b). | Suppose now A is a matrix whose rows are vals defining a ''p''-limit regular temperament. Then the corresponding weighted matrix is V = AW. The [[Tenney-Euclidean_Tuning|TE tuning]] projection matrix is then V<sup>+</sup>V, where V<sup>+</sup> is the [[Tenney-Euclidean_Tuning|pseudoinverse]]. If the rows of V (or equivalently, A) are linearly independent, then we have V<sup>+</sup> = V<sup>T</sup>(VV<sup>T</sup>)<sup>-1</sup>, where V<sup>T</sup> denotes the transpose. In terms of vals, the tuning projection matrix is P = V<sup>+</sup>V = V<sup>T</sup>(VV<sup>T</sup>)<sup>-1</sup>V = WA<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>AW. P is a [http://en.wikipedia.org/wiki/Positive-definite_matrix positive semidefinite matrix], so it defines a [http://en.wikipedia.org/wiki/Definite_bilinear_form positive semidefinite bilinear form]. In terms of weighted monzos m<sub>1</sub> and m<sub>2</sub>, m<sub>1</sub><sup>T</sup>Pm<sub>2</sub> defines the semidefinite form on weighted monzos, and hence b<sub>1</sub><sup>T</sup>W<sup>-1</sup>PW<sup>-1</sup>b<sub>2</sub> defines a semidefinite form on unweighted monzos, in terms of the matrix W<sup>-1</sup>WA<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>AWW<sup>-1</sup> = A<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>A = '''P'''. From the semidefinite form we obtain an associated [http://en.wikipedia.org/wiki/Definite_quadratic_form semidefinite quadratic form] b<sup>T</sup>'''P'''b and from this the [http://en.wikipedia.org/wiki/Norm_%28mathematics%29 seminorm] sqrt (b<sup>T</sup>'''P'''b). | ||
| Line 10: | Line 10: | ||
Denoting the temperament-defined, or temperamental, seminorm by T(x), the subspace of interval space such that T(x) = 0 contains a lattice consisting of the commas of the temperament, which is a sublattice of the lattice of monzos. The [http://en.wikipedia.org/wiki/Quotient_space_%28linear_algebra%29 quotient space] of the full vector space by the commatic subspace such that T(x) = 0 is now a [http://en.wikipedia.org/wiki/Normed_vector_space normed vector space] with norm given by T, in which the intervals of the regular temperament define a lattice. The norm T on these lattice points is the '''temperamental norm''' or '''temperamental complexity''' of the intervals of the regular temperament; in terms of the basis defined by A, it is sqrt (t<sup>T</sup>''P''t) where t is the image of a monzo b by t = Ab. | Denoting the temperament-defined, or temperamental, seminorm by T(x), the subspace of interval space such that T(x) = 0 contains a lattice consisting of the commas of the temperament, which is a sublattice of the lattice of monzos. The [http://en.wikipedia.org/wiki/Quotient_space_%28linear_algebra%29 quotient space] of the full vector space by the commatic subspace such that T(x) = 0 is now a [http://en.wikipedia.org/wiki/Normed_vector_space normed vector space] with norm given by T, in which the intervals of the regular temperament define a lattice. The norm T on these lattice points is the '''temperamental norm''' or '''temperamental complexity''' of the intervals of the regular temperament; in terms of the basis defined by A, it is sqrt (t<sup>T</sup>''P''t) where t is the image of a monzo b by t = Ab. | ||
==Octave equivalent TE seminorm== | == Octave equivalent TE seminorm == | ||
Instead of starting from a matrix of vals, we may start from a matrix of monzos. If B is a matrix with rows of monzos spanning the commas of a regular temperament, then M = BW<sup>-1</sup> is the corresponding weighted matrix. Q = M<sup>+</sup>M is a projection matrix dual to P = I - Q, where I is the identity matrix, and P is the same symmetric matrix as in the previous section. If the rows define a basis for the commas of the temperament, and are therefor linearly independent, then P = I - M<sup>T</sup>(MM<sup>T</sup>)<sup>-1</sup>M = I - W<sup>-1</sup>B<sup>T</sup>(BW<sup>-2</sup>B<sup>T</sup>)<sup>-1</sup>BW<sup>-1</sup>, and mPm<sup>T</sup> = bW<sup>-1</sup>PW<sup>-1</sup>b<sup>T</sup>, or b(W<sup>-2</sup> - W<sup>-2</sup>B<sup>T</sup>(BW<sup>-2</sup>B<sup>T</sup>)<sup>-1</sup>BW<sup>-2</sup>)b<sup>T</sup>, so that the terms inside the parenthesis define a formula for '''P''' in terms of the matrix of monzos B. | Instead of starting from a matrix of vals, we may start from a matrix of monzos. If B is a matrix with rows of monzos spanning the commas of a regular temperament, then M = BW<sup>-1</sup> is the corresponding weighted matrix. Q = M<sup>+</sup>M is a projection matrix dual to P = I - Q, where I is the identity matrix, and P is the same symmetric matrix as in the previous section. If the rows define a basis for the commas of the temperament, and are therefor linearly independent, then P = I - M<sup>T</sup>(MM<sup>T</sup>)<sup>-1</sup>M = I - W<sup>-1</sup>B<sup>T</sup>(BW<sup>-2</sup>B<sup>T</sup>)<sup>-1</sup>BW<sup>-1</sup>, and mPm<sup>T</sup> = bW<sup>-1</sup>PW<sup>-1</sup>b<sup>T</sup>, or b(W<sup>-2</sup> - W<sup>-2</sup>B<sup>T</sup>(BW<sup>-2</sup>B<sup>T</sup>)<sup>-1</sup>BW<sup>-2</sup>)b<sup>T</sup>, so that the terms inside the parenthesis define a formula for '''P''' in terms of the matrix of monzos B. | ||
To define the '''octave equivalent Tenney-Euclidean seminorm''', or '''OETES''', we simply add a row |1 0 0 … 0> representing 2 to the matrix B. An alternative proceedure is to find the [[Normal_lists|normal val list]], and remove the first val from the list, corresponding to the octave or some fraction thereof, and proceed as in the previous section on temperamental complexity. This seminorm is a measure of the octave-equivalent complexity of a given ''p''-limit rational interval in terms of the ''p''-limit regular temperament given by A. | To define the '''octave equivalent Tenney-Euclidean seminorm''', or '''OETES''', we simply add a row |1 0 0 … 0> representing 2 to the matrix B. An alternative proceedure is to find the [[Normal_lists|normal val list]], and remove the first val from the list, corresponding to the octave or some fraction thereof, and proceed as in the previous section on temperamental complexity. This seminorm is a measure of the octave-equivalent complexity of a given ''p''-limit rational interval in terms of the ''p''-limit regular temperament given by A. | ||
== | == TE logflat badness == | ||
Given a matrix A whose rows are linearly independent vals defining a regular temperament, then the rank r of the temperament is the number of rows, which equals the number of linearly independent vals. The dimension of the temperament is the number of primes it covers; if ''p'' is the largest such prime, then the dimension ''n'' is π(p), the number of primes to ''p''. If we define S(A) to be the simple badness (relative error) of A, and C(A) to be the complexity of A, then '''logflat badness''' is defined by the formula | Given a matrix A whose rows are linearly independent vals defining a regular temperament, then the rank ''r'' of the temperament is the number of rows, which equals the number of linearly independent vals. The dimension of the temperament is the number of primes it covers; if ''p'' is the largest such prime, then the dimension ''n'' is π(''p''), the number of primes to ''p''. If we define S(A) to be the simple badness (relative error) of A, and C(A) to be the complexity of A, then '''logflat badness''' is defined by the formula | ||
==Examples== | <math>\displaystyle | ||
S(A)C(A)^{r/(n-r)}</math> | |||
If we set a cutoff margin for logflat badness, there are still infinite numbers of new temperaments appearing as complexity goes up, at a lower rate which is approximately logarithmic in terms of complexity. | |||
== Examples == | |||
Consider the temperament defined by the 5-limit [[Patent_val|patent vals]] for 15 and 22 equal. From the vals, we may construct a 2×3 matrix A = [<15 24 35|, <22 35 51|]. From this we may obtain the matrix '''P''' as A<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>A, approximately | Consider the temperament defined by the 5-limit [[Patent_val|patent vals]] for 15 and 22 equal. From the vals, we may construct a 2×3 matrix A = [<15 24 35|, <22 35 51|]. From this we may obtain the matrix '''P''' as A<sup>T</sup>(AW<sup>2</sup>A<sup>T</sup>)<sup>-1</sup>A, approximately | ||
| Line 46: | Line 51: | ||
If we start from a normal val list and remove the first val, the remaining vals map to the octave classes of the notes of the temperament. If we call this reduced list of vals R, then the inner product on note classes in this basis is defined by the symmetric matrix S = (RW<sup>2</sup>R<sup>T</sup>)<sup>-1</sup>. In the case of marvel, we obtain S = [[(p3)<sup>2</sup>(4(p5)<sup>2</sup>+(p7)<sup>2</sup>) -4(p3)<sup>2</sup>(p5)<sup>2</sup>], [-4(p3)<sup>2</sup>(p5)<sup>2</sup> (p5)<sup>2</sup>(4(p3)<sup>2</sup>+(p7)<sup>2</sup>)]]/H. If k = [a b] is a note class of marvel in the coordinates defined by the truncated val list R, which in this case has a basis corresponding to tempered 3 and 5, then sqrt (kSk<sup>T</sup>) gives the OE complexity of the note class. | If we start from a normal val list and remove the first val, the remaining vals map to the octave classes of the notes of the temperament. If we call this reduced list of vals R, then the inner product on note classes in this basis is defined by the symmetric matrix S = (RW<sup>2</sup>R<sup>T</sup>)<sup>-1</sup>. In the case of marvel, we obtain S = [[(p3)<sup>2</sup>(4(p5)<sup>2</sup>+(p7)<sup>2</sup>) -4(p3)<sup>2</sup>(p5)<sup>2</sup>], [-4(p3)<sup>2</sup>(p5)<sup>2</sup> (p5)<sup>2</sup>(4(p3)<sup>2</sup>+(p7)<sup>2</sup>)]]/H. If k = [a b] is a note class of marvel in the coordinates defined by the truncated val list R, which in this case has a basis corresponding to tempered 3 and 5, then sqrt (kSk<sup>T</sup>) gives the OE complexity of the note class. | ||
[[Category:math]] | [[Category:math]] | ||
[[Category:metric]] | [[Category:metric]] | ||
[[Category:todo:reduce_mathslang]] | [[Category:todo:reduce_mathslang]] | ||