What is lcm($2^n,3^m$)?

87 Views Asked by At

Given $n,m\in\mathbb{N}$, what can be said about $\text{lcm}(2^n,3^m)$?

In general, for $a,b\in\mathbb{N}$, is there a closed formula of $\text{lcm}(a^n,b^m)$?

2

There are 2 best solutions below

2
On BEST ANSWER

The key to both questions is the formula $$ab=\operatorname{lcm} (a,b)\gcd(a,b)$$

Since $2$ and $3$ are coprime, so are any of their powers, and therefore $$\operatorname{lcm}(2^n,3^m)=2^n3^m.$$

In general, $$\operatorname{lcm}(a^n,b^m)=\frac{a^nb^m}{\gcd(a^n,b^m)}.$$


Although it feels natural, the equation $$\gcd(a^n,b^m)=\gcd(a,b)^{\min(m,n)}$$ is wrong in general (nice catch, @S.Dolan). The reason it fails is as follows:

Assume for simplicity that $\min(m,n)=m$. Assume that a prime number $p$ divides $\frac{a^n}{\gcd(a,b)^m}$ and $\frac{b^m}{\gcd(a,b)^m}$. You would like to find a contradiction. Yet all you can say is that,

  • First, $p|\frac{b}{\gcd(a,b)}$ (by Euclid's lemma), which implies that $p$ is coprime with $\frac{a}{\gcd(a,b)}$ (as $\frac{a}{\gcd(a,b)}$ and $\frac{b}{\gcd(a,b)}$ are coprime), and

  • Second, since $ p|\frac{a^n}{\gcd(a,b)^m}$ and $p$ is coprime with $\frac{a}{\gcd(a,b)}$ it follows that $p|a^{n-m}$ (again, Euclid's lemma).

This being said, this shows that the formula would hold (we would get a contradiction) in the following cases:

Case 1: $n=m$. In this case, $p|a^{n-m}=1$ clearly is a contradiction.

Case 2: $a$ and $\frac{b}{\gcd(a,b)}$ are coprime. Indeed, we know that $p$ divides both of them, so this would give a contradiction. In general all we know is that $\frac{a}{\gcd(a,b)}$ and $\frac{b}{\gcd(a,b)}$ are coprime.

5
On

$$\operatorname{lcm}(a^n,b^m)=\frac{a^nb^m}{\gcd(a^n,b^m)}$$ Note that $\gcd(a^n,b^m)$ is not always equal to $\gcd(a,b)^{\min(m,n)}$.

Perhaps the neatest form for calculating the solution is:-

Assume $n\ge m$ and $c=\gcd (a,b)$, then $$\operatorname{lcm}(a^n,b^m)=\frac{a^nb^m}{\gcd(c^n,b^m)}.$$