Generator form manipulation: Difference between revisions

Cmloegcmluin (talk | contribs)
mingen form: could be minimal-generator too I suppose
Cmloegcmluin (talk | contribs)
No edit summary
Line 1: Line 1:
A [[User:Cmloegcmluin/Defactored_canonical_form|canonical mapping form]] is an important standard to have as community for uniquely identifying [[temperaments]], but it is not the only mapping form one should ever need, because one may wish to use differently-sized [[generators]].
A [[User:Cmloegcmluin/Defactored_canonical_form|canonical mapping form]] is an important standard to have as community for uniquely identifying [[temperaments]], but it is not the only mapping form one should ever need, because one may wish to use differently-sized [[generators]]. Several such forms with different generator sizes have been presented, such as [[Normal_lists#Positive_generator_form|positive generator form]], [[Normal_lists#Equave-reduced_generator_form|equave-reduced generator form]], and [[Normal_lists#Minimal_generator_form|minimal-generator form]].


If two mappings are equivalent, i.e. they have the same canonical form and therefore represent the same temperament, then their corresponding generators are equivalent too. That doesn't mean their generators are the same sizes; it only means that in combination with each other, their generators reach the same set of pitches.  
If two mappings are equivalent, i.e. they have the same canonical form and therefore represent the same temperament, then their corresponding generators are equivalent too. That doesn't mean their generators are the same sizes; it only means that in combination with each other, their generators reach the same set of pitches.  
Line 19: Line 19:
|}
|}


Now clearly all three of these mapping forms look related, and they are indeed, but the exact relationships between them may not be immediately apparent, or how those relationships correspond to the relationships between their generator sizes. The purpose of this section is to demonstrate tricks for transforming from one matrix form to another so that we can make the generators the sizes we want, and along the way we'll look at how the tricks work in order to explain these relationships.  
Now clearly all three of these mapping forms look related, and they are indeed, but the exact relationships between them may not be immediately apparent, or how those relationships correspond to the relationships between their generator sizes. The purpose of this article is to demonstrate tricks for transforming from one matrix form to another so that we can make the generators the sizes we want, and along the way we'll look at how the tricks work in order to explain these relationships.  


== generator size manipulation tricks ==
== generator size manipulation tricks ==
Line 105: Line 105:
Using these two tricks, you do not have to worry about enfactoring the mapping, i.e. introducing a common factor in one of the rows. This is because neither of these tricks ever involve replacing a row with a multiple of that row; we always replace a row with a combination of at least one each of two different rows, as in trick 1, or with the row negated, as in trick 2.
Using these two tricks, you do not have to worry about enfactoring the mapping, i.e. introducing a common factor in one of the rows. This is because neither of these tricks ever involve replacing a row with a multiple of that row; we always replace a row with a combination of at least one each of two different rows, as in trick 1, or with the row negated, as in trick 2.


== mingen form ==
== tuning strategy ==
 
A number of generator size targets have been described, such as [[UDP#Generalizing_to_Arbitrary_MOS.27s:_Bright_and_Dark_Generators_.28Chroma-Positive_and_Chroma-Negative.29|chroma-positive generators]], "musician's form"<ref>probably: the generator with the simplest JI preimage while still being smaller than the previous generator (not smaller than half of the previous generator, as with mingen). For example, for meantone, the musician's form is 3/2. That's because 3/1 is simpler but greater than 2/1, and while 4/3 also works, it's slightly more complex than 3/2.</ref>, and probably more will be described in the future<ref>Such as forms using [https://mathworld.wolfram.com/LLLAlgorithm.html LLL] to get "a simple set of generators", per a post by Graham Breed on Facebook [https://bit.ly/3AhDYP8 here].</ref>. The generator size target we'll be demonstrating here may not have been rigorously described elsewhere, or named<ref>It is the form used by [[Graham Breed]]'s regular temperament finding scripts hosted here: http://x31eq.com/temper/net.html, at least for rank-2 temperaments.</ref>, but these purposes, we'll be calling it minimum-generator, minimal-generator, or mingen, for short.
 
=== definition ===
 
Mingen form is when each successive generator is less than half the size of the previous generator.<ref>Like octave reduction combined with octave inversion, since you can't just add or subtract half octaves until it's between 0 and 600 cents. You have to add or subtract octaves until it's between -600 and +600 cents, then multiply by -1 if it's negative.</ref><ref>You could always find a smaller and smaller generator by going negative, so this assumes positive generators.</ref>
 
=== tuning strategy ===


In order to define the size of the generators, you need to specify a tuning strategy. Though if you have two generators that are close enough that their size ranking depends on the tuning, then you probably have other problems. In any case, the tuning strategy that we'll be using here is T2, because it's decent enough and easy to compute.
In order to define the size of the generators, you need to specify a tuning strategy. Though if you have two generators that are close enough that their size ranking depends on the tuning, then you probably have other problems. In any case, the tuning strategy that we'll be using here is T2, because it's decent enough and easy to compute.


=== rank-2 instructions table ===
== easy instructions table to achieve mingen form for rank-2 mapping ==


Let's begin with the simple example of 5-limit meantone. The following table demonstrates how to obtain mingen form from various starting positions, by synthesizing the two generator size manipulation tricks explained in the previous section. In this table, the period <span><math>p</math></span> is the first mapping row <span><math>r_1</math></span> in cents and the generator <span><math>g</math></span> is the second mapping row <span><math>r_2</math></span> in cents.
The following table shows how to obtain minimal-generator form from various starting positions, by synthesizing the two generator size manipulation tricks explained in the previous section. In this table, the period <span><math>p</math></span> is the first mapping row <span><math>r_1</math></span> in cents and the generator <span><math>g</math></span> is the second mapping row <span><math>r_2</math></span> in cents. It uses the simple example of 5-limit meantone.  


  {| class="wikitable"
  {| class="wikitable"
Line 187: Line 179:
|}
|}


=== Wolfram Language implementation ===
=== Wolfram Language implementation of mingen form instructions above ===


The below code essentially works through the input matrix M two rows at a time, beginning with the first two rows. Each pair of rows is "fixed" so that the second row is less than half of the first row. The same set of changes and potential recursions as described in the table in the previous section is used for each pair of rows. When the sizes of the generators is computed, a weighted Frobenius tuning is used for its computational frugality and reasonableness.  
The below code essentially works through the input matrix M two rows at a time, beginning with the first two rows. Each pair of rows is "fixed" so that the second row is less than half of the first row. The same set of changes and potential recursions as described in the table in the previous section is used for each pair of rows. When the sizes of the generators is computed, a weighted Frobenius tuning is used for its computational frugality and reasonableness.  
Line 270: Line 262:
tester[randomM]
tester[randomM]
</nowiki>
</nowiki>
=== limitations ===
Beyond rank-2, the mingen form of a temperament is no longer unique. You can always get smaller and smaller generators.<ref>This is why on Graham Breed's temperament finding tool, beyond rank-2 he simply uses the Hermite Normal Form.</ref>
Consider the example in the diagram above. We begin with {{vector|{{map|1 2 0 -1}} {{map|0 -1 6 10}} {{map|0 0 -1 -2}}}} with generators of 1200.6¢, 499.841¢, and 214.024¢, which therefore already satisfies the condition that each generator is less than half the previous generator. But we can transform it into {{vector|{{map|1 2 2 3}} {{map|0 -1 1 0}} {{map|0 0 -1 -2}}}} which has a third generator of 116.013¢ instead. This is accomplished by adding row 3 to row 2 five times, which decreases generator 3 by the size of five times row 2, from 214.024¢ by 5 × 499.841 = 2499.205¢ to -2285.18¢; and then subtracting row 3 from row 1 twice, which increases generator 3 by the size of two times row 1, from -2285.18¢ by 2 × 1200.6¢ = 2401.2¢ to 116.013¢. And we can get that generator even smaller if we had instead moved up by 499.841 twice to 1213.71¢ and then down by 1200.6¢ once to 13.109¢ (that's a final mapping of {{vector|{{map|1 2 -1 -3}} {{map|0 -1 8 14}} {{map|0 0 -1 -2}}}}.
You could find smaller and smaller generators if you wanted, by essentially finding increasingly small "commas" between the other generators' sizes (e.g. 5 × 1200.6¢ versus 12 × 499.841¢ is a difference of only 4.908¢) and then shifting generators by those commas.
This problem also precludes the possibility of a definitive maximum generator which is still less than half of the previous generator.


== References ==
== References ==