Skip to the calculator
Rule Calculator

Fraction Calculator

With first: whole number 0, first: numerator 3, first: denominator 8, second: whole number 0 and 2 more fields, fraction comes to 5/8 — result. It is reached in 9 steps, the last of which is 20 / 32, and each one is printed on the page with its numbers filled in. The formula is the one published by Euclid, Elements VII.2, not an approximation fitted to it.

Add, subtract, multiply or divide fractions and mixed numbers, with an exact reduced answer and every step shown.

Formula and sources checked · How we check

First: numerator 3, First: denominator 8, Operation Add +, Second: numerator 1

5/8

Result for the example below. Editing a field recomputes the calculator below; this figure holds the answer the page was loaded with.

It is written into the HTML rather than drawn by a script, so a search engine reading this page without running JavaScript still finds an answer.

Result
5/8
First as an improper fraction
sign(0 + (1)) * (abs(0) * 8 + 3)3 over a_den
Second as an improper fraction
sign(0 + (1)) * (abs(0) * 4 + 1)1 over b_den
Numerator before reducing
1 * (3 * 4 + 1 * 8) + 0 * (3 * 4 - 1 * 8) + 0 * (3 * 1) + 0 * (3 * 4)20
Denominator before reducing
(1 + 0) * (8 * 4) + 0 * (8 * 4) + 0 * (8 * 1 + (0))32
Greatest common divisor
max(1, gcd(abs(20), abs(32)))4
Reduced numerator
20 / 45
Reduced denominator
abs(32 / 4)8
As a decimal
20 / 320.625
If these are inches, in millimeters
20 / 32 * 25.415.875 mm

Ask about this in the chat

Worked example

Three eighths plus a quarter is five eighths. Over the common denominator of 8 that is 3/8 + 2/8; the raw result 20/32 reduces by a greatest common divisor of 4. As a decimal it is 0.625, and as a measurement 15.875 mm exactly.

How to work it out yourself

  1. 1.Enter each fraction as a whole number, a numerator and a denominator. A plain fraction leaves the whole number at zero.
  2. 2.For a negative mixed number, put the minus on the whole number. −1 3/4 means −(1 + 3/4), so the whole quantity is negative rather than just the integer part.
  3. 3.Pick the operation. Dividing flips the second fraction and multiplies, which the derivation shows as the swapped numerator and denominator.
  4. 4.Read the reduced answer. The greatest common divisor that reduced it is its own line, so you can check the reduction rather than trust it.

The formula

  1. First as an improper fractionsign(0 + (1)) * (abs(0) * 8 + 3)
  2. Second as an improper fractionsign(0 + (1)) * (abs(0) * 4 + 1)
  3. Numerator before reducing1 * (3 * 4 + 1 * 8) + 0 * (3 * 4 - 1 * 8) + 0 * (3 * 1) + 0 * (3 * 4)
  4. Denominator before reducing(1 + 0) * (8 * 4) + 0 * (8 * 4) + 0 * (8 * 1 + (0))
  5. Greatest common divisormax(1, gcd(abs(20), abs(32)))
  6. Reduced numerator20 / 4
  7. Reduced denominatorabs(32 / 4)
  8. As a decimal20 / 32
  9. If these are inches, in millimeters20 / 32 * 25.4

Source: Euclid, Elements VII.2 — the algorithm for the greatest common divisor, NIST Special Publication 811, App. B.6 — the inch is exactly 25.4 mm

Questions people actually ask

What does −1 3/4 mean?
Minus one and three quarters, which is −1.75. The sign applies to the whole quantity, not only to the integer part, so it is −(1 + 3/4) and never −1 + 3/4 = −0.25. Calculators that do not state which convention they use are the main reason answers to this question disagree, so this one puts the improper fraction on screen before doing any arithmetic.
How do I add fractions with different denominators?
Put both over a common denominator, add the numerators, then reduce. Multiplying the denominators together always gives a common one — 8 × 4 = 32 here — and reducing afterwards cleans it up. Using the lowest common denominator first is less arithmetic but the same answer; both are shown in the derivation.
Why divide by the greatest common divisor?
Because it is what reduces a fraction to lowest terms in one step. 20/32 shares a factor of 4, so it becomes 5/8. Dividing by any smaller common factor leaves the fraction reducible; the greatest one finishes the job, which is what Euclid's algorithm computes.
Why is there a millimeter line?
Because most fractions typed into a calculator are inches off a tape measure. The inch is exactly 25.4 mm by international agreement, so the conversion is exact rather than rounded, and it saves a second lookup when a drawing is metric and the tape is not.

Related

Put this calculator on your site

Free, no attribution required beyond the link.

<iframe src="https://rulecalculators.com/embed/fraction-calculator" width="100%" height="420" style="border:1px solid #e7e4de;border-radius:12px" title="Fraction Calculator"></iframe>
Did this answer your question?