Miller's Marvelous Math (Mn-Logo.gif)

Home Page
Personal Information
School Information
Reference Materials
Information for Students
Problem of the Week
Chaparral & New Mexico
Math Tutorial
Marvelous Math Links
Odds & Ends
Games and Gadgets
Fraction Calculator
Weekly Skills Quiz
Famous Mathematicians
Student of the Month
Finding the GCD using Euclid's Algorithm

The largest number which divides two numbers n and m is called the greatest common divisor of n and m, and denoted gcd(n, m).

Using Euclid's Algorithm is easy, just follow the steps shown below.

  1. Write down both n and m
  2. Write the larger as a number + something times the smaller
  3. Repeat step 2 until the result is zero
  4. The number in the row with the final 0 is the GCD of n and m

An example of using the algorithm to find the GCD of 340 and 245 is shown below:
	  340                 245
	  340-245=95          245
	   95                 245
	   95                 245=55+2*95
	   95                  55
	   95=40+1*55          55
	   40                  55
	   40                  55=15+1*40
	   40                  15
	   40=10+2*15          15
	   10                  15
	   10                  15=5+1*10
	   10                   5
	   10=0+2*5             5
	    0                   5
Which shows the GCD of 340 and 245 is 5.

Use the Euclidian Calculator below to find the GCD of two numbers.
1st Number    2nd Number      GCD
, =
Hosted by www.Geocities.ws

1