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 A120858 #21 Nov 18 2024 08:33:41 %S A120858 1,2,5,3,11,29,4,17,64,169,6,23,99,373,985,7,34,134,577,2174,5741,8, %T A120858 40,198,781,3363,12671,33461,9,46,233,1154,4552,19601,73852,195025,10, %U A120858 52,268,1358,6726,26531,114243,430441,1136689,12,58,303,1562 %N A120858 Dispersion of the Beatty sequence ([r*n]: n >= 1), where r = 3 + 8^(1/2): square array D(n,m) (n, m >= 1), read by ascending antidiagonals. %C A120858 Every positive integer occurs exactly once in array D and every pair of rows are mutually interspersed. That is, beginning at the first term of any row in D having greater initial term than that of another row, all the following terms individually separate the individual terms of the other row. %H A120858 Clark Kimberling, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL10/Kimberling2/kimberling45.html">The equation (j+k+1)^2 - 4*k = Q*n^2 and related dispersions</a>, Journal of Integer Sequences, 10 (2007), Article #07.2.7. %H A120858 N. J. A. Sloane, <a href="/classic.html#WYTH">Classic Sequences</a>. %H A120858 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/BeattySequence.html">Beatty sequence</a>. %H A120858 Wikipedia, <a href="https://en.wikipedia.org/wiki/Beatty_sequence">Beatty sequence</a>. %F A120858 (1) Column 1 is the sequence ([s*n]: n >= 1) where 1/r + 1/s = 1. The numbers in all the other columns, arranged in increasing order, form the sequence ([r*n]: n >= 1). %F A120858 (2) Every row satisfies these recurrences: x(n+1) = [r*x(n)] and x(n+2) = 6*x(n+1) - x(n). (Here [a] is the floor of number a.) %e A120858 Northwest corner: %e A120858 1, 5, 29, 169, 985, ... %e A120858 2, 11, 64, 373, 2174, ... %e A120858 3, 17, 99, 577, 3363, ... %e A120858 4, 23, 134, 781, 4552, ... %e A120858 6, 34, 198, 1154, 6726, ... %e A120858 ... %e A120858 In row 1, we have 5 = [r], 29 = [5*r], 169 = [29*r], etc., where r = 3 + 8^(1/2); each new row starts with the least "new" number n, followed by [n*r], [[n*r]*r], [[[n*r]*r]*r], and so on. %o A120858 (PARI) tabls(nn)={default("realprecision", 1000); my(D=matrix(nn,nn)); r = 3 + 8^(1/2); s=r/(r-1); for(n=1, nn, D[n,1]=floor(s*n)); for(m=2, nn, for(n=1, nn, D[n,m]=floor(r*D[n,m-1]))); D} %o A120858 /* To print the array flattened */ %o A120858 flat(nn)={D=tabls(nn); for(n=1, nn, for(m=1, n, print1(D[n+1-m,m],",")))} %o A120858 /* To print the square array */ %o A120858 square(nn)={D=tabls(nn); for(n=1,nn, for(m=1,nn, print1(D[n,m], ",")); print())} \\ _Petros Hadjicostas_, Jul 07 2020 %Y A120858 Cf. A120859, A120860, A120861, A120862, A120863. %K A120858 nonn,tabl %O A120858 1,2 %A A120858 _Clark Kimberling_, Jul 09 2006 %E A120858 Name edited by _Petros Hadjicostas_, Jul 07 2020