OFFSET
1,2
COMMENTS
Let Q = {a/b: gcd(a,b)=1, a>0, b>0}; i.e., the positive rationals, reduced to lowest terms, and let x be a positive irrational number. For any dense subset S of Q, a sequence of fractions a(n)/b(n) in S is the S-best upper approximating sequence if it satisfies these three conditions:
(1) a(1)/b(1) > a(2)/b(2) > a(3)/b(3) > ... > x
(2) b(1) < b(2) < b(3) < ...
(3) if b(k) < v < b(k+1) for some u/v in S and k>=1, then u/v is not between a(k)/b(k) and a(k+1)/b(k+1).
Define the best upper approximating array to x by rows, r(n,k), for k>=1, as follows:
Row 1: With S = Q, put r(1,1) = a(1)/b(1), where a(1) = ceiling(x) and b(1)=1. The terms r(1,k) are then uniquely determined by conditions (1), (2), (3). Note that row 1 consists of the upper convergents to x.
Rows n>=2: With S = (Q after deleting all fractions in rows 1,2,...,n-1), let r(n,1) = the fraction a/b in S that is nearest x and > x and has least denominator b that is new; i.e., a/b is not in the first n-1 rows. The terms of row (r(n,k)) are uniquely determined by (1), (2), (3).
Every row and every column converges to x. Regarding the arrays of denominators and numerators for the best lower and upper approximating arrays, every row and every column is strictly increasing.
For the present array, x = phi.
EXAMPLE
Corner of array of denominators:
1 3 8 21 55 144 377 987 2584 6765 17711
4 7 10 11 19 27 29 50 71 76 131
5 13 14 25 30 35 37 66 79 92 97
17 31 36 41 43 45 82 95 108 113 118
20 39 46 51 53 98 103 121 134 139 207
23 47 49 59 61 114 119 124 129 155 160
Corner of array of numerators:
2 5 13 34 89 233 610 1597 4181 10946 28657
7 12 17 18 31 44 47 81 115 123 212
9 22 23 41 49 57 60 107 128 149 157
28 51 59 67 70 73 133 154 175 183 191
33 64 75 83 86 159 167 196 217 225 335
38 77 80 96 99 185 193 201 209 251 259
Corner of array of approximations:
2. 1.66667 1.625 1.61905 1.61818 1.61806
1.75 1.71429 1.7 1.63636 1.63158 1.62963
1.8 1.69231 1.64286 1.64 1.63333 1.62857
1.64706 1.64516 1.63889 1.63415 1.62791 1.62222
1.65 1.64103 1.63043 1.62745 1.62264 1.62245
1.65217 1.6383 1.63265 1.62712 1.62295 1.62281
MATHEMATICA
x = GoldenRatio; numRows = 6; numCols = 12;
usedValuesUpper = {}; upperArray = Table[Null, {numRows}, {numCols}];
For[n = 1, n <= numRows, n++, b = 1; foundStart = False;
While[! foundStart, a = Ceiling[b*x];
val = a/b;
If[val > x && GCD[a, b] == 1 && ! MemberQ[usedValuesUpper, val],
upperArray[[n, 1]] = val;
AppendTo[usedValuesUpper, val];
foundStart = True, b++]];
For[k = 1, k < numCols, k++, currentVal = upperArray[[n, k]];
currentB = Denominator[currentVal];
nextVal = Null; testB = currentB + 1;
While[nextVal === Null, testA = Ceiling[testB*x];
candidate = testA/testB;
If[GCD[testA, testB] == 1 && candidate < currentVal &&
candidate > x && ! MemberQ[usedValuesUpper, candidate],
nextVal = candidate;
AppendTo[usedValuesUpper, candidate];
upperArray[[n, k + 1]] = nextVal, testB++]]; ]; ];
Grid[upperArray] (* Best lower approximating array to golden ratio *)
Grid[N[upperArray]] (* Approximations *)
Grid[Denominator[upperArray]] (* A394035 *)
Grid[Numerator[upperArray]] (* A394036 *)
CROSSREFS
KEYWORD
AUTHOR
Clark Kimberling, Mar 10 2026
STATUS
approved
