A366191 Enumeration of the rational numbers in the closed real interval [0, 1] after Cantor.
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, 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, 9, 1, 14, 2, 13, 4, 11, 7, 8, 1, 15, 3, 13, 5, 11, 7, 9
Offset: 1
Examples
Seen as an irregular table: 1: [0, 1], 2: [1, 1], 3: [1, 2], 4: [1, 3], 5: [1, 4], [2, 3], 6: [1, 5], 7: [1, 6], [2, 5], [3, 4], 8: [1, 7], [3, 5], 9: [1, 8], [2, 7], [4, 5], 10: [1, 9], [3, 7], 11: [1, 10], [2, 9], [3, 8], [4, 7], [5, 6], ...
Links
- Paolo Xausa, Table of n, a(n) for n = 1..12234
- Georg Cantor, Ein Beitrag zur Mannigfaltigkeitslehre, Journal für die reine und angewandte Mathematik 84 (1878), 242-258, (p. 250).
- Index entries for sequences related to enumerating the rationals
Crossrefs
Programs
-
Maple
A366191List := proc(upto) local C, F, n, t, count; C := [0, 1]; count := 0: for n from 2 while count < upto do F := select(t -> igcd(t, n - t) = 1, [$1..iquo(n,2)]); C := C, seq([t, n - t], t = F); count := count + nops(F) od; ListTools:-Flatten([C]) end: A366191List(40);
-
Mathematica
A366191row[n_] := If[n == 1, {0, 1}, Select[Array[{#, n - #}&, Floor[n/2]], CoprimeQ[First[#], Last[#]]&]]; Array[A366191row, 20] (* Paolo Xausa, Jan 16 2024 *)
Comments