0

I couldn't find an answer on the internet but my script fails solving this. I have to know this because this is required to prove something else (it has to do with random numbers and their period).

I cannot say if they are coprime because I don't know if they are coprime because of the fact that division by $0$ doesn't work.

On the other hand I say they are not coprime because we don't get to $\text{gcd}(0,13)=1$.

But this is very confusing for me, please help!

berndgr
  • 455
  • Thanks! From this I deduce that $\text{gcd}(0,13)=13$ and because it doesn't equal $1$, they are not coprime. Is that correct or not? – berndgr Nov 24 '16 at 22:49
  • 1
    $0$ and $13$ do indeed have $13$ as a common divisor. – Arthur Nov 24 '16 at 22:57

1 Answers1

2

$gcd(a, b) = d \iff g |a \wedge g |b \Rightarrow g |d$

Notice that $x |0$ for any $x $ therefore

$gcd(a, 0) = a $ because $a |0 \wedge a |a $ and there cannot be a bigger integer that divides $a $. If $a \neq 1$, then 0 and $a $ are not coprime.

RGS
  • 9,883
  • It might be worth noting that usually gcd$(a,b)$ is not defined when $a=0$ or $b=0$. –  Nov 24 '16 at 23:05
  • @mathbeing even so, it would not make sense to define gcd(0,a) as 0 or 1. – RGS Nov 24 '16 at 23:08
  • 1
    It wouldn't definitely!! Actually I think that gcd$(a,0)=a$ is a good convention (maybe I would express it as gcd$(a,0)=$gcd$(a)=a$ instead but OK) for it is consistent. I just wanted to point out that one could argue as in my above comment. –  Nov 24 '16 at 23:18