TExcelTAD
Home › Basic Math & Pre-Algebra › Dividing Fractions

Dividing Fractions

To divide by a fraction, multiply by its reciprocal: flip the second fraction and multiply. This lesson explains what the reciprocal is, why "flip and multiply" works, how to divide with mixed and whole numbers, and how to answer "how many fit?" questions exactly in Python.

The reciprocal

The reciprocal of a fraction swaps its numerator and denominator. A number times its reciprocal is always 1:

Number Reciprocal Check
34\frac{3}{4} 43\frac{4}{3} 34×43=1\frac{3}{4} \times \frac{4}{3} = 1
5 (=51= \frac{5}{1}) 15\frac{1}{5} 5×15=15 \times \frac{1}{5} = 1
18\frac{1}{8} 8 18×8=1\frac{1}{8} \times 8 = 1
2122\frac{1}{2} (=52= \frac{5}{2}) 25\frac{2}{5} 52×25=1\frac{5}{2} \times \frac{2}{5} = 1
0 none nothing times 0 gives 1

Flip and multiply

ab÷cd=ab×dc=a×db×c\frac{a}{b} \div \frac{c}{d} = \frac{a}{b} \times \frac{d}{c} = \frac{a \times d}{b \times c}

Examples:

34÷18=34×81=244=623÷45=23×54=1012=566÷34=61×43=243=8\begin{aligned} \frac{3}{4} \div \frac{1}{8} &= \frac{3}{4} \times \frac{8}{1} = \frac{24}{4} = 6 \\ \frac{2}{3} \div \frac{4}{5} &= \frac{2}{3} \times \frac{5}{4} = \frac{10}{12} = \frac{5}{6} \\ 6 \div \frac{3}{4} &= \frac{6}{1} \times \frac{4}{3} = \frac{24}{3} = 8 \end{aligned}

Why it works

Division asks "how many of these fit into that?". How many eighths fit into three quarters? Three quarters is 68\frac{6}{8}, so the answer is 6. Flip-and-multiply gave the same 6.

Another way: dividing by 18\frac{1}{8} means asking how many eighths there are, and every whole has 8 of them, so dividing by 18\frac{1}{8} is the same as multiplying by 8. In general, dividing by cd\frac{c}{d} undoes multiplying by cd\frac{c}{d}, and multiplying by dc\frac{d}{c} is exactly what undoes it:

(x×cd)×dc=x×(cd×dc)=x×1=x\left(x \times \frac{c}{d}\right) \times \frac{d}{c} = x \times \left(\frac{c}{d} \times \frac{d}{c}\right) = x \times 1 = x

Tip: Dividing by a number less than 1 makes the result bigger (6÷34=86 \div \frac{3}{4} = 8). That surprises people at first, but it makes sense: more small pieces fit.

Mixed numbers and whole numbers

Convert to improper fractions first, then flip the divisor (the second number) only:

313÷114=103÷54=103×45=4015=83=22325÷4=25×14=220=110\begin{aligned} 3\frac{1}{3} \div 1\frac{1}{4} &= \frac{10}{3} \div \frac{5}{4} = \frac{10}{3} \times \frac{4}{5} = \frac{40}{15} = \frac{8}{3} = 2\frac{2}{3} \\ \frac{2}{5} \div 4 &= \frac{2}{5} \times \frac{1}{4} = \frac{2}{20} = \frac{1}{10} \end{aligned}

Only the second number flips. Flipping the first, or both, gives a wrong answer.

In Python

Fraction divides exactly with /. For "how many whole pieces fit, and what is left?" use // and %, which also work on fractions:

python · try it yourself
from fractions import Fraction as F

print(F(3, 4) / F(1, 8))
print(F(2, 3) / F(4, 5))
print(6 / F(3, 4))
print((3 + F(1, 3)) / (1 + F(1, 4)))

# a 5 m roll of ribbon, cut into pieces of 3/4 m
roll, piece = F(5), F(3, 4)
print("pieces:", roll // piece, " left over:", roll % piece, "m")
print("exact ratio:", roll / piece)
6
5/6
8
8/3
pieces: 6  left over: 1/2 m
exact ratio: 20/3

5÷34=203=6235 \div \frac{3}{4} = \frac{20}{3} = 6\frac{2}{3}: six full pieces, and the leftover 12\frac{1}{2} m is 23\frac{2}{3} of a piece.

Complex fractions

A fraction whose top or bottom is itself a fraction is a complex fraction. It is just a division in disguise:

3/59/10=35÷910=35×109=3045=23\frac{3/5}{9/10} = \frac{3}{5} \div \frac{9}{10} = \frac{3}{5} \times \frac{10}{9} = \frac{30}{45} = \frac{2}{3}

Dividing by zero, again

F(1, 2) / 0 raises ZeroDivisionError, because 0 has no reciprocal. Programs that compute ratios such as "average per item" must handle the empty case first:

python · try it yourself
from fractions import Fraction as F

def per_item(total, count):
    if count == 0:
        return None          # no items: there is no average
    return F(total) / count

print(per_item(F(7, 2), 3))
print(per_item(F(7, 2), 0))
7/6
None

In software

  • Rates and speeds. "Distance÷time\text{Distance} \div \text{time}" with fractional times, e.g. 3 km in 14\frac{1}{4} hour is 3÷14=12 km/h3 \div \frac{1}{4} = 12\ \text{km/h}.
  • Frame timing. At 60 fps each frame lasts 160\frac{1}{60} s. A 2122\frac{1}{2}-second animation is 52÷160=150\frac{5}{2} \div \frac{1}{60} = 150 frames.
  • Undoing a scale. If a canvas is drawn at scale 32\frac{3}{2}, mouse coordinates are divided by 32\frac{3}{2} (multiplied by 23\frac{2}{3}) to map clicks back to the original drawing. This is the same "inverse" idea you will meet with matrices.

Exercises

Exercise 1: Flip and multiply

Compute 56÷109\frac{5}{6} \div \frac{10}{9} in lowest terms.

Answer

34\frac{3}{4}

Solution
56÷109=56×9105 and 10 share 5: →16×929 and 6 share 3: →12×32=34\begin{aligned} &\frac{5}{6} \div \frac{10}{9} = \frac{5}{6} \times \frac{9}{10} \\ &\quad \text{5 and 10 share 5: } \to \frac{1}{6} \times \frac{9}{2} \\ &\quad \text{9 and 6 share 3: } \to \frac{1}{2} \times \frac{3}{2} \\ &= \frac{3}{4} \end{aligned}

Exercise 2: How many servings?

You have 4124\frac{1}{2} cups of rice. One serving is 34\frac{3}{4} cup. How many servings is that?

Answer

6 servings

Solution
412÷34=92×43=366=64\frac{1}{2} \div \frac{3}{4} = \frac{9}{2} \times \frac{4}{3} = \frac{36}{6} = 6

Exercise 3: Frames in a clip

A clip lasts 3343\frac{3}{4} seconds. At 24 frames per second each frame lasts 124\frac{1}{24} s. How many frames is the clip? Check with Python.

Answer

90 frames

Solution
334÷124=154×241=3604=903\frac{3}{4} \div \frac{1}{24} = \frac{15}{4} \times \frac{24}{1} = \frac{360}{4} = 90
python · try it yourself
from fractions import Fraction as F
print((3 + F(3, 4)) / F(1, 24))
90

Exercise 4: Shelves and leftovers

A board is 7127\frac{1}{2} feet long. Each shelf needs 1341\frac{3}{4} feet. Write Python that prints how many shelves you can cut and how much board is left over.

Answer

4 shelves, 12\frac{1}{2} foot left over.

Solution

152÷74=152×47=6014=307=427\frac{15}{2} \div \frac{7}{4} = \frac{15}{2} \times \frac{4}{7} = \frac{60}{14} = \frac{30}{7} = 4\frac{2}{7}, so 4 whole shelves. They use 4×74=74 \times \frac{7}{4} = 7 feet, leaving 152−7=12\frac{15}{2} - 7 = \frac{1}{2} foot.

python · try it yourself
from fractions import Fraction as F
board, shelf = 7 + F(1, 2), 1 + F(3, 4)
print("shelves:", board // shelf, " left:", board % shelf, "ft")
shelves: 4  left: 1/2 ft

Test yourself

What is the reciprocal of 2132\frac{1}{3}?

  1. 37\frac{3}{7}
  2. 13\frac{1}{3}
  3. 73\frac{7}{3}
  4. 32\frac{3}{2}

What is 4÷234 \div \frac{2}{3}?

  1. 83\frac{8}{3}
  2. 6
  3. 2232\frac{2}{3}
  4. 16\frac{1}{6}

In ab÷cd\frac{a}{b} \div \frac{c}{d}, which fraction do you flip?

  1. ab\frac{a}{b}
  2. both
  3. cd\frac{c}{d}
  4. neither