please help me in doing my project in one of my subject in college. it is all about getting the GCD of fractions... can anyone tell me the logic or the formula for getting it? tnxx in advance
please help me in doing my project in one of my subject in college. it is all about getting the GCD of fractions... can anyone tell me the logic or the formula for getting it? tnxx in advance
This wiki article tells you how to derive the gcd. Pay close attention to the section about the Euclidean algorithm.
i see but i can't understand it much ... can anyone help me how to use euclidean algo.? how can i use it to get the gcd of fractions??
Excerpt from wiki:
In mathematics, the greatest common divisor (gcd), also known as the greatest common denominator, greatest common factor (gcf), or highest common factor (hcf), of two or more non-zero integers.
Some recursive algo I remember off the top:
procedure gcd(a,b)
.if b = 0 then return a
.else gcd(a, b mod a)
the modulo is operated *mainly* upon integers(see: fmod).