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.

A076620 Coefficient of x^a(n) in (x+1)*(x+2)*...*(x+n) is the largest one.

Original entry on oeis.org

0, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4
Offset: 1

Views

Author

Benoit Cloitre, Nov 10 2002

Keywords

Examples

			In (x+1)(x+2)(x+3) = x^3 + 6*x^2 + 11*x + 6, the largest coefficient (11) appears at x^1, hence a(3)=1.
		

Crossrefs

Programs

  • PARI
    a(n) = my(p=prod(j=1, n, x+j), m=vecmax(Vec(p))); for (i=0, poldegree(p), if (polcoef(p, i)==m, return(i))); \\ Michel Marcus, Feb 19 2021
    
  • PARI
    first(n) = {res = vector(n); my(r = 1); v = [1]; for(i = 1, n, v = concat(0, v) + concat(v, 0)*i; for(j = r + 1, #v, if(v[j] > v[j - 1], r++ , next ); ); res[i] = r-1 ); res } \\ David A. Corneth, Feb 21 2021
    
  • Python
    from sympy import prod, Poly
    from sympy.abc import x
    def A076620(n):
        y = Poly(prod(x+i for i in range(1,n+1))).all_coeffs()[::-1]
        return y.index(max(y)) # Chai Wah Wu, Mar 07 2021

Formula

Is a(n) - floor(log(n)) bounded?