Kite's thoughts on Stern-Brocot ancestors and rank 2 temperaments
IMPORTED REVISION FROM WIKISPACES
This is an imported revision from Wikispaces. The revision metadata is included below for reference:
- This revision was by author TallKite and made on 2014-02-22 05:59:28 UTC.
- The original revision id was 491188008.
- The revision comment was:
The revision contents are below, presented both in the original Wikispaces Wikitext format, and in HTML exactly as Wikispaces rendered it.
Original Wikitext content:
==Rank 2 tunings== Let's say you have a rank 2 tuning, with a period of P cents and a generator of G cents. You construct an N-note scale with a chain of N-1 generators. The classic example of this is a diatonic scale with an octave as period and a fifth as generator, with P = 1200¢, G = 702¢, and N = 7. Or perhaps the fifth is tempered down to 700¢ for 12-EDO, or 696¢ for quarter-comma meantone. Or perhaps N = 5 because you live in a pentatonic culture. Or N = 12 because you're creating a full keyboard tuning, not just a scale. Or perhaps you're using the third 5/4 as your generator. Or the tritave 3/1 as your period. Whatever, this discussion applies to all these cases. But for now we'll assume that the period is an octave and the generator is a roughly fifth-sized interval. The process of filling in the period with notes can be visualized as drawing a star of sorts in a circle. Think of a clock. An octave is 12 hours and a fifth is about 7 hours. To construct a scale, draw a line from 12:00 to 7:00 to 2:00 to 9:00 to 4:00 and back to 12:00. You've made a pentatonic scale C D E G A C. The first four lines you drew were generators, but the last one is a different interval. (Sometimes it works out that that last line is also a generator, but it usually isn't.) In this case the first four lines were perfect fifths and the last one was a minor sixth E-C. Now erase that last line, and continue from 4:00 to 11:00 to 6:00 and back to 12:00. That's a diatonic, aka heptatonic, scale C D E F# G A B C. We drew six generators and a non-generator. In musical terms, six perfect fifths and a diminished fifth F#-C. Because the fifth may not be exactly 700¢, the line may not hit 7:00 exactly. That error will add up as we draw the star, so if the star misses 7:00 by a tiny bit, it will miss 6:00 by six times as much. But as long as the tiny bit is small, it won't matter. The shape of the star will be the same. N is called the __**stepspan**__ of the period. The stepspan is one less than the degree, so a third has stepspan 2, a fourth has stepspan 3, etc. We'll use stepspan instead of degree because it makes the math a little easier. The generator has a stepspan too, determined by how many star-points fall between our starting point 12:00 and the first generator at 7:00. Let's call this stepspan M. If N = 7, M = 4, because our heptatonic scale has four steps from C to G. For the pentatonic scale, N = 5 and M = 3. Ideally, every time we draw a line on the clock face, the stepspan of that interval is M. Even the last line. But it's possible for some of the generators to have a different stepspan, which makes the tuning hard to notate. If all the generators have the same stepspan, we'll call that a __**well-formed**__ scale. Let's call the opposite a __**paradoxical**__ scale. What's the criteria for well-formed-ness? It has to do with M, N, G and P. It turns out that the generator must be roughly M/N of a period. In other words, G/P must be roughly M/N. Or to put it another way, M/N must be roughly G/P. Think of it this way: when we define 2/1 as an octave containing 7 steps, and 3/2 as a fifth containing 4 steps, we're saying that 3/2 is approximately four sevenths of 2/1. We're doing more than just saying it, we're basing our entire notation on it. Now a fifth isn't four-sevenths of an octave, not unless you flatten the heck out of it, but we can get away with saying it is because it's __roughly__ four-sevenths. It's close enough to generate a well-formed heptatonic scale. Pentatonic cultures define 2/1 as containing 5 steps and 3/2 as containing 3 steps. They approximate the fifth as three-fifths of an octave, and it works. Pentatonic scales are well-formed. What if we said that 2/1 is a ninth of 8 steps, and 3/2 is a sixth of 5 steps? This would be an octotonic scale. What happens when you draw an eight-pointed star on a clock? You go 12:00 to 7:00 to 2:00 to 9:00 to 4:00 to 11:00 to 6:00 to 1:00 and back to 12:00. That last step 1:00 to 12:00 is NOT a sixth! Neither is 2:00 to 9:00, or 4:00 to 11:00, because there aren't enough steps in between them. So if M = 5, N = 8, P = 1200¢ and G = about 702¢, we get a paradoxical scale. For the five-eighths approximation to work, G/P would have to be closer to 5/8, and our generator would need to be significantly sharper than 702¢. What's wrong with paradoxical scales? Some of the generators are fifths and some are sixths, naming them by the number of scale steps they contain. And the last line is a seventh. But wait, you say, doesn't that happen in our standard system? Isn't a tritone both an aug 4th and a dim 5th? Yes, but remember that only in certain tunings (12-EDO, 24-EDO, 36-EDO, etc.) is the aug4 identical to the dim5. Often they are different intervals. But our octotonic generators are always identical by definition. More on this later. So four-sevenths works for the fifth, but five-eighths doesn't. How accurate does this M/N approximation have to be? What are the exact limits of what G can be? How flat or sharp can our fifth be and still make a well-formed heptatonic scale? Or to put it another way, how sharp would the generator have to be for five-eighths to work? It turns out that if the scale is well-formed, M and N are always co-prime, meaning no common factors. If they weren't, the star wouldn't hit all the points before returning to 12:00. For example, if N = 10 and M = 6, your star would only hit 5 out of the 10 points. Another example: we've drawn a 5-pointed star and a 7-pointed star on a clock. Try drawing a 6-pointed star, as symmetrical as the other stars. The Star of David doesn't count, because you must draw it all in one go, without lifting your pencil from the page. Give up yet? It can't be done. That's because 2, 3 and 4 aren't co-prime with 6. The only numbers smaller than 6 that are co-prime with it are 1 and 5. Using those numbers is equivalent to drawing a hexagon in a circle. A musically valid generator, but not very star-like. If you draw a well-formed star on a clock, at some point you reach the point to the immediate right of the starting point at 12:00, the 2nd note of the scale. Let's say that point is after you draw X lines. Mathematically speaking, we say there exists a number X between 0 and N such that XM mod N = 1. X must be less than N because after N lines, we've drawn the whole star. In the course of drawing these X lines, we have probably gone around the clock a number of times. In musical terms, we probably need to octave-reduce the sum of X generators to make a 2nd, as opposed to a 9th or something. Let's say we've gone around the clock Y times. We need to reduce X generators by Y periods, and we say XM - YN = 1, or XM = YN + 1. Y will always be less than M, because we go around the clock M times total. We know this because NM = MN, so N generators = M periods. Now at some other point while drawing, you reach the point to the immediate left of 12:00, which is the 7th, or more generally the penultimate note. How many lines does it take? We want an equation like XM = YN + 1, except with - 1 instead of +1, and different X and Y of course. It turns out that N - X generators is just shy of M - Y periods. Proof: || #1 || XM = YN + 1 || || #2 || NM = MN (duh!) || || subtract #1 from #2: || NM - XM = MN - YN - 1 || || rewrite it || (N - X) M = (M - Y) N - 1 || So far we've been thinking of the generator only as an M-step interval. But it's actually an interval of G cents. If you make the generator flatter (or narrower, strictly speaking), all the intervals of the scale become flatter. If you flatten the generator to the point that scale is paradoxical, your 2nd will be flattened down to the tonic. If this happens, X generators will be equal to Y periods, in other words, XG = YP. Thus the lower limit of what G can be is (Y/X) P. If you make the generator sharper (or wider), all the intervals become sharper. If you sharpen the generator to the paradoxical point, the penultimate note becomes equal to the period, and N - X generators will equal M - Y periods. Thus (N - X) G = (M - Y) P, and the upper limit of what G can be is [(M - Y) / (N - X)] P. Thus: Y / X < G / P < (M - Y) / (N - X) Let's check this for a heptatonic scale generated by a fifth. If N = 7 and M = 4, 4X mod 7 = 1 implies that X = 2. 4X = 7Y + 1 implies Y = 1. N - X is 5 and M - Y is 3. Thus 1/2 < G/P < 3/5. P = 1200¢, so the generator must be between 600¢ and 720¢. By symmetry we can deduce that if M = 3, the generator must be 480-600¢. Although we used the ratio 2/1 to derive 1200¢, we didn't use 3/2 or 702¢ anywhere in our calculations. We simply said that our 7-pointed star must have lines that go about 4/7 of the way around the clock. We could use as our generator any ratio that falls in the 600-720¢ range, such as 10/7 or 16/11. We could also use any irrational interval in this range, such as the EDO intervals 7\12 or 11\19 or 13\22. As long as we assign a stepspan of 4 to the generator, the scale will be well-formed. In other words, we're using the term "fifth" in the loosest possible sense, meaning any note-to-note interval that skips over 3 other notes and is 600-720¢. Let's try this for pentatonic scales: N = 5 and M = 3. X is again 2, and Y is again 1. N - X is 3 and M - Y is 2. The limits for G are (1/2)1200 = 600¢ and (2/3)1200 = 800¢. The upper limit is higher for pentatonic than for heptatonic, meaning it's more robust. Makes sense, a shorter chain of fifths is less likely to cause a paradox. Thus a generator of 14/9 = 765¢ would make a well-formed pentatonic scale but a paradoxical heptatonic scale. As would an 8-EDO generator of 5\8 = 750¢. Back to heptatonic, what if the generator was a third? Then M = 2, and X = 4 and Y = 1. N - X = 3 and M - Y = 1. The limits of G are 1/4 and 1/3, which is 300-400¢. Thus the ratios 6/5, 5/4, or 11/9, or the EDO-steps 3\10, 4\13 or 5\17 would all be valid generators. 7/6 would not work, it's too small. Would it work as a 2nd, with M = 1? If M = 1, we can find the limits very easily. X is always 1 and Y is always 0. The lower limit is 0/1 = 0¢, in other words any interval at all will be big enough. The upper limit is 1/(N - 1). For N = 7, the upper limit is 1/6 P = 200¢. So 7/6 wouldn't work heptatonically because it's too big to be a 2nd and too small to be a 3rd. But pentatonically, the upper limit is 1/4 P = 300¢, and 7/6 would work as a 2nd. We can also find the limits easily when M = N - 1. X is always N - 1, because XM mod N = (N - 1) (N - 1) mod N = (N^2 -2N + 1) mod N = 1. Y is always N - 2 because XM = YN + 1, so Y = (XM - 1) / N = (N^2 - 2N + 1 - 1) / N = N - 2. The limits are (N - 2) / (N - 1) and 1/1. For heptatonic scales, M = 6 and the limits are 5/6 P = 1000¢ and 1/1 P = 1200¢. For pentatonic scales, the limits are 3/4 and 1/1, or 900-1200¢. Putting this all together: Heptatonic second: 0-200¢ Heptatonic third: 300-400¢ Heptatonic fourth: 480-600¢ Heptatonic fifth: 600-720¢ Heptatonic sixth: 800-900¢ Heptatonic seventh: 1000-1200¢ Pentatonic second: 0-300¢ Pentatonic third: 400-600¢ Pentatonic fourth: 600-800¢ Pentatonic fifth: 900-1200¢ We see that there are gaps between the ranges. Some intervals like 7/6 can never be heptatonic generators because they fall through the cracks. Likewise some intervals can never be pentatonic generators. But every interval can be one or the other. Hexatonic second: 0-240¢ Hexatonic third, fourth and fifth: impossible, not co-prine Hexatonic sixth: 960-1200¢ Octotonic second: 0-171¢ (171¢ = 1\7) Octotonic third: impossible, not co-prime Octotonic fourth: 400-480¢ Octotonic fifth: impossible, not co-prime Octotonic sixth: 720-800¢ Octotonic seventh: impossible, not co-prime Octotonic eighth: 1029-1200¢ (1029¢ = 6\7) It's obvious why hexatonic or octotonic notation is rarely used! 9-note second: 0-150¢ 9-note third: 240-300¢ 9-note fourth: impossible, not co-prime 9-note fifth: 515-600¢ (515¢ = 3\7) 9-note sixth: 600-685¢ (685¢ = 4\7) 9-note seventh: impossible, not co-prime 9-note eighth: 900-960¢ 9-note ninth: 1050-1200¢ How to find X and Y? It helps if you know about the Stern-Brocot tree. Read about it here: [[@http://en.wikipedia.org/wiki/Stern%E2%80%93Brocot_tree]] [[image:xenharmonic/500px-SternBrocotTree.svg.png]] It turns out that the upper and lower limits of G/P are the ancestors of M/N on the Stern-Brocot tree! How do we know this? Because we know that X < N and Y < M. Therefore N - X < N and M - Y < M. So both limits have smaller numbers than M/N. And obviously the "freshman sum" of Y/X and (M - Y) / (N - X) is M/N. Furthermore, X and Y are relatively prime. If they weren't, suppose they were both even numbers, with X = 2V and Y = 2W. Then XM = YN + 1 becomes 2VM = 2WN + 1. But 2VM and 2WN are both even numbers, and an even number plus 1 must be an odd number. So X and Y can't both be even. By similar logic, they can't both be multiples of 3, or of 4, or of any other number. They must be co-prime. How to find the ancestors of M/N? Suppose that G/P was exactly M/N. This would correspond to notating 7edo heptatonically. (By the way, G/P = M/N is the only way in which the final line of the star can be a generator.) The generator is MP/N cents. The 2nd of the scale would be P/N cents. Now suppose we flatten that 2nd down to 0¢. That means X generators would be flattened down by P/N cents, and each generator would be flattened by P/(XN) cents. The original generator was G = MP/N, and the new generator would be G = MP/N - P/(XN) = P (XM - 1)/XN. The lower ancestor of M/N is therefore (XM - 1) / XN. Similarly, the penultimate note is shy of the period by P/N cents. To close the gap, we must sharpen (N - X) generators by P/N cents, and sharpen one generator by P / [N(N - X)] cents. The new generator is G = MP/N + P / [N(N - X)] = P [(N - X)M + 1] / [(N - X)N]. The upper ancestor of M/N is therefore [(N - X)M + 1] / [(N - X)N]. Don't let this formula scare you. Once you find the lower ancestor, you can find the upper one by "freshman subtraction" of the lower one from M/N. To find X, either consult the Stern-Brocot tree, or find X from the formula XM mod N = 1. If you find a number Z such that ZM mod N = -1, then X = N - Z. ==EDO notation== Stern-Brocot ancestors have a specific application in notating EDOs.
Original HTML content:
<html><head><title>Stern-Brocot ancestors and rank 2 temperaments</title></head><body><!-- ws:start:WikiTextHeadingRule:0:<h2> --><h2 id="toc0"><a name="x-Rank 2 tunings"></a><!-- ws:end:WikiTextHeadingRule:0 -->Rank 2 tunings</h2> <br /> Let's say you have a rank 2 tuning, with a period of P cents and a generator of G cents. You construct an N-note scale with a chain of N-1 generators. The classic example of this is a diatonic scale with an octave as period and a fifth as generator, with P = 1200¢, G = 702¢, and N = 7. Or perhaps the fifth is tempered down to 700¢ for 12-EDO, or 696¢ for quarter-comma meantone. Or perhaps N = 5 because you live in a pentatonic culture. Or N = 12 because you're creating a full keyboard tuning, not just a scale. Or perhaps you're using the third 5/4 as your generator. Or the tritave 3/1 as your period. Whatever, this discussion applies to all these cases. But for now we'll assume that the period is an octave and the generator is a roughly fifth-sized interval.<br /> <br /> The process of filling in the period with notes can be visualized as drawing a star of sorts in a circle. Think of a clock. An octave is 12 hours and a fifth is about 7 hours. To construct a scale, draw a line from 12:00 to 7:00 to 2:00 to 9:00 to 4:00 and back to 12:00. You've made a pentatonic scale C D E G A C. The first four lines you drew were generators, but the last one is a different interval. (Sometimes it works out that that last line is also a generator, but it usually isn't.) In this case the first four lines were perfect fifths and the last one was a minor sixth E-C. Now erase that last line, and continue from 4:00 to 11:00 to 6:00 and back to 12:00. That's a diatonic, aka heptatonic, scale C D E F# G A B C. We drew six generators and a non-generator. In musical terms, six perfect fifths and a diminished fifth F#-C.<br /> <br /> Because the fifth may not be exactly 700¢, the line may not hit 7:00 exactly. That error will add up as we draw the star, so if the star misses 7:00 by a tiny bit, it will miss 6:00 by six times as much. But as long as the tiny bit is small, it won't matter. The shape of the star will be the same.<br /> <br /> N is called the <u><strong>stepspan</strong></u> of the period. The stepspan is one less than the degree, so a third has stepspan 2, a fourth has stepspan 3, etc. We'll use stepspan instead of degree because it makes the math a little easier. The generator has a stepspan too, determined by how many star-points fall between our starting point 12:00 and the first generator at 7:00. Let's call this stepspan M. If N = 7, M = 4, because our heptatonic scale has four steps from C to G. For the pentatonic scale, N = 5 and M = 3.<br /> <br /> Ideally, every time we draw a line on the clock face, the stepspan of that interval is M. Even the last line. But it's possible for some of the generators to have a different stepspan, which makes the tuning hard to notate. If all the generators have the same stepspan, we'll call that a <u><strong>well-formed</strong></u> scale. Let's call the opposite a <u><strong>paradoxical</strong></u> scale. What's the criteria for well-formed-ness? It has to do with M, N, G and P. It turns out that the generator must be roughly M/N of a period. In other words, G/P must be roughly M/N. Or to put it another way, M/N must be roughly G/P. Think of it this way: when we define 2/1 as an octave containing 7 steps, and 3/2 as a fifth containing 4 steps, we're saying that 3/2 is approximately four sevenths of 2/1. We're doing more than just saying it, we're basing our entire notation on it. Now a fifth isn't four-sevenths of an octave, not unless you flatten the heck out of it, but we can get away with saying it is because it's <u>roughly</u> four-sevenths. It's close enough to generate a well-formed heptatonic scale.<br /> <br /> Pentatonic cultures define 2/1 as containing 5 steps and 3/2 as containing 3 steps. They approximate the fifth as three-fifths of an octave, and it works. Pentatonic scales are well-formed.<br /> <br /> What if we said that 2/1 is a ninth of 8 steps, and 3/2 is a sixth of 5 steps? This would be an octotonic scale. What happens when you draw an eight-pointed star on a clock? You go 12:00 to 7:00 to 2:00 to 9:00 to 4:00 to 11:00 to 6:00 to 1:00 and back to 12:00. That last step 1:00 to 12:00 is NOT a sixth! Neither is 2:00 to 9:00, or 4:00 to 11:00, because there aren't enough steps in between them. So if M = 5, N = 8, P = 1200¢ and G = about 702¢, we get a paradoxical scale. For the five-eighths approximation to work, G/P would have to be closer to 5/8, and our generator would need to be significantly sharper than 702¢.<br /> <br /> What's wrong with paradoxical scales? Some of the generators are fifths and some are sixths, naming them by the number of scale steps they contain. And the last line is a seventh. But wait, you say, doesn't that happen in our standard system? Isn't a tritone both an aug 4th and a dim 5th? Yes, but remember that only in certain tunings (12-EDO, 24-EDO, 36-EDO, etc.) is the aug4 identical to the dim5. Often they are different intervals. But our octotonic generators are always identical by definition. More on this later.<br /> <br /> So four-sevenths works for the fifth, but five-eighths doesn't. How accurate does this M/N approximation have to be? What are the exact limits of what G can be? How flat or sharp can our fifth be and still make a well-formed heptatonic scale? Or to put it another way, how sharp would the generator have to be for five-eighths to work?<br /> <br /> It turns out that if the scale is well-formed, M and N are always co-prime, meaning no common factors. If they weren't, the star wouldn't hit all the points before returning to 12:00. For example, if N = 10 and M = 6, your star would only hit 5 out of the 10 points. Another example: we've drawn a 5-pointed star and a 7-pointed star on a clock. Try drawing a 6-pointed star, as symmetrical as the other stars. The Star of David doesn't count, because you must draw it all in one go, without lifting your pencil from the page. Give up yet? It can't be done. That's because 2, 3 and 4 aren't co-prime with 6. The only numbers smaller than 6 that are co-prime with it are 1 and 5. Using those numbers is equivalent to drawing a hexagon in a circle. A musically valid generator, but not very star-like.<br /> <br /> If you draw a well-formed star on a clock, at some point you reach the point to the immediate right of the starting point at 12:00, the 2nd note of the scale. Let's say that point is after you draw X lines. Mathematically speaking, we say there exists a number X between 0 and N such that XM mod N = 1. X must be less than N because after N lines, we've drawn the whole star. In the course of drawing these X lines, we have probably gone around the clock a number of times. In musical terms, we probably need to octave-reduce the sum of X generators to make a 2nd, as opposed to a 9th or something. Let's say we've gone around the clock Y times. We need to reduce X generators by Y periods, and we say XM - YN = 1, or XM = YN + 1. Y will always be less than M, because we go around the clock M times total. We know this because NM = MN, so N generators = M periods.<br /> <br /> Now at some other point while drawing, you reach the point to the immediate left of 12:00, which is the 7th, or more generally the penultimate note. How many lines does it take? We want an equation like XM = YN + 1, except with - 1 instead of +1, and different X and Y of course. It turns out that N - X generators is just shy of M - Y periods. Proof:<br /> <table class="wiki_table"> <tr> <td>#1<br /> </td> <td>XM = YN + 1<br /> </td> </tr> <tr> <td>#2<br /> </td> <td>NM = MN (duh!)<br /> </td> </tr> <tr> <td>subtract #1 from #2:<br /> </td> <td>NM - XM = MN - YN - 1<br /> </td> </tr> <tr> <td>rewrite it<br /> </td> <td>(N - X) M = (M - Y) N - 1<br /> </td> </tr> </table> So far we've been thinking of the generator only as an M-step interval. But it's actually an interval of G cents. If you make the generator flatter (or narrower, strictly speaking), all the intervals of the scale become flatter. If you flatten the generator to the point that scale is paradoxical, your 2nd will be flattened down to the tonic. If this happens, X generators will be equal to Y periods, in other words, XG = YP. Thus the lower limit of what G can be is (Y/X) P.<br /> <br /> If you make the generator sharper (or wider), all the intervals become sharper. If you sharpen the generator to the paradoxical point, the penultimate note becomes equal to the period, and N - X generators will equal M - Y periods. Thus (N - X) G = (M - Y) P, and the upper limit of what G can be is [(M - Y) / (N - X)] P. Thus:<br /> <br /> Y / X < G / P < (M - Y) / (N - X)<br /> <br /> Let's check this for a heptatonic scale generated by a fifth. If N = 7 and M = 4, 4X mod 7 = 1 implies that X = 2. 4X = 7Y + 1 implies Y = 1. N - X is 5 and M - Y is 3. Thus 1/2 < G/P < 3/5. P = 1200¢, so the generator must be between 600¢ and 720¢. By symmetry we can deduce that if M = 3, the generator must be 480-600¢. Although we used the ratio 2/1 to derive 1200¢, we didn't use 3/2 or 702¢ anywhere in our calculations. We simply said that our 7-pointed star must have lines that go about 4/7 of the way around the clock. We could use as our generator any ratio that falls in the 600-720¢ range, such as 10/7 or 16/11. We could also use any irrational interval in this range, such as the EDO intervals 7\12 or 11\19 or 13\22. As long as we assign a stepspan of 4 to the generator, the scale will be well-formed. In other words, we're using the term "fifth" in the loosest possible sense, meaning any note-to-note interval that skips over 3 other notes and is 600-720¢.<br /> <br /> Let's try this for pentatonic scales: N = 5 and M = 3. X is again 2, and Y is again 1. N - X is 3 and M - Y is 2. The limits for G are (1/2)1200 = 600¢ and (2/3)1200 = 800¢. The upper limit is higher for pentatonic than for heptatonic, meaning it's more robust. Makes sense, a shorter chain of fifths is less likely to cause a paradox. Thus a generator of 14/9 = 765¢ would make a well-formed pentatonic scale but a paradoxical heptatonic scale. As would an 8-EDO generator of 5\8 = 750¢.<br /> <br /> Back to heptatonic, what if the generator was a third? Then M = 2, and X = 4 and Y = 1. N - X = 3 and M - Y = 1. The limits of G are 1/4 and 1/3, which is 300-400¢. Thus the ratios 6/5, 5/4, or 11/9, or the EDO-steps 3\10, 4\13 or 5\17 would all be valid generators. 7/6 would not work, it's too small. Would it work as a 2nd, with M = 1?<br /> <br /> If M = 1, we can find the limits very easily. X is always 1 and Y is always 0. The lower limit is 0/1 = 0¢, in other words any interval at all will be big enough. The upper limit is 1/(N - 1). For N = 7, the upper limit is 1/6 P = 200¢. So 7/6 wouldn't work heptatonically because it's too big to be a 2nd and too small to be a 3rd. But pentatonically, the upper limit is 1/4 P = 300¢, and 7/6 would work as a 2nd.<br /> <br /> We can also find the limits easily when M = N - 1. X is always N - 1, because XM mod N = (N - 1) (N - 1) mod N = (N^2 -2N + 1) mod N = 1. Y is always N - 2 because XM = YN + 1, so Y = (XM - 1) / N = (N^2 - 2N + 1 - 1) / N = N - 2. The limits are (N - 2) / (N - 1) and 1/1. For heptatonic scales, M = 6 and the limits are 5/6 P = 1000¢ and 1/1 P = 1200¢. For pentatonic scales, the limits are 3/4 and 1/1, or 900-1200¢. Putting this all together:<br /> <br /> Heptatonic second: 0-200¢<br /> Heptatonic third: 300-400¢<br /> Heptatonic fourth: 480-600¢<br /> Heptatonic fifth: 600-720¢<br /> Heptatonic sixth: 800-900¢<br /> Heptatonic seventh: 1000-1200¢<br /> <br /> Pentatonic second: 0-300¢<br /> Pentatonic third: 400-600¢<br /> Pentatonic fourth: 600-800¢<br /> Pentatonic fifth: 900-1200¢<br /> <br /> We see that there are gaps between the ranges. Some intervals like 7/6 can never be heptatonic generators because they fall through the cracks. Likewise some intervals can never be pentatonic generators. But every interval can be one or the other.<br /> <br /> Hexatonic second: 0-240¢<br /> Hexatonic third, fourth and fifth: impossible, not co-prine<br /> Hexatonic sixth: 960-1200¢<br /> <br /> Octotonic second: 0-171¢ (171¢ = 1\7)<br /> Octotonic third: impossible, not co-prime<br /> Octotonic fourth: 400-480¢<br /> Octotonic fifth: impossible, not co-prime<br /> Octotonic sixth: 720-800¢<br /> Octotonic seventh: impossible, not co-prime<br /> Octotonic eighth: 1029-1200¢ (1029¢ = 6\7)<br /> <br /> It's obvious why hexatonic or octotonic notation is rarely used!<br /> <br /> 9-note second: 0-150¢<br /> 9-note third: 240-300¢<br /> 9-note fourth: impossible, not co-prime<br /> 9-note fifth: 515-600¢ (515¢ = 3\7)<br /> 9-note sixth: 600-685¢ (685¢ = 4\7)<br /> 9-note seventh: impossible, not co-prime<br /> 9-note eighth: 900-960¢<br /> 9-note ninth: 1050-1200¢<br /> <br /> <br /> <br /> <br /> How to find X and Y? It helps if you know about the Stern-Brocot tree. Read about it here:<br /> <a class="wiki_link_ext" href="http://en.wikipedia.org/wiki/Stern%E2%80%93Brocot_tree" rel="nofollow" target="_blank">http://en.wikipedia.org/wiki/Stern%E2%80%93Brocot_tree</a><br /> <!-- ws:start:WikiTextLocalImageRule:30:<img src="http://xenharmonic.wikispaces.com/file/view/500px-SternBrocotTree.svg.png/490708222/500px-SternBrocotTree.svg.png" alt="" title="" /> --><img src="http://xenharmonic.wikispaces.com/file/view/500px-SternBrocotTree.svg.png/490708222/500px-SternBrocotTree.svg.png" alt="500px-SternBrocotTree.svg.png" title="500px-SternBrocotTree.svg.png" /><!-- ws:end:WikiTextLocalImageRule:30 --><br /> It turns out that the upper and lower limits of G/P are the ancestors of M/N on the Stern-Brocot tree! How do we know this? Because we know that X < N and Y < M. Therefore N - X < N and M - Y < M. So both limits have smaller numbers than M/N. And obviously the "freshman sum" of Y/X and (M - Y) / (N - X) is M/N. Furthermore, X and Y are relatively prime. If they weren't, suppose they were both even numbers, with X = 2V and Y = 2W. Then XM = YN + 1 becomes 2VM = 2WN + 1. But 2VM and 2WN are both even numbers, and an even number plus 1 must be an odd number. So X and Y can't both be even. By similar logic, they can't both be multiples of 3, or of 4, or of any other number. They must be co-prime.<br /> <br /> How to find the ancestors of M/N? Suppose that G/P was exactly M/N. This would correspond to notating 7edo heptatonically. (By the way, G/P = M/N is the only way in which the final line of the star can be a generator.) The generator is MP/N cents. The 2nd of the scale would be P/N cents. Now suppose we flatten that 2nd down to 0¢. That means X generators would be flattened down by P/N cents, and each generator would be flattened by P/(XN) cents. The original generator was G = MP/N, and the new generator would be G = MP/N - P/(XN) = P (XM - 1)/XN. The lower ancestor of M/N is therefore (XM - 1) / XN.<br /> <br /> Similarly, the penultimate note is shy of the period by P/N cents. To close the gap, we must sharpen (N - X) generators by P/N cents, and sharpen one generator by P / [N(N - X)] cents. The new generator is G = MP/N + P / [N(N - X)] = P [(N - X)M + 1] / [(N - X)N]. The upper ancestor of M/N is therefore [(N - X)M + 1] / [(N - X)N]. Don't let this formula scare you. Once you find the lower ancestor, you can find the upper one by "freshman subtraction" of the lower one from M/N.<br /> <br /> To find X, either consult the Stern-Brocot tree, or find X from the formula XM mod N = 1. If you find a number Z such that ZM mod N = -1, then X = N - Z.<br /> <br /> <!-- ws:start:WikiTextHeadingRule:2:<h2> --><h2 id="toc1"><a name="x-EDO notation"></a><!-- ws:end:WikiTextHeadingRule:2 -->EDO notation</h2> <br /> Stern-Brocot ancestors have a specific application in notating EDOs.</body></html>