This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A366191 #23 Feb 27 2024 06:17:21 %S A366191 0,1,1,1,1,2,1,3,1,4,2,3,1,5,1,6,2,5,3,4,1,7,3,5,1,8,2,7,4,5,1,9,3,7, %T A366191 1,10,2,9,3,8,4,7,5,6,1,11,5,7,1,12,2,11,3,10,4,9,5,8,6,7,1,13,3,11,5, %U A366191 9,1,14,2,13,4,11,7,8,1,15,3,13,5,11,7,9 %N A366191 Enumeration of the rational numbers in the closed real interval [0, 1] after Cantor. %C A366191 The rational numbers in the interval [0, 1] are listed as pairs of relatively prime integers a(2*n-1) / a(2*n). %C A366191 Start with (0, 1). Then append pairs (t, n - t) where t and n - t are relatively prime positive integers and 1 <= t <= floor(n/2). Sort first by n then by t in ascending order. %H A366191 Paolo Xausa, <a href="/A366191/b366191.txt">Table of n, a(n) for n = 1..12234</a> %H A366191 Georg Cantor, <a href="http://gdz.sub.uni-goettingen.de/dms/resolveppn/?PPN=GDZPPN002156806">Ein Beitrag zur Mannigfaltigkeitslehre</a>, Journal für die reine und angewandte Mathematik 84 (1878), 242-258, (p. 250). %H A366191 <a href="/index/Ra#rational">Index entries for sequences related to enumerating the rationals</a> %e A366191 Seen as an irregular table: %e A366191 1: [0, 1], %e A366191 2: [1, 1], %e A366191 3: [1, 2], %e A366191 4: [1, 3], %e A366191 5: [1, 4], [2, 3], %e A366191 6: [1, 5], %e A366191 7: [1, 6], [2, 5], [3, 4], %e A366191 8: [1, 7], [3, 5], %e A366191 9: [1, 8], [2, 7], [4, 5], %e A366191 10: [1, 9], [3, 7], %e A366191 11: [1, 10], [2, 9], [3, 8], [4, 7], [5, 6], %e A366191 ... %p A366191 A366191List := proc(upto) local C, F, n, t, count; %p A366191 C := [0, 1]; count := 0: %p A366191 for n from 2 while count < upto do %p A366191 F := select(t -> igcd(t, n - t) = 1, [$1..iquo(n,2)]); %p A366191 C := C, seq([t, n - t], t = F); %p A366191 count := count + nops(F) od; %p A366191 ListTools:-Flatten([C]) end: %p A366191 A366191List(40); %t A366191 A366191row[n_] := If[n == 1, {0, 1}, Select[Array[{#, n - #}&, Floor[n/2]], CoprimeQ[First[#], Last[#]]&]]; %t A366191 Array[A366191row, 20] (* _Paolo Xausa_, Jan 16 2024 *) %Y A366191 Cf. A352911, A333856 (numerators only). %Y A366191 Essentially, A182972/A182973 give the numerators/denominators separately. %K A366191 nonn,easy,tabf %O A366191 1,6 %A A366191 _Peter Luschny_, Oct 10 2023