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.

A262324 Conway's triangle of "happy factorizations" (flattened).

Original entry on oeis.org

0, 0, 1, 1, 1, 2, 1, 3, 2, 2, 1, 5, 2, 3, 7, 1, 2, 4, 3, 3, 1, 10, 1, 11, 3, 4, 1, 13, 7, 2, 3, 5, 4, 4, 1, 17, 2, 9, 1, 19, 4, 5, 3, 7, 2, 11, 23, 1, 4, 6, 5, 5, 1, 26, 1, 27, 7, 4, 1, 29, 5, 6, 31, 1, 16, 2, 11, 3, 17, 2, 5, 7, 6, 6, 1, 37, 2, 19, 3, 13, 2, 20, 1, 41, 6, 7, 1, 43, 11, 4, 5, 9, 23, 2, 47, 1, 6, 8, 7, 7
Offset: 0

Views

Author

Jean-François Alcover, Sep 18 2015

Keywords

Comments

Conway's triangle is listed by increasing couple products, with duplicate squares removed.

Examples

			Triangle begins:
{0,0},
{1,1},
{1,2},   {1,3},  {2,2},
{1,5},   {2,3},  {7,1},  {2,4}, {3,3},
{1,10}, {1,11},  {3,4}, {1,13}, {7,2},  {3,5},  {4,4},
{1,17},  {2,9}, {1,19},  {4,5}, {3,7}, {2,11}, {23,1}, {4,6}, {5,5},
...
The original triangle (adapted and truncated):
                           ...
                      5^2  ...
                 4^2  1*26 ...
            3^2  1*17 1*27 ...
        2^2 1*10 2*9  7*4  ...
    1^2 1*5 1*11 1*19 1*29 ...
0^2 1*2 2*3 3*4  4*5  5*6  ...
1^2 1*3 7*1 1*13 3*7  31*1 ...
    2^2 2*4 7*2  2*11 16*2 ...
        3^2 3*5  23*1 11*3 ...
            4^2  4*6  17*2 ...
                 5^2  5*7  ...
                      6^2  ...
                           ...
		

Crossrefs

Programs

  • Mathematica
    f[0] = {0, 0}; f[32] = {16, 2}(* to speed up *); f[n_] := Do[c = n/b; If[b == c, Return[{b, b}]]; r1 = Reduce[r >= 0 && s >= 0 && c > 1 && b*r^2 + 1 == c*s^2, {r, s}, Integers]; If[r1 =!= False, Return[{b, c}]]; r2 = Reduce[r >= 0 && s >= 0 && r == 2x + 1 && s == 2y + 1 && b*r^2 + 2 == c *s^2, {r, s, x, y}, Integers]; If[r2 =!= False, Return[{b, c}]], {b, Divisors[n]}]; Table[Print["f(", n, ") = ", fn = f[n]]; fn, {n, 0, 49}] // Flatten