Sub topic 9
Clearing fractions and decimals
This chapter assumes you can solve two-step equations and equations with variables on both sides. You should also know how to distribute and combine like terms, and how to add, subtract, multiply, and compare fractions and decimals. Here you learn to turn an equation with fractions or decimals into an equivalent equation with integer coefficients, then solve it with the methods you already know.
Why clear fractions at all
You can solve an equation such as x/2 + 1/3 = 3/4 by working directly with fractions. That works, but every step needs common denominators, and one slip is easy to make. Integer arithmetic is more reliable.
The balance principle gives a way out. Multiplying both sides of an equation by the same nonzero number produces an equivalent equation, which has exactly the same solution. If you choose that number so every denominator divides into it, all the fractions disappear. This is called clearing the fractions.
The method
- Find the least common denominator (LCD) of every fraction in the equation. The LCD is the smallest positive integer that each denominator divides evenly.
- Multiply both sides by the LCD. Multiply every term, including terms that have no fraction.
- Simplify. Each fraction term collapses because its denominator cancels against the LCD.
- Solve the resulting integer equation with the usual steps.
- Check the answer in the original equation, not the cleared one.
Worked example: one fraction per term
Solve x/2 + 1/3 = 3/4.
The denominators are 2, 3, and 4, so the LCD is 12. Multiply every term by 12:
- 12 · (x/2) = 6x
- 12 · (1/3) = 4
- 12 · (3/4) = 9
The equation becomes 6x + 4 = 9. Subtract 4 to get 6x = 5, then divide by 6 to get x = 5/6.
Check in the original: 5/12 + 1/3 = 5/12 + 4/12 = 9/12 = 3/4. The left side matches the right.
Multiply every term
The most common error is multiplying only the fraction terms. Take x/2 + 3 = 7. The LCD is 2, and the correct result is x + 6 = 14, so x = 8. If you forget to multiply the 3 and the 7, you get x + 3 = 7 and a wrong answer of x = 4. Check: 4/2 + 3 = 5, not 7.
Fraction bars act as grouping symbols
When the numerator has more than one term, the fraction bar groups it. Clearing the denominator leaves a parenthesized expression, and you must distribute carefully, especially across a subtraction.
Solve (x + 1)/2 − (x − 1)/3 = 1.
The LCD is 6.
6 · (x + 1)/2 − 6 · (x − 1)/3 = 6 · 1
3(x + 1) − 2(x − 1) = 6
3x + 3 − 2x + 2 = 6 distribute; the minus sign flips both terms in (x - 1)
x + 5 = 6 combine like terms
x = 1 subtract 5
Check: (1 + 1)/2 − (1 − 1)/3 = 1 − 0 = 1The usual mistake is writing 3(x + 1) − 2x − 1. That changes the sign on only one term and gives the wrong equation.
Fractions on both sides
The method does not change when variables appear on both sides. Solve (2x − 1)/3 = (x + 4)/2.
The LCD is 6, so multiply both sides by 6:
6 · (2x - 1)/3 = 6 · (x + 4)/2
2(2x - 1) = 3(x + 4)
4x - 2 = 3x + 12
x = 14
Check: (2·14 - 1)/3 = 27/3 = 9 and (14 + 4)/2 = 18/2 = 9When each side is a single fraction, as here, multiplying by the LCD gives the same equation as cross-multiplication: a/b = c/d becomes ad = bc. Cross-multiplication is a shortcut for this special case. It does not apply when a side has several terms, such as x/2 + 1/3, so the LCD method is the one to remember.
Clearing decimals
A decimal is a fraction whose denominator is a power of ten. Two approaches work.
- Scale by a power of ten. Multiply by 10, 100, or 1000, matching the largest number of decimal places in the equation.
- Convert to fractions. Rewrite each decimal as a fraction, then use the LCD. This sometimes gives a smaller multiplier.
| Decimal places (most in any term) | Multiply both sides by |
|---|---|
| 1 | 10 |
| 2 | 100 |
| 3 | 1000 |
Solve 0.2x + 1.5 = 0.05x + 3. The most decimal places is 2 (in 0.05), so multiply every term by 100:
20x + 150 = 5x + 300
15x = 150 subtract 5x and 150
x = 10
Check: 0.2(10) + 1.5 = 3.5 and 0.05(10) + 3 = 3.5Fractions and decimals can appear in the same equation. Solve x/4 + 0.5 = 2. Since 0.5 = 1/2, the denominators are 4 and 2, and the LCD is 4. Multiplying by 4 gives x + 2 = 8, so x = 6. Check: 6/4 + 0.5 = 1.5 + 0.5 = 2.
Why the multiplier does not need to be the smallest
Any common multiple of the denominators clears the fractions. For x/2 + 1/3 = 3/4, multiplying by 24 gives 12x + 8 = 18, which has the same solution x = 5/6. The LCD only keeps the numbers small. If you cannot find the LCD, multiply the denominators together, and reduce at the end.
The multiplier must be a nonzero constant. Multiplying by zero would turn every equation into 0 = 0 and lose the solution. Multiplying by an expression that contains x is a different technique that can introduce false solutions, and it is not used in linear equations.
Equations that clear to no solution or infinitely many
Clearing denominators does not change the solution type. Consider x/2 + 1 = (x + 3)/2. Multiplying by 2 gives x + 2 = x + 3, which simplifies to 2 = 3. That is false, so there is no solution. Now consider x/2 + 1 = (x + 2)/2. Multiplying by 2 gives x + 2 = x + 2, which is true for every x, so there are infinitely many solutions.
Automating the method
The function below applies the same steps to an equation in the form ax + b = c. It converts decimal strings to exact fractions, finds the LCD of the denominators, scales all three numbers, and solves. It needs Python 3.9 or later for math.lcm.
from fractions import Fraction
from math import lcm
def clear_and_solve(a, b, c):
"""Clear denominators in a*x + b = c, then solve exactly.
Returns the integer coefficients (A, B, C) of the cleared
equation A*x + B = C and the solution (or a description).
"""
a, b, c = Fraction(a), Fraction(b), Fraction(c)
m = lcm(a.denominator, b.denominator, c.denominator)
A, B, C = a * m, b * m, c * m # all integers now
cleared = (int(A), int(B), int(C))
if A == 0:
return cleared, ("infinitely many solutions" if B == C else "no solution")
return cleared, (C - B) / A
print(clear_and_solve("1/2", "1/3", "3/4")) # ((6, 4, 9), Fraction(5, 6))
print(clear_and_solve("0.25", "1.5", "0.75")) # ((1, 6, 3), Fraction(-3, 1))The second call shows the LCD at work. The decimals 0.25, 1.5, and 0.75 are 1/4, 3/2, and 3/4, so the multiplier is 4 rather than 100. The cleared equation is x + 6 = 3, and x = −3. Check: 0.25(−3) + 1.5 = −0.75 + 1.5 = 0.75.
Using Fraction with strings avoids floating-point error. The float 0.1 is not stored exactly, so comparing computed results with == can fail in ways that exact fractions cannot.
Common errors
- Multiplying only the fraction terms and leaving other terms unchanged.
- Multiplying one side by the LCD and forgetting the other side.
- Dropping parentheses around a multi-term numerator, which breaks distribution and sign handling.
- Misplacing the decimal point when scaling, for example turning 0.05x into 50x instead of 5x when multiplying by 100.
- Checking the answer in the cleared equation. A mistake made while clearing would pass that check unnoticed, so always substitute into the original.
Exercise
Solve (x − 2)/4 + x/6 = 3. Give the LCD you use, the cleared equation, the solution, and a check.
Show answer
The LCD of 4 and 6 is 12. Multiplying every term by 12 gives 3(x − 2) + 2x = 36, so 3x − 6 + 2x = 36, then 5x = 42, and x = 42/5 = 8.4. Check: (8.4 − 2)/4 = 6.4/4 = 1.6 and 8.4/6 = 1.4, and 1.6 + 1.4 = 3.
Exercise
Solve 0.3x − 0.45 = 0.15x + 1.2 by clearing decimals. Which multiplier do you use, and what is x?
Show answer
The most decimal places is 2, so multiply every term by 100: 30x − 45 = 15x + 120. Subtract 15x and add 45 to get 15x = 165, so x = 11. Check: 0.3(11) − 0.45 = 2.85 and 0.15(11) + 1.2 = 2.85.
Exercise
Without solving fully, decide whether x/3 + 2 = (x + 6)/3 has one solution, no solution, or infinitely many. Show the cleared equation.
Show answer
Multiply by 3: x + 6 = x + 6. This is true for every x, so there are infinitely many solutions.