One of the distinctive properties of the set of integers,
is that if you divide a positive number into any integer, you will get a unique quotient and remainder. More precisely, if you divide b (
) into a, there will be integers q and r such that
and
. We will take this as given, but it can be proven by mathematical induction.
If
, i. e.,
, then all of the following say the same thing
b divides a
a is a multiple of b
b is a factor of a
b is a divisor of a
is the largest positive integer that is a divisor of both a and b.
In Mathematica you can get the gcd of two numbers using the function GCD:
![[Graphics:../Images/gcd_gr_8.gif]](../Images/gcd_gr_8.gif)
![[Graphics:../Images/gcd_gr_10.gif]](../Images/gcd_gr_10.gif)
More information can be obtained with ExtendedGCD
![[Graphics:../Images/gcd_gr_12.gif]](../Images/gcd_gr_12.gif)
![[Graphics:../Images/gcd_gr_14.gif]](../Images/gcd_gr_14.gif)
We'll see what the second item in this output represents below.