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.

A324465 Exponent of highest power of 2 that divides A324152(n).

Original entry on oeis.org

0, 0, 1, 3, 2, 2, 3, 5, 2, 3, 4, 6, 5, 4, 5, 7, 2, 3, 4, 6, 5, 5, 6, 8, 5, 6, 7, 9, 8, 6, 7, 9, 2, 3, 4, 6, 5, 5, 6, 8, 5, 6, 7, 9, 8, 7, 8, 10, 5, 6, 7, 9, 8, 8, 9, 11, 8, 9, 10, 12, 11, 8, 9, 11, 2, 3, 4, 6, 5, 5, 6, 8, 5, 6, 7, 9, 8, 7, 8, 10, 5, 6, 7, 9
Offset: 0

Views

Author

N. J. A. Sloane, Mar 01 2019

Keywords

Comments

First occurrence of k=0,1,2,...: 0, 2, 4, 3, 10, 7, 11, 15, 23, 27, 47, 55, 59, 111, 119, 123, 239, 247, 251, 495, 503, 507, 1007, 1015, 1019, 2031, 2039, 2043, 4079, 4087, 4091, 8175, 8183, 8187, 16367, 16375, 16379, 32751, 32759, 32763, 65519, 65527, 65531, 131055, 131063, 131067, ..., . Robert G. Wilson v, Mar 01 2019

Crossrefs

Cf. A000120 (binary weight), A007814, A324152, A324467.

Programs

  • Mathematica
    f[n_] := IntegerExponent[(3/((n + 1)(n + 2)(n + 3)))*Multinomial[n, n, n, n], 2]; f[0] = 0; Array[f, 84, 0] (* Robert G. Wilson v, Mar 01 2019 *)
  • PARI
    a(n) = 3*hammingweight(n) - valuation((n+1)*(n+2)*(n+3), 2); \\ Michel Marcus, Jul 10 2022

Formula

a(n) = 3*wt(n) - (2-adic valuation of (n+1)*(n+2)*(n+3))
= 3*A000120(n) - (A007814(n+1)+A007814(n+2)+A007814(n+3)).
E.g. if n = 14 = 1110_2, with weight 3, we get a(14) = 3*3 - 2-adic valuation of 15*16*17 = 9 - 4 = 5.