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.

A144387 Triangle read by rows: row n gives the coefficients in the expansion of Sum_{j=0..n} A000040(j+1)*x^j*(1 - x)^(n - j).

Original entry on oeis.org

2, 2, 1, 2, -1, 4, 2, -3, 5, 3, 2, -5, 8, -2, 8, 2, -7, 13, -10, 10, 5, 2, -9, 20, -23, 20, -5, 12, 2, -11, 29, -43, 43, -25, 17, 7, 2, -13, 40, -72, 86, -68, 42, -10, 16, 2, -15, 53, -112, 158, -154, 110, -52, 26, 13, 2, -17, 68, -165, 270, -312, 264, -162, 78, -13, 18
Offset: 0

Views

Author

Roger L. Bagula and Gary W. Adamson, Oct 01 2008

Keywords

Comments

Row sums yield the primes A000040.

Examples

			Triangle begins
    2;
    2,   1;
    2,  -1,  4;
    2,  -3,  5,    3;
    2,  -5,  8,   -2,   8;
    2,  -7, 13,  -10,  10,    5;
    2,  -9, 20,  -23,  20,   -5,  12;
    2, -11, 29,  -43,  43,  -25,  17,    7;
    2, -13, 40,  -72,  86,  -68,  42,  -10, 16;
    2, -15, 53, -112, 158, -154, 110,  -52, 26,  13;
    2, -17, 68, -165, 270, -312, 264, -162, 78, -13, 18;
    ...
		

Crossrefs

Programs

  • Mathematica
    p[x_, n_] = Sum[Prime[k + 1]*x^k*(1 - x)^(n - k), {k, 0, n}];
    Table[CoefficientList[p[x, n], x], {n, 0, 10}]//Flatten
  • Sage
    def p(n,x): return sum( nth_prime(j+1)*x^j*(1-x)^(n-j) for j in (0..n) )
    def T(n): return ( p(n,x) ).full_simplify().coefficients(sparse=False)
    [T(n) for n in (0..12)] # G. C. Greubel, Jul 15 2021

Extensions

Edited, new name, and offset corrected by Franck Maminirina Ramaharo, Oct 19 2018