cp's OEIS Frontend

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.

A319513 The boustrophedonic Rosenberg-Strong function maps N onto N X N where N = {0, 1, 2, ...} and n -> factor(a(n)) = 2^x*3^y -> (x, y).

This page as a plain text file.
%I A319513 #29 Feb 14 2019 05:56:47
%S A319513 1,3,6,2,4,12,36,18,9,27,54,108,216,72,24,8,16,48,144,432,1296,648,
%T A319513 324,162,81,243,486,972,1944,3888,7776,2592,864,288,96,32,64,192,576,
%U A319513 1728,5184,15552,46656,23328,11664,5832,2916,1458,729,2187,4374,8748,17496
%N A319513 The boustrophedonic Rosenberg-Strong function maps N onto N X N where N = {0, 1, 2, ...} and n -> factor(a(n)) = 2^x*3^y -> (x, y).
%C A319513 If (x, y) and (x', y') are adjacent points on the trajectory of the map then for the boustrophedonic Rosenberg-Strong function max(|x - x'|, |y - y'|) is always 1 whereas for the Rosenberg-Strong function this quantity can become arbitrarily large. In this sense the boustrophedonic variant is continuous in contrast to the original Rosenberg-Strong function.
%D A319513 A. L. Rosenberg, H. R. Strong, Addressing arrays by shells, IBM Technical Disclosure Bulletin, vol 14(10), 1972, p. 3026-3028.
%H A319513 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.
%H A319513 Steven Pigeon, <a href="https://hbfs.wordpress.com/2018/08/07/moeud-deux/">Mœud deux</a>, 2018.
%H A319513 A. L. Rosenberg, <a href="https://doi.org/10.1145/321850.321861">Allocating storage for extendible Arrays</a>, J. ACM, vol 21(4), 1974, p. 652-670.
%H A319513 M. P. Szudzik, <a href="http://arxiv.org/abs/1706.04129">The Rosenberg-Strong Pairing Function"</a>, arXiv:1706.04129 [cs.DM], 2017.
%p A319513 A319513 := proc(n) local b, r, p, m;
%p A319513     b := floor(sqrt(n)); r := n - b^2;
%p A319513     p := `if`(r < b, [b, r], [2*b-r, b]);
%p A319513     m := `if`(p[1] > p[2], p[1], p[2]);
%p A319513     `if`(irem(m,2) = 0, 2^p[1]*3^p[2], 2^p[2]*3^p[1]) end:
%p A319513 seq(A319513(n), n=0..52);
%t A319513 a[n_] := Module[{b, r, p1, p2, m}, b = Floor[Sqrt[n]]; r = n-b^2; {p1, p2} = If[r<b, {b, r}, {2b-r, b}]; m = If[p1>p2, p1, p2]; If[EvenQ[m], 2^p1 3^p2, 2^p2 3^p1]]; Table[a[n], {n, 0, 52}] (* _Jean-François Alcover_, Feb 14 2019, from Maple *)
%o A319513 (Julia)
%o A319513 function bRS(n)
%o A319513     m = x = isqrt(n)
%o A319513     y = n - x^2
%o A319513     x <= y && ((x, y) = (2x - y, x))
%o A319513     isodd(m) ? (y, x) : (x, y)
%o A319513 end
%o A319513 A319513(n) = ((x, y) = bRS(n); 2^x * 3^y)
%o A319513 [A319513(n) for n in 0:52] |> println
%Y A319513 See A319514 for a non-decoded variant with interleaved x and y coordinates.
%Y A319513 Cf. A038566/A038567, A157807/A157813.
%K A319513 nonn
%O A319513 0,2
%A A319513 _Peter Luschny_, Sep 21 2018