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.

A082908 Largest value of gcd(2^n, binomial(n,j)) with j=0..n-1; maximum value of largest power of 2 dividing binomial(n,j) in the n-th row of Pascal's triangle.

Original entry on oeis.org

1, 1, 2, 1, 4, 2, 4, 1, 8, 4, 8, 2, 8, 4, 8, 1, 16, 8, 16, 4, 16, 8, 16, 2, 16, 8, 16, 4, 16, 8, 16, 1, 32, 16, 32, 8, 32, 16, 32, 4, 32, 16, 32, 8, 32, 16, 32, 2, 32, 16, 32, 8, 32, 16, 32, 4, 32, 16, 32, 8, 32, 16, 32, 1, 64, 32, 64, 16, 64, 32, 64, 8, 64, 32, 64, 16, 64, 32, 64, 4, 64, 32
Offset: 0

Views

Author

Labos Elemer, Apr 23 2003

Keywords

Examples

			For n = 10: the 10th row = {1,10,45,120,210,252,210,120,45,10,1}, the largest powers of 2 dividing the entries: {1,2,1,8,2,4,2,8,1,2,1}; maximum 2^k-divisor is a(10) = 8.
		

Crossrefs

Programs

  • Mathematica
    Table[Max[Table[GCD[2^n, Binomial[n, j]], {j, 0, n}]], {n, 0, 128}]
    a[n_] := 2^Floor[Log2[(n+1) / 2^IntegerExponent[n+1, 2]]]; Array[a, 82, 0] (* Amiram Eldar, Mar 15 2025 *)
  • PARI
    a(n)=n--; 2^(log(n>>valuation(n, 2)+.5)\log(2)) \\ Charles R Greathouse IV, May 06 2013

Formula

a(n) = Max_{gcd(2^n, binomial(n, j)), j=0..n}.
a(n-1) = 2^floor(log_2(A000265(n))). - Brad Clardy, May 06 2013