EDO Exceptions

Previously: EDO Generators

If we let a variable A1 range over the positive integers and let a variable d2 range over positive integers, then the values of (d2 * 12 - A1 * 7) // gcd(A1, d2) that we can get when d2 >= A1 are these:

    [5, 12, 17, 19, 22, 26, 27, 29, 31, 32, 33, 37, 39, 40, 41, 42, 43, 45, 46, 47, 49, 50, 52, 53, 54, 55, 56, 57, 59, 61, 62, 63, 64, 65, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 79, 80, 81, 82, 83, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 157, 158, 159, 160, ...].

I'm interested in this sequence because of some music theory I was developing/discovering about EDO tuning system, which is why the variables have the weird names A1 and d2. The sequence has finitely many exceptions among the positive integers, and I wanted to better understand why.

I will call the set of exceptions.... an exceptions set.

To start the investigation, I'm going to simply look at the exception set for (d2 * 12 - A1 * 7) without the gcd() denominator term. And more generally, I'll look at (d2 * Q - A1 * R) for different integer values of Q and R.

Lots of pairs of values for Q and R produce no exceptions or infinitely many exceptions. When Q and R have a common factor, there are infinitely many exceptions. We only get finitely many exceptions if  R <= Q - 2 and also Q and R are coprime.

Here are the finite exception sets [] for some different values of (Q, R), sorted by R first and then by Q:

3, 1 :: [1]

4, 1 :: [1, 2]

5, 1 :: [1, 2, 3]

6, 1 :: [1, 2, 3, 4]

7, 1 :: [1, 2, 3, 4, 5]

8, 1 :: [1, 2, 3, 4, 5, 6]

9, 1 :: [1, 2, 3, 4, 5, 6, 7]

10, 1 :: [1, 2, 3, 4, 5, 6, 7, 8]

11, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9]

12, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]

13, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]

14, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]

15, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]

16, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]

17, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15]

18, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]

19, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17]

20, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18]

21, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]

22, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20]

23, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21]

24, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22]

5, 2 :: [1, 2, 4]

7, 2 :: [1, 2, 3, 4, 6, 8]

9, 2 :: [1, 2, 3, 4, 5, 6, 8, 10, 12]

11, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 12, 14, 16]

13, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 16, 18, 20]

15, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 16, 18, 20, 22, 24]

17, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 16, 18, 20, 22, 24, 26, 28]

19, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 20, 22, 24, 26, 28, 30, 32]

21, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36]

23, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40]

5, 3 :: [1, 3]

7, 3 :: [1, 2, 3, 5, 6, 9]

8, 3 :: [1, 2, 3, 4, 6, 7, 9, 12]

10, 3 :: [1, 2, 3, 4, 5, 6, 8, 9, 11, 12, 15, 18]

11, 3 :: [1, 2, 3, 4, 5, 6, 7, 9, 10, 12, 13, 15, 18, 21]

13, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 12, 14, 15, 17, 18, 21, 24, 27]

14, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 15, 16, 18, 19, 21, 24, 27, 30]

16, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 17, 18, 20, 21, 23, 24, 27, 30, 33, 36]

17, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 15, 16, 18, 19, 21, 22, 24, 25, 27, 30, 33, 36, 39]

19, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17, 18, 20, 21, 23, 24, 26, 27, 29, 30, 33, 36, 39, 42, 45]

20, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 19, 21, 22, 24, 25, 27, 28, 30, 31, 33, 36, 39, 42, 45, 48]

22, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 20, 21, 23, 24, 26, 27, 29, 30, 32, 33, 35, 36, 39, 42, 45, 48, 51, 54]

23, 3 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 21, 22, 24, 25, 27, 28, 30, 31, 33, 34, 36, 37, 39, 42, 45, 48, 51, 54, 57]

7, 4 :: [1, 2, 4, 5, 8]

9, 4 :: [1, 2, 3, 4, 6, 7, 8, 11, 12, 16]

11, 4 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 12, 13, 16, 17, 20, 24]

13, 4 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 14, 15, 16, 19, 20, 23, 24, 28, 32]

15, 4 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 16, 17, 18, 20, 21, 24, 25, 28, 29, 32, 36, 40]

17, 4 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 18, 19, 20, 22, 23, 24, 27, 28, 31, 32, 35, 36, 40, 44, 48]

19, 4 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 16, 17, 18, 20, 21, 22, 24, 25, 26, 28, 29, 32, 33, 36, 37, 40, 41, 44, 48, 52, 56]

21, 4 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 19, 20, 22, 23, 24, 26, 27, 28, 30, 31, 32, 35, 36, 39, 40, 43, 44, 47, 48, 52, 56, 60, 64]

23, 4 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 20, 21, 22, 24, 25, 26, 28, 29, 30, 32, 33, 34, 36, 37, 40, 41, 44, 45, 48, 49, 52, 53, 56, 60, 64, 68, 72]

7, 5 :: [1, 3, 5]

8, 5 :: [1, 2, 4, 5, 7, 10]

9, 5 :: [1, 2, 3, 5, 6, 7, 10, 11, 15]

11, 5 :: [1, 2, 3, 4, 5, 7, 8, 9, 10, 13, 14, 15, 19, 20, 25]

12, 5 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 13, 15, 16, 18, 20, 23, 25, 30]

13, 5 :: [1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 14, 15, 17, 19, 20, 22, 25, 27, 30, 35]

14, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 15, 16, 17, 20, 21, 22, 25, 26, 30, 31, 35, 40]

16, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 17, 18, 19, 20, 23, 24, 25, 28, 29, 30, 34, 35, 39, 40, 45, 50]

17, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 14, 15, 16, 18, 19, 20, 21, 23, 25, 26, 28, 30, 31, 33, 35, 38, 40, 43, 45, 50, 55]

18, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 19, 20, 21, 22, 24, 25, 27, 29, 30, 32, 34, 35, 37, 40, 42, 45, 47, 50, 55, 60]

19, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 15, 16, 17, 18, 20, 21, 22, 23, 25, 26, 27, 30, 31, 32, 35, 36, 37, 40, 41, 45, 46, 50, 51, 55, 60, 65]

21, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 22, 23, 24, 25, 27, 28, 29, 30, 33, 34, 35, 38, 39, 40, 43, 44, 45, 49, 50, 54, 55, 59, 60, 65, 70, 75]

22, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 19, 20, 21, 23, 24, 25, 26, 28, 29, 30, 31, 33, 35, 36, 38, 40, 41, 43, 45, 46, 48, 50, 53, 55, 58, 60, 63, 65, 70, 75, 80]

23, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 19, 20, 21, 22, 24, 25, 26, 27, 29, 30, 31, 32, 34, 35, 37, 39, 40, 42, 44, 45, 47, 49, 50, 52, 55, 57, 60, 62, 65, 67, 70, 75, 80, 85]

24, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 20, 21, 22, 23, 25, 26, 27, 28, 30, 31, 32, 33, 35, 36, 37, 40, 41, 42, 45, 46, 47, 50, 51, 52, 55, 56, 60, 61, 65, 66, 70, 71, 75, 80, 85, 90]

11, 6 :: [1, 2, 3, 4, 6, 7, 8, 9, 12, 13, 14, 18, 19, 24]

13, 6 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 15, 16, 17, 18, 22, 23, 24, 29, 30, 36]

17, 6 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 18, 19, 20, 21, 24, 25, 26, 27, 30, 31, 32, 36, 37, 38, 42, 43, 48, 49, 54, 60]

19, 6 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 20, 21, 22, 23, 24, 27, 28, 29, 30, 33, 34, 35, 36, 40, 41, 42, 46, 47, 48, 53, 54, 59, 60, 66, 72]

23, 6 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 19, 20, 21, 22, 24, 25, 26, 27, 28, 30, 31, 32, 33, 36, 37, 38, 39, 42, 43, 44, 45, 48, 49, 50, 54, 55, 56, 60, 61, 62, 66, 67, 72, 73, 78, 79, 84, 90, 96]

9, 7 :: [1, 3, 5, 7]

10, 7 :: [1, 2, 4, 5, 7, 8, 11, 14]

11, 7 :: [1, 2, 3, 5, 6, 7, 9, 10, 13, 14, 17, 21]

12, 7 :: [1, 2, 3, 4, 6, 7, 8, 9, 11, 13, 14, 16, 18, 21, 23, 28]

13, 7 :: [1, 2, 3, 4, 5, 7, 8, 9, 10, 11, 14, 15, 16, 17, 21, 22, 23, 28, 29, 35]

15, 7 :: [1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 17, 18, 19, 20, 21, 25, 26, 27, 28, 33, 34, 35, 41, 42, 49]

16, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 17, 19, 20, 21, 22, 24, 26, 28, 29, 31, 33, 35, 38, 40, 42, 47, 49, 56]

17, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 12, 13, 14, 15, 16, 18, 19, 21, 22, 23, 25, 26, 28, 29, 32, 33, 35, 36, 39, 42, 43, 46, 49, 53, 56, 63]

18, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 19, 20, 21, 23, 24, 26, 27, 28, 30, 31, 34, 35, 37, 38, 41, 42, 45, 48, 49, 52, 56, 59, 63, 70]

19, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 14, 15, 16, 17, 18, 20, 21, 22, 23, 25, 27, 28, 29, 30, 32, 34, 35, 37, 39, 41, 42, 44, 46, 49, 51, 53, 56, 58, 63, 65, 70, 77]

20, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 21, 22, 23, 24, 25, 28, 29, 30, 31, 32, 35, 36, 37, 38, 42, 43, 44, 45, 49, 50, 51, 56, 57, 58, 63, 64, 70, 71, 77, 84]

22, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 31, 32, 33, 34, 35, 38, 39, 40, 41, 42, 46, 47, 48, 49, 53, 54, 55, 56, 61, 62, 63, 68, 69, 70, 76, 77, 83, 84, 91, 98]

23, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 24, 25, 26, 27, 28, 29, 31, 33, 34, 35, 36, 38, 40, 41, 42, 43, 45, 47, 49, 50, 52, 54, 56, 57, 59, 61, 63, 66, 68, 70, 73, 75, 77, 82, 84, 89, 91, 98, 105]

24, 7 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 19, 20, 21, 22, 23, 25, 26, 27, 28, 29, 30, 32, 33, 35, 36, 37, 39, 40, 42, 43, 44, 46, 47, 49, 50, 53, 54, 56, 57, 60, 61, 63, 64, 67, 70, 71, 74, 77, 78, 81, 84, 88, 91, 95, 98, 105, 112]

11, 8 :: [1, 2, 4, 5, 7, 8, 10, 13, 16]

13, 8 :: [1, 2, 3, 4, 6, 7, 8, 9, 11, 12, 14, 16, 17, 19, 22, 24, 27, 32]

15, 8 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 16, 17, 18, 19, 20, 24, 25, 26, 27, 32, 33, 34, 40, 41, 48]

17, 8 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 16, 19, 20, 21, 22, 23, 24, 28, 29, 30, 31, 32, 37, 38, 39, 40, 46, 47, 48, 55, 56, 64]

19, 8 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 20, 21, 23, 24, 25, 26, 28, 29, 31, 32, 34, 36, 37, 39, 40, 42, 45, 47, 48, 50, 53, 56, 58, 61, 64, 69, 72, 80]

21, 8 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 22, 23, 24, 25, 27, 28, 30, 31, 32, 33, 35, 36, 38, 40, 41, 43, 44, 46, 48, 49, 51, 54, 56, 57, 59, 62, 64, 67, 70, 72, 75, 80, 83, 88, 96]

23, 8 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 16, 17, 18, 19, 20, 21, 22, 24, 25, 26, 27, 28, 29, 32, 33, 34, 35, 36, 37, 40, 41, 42, 43, 44, 48, 49, 50, 51, 52, 56, 57, 58, 59, 64, 65, 66, 67, 72, 73, 74, 80, 81, 82, 88, 89, 96, 97, 104, 112]

11, 9 :: [1, 3, 5, 7, 9]

13, 9 :: [1, 2, 3, 5, 6, 7, 9, 10, 11, 14, 15, 18, 19, 23, 27]

14, 9 :: [1, 2, 3, 4, 6, 7, 8, 9, 11, 12, 13, 16, 17, 18, 21, 22, 26, 27, 31, 36]

16, 9 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 17, 18, 19, 20, 22, 24, 26, 27, 29, 31, 33, 36, 38, 40, 45, 47, 54]

17, 9 :: [1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 18, 19, 20, 21, 22, 23, 27, 28, 29, 30, 31, 36, 37, 38, 39, 45, 46, 47, 54, 55, 63]

19, 9 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 12, 13, 14, 15, 16, 17, 18, 21, 22, 23, 24, 25, 26, 27, 31, 32, 33, 34, 35, 36, 41, 42, 43, 44, 45, 51, 52, 53, 54, 61, 62, 63, 71, 72, 81]

20, 9 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 21, 23, 24, 25, 26, 27, 28, 30, 32, 34, 35, 36, 37, 39, 41, 43, 45, 46, 48, 50, 52, 54, 57, 59, 61, 63, 68, 70, 72, 79, 81, 90]

22, 9 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 27, 28, 29, 30, 32, 33, 34, 36, 37, 38, 41, 42, 43, 45, 46, 47, 50, 51, 54, 55, 56, 59, 60, 63, 64, 68, 69, 72, 73, 77, 81, 82, 86, 90, 95, 99, 108]

23, 9 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 15, 16, 17, 18, 19, 20, 21, 22, 24, 25, 26, 27, 29, 30, 31, 33, 34, 35, 36, 38, 39, 40, 43, 44, 45, 47, 48, 49, 52, 53, 54, 57, 58, 61, 62, 63, 66, 67, 71, 72, 75, 76, 80, 81, 85, 89, 90, 94, 99, 103, 108, 117]

13, 10 :: [1, 2, 4, 5, 7, 8, 10, 11, 14, 17, 20]

17, 10 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 16, 18, 19, 20, 22, 23, 25, 26, 29, 30, 32, 33, 36, 39, 40, 43, 46, 50, 53, 60]

19, 10 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 16, 17, 20, 21, 22, 23, 24, 25, 26, 30, 31, 32, 33, 34, 35, 40, 41, 42, 43, 44, 50, 51, 52, 53, 60, 61, 62, 70, 71, 80]

21, 10 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 23, 24, 25, 26, 27, 28, 29, 30, 34, 35, 36, 37, 38, 39, 40, 45, 46, 47, 48, 49, 50, 56, 57, 58, 59, 60, 67, 68, 69, 70, 78, 79, 80, 89, 90, 100]

23, 10 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 21, 22, 24, 25, 27, 28, 29, 30, 31, 32, 34, 35, 37, 38, 40, 41, 42, 44, 45, 47, 48, 50, 51, 54, 55, 57, 58, 60, 61, 64, 67, 68, 70, 71, 74, 77, 80, 81, 84, 87, 90, 94, 97, 100, 107, 110, 120]

13, 11 :: [1, 3, 5, 7, 9, 11]

14, 11 :: [1, 2, 4, 5, 7, 8, 10, 11, 13, 16, 19, 22]

15, 11 :: [1, 2, 3, 5, 6, 7, 9, 10, 11, 13, 14, 17, 18, 21, 22, 25, 29, 33]

16, 11 :: [1, 2, 3, 4, 6, 7, 8, 9, 11, 12, 13, 14, 17, 18, 19, 22, 23, 24, 28, 29, 33, 34, 39, 44]

17, 11 :: [1, 2, 3, 4, 5, 7, 8, 9, 10, 11, 13, 14, 15, 16, 19, 20, 21, 22, 25, 26, 27, 31, 32, 33, 37, 38, 43, 44, 49, 55]

18, 11 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 15, 16, 17, 19, 20, 22, 23, 24, 26, 27, 30, 31, 33, 34, 37, 38, 41, 44, 45, 48, 52, 55, 59, 66]

19, 11 :: [1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 17, 18, 20, 21, 22, 23, 25, 26, 28, 29, 31, 33, 34, 36, 37, 39, 42, 44, 45, 47, 50, 53, 55, 58, 61, 66, 69, 77]

20, 11 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 16, 17, 19, 21, 22, 23, 24, 25, 26, 28, 30, 32, 33, 34, 35, 37, 39, 41, 43, 44, 46, 48, 50, 52, 55, 57, 59, 61, 66, 68, 70, 77, 79, 88]

21, 11 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 12, 13, 14, 15, 16, 17, 18, 19, 22, 23, 24, 25, 26, 27, 28, 29, 33, 34, 35, 36, 37, 38, 39, 44, 45, 46, 47, 48, 49, 55, 56, 57, 58, 59, 66, 67, 68, 69, 77, 78, 79, 88, 89, 99]

23, 11 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 25, 26, 27, 28, 29, 30, 31, 32, 33, 37, 38, 39, 40, 41, 42, 43, 44, 49, 50, 51, 52, 53, 54, 55, 61, 62, 63, 64, 65, 66, 73, 74, 75, 76, 77, 85, 86, 87, 88, 97, 98, 99, 109, 110, 121]

24, 11 :: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 25, 27, 28, 29, 30, 31, 32, 33, 34, 36, 38, 40, 41, 42, 43, 44, 45, 47, 49, 51, 53, 54, 55, 56, 58, 60, 62, 64, 66, 67, 69, 71, 73, 75, 77, 80, 82, 84, 86, 88, 93, 95, 97, 99, 106, 108, 110, 119, 121, 132]


For fixed R, the length of the set increases with Q. If we sort by Q first, we see that the sequence lengthen and then shorten.
...

9, 1 :: [1, 2, 3, 4, 5, 6, 7]
9, 2 :: [1, 2, 3, 4, 5, 6, 8, 10, 12]
9, 4 :: [1, 2, 3, 4, 6, 7, 8, 11, 12, 16]
9, 5 :: [1, 2, 3, 5, 6, 7, 10, 11, 15]
9, 7 :: [1, 3, 5, 7]
10, 1 :: [1, 2, 3, 4, 5, 6, 7, 8]
10, 3 :: [1, 2, 3, 4, 5, 6, 8, 9, 11, 12, 15, 18]
10, 7 :: [1, 2, 4, 5, 7, 8, 11, 14]
11, 1 :: [1, 2, 3, 4, 5, 6, 7, 8, 9]
11, 2 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 12, 14, 16]
11, 3 :: [1, 2, 3, 4, 5, 6, 7, 9, 10, 12, 13, 15, 18, 21]
11, 4 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 12, 13, 16, 17, 20, 24]
11, 5 :: [1, 2, 3, 4, 5, 7, 8, 9, 10, 13, 14, 15, 19, 20, 25]
11, 6 :: [1, 2, 3, 4, 6, 7, 8, 9, 12, 13, 14, 18, 19, 24]
11, 7 :: [1, 2, 3, 5, 6, 7, 9, 10, 13, 14, 17, 21]
11, 8 :: [1, 2, 4, 5, 7, 8, 10, 13, 16]
11, 9 :: [1, 3, 5, 7, 9]
...
.
Kind of interesting, right? 

For fixed R, the length of the exception set increases linearly in Q. If we call the length of the exception set L, then the full formula is:
L = (Q - (R + 1)) * (R + 1) / 2

For example, when Q=11 and R=9, then L = 5, and indeed as you can see above, the exception set for (11, 9) has five members: [1, 3, 5, 7, 9].
.
For fixed Q, this formula is an inverted parabola, so that explains why the exceptions sets lengthened and then shortened as R increased with Q fixed, yeah? Yeah.

I've found a regularity in the maximum values of the exception sets. Take for example some exception sets with R=5:

7, 5 :: [1, 3, 5]
8, 5 :: [1, 2, 4, 5, 7, 10]
9, 5 :: [1, 2, 3, 5, 6, 7, 10, 11, 15]
11, 5 :: [1, 2, 3, 4, 5, 7, 8, 9, 10, 13, 14, 15, 19, 20, 25]
12, 5 :: [1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 13, 15, 16, 18, 20, 23, 25, 30]
13, 5 :: [1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, 14, 15, 17, 19, 20, 22, 25, 27, 30, 35]
14, 5 :: [1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 15, 16, 17, 20, 21, 22, 25, 26, 30, 31, 35, 40]
.
First, the maximum value is always divisible by R. Second, the maximum value increase linearly with increasing Q,

7, 5 |> 5 = 5 * 1
8, 5 |> 10 = 5 * 2
9, 5 |> 15 = 5 * 3
10, 5 |> exceptions not finite
11, 5 |> 25 = 5 * 5
12, 5 |> 30 = 5 * 6
13, 5 |> 35 = 5 * 7
14, 5 |> 40 = 5 * 8
.
The largest valued exception, when there are a positive finite number of exceptions, is 
  MAX = (Q - (R + 1)) * R
.
With this formula, we can predict, for example, that with Q=24 and R=11, we get 132 as a maximum, which matches the full data above.

We can use this to find out when the maximum value will equal R, as it does above for (7, 5). The formula R * (Q - (R + 1)) equals R when {Q - R = 2}, so for R = 5, we get a maximum value of 5 when ... *computing* ... when Q = 7, provided that the exception set exists, for which we also require that (5, 7) be coprime, which of course they are.

That's all I've figured out so far, but I'll keep at it, and then eventually I'll reintroduce the gcd() denominator term, and figure that out too.

There's also a regularity in the second most maximum member of each exception set. Let's count backward with indices and call the maximum exception member "e_set[-1]", and second most maximum exception member "e_set[-2]" and so on. Then we can write:
e_set[-2] = (Q - (R + 2)) * R
.

For example, when Q=23 and R=6, we have a penultimate maximum of ...*computes* ... of 90, and indeed the exception set for (23, 6) ends [.., 84, 90, 96].

Next let's try to characterize the first positive integer that isn't in the exception set. It will be the 0th member of the covered set, so let's call it c_set[0]? I've heard of worse names. This one was really easy to figure out.
c_set[0] = Q - R
.
So the first gap in the exception set for (24, 11) is 13.

You know, I've been thinking: the form of MAX, i.e. e_set[-1], and the penultimate max, e_set[-2], were almost identical. 
  e_set[-1] = (Q - (R + 1)) * R
e_set[-2] = (Q - (R + 2)) * R

Let's look at e_set[-3] next Might it be
e_set[-2] = (Q - (R + 3)) * R
?

Oh, fascinating! That works for small R and Q, but it breaks down higher up, e.g. it predicts e_set[-2] of 12 for (11, 6), but it's actually 18.  The numbers predicted by my formula seem to be in the exceptions sets (or non-positive), but when they show up, they're not always the third member from the end.  Indeed, the third member from the end isn't generally divisible by R.

New plan! Let's look at all the members of the exception set that are larger than (Q - R) and not divisible by R.

Here are some for R=3: 
11, 3 :: [10, 13]
13, 3 :: [11, 14, 17]
14, 3 :: [13, 16, 19]
16, 3 :: [14, 17, 20, 23]
17, 3 :: [16, 19, 22, 25]
19, 3 :: [17, 20, 23, 26, 29]
20, 3 :: [19, 22, 25, 28, 31]
22, 3 :: [20, 23, 26, 29, 32, 35]
23, 3 :: [22, 25, 28, 31, 34, 37]
The last member increases from one line to the next by 4 then by 2 then by 4 then 2 then 4 then .... Kind of cool, I suppose.  Yeah, I don't know what to do with this. Let's look somewhere else for a bit.

Better idea: let's just look at the first exception set member larger than (Q - R). Way easier: it's 
Q - R + 1
.
How about the second exception set member larger than (Q - R)?  No, that's not good either.

...

No comments:

Post a Comment