login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A090621
Exponent of highest power of 16 dividing n!.
2
0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19
OFFSET
0,11
FORMULA
a(n) = A090622(n, 16) = floor(A011371(n)/4) = floor(A090616(n)/2) = floor((floor(n/2) + floor(n/4) + floor(n/8) + floor(n/16) + ...)/4). Almost n/4.
EXAMPLE
a(10)=2 since 10! = 3628800 = 16^2 * 14175.
PROG
(Python 3.10+)
def A090621(n): return (n-n.bit_count())>>2 # Chai Wah Wu, Jul 09 2022
(PARI) a(n) = valuation(n!, 16); \\ Michel Marcus, Jul 10 2022
KEYWORD
nonn
AUTHOR
Henry Bottomley, Dec 06 2003
STATUS
approved