N2D3P9: Difference between revisions
clean up lede |
Cmloegcmluin (talk | contribs) add link to published paper |
||
| (3 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
'''N2D3P9''' (Entoo-Deethree-Peenine) is a mathematical function which was developed to help in designing the [[Sagittal notation|Sagittal microtonal notation]]. Given a rational number <math>\frac{n}{d}</math> representing a pitch (relative to some tonic note), N2D3P9 estimates its rank in popularity among all rational pitches in musical use. A low value of N2D3P9 indicates that the ratio is used often, and so should have a simple accidental symbol, while a high value indicates that the ratio is used rarely and so can have a more complex symbol if necessary. It may also be useful in designing rational scales or tunings. The name "'''N2D3P9'''" is an abbreviation of key components of its formula, as described below. | '''N2D3P9''' (Entoo-Deethree-Peenine) is a mathematical function which was developed to help in designing the [[Sagittal notation|Sagittal microtonal notation]]. Given a rational number <math>\frac{n}{d}</math> representing a pitch (relative to some tonic note), N2D3P9 estimates its rank in popularity among all rational pitches in musical use. A low value of N2D3P9 indicates that the ratio is used often, and so should have a simple accidental symbol, while a high value indicates that the ratio is used rarely and so can have a more complex symbol if necessary. It may also be useful in designing rational scales or tunings. The name "'''N2D3P9'''" is an abbreviation of key components of its formula, as described below. | ||
As a mnemonic, you can imagine the name N2D3P9 comes from a fictional character in the Star Wars franchise. In an alternative timeline, the young Anakin Skywalker assembles the droid N2D3P9 from the parts of three other droids: R<span style="color:#FF0000">2D</span>2, C<span style="color:#FF0000">3P</span>0 and <span style="color:#FF0000">N</span>R-N9<span style="color:#FF0000">9</span>. | As a mnemonic, you can imagine the name N2D3P9 comes from a fictional character in the Star Wars franchise. In an alternative timeline, the young Anakin Skywalker assembles the droid N2D3P9 from the parts of three other droids: R<span style="color:#FF0000">2D</span>2, C<span style="color:#FF0000">3P</span>0 and <span style="color:#FF0000">N</span>R-N9<span style="color:#FF0000">9</span>. | ||
== Formula == | == Formula == | ||
| Line 8: | Line 7: | ||
Before describing how to calculate <math>\text{N2D3P9}</math>, we define three simpler terms that are used in its formula: | Before describing how to calculate <math>\text{N2D3P9}</math>, we define three simpler terms that are used in its formula: | ||
# '''2,3-free''' ratios, which are also known as "[https://en.wikipedia.org/wiki/Rough_number 5-rough]" ratios. Because factors of <math>2</math> and <math>3</math> in pitch ratios are already notated by changing octaves or moving along the chain of fifths (... B♭♭ F♭ C♭ G♭ D♭ A♭ E♭ B♭ F C G D A E B F♯ C♯ G♯ D♯ A♯ E♯ B♯ Fx ...), '''N2D3P9''' only operates on ratios that have had their factors of <math>2</math> and <math>3</math> removed. For example, there are various numbers of factors of <math>2</math> and <math>3</math> in the following ratios: <math>\frac{16}{15}, \frac{10}{9}, \frac{6}{5}, \frac{5}{4}, \frac{27}{20}, \frac{45}{32}, \frac{64}{45}, \frac{40}{27}, \frac{8}{5}, \frac{5}{3}, \frac{9}{5}, \frac{15}{8}</math>, but when their factors of <math>2</math> and <math>3</math> are removed, they all reduce to <math>\frac{1}{5}</math> or <math>\frac{5}{1}</math>, and so they can all be notated using the same microtonal accidental, pointing either up or down, combined with different letters and sharps or flats. We say that <math>\frac{1}{5}</math> or <math>\frac{5}{1}</math> is the '''2,3-removed''' or '''2,3-free''' form of these pitch ratios, and because <math>\frac{1}{5}</math> and <math>\frac{5}{1}</math> use the same accidental pointing either up or down, and because '''N2D3P9''' only operates on ratios whose numerator is larger than their denominator (superunison ratios), <math>\frac{5}{1}</math> can represent this entire '''2,3-equivalent pitch ratio class''' or '''2,3-equivalence-class''' for the purpose of notation design. | # '''2,3-free''' ratios, which are also known as "[https://en.wikipedia.org/wiki/Rough_number 5-rough]" ratios. Because factors of <math>2</math> and <math>3</math> in pitch ratios are already notated by changing octaves or moving along the chain of fifths (... B♭♭ F♭ C♭ G♭ D♭ A♭ E♭ B♭ F C G D A E B F♯ C♯ G♯ D♯ A♯ E♯ B♯ Fx ...), '''N2D3P9''' only operates on ratios that have had their factors of <math>2</math> and <math>3</math> removed. For example, there are various numbers of factors of <math>2</math> and <math>3</math> in the following ratios: <math>\frac{16}{15}, \frac{10}{9}, \frac{6}{5}, \frac{5}{4}, \frac{27}{20}, \frac{45}{32}, \frac{64}{45}, \frac{40}{27}, \frac{8}{5}, \frac{5}{3}, \frac{9}{5}, \frac{15}{8}</math>, but when their factors of <math>2</math> and <math>3</math> are removed, they all reduce to <math>\frac{1}{5}</math> or <math>\frac{5}{1}</math>, and so they can all be notated using the same microtonal accidental, pointing either up or down, combined with different letters and sharps or flats. We say that <math>\frac{1}{5}</math> or <math>\frac{5}{1}</math> is the '''2,3-removed''' or '''2,3-free''' form of these pitch ratios, and because <math>\frac{1}{5}</math> and <math>\frac{5}{1}</math> use the same accidental pointing either up or down, and because '''N2D3P9''' only operates on ratios whose numerator is larger than their denominator ([[superunison]] ratios), <math>\frac{5}{1}</math> can represent this entire '''2,3-equivalent pitch ratio class''' or '''2,3-equivalence-class''' for the purpose of notation design. | ||
# The '''copfr''' function, which stands for "<u>C</u>ount <u>O</u>f <u>P</u>rime <u>F</u>actors with <u>R</u>epeats". It applies to any positive integer. For example <math>175</math> has the prime factorization <math>5 × 5 × 7</math>, which has 3 factors including the repeat of <math>5</math>, so <math>\text{copfr}(175) = 3</math>. <math>\text{copfr}(1) = 0</math>. <math>\text{copfr}</math> is also called the "[https://en.wikipedia.org/wiki/Prime_omega_function big omega]" function, <math>Ω</math>. | # <span id=copfr>The '''copfr''' function, which stands for "<u>C</u>ount <u>O</u>f <u>P</u>rime <u>F</u>actors with <u>R</u>epeats". It applies to any positive integer. For example <math>175</math> has the prime factorization <math>5 × 5 × 7</math>, which has 3 factors including the repeat of <math>5</math>, so <math>\text{copfr}(175) = 3</math>. <math>\text{copfr}(1) = 0</math>. <math>\text{copfr}</math> is also called the "[https://en.wikipedia.org/wiki/Prime_omega_function big omega]" function, <math>Ω</math>.</span> | ||
# The '''prime-limit''' function, which is also known as <math>\text{gpf}</math>, which stands for [https://mathworld.wolfram.com/GreatestPrimeFactor.html greatest prime factor]. <math>\text{prime-limit}(175) = 7</math>. Some authors leave <math>\text{prime-limit}(1)</math> undefined; we avoid the question because we define <math>\text{N2D3P9}(\frac{1}{1})</math> ≡ <math>\text{N2D3P9}(\frac{3}{1}) = 1</math>. This is because the ratios in the equivalence class represented by the 2,3-removed <math>\frac{1}{1}</math> actually have a prime limit of 3. | # The '''prime-limit''' function, which is also known as <math>\text{gpf}</math>, which stands for [https://mathworld.wolfram.com/GreatestPrimeFactor.html greatest prime factor]. <math>\text{prime-limit}(175) = 7</math>. Some authors leave <math>\text{prime-limit}(1)</math> undefined; we avoid the question because we define <math>\text{N2D3P9}(\frac{1}{1})</math> ≡ <math>\text{N2D3P9}(\frac{3}{1}) = 1</math>. This is because the ratios in the equivalence class represented by the 2,3-removed <math>\frac{1}{1}</math> actually have a prime limit of 3. | ||
| Line 87: | Line 86: | ||
Several techniques were used to find and decide on <math>\text{N2D3P9}</math> as the best 2,3-removed-ratio notational-popularity rank-estimation function. Initial observations about shortcomings of <math>\text{sopfr}</math>, such as its failure to differentiate balanced ratios from their imbalanced equivalents — such as <math>\frac{11}{5}</math> versus <math>\frac{55}{1}</math> — or those with different prime limits such as <math>\frac{13}{5}</math> and <math>\frac{11}{7}</math>, despite those pairs of ratios exhibiting remarkably different actual ranks in the Scala stats, formed the basis of the investigation. Psychoacoustic plausibility of functions was used as a top-down guide for experimentation. [https://en.wikipedia.org/wiki/Mathematical_optimization Optimization] tools such as [https://www.microsoft.com/en-us/microsoft-365/blog/2009/09/21/new-and-improved-solver/ Excel's Evolutionary Solver] were used to navigate toward ideal values for each parameter. The approach that was finally successful was a brute-force approach implemented by Douglas Blumeyer, whereby nearly 2 billion functions combined out of constituent "submetrics" were checked automatically. In the end, one of the functions on the short-list generated from the brute-force checker was recognized as being re-writable in a much simpler form with parameter values rounded to whole numbers without doing much damage to its sum-of-squares, and thus <math>\text{N2D3P9}</math> was born. | Several techniques were used to find and decide on <math>\text{N2D3P9}</math> as the best 2,3-removed-ratio notational-popularity rank-estimation function. Initial observations about shortcomings of <math>\text{sopfr}</math>, such as its failure to differentiate balanced ratios from their imbalanced equivalents — such as <math>\frac{11}{5}</math> versus <math>\frac{55}{1}</math> — or those with different prime limits such as <math>\frac{13}{5}</math> and <math>\frac{11}{7}</math>, despite those pairs of ratios exhibiting remarkably different actual ranks in the Scala stats, formed the basis of the investigation. Psychoacoustic plausibility of functions was used as a top-down guide for experimentation. [https://en.wikipedia.org/wiki/Mathematical_optimization Optimization] tools such as [https://www.microsoft.com/en-us/microsoft-365/blog/2009/09/21/new-and-improved-solver/ Excel's Evolutionary Solver] were used to navigate toward ideal values for each parameter. The approach that was finally successful was a brute-force approach implemented by Douglas Blumeyer, whereby nearly 2 billion functions combined out of constituent "submetrics" were checked automatically. In the end, one of the functions on the short-list generated from the brute-force checker was recognized as being re-writable in a much simpler form with parameter values rounded to whole numbers without doing much damage to its sum-of-squares, and thus <math>\text{N2D3P9}</math> was born. | ||
After deciding upon <math>\text{N2D3P9}</math>, the Sagittal forum members checked the ratios for the existing Sagittal symbols against it, to see how well they'd been served by the Scala archive stats and the earlier <math>\text{sopfr}</math> metric. Each symbol in Sagittal's JI notations has a default value, or primary comma, which allows | After deciding upon <math>\text{N2D3P9}</math>, the Sagittal forum members checked the ratios for the existing Sagittal symbols against it, to see how well they'd been served by the Scala archive stats and the earlier <math>\text{sopfr}</math> metric. Each symbol in Sagittal's JI notations has a default value, or primary comma, which for our purposes is a rational number between 1 and sqrt(3¹⁹/2³⁰) ≈ 1.040404 exclusive, that by multiplication, takes us from some 3-smooth ratio (notated using standard music notation) to a nearby 5-rough ratio. This allows the symbol to exactly notate all the ratios in the corresponding 2,3-equivalence-class. For example, the most important such comma is 81/80 (the 1/5-comma), whose symbol is an upward pointing left-half-arrow ⁄|, which takes us from 2⁴/3⁴ (A♭) to 1/5 (A♭ ⁄|). Based on N2D3P9, it was found that only a couple of these commas should be changed (these were among the rarest-used symbols in Sagittal). This was as expected; <math>\text{N2D3P9}</math> was developed primarily in order to add new accent marks to Sagittal, to enable it to exactly notate even rarer JI pitches than it already does. | ||
== Table of top 100 (2,3-equivalent) pitch ratio classes by N2D3P9 == | == Table of top 100 (2,3-equivalent) pitch ratio classes by N2D3P9 == | ||
| Line 698: | Line 697: | ||
|29 | |29 | ||
|} | |} | ||
== See also == | |||
[https://link.springer.com/chapter/10.1007/978-3-031-07015-0_26 Keenan, D., Blumeyer, D. (2022). N2D3P9]. In: Montiel, M., Agustín-Aquino, O.A., Gómez, F., Kastine, J., Lluis-Puebla, E., Milam, B. (eds) Mathematics and Computation in Music. MCM 2022. Lecture Notes in Computer Science(), vol 13267. Springer, Cham. | |||
[[Category:Just intonation]] | [[Category:Just intonation]] | ||