Difference between revisions of "Legendre's Formula"
Nikoislife (talk | contribs) |
|||
Line 4: | Line 4: | ||
where <math>p</math> is a prime and <math>e_p(n)</math> is the [[exponent]] of <math>p</math> in the [[prime factorization]] of <math>n!</math> and <math>S_p(n)</math> is the [[sum]] of the [[digit]]s of <math>n</math> when written in [[base]] <math>p</math>. | where <math>p</math> is a prime and <math>e_p(n)</math> is the [[exponent]] of <math>p</math> in the [[prime factorization]] of <math>n!</math> and <math>S_p(n)</math> is the [[sum]] of the [[digit]]s of <math>n</math> when written in [[base]] <math>p</math>. | ||
+ | |||
+ | ==Examples== | ||
+ | Find the largest integer <math>k</math> for which <math>2^k</math> divides <math>27!</math> | ||
+ | |||
+ | ===Solution 1=== | ||
+ | Using the first form of Legendre's Formula, substituting <math>n=27</math> and <math>p=2</math> gives | ||
+ | <cmath>\begin{align*}e_2(27!)=&\left\lfloor\frac{27}{2}\right\rfloor+\left\lfloor\frac{27}{2^2}\right\rfloor+\left\lfloor\frac {27}{2^3}\right\rfloor+\left\lfloor\frac{27}{2^4}\right\rfloor\\ | ||
+ | =&13+6+3+1\\ | ||
+ | =&23\end{align*}</cmath> | ||
+ | which means that the largest integer <math>k</math> for which <math>2^k</math> divides <math>27!</math> is <math>\boxed{23}</math>. | ||
+ | |||
+ | ===Solution 2=== | ||
+ | Using the second form of Legendre's Formula, substituting <math>n=27</math> and <math>p=2</math> gives | ||
+ | <cmath>e_2(27!)=\frac{27-S_2(27)}{2-1}=27-S_2(27)</cmath> | ||
+ | The number <math>27</math> when expressed in Base-2 is <math>11011</math>. This gives us <math>S_2(27)=1+1+0+1+1=4</math>. Therefore, | ||
+ | <cmath>e_2(27!)=27-S_2(27)=27-4=23</cmath> | ||
+ | which means that the largest integer <math>k</math> for which <math>2^k</math> divides <math>27!</math> is <math>\boxed{23}</math>. | ||
==Proofs== | ==Proofs== |
Revision as of 20:59, 26 June 2019
Legendre's Formula states that
where is a prime and is the exponent of in the prime factorization of and is the sum of the digits of when written in base .
Contents
Examples
Find the largest integer for which divides
Solution 1
Using the first form of Legendre's Formula, substituting and gives which means that the largest integer for which divides is .
Solution 2
Using the second form of Legendre's Formula, substituting and gives The number when expressed in Base-2 is . This gives us . Therefore, which means that the largest integer for which divides is .
Proofs
Part 1
We use a counting argument.
We could say that is equal to the number of multiples of less than , or . But the multiples of are only counted once, when they should be counted twice. So we need to add on. But this only counts the multiples of twice, when we need to count them thrice. Therefore we must add a on. We continue like this to get . This makes sense, because the terms of this series tend to 0.
Part 2
Let the base representation of be where the are digits in base Then, the base representation of is Note that the infinite sum of these numbers (which is ) is
Problems
Introductory
Olympiad
- Let be numbers of factors of the number (that is, and ). Find the least such that . (Turkey TST 1990)
This article is a stub. Help us out by expanding it.