
Number Theory Number Theory Math Forum 
 LinkBack  Thread Tools  Display Modes 
August 16th, 2018, 05:14 AM  #1 
Newbie Joined: Aug 2018 From: TÃ¼rkiye Posts: 1 Thanks: 0  The number of a number in the prime factorization of a factorial
How do we find, for example, how many '5's there are in the prime factorization of n! ? I've read that it's floor(n/5), but why is that? Thanks a lot. Last edited by skipjack; August 16th, 2018 at 02:26 PM. 
August 16th, 2018, 06:12 AM  #2 
Member Joined: Aug 2015 From: Montenegro (Podgorica) Posts: 37 Thanks: 3 
Because 5 must appear at least once in every fifth number from 1 to n. Sent from my HUAWEI SCLL04 using Tapatalk 
August 16th, 2018, 08:49 AM  #3 
Global Moderator Joined: Dec 2006 Posts: 20,107 Thanks: 1907 
So it would be at least floor(n/5), not necessarily exactly floor(n/5).

August 16th, 2018, 01:14 PM  #4 
Global Moderator Joined: May 2007 Posts: 6,665 Thanks: 651 
The answer is $\sum_{k=1}^{\infty}\lfloor \frac{n}{5^k}\rfloor$. Note that the sum is finite since terms where $5^k \gt n$ are all 0.


Tags 
factorial, factorization, number, prime 
Thread Tools  
Display Modes  

Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
The relationships between Prime number and Fibonacci number (Part 2)  thinhnghiem  Math  0  May 15th, 2018 09:07 AM 
The relationships between Prime number and Fibonacci number  thinhnghiem  Number Theory  15  December 18th, 2016 02:31 PM 
Sum based on number of primes in a factorial  oasawant  Number Theory  6  October 25th, 2012 07:25 AM 
Prime factorization and Stirling number  zoizaite  Algebra  1  January 13th, 2012 06:49 AM 
Computing Factorial of a Number  prashantakerkar  Algebra  9  November 15th, 2011 11:55 PM 