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.

A181738 T(n, k) is the coefficient of x^k of the polynomial p(n) which is defined as the scalar part of P(n) = Q(x+1, 1, 1, 1) * P(n-1) for n > 0 and P(0) = Q(1, 0, 0, 0) where Q(a, b, c, d) is a quaternion, triangle read by rows.

Original entry on oeis.org

1, 1, 1, -2, 2, 1, -8, -6, 3, 1, -8, -32, -12, 4, 1, 16, -40, -80, -20, 5, 1, 64, 96, -120, -160, -30, 6, 1, 64, 448, 336, -280, -280, -42, 7, 1, -128, 512, 1792, 896, -560, -448, -56, 8, 1, -512, -1152, 2304, 5376, 2016, -1008, -672, -72, 9, 1, -512, -5120, -5760, 7680, 13440, 4032, -1680, -960, -90, 10, 1
Offset: 0

Views

Author

Keywords

Comments

The symbol '*' in the name refers to the noncommutative multiplication in Hamilton's division algebra. Traditionally Q(a, b, c, d) is written a + b*i + c*j + d*k.

Examples

			The list of polynomials starts 1, 1 + x, -2 + 2*x + x^2, -8 - 6*x + 3*x^2 + x^3, ... and the list of coefficients of the polynomials starts:
{   1},
{   1,     1},
{  -2,     2,     1},
{  -8,    -6,     3,    1},
{  -8,   -32,   -12,    4,     1},
{  16,   -40,   -80,  -20,     5,     1},
{  64,    96,  -120, -160,   -30,     6,     1},
{  64,   448,   336, -280,  -280,   -42,     7,    1},
{-128,   512,  1792,  896,  -560,  -448,   -56,    8,   1},
{-512, -1152,  2304, 5376,  2016, -1008,  -672,  -72,   9,  1},
{-512, -5120, -5760, 7680, 13440,  4032, -1680, -960, -90, 10, 1}.
		

Crossrefs

Cf. T(n,0) = A138230, A213421 (row sums).

Programs

  • Mathematica
    Needs["Quaternions`"]
    P[x_, 0 ] := Quaternion[1, 0, 0, 0];
    P[x_, n_] := P[x, n] = Quaternion[x + 1, 1, 1, 1] ** P[x, n - 1];
    Table[CoefficientList[P[x, n][[1]], x], {n, 0, 10}] // Flatten
  • Sage
    R. = QQ[]
    K = R.fraction_field()
    H. = QuaternionAlgebra(K, -1, -1)
    def Q(a, b, c, d): return H(a + b*i + c*j + d*k)
    @cached_function
    def P(n):
        return Q(x+1,1,1,1)*P(n-1) if n > 0 else Q(1,0,0,0)
    def p(n): return P(n)[0].numerator().list()
    flatten([p(n) for n in (0..10)]) # Kudos to William Stein, Peter Luschny, Sep 14 2018

Extensions

Edited by Peter Luschny, Sep 14 2018