Sub topic 12
HCF and LCM of Fractions
Prerequisites and working definitions
Assume you can reduce fractions, use prime factorization, and compute the HCF and LCM of whole numbers.
For positive fractions, the HCF is the greatest fraction that divides each given fraction exactly. The LCM is the least positive fraction that each given fraction divides exactly. “Divides” means that the quotient is a whole number.
First write every fraction in lowest terms. If the fractions are
\[ \frac{a1}{b1},\frac{a2}{b2},\ldots \]
then:
| Quantity | Formula |
|---|---|
| HCF of fractions | HCF of numerators / LCM of denominators |
| LCM of fractions | LCM of numerators / HCF of denominators |
The formulas work when all fractions are positive and reduced.
Why the formulas work
A common factor of the fractions must have a numerator that divides every numerator. Therefore, its numerator cannot exceed the HCF of the numerators.
Its denominator must be large enough to divide each fraction exactly. The smallest denominator that accommodates all denominators is their LCM. Hence:
\[ \operatorname{HCF}\left(\frac{a}{b},\frac{c}{d}\right) = \frac{\operatorname{HCF}(a,c)}{\operatorname{LCM}(b,d)} \]
For the LCM, the numerator must contain every required numerator factor, so we use the LCM of the numerators. The denominator should be as small as possible while fitting both fractions, so we use the HCF of the denominators:
\[ \operatorname{LCM}\left(\frac{a}{b},\frac{c}{d}\right) = \frac{\operatorname{LCM}(a,c)}{\operatorname{HCF}(b,d)} \]
Worked example
Find the HCF and LCM of \(6/35\) and \(9/14\).
The fractions are already reduced.
\[ \operatorname{HCF}(6,9)=3,\qquad \operatorname{LCM}(35,14)=70 \]
Therefore:
\[ \operatorname{HCF}\left(\frac{6}{35},\frac{9}{14}\right)=\frac{3}{70} \]
Also,
\[ \operatorname{LCM}(6,9)=18,\qquad \operatorname{HCF}(35,14)=7 \]
So:
\[ \operatorname{LCM}\left(\frac{6}{35},\frac{9}{14}\right)=\frac{18}{7} \]
Check the result:
\[ \frac{6}{35}\div\frac{3}{70}=4,\qquad \frac{9}{14}\div\frac{3}{70}=15 \]
Both quotients are whole numbers. Similarly, \(18/7\) is divisible by both original fractions.
CAT decision rule
Use fractional HCF when a question asks for the largest equal fractional unit that measures each quantity. Use fractional LCM when it asks for the smallest fractional quantity that contains each given fraction an integer number of times. Convert mixed numbers to improper fractions before starting.
from fractions import Fraction
from math import gcd, lcm
def hcf_fractions(*values):
return Fraction(
gcd(*(value.numerator for value in values)),
lcm(*(value.denominator for value in values)),
)
def lcm_fractions(*values):
return Fraction(
lcm(*(value.numerator for value in values)),
gcd(*(value.denominator for value in values)),
)
x = Fraction(6, 35)
y = Fraction(9, 14)
print(hcf_fractions(x, y)) # 3/70
print(lcm_fractions(x, y)) # 18/7Exercise
Find the HCF and LCM of 4/15 and 14/25.
Show answer
HCF = HCF(4, 14) / LCM(15, 25) = 2/75. LCM = LCM(4, 14) / HCF(15, 25) = 28/5.