If $\gcd(n^2,m^2)=1$, find $\gcd(n,m)$ where $n$ and $m$ are both integers and $n,m \geq 0$. I think $\gcd(n,m)=1$, is that right?
Asked
Active
Viewed 102 times
1
-
1Yes, this is basically Euclid's Lemma. Because as $n^2$ and $m^2$ have no common divisor, so do $n$ and $m$. Can you proof this? – Cornman Aug 16 '22 at 13:00
-
What happens if $n, m$ have a common divisor $> 1$? – Paul Frost Aug 16 '22 at 13:09
-
I do not know how to prove it @Cornman – Xun Aug 16 '22 at 13:31
-
Try a contradiction. Suppose there is a $p\neq 1$ which divides $n$ and $m$. What do you then know about the divisibility of $p$ with $n^2$ and $m^2$? How do you arrive to a contradiction then? – Cornman Aug 16 '22 at 13:43
-
You can do $1\leq \gcd(m,n)\leq \gcd(m^2,n)\leq \gcd(m^2,n^2)=1$, where the inequalities are coming from the definition of $\gcd$ as being largest common divisor, and $d|a\implies d|a^2$. The latter gives that the collection of common divisors of say $m^2$ and $n$ can only be larger than the collection of common divisors of $m$ and $n$. – plop Aug 16 '22 at 14:07
-
From the definition: Every divisor of n divides n^2. Every divisor of m divides m^2. Every common divisor of n and m divides n^2 and m^2. The only common divisor of n^2 and m^2 is 1, so the only common divisor of n and m is a divisor of 1, and that is again 1. Being the only common divisor, it is the greatest common divisor. – gnasher729 Aug 16 '22 at 15:13
2 Answers
5
This is an immediate consequence of Bezout's theorem:
$\mathrm{gcd}(a,b) = 1$ if and only if there exist integers $x,y$ satisfying $ax + by = 1$.

Umberto P.
- 52,165
-
Please strive not to post more (dupe) answers to dupes of FAQs, cf. recent site policy announcement here. – Bill Dubuque Aug 25 '22 at 19:50
2
Hint
Call $\gcd(m,n)=d$. It means that $$m=d\cdot m_1\quad and \quad n=d\cdot n_1,$$ where $\gcd(m_1,n_1)=1$.
From it, we get
$$m^2=d^2\cdot m_1^2\quad and \quad n^2=d^2\cdot n_1^2.$$
Can you finish?

Arnaldo
- 21,342
-
Please strive not to post more (dupe) answers to dupes of FAQs, cf. recent site policy announcement here. – Bill Dubuque Aug 25 '22 at 19:50