Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

If I know the GCD of 20 numbers, and know the 20 numbers, is there a formula such that I input the 20 numbers and input their GCD, and it outputs their LCM? I know that $$\frac{\left| a\cdot b\right|}{\gcd(a,b)} = \text{lcm}(a,b).$$ So is it$$\frac{\left| a\cdot b\cdot c\cdot d\cdot e\cdot f\right|}{\gcd(a,b,c,d,e,f)}?$$If not, what is it?

share|improve this question

4 Answers 4

up vote 6 down vote accepted

There can be no formula that computes $\text{lcm}(a,b,c)$ using only the values of $abc$ and $\gcd(a,b,c)$ as input: that's because $(a,b,c) = (1,2,2)$ and $(a,b,c) = (1,1,4)$ both have $abc=4$, $\gcd(a,b,c)=1$, but they don't have the same lcm.

However, there is a straightforward generalization of the $2$-variable formula. For instance, $$\text{lcm}(a,b,c,d) = \frac{abcd}{\gcd(abc,abd,acd,bcd)}.$$

The correct gcd to take is not of the individual terms $a,b,c,d$ but the products of all the complementary terms (which looks the same in the two-variable case).

share|improve this answer
    
See my answer for a simple proof. –  Math Gems Mar 3 '13 at 18:56

As mentioned, it does not generalize like that. But there do exist generalizations. For example, using the standard gcd notation $\rm\ (x,y,\ldots)\, :=\, gcd(x,y,\ldots),\:$ we have

Theorem $\rm\,\ lcm(a,b,c)\, =\, \dfrac{abc}{(bc,ca,ab)}$

$\begin{eqnarray}{\bf Proof}\qquad\qquad\rm\ a,b,c&\mid&\rm\ n\\ \iff\quad\rm abc&\mid&\rm\,\ nbc,nca,nab\\ \iff\quad\rm abc&\mid&\rm (nbc,nca,nab)\, =\, n(bc,ca,ab)\\ \iff\rm\ \ \dfrac{abc}{(bc,ca,ab)}\ \Bigg|\!\!\!\!\!&&\rm\ n\end{eqnarray}$

Hence the claimed equality follows by the (universal) definition of lcm. $\ \ $ QED

Remark $\ $ Notice the penultimate equivalence in the proof uses said (universal) definition of gcd, followed by the gcd distributive law. An analogous proof works for any number of arguments.

share|improve this answer
    
This was fine as posted: $(a,b,c)$ is a standard notation for the greatest common divisor of $a,b$, and $c$. –  Brian M. Scott Mar 3 '13 at 19:03

It certainly doesn't work like that. Consider that $\gcd(1, 2, 2) = 1$, $\text{lcm}(1, 2, 2) = 2$ and $1 \times 2 \times 2 = 4$.

A good way to think of this is to consider a natural number $n$ as a vector which has $x$ for $i$th component if $x$ is the largest power of $i$th prime, dividing $n$. For example, $50 = 2\times 5^2$ would be $(1, 0, 2, 0, 0 \dots)$. Then $\gcd$ is a componentwise $\min$, $\text{lcm}$ is a componentwise $\max$ and $\times$ is a componentwise $+$. It just so happens that for two numbers, $\min(a, b) + \max(a, b) = a+b$. Same is not true for three or more numbers.

Using the same interpretation, you can construct many other similar formulas though. For example, $\text{lcm}(a, b, c, \dots) = \text{lcm}(a, \text{lcm}(b, \text{lcm}(c, \dots)))$.

share|improve this answer

If you are asking whether the identity $\dfrac{|a_1a_2\cdots a_n|}{\gcd(a_1,a_2,\ldots,a_n)}=\text{lcm}(a_1,a_2,\ldots,a_n)$ is true for $n>2$ then the answer is no.
Take for example $n=3, a_1=2, a_2=4,a_3=3$.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.