PureTools

Fraction Calculator: Add, Subtract, Multiply, and Divide Fractions

PureTools Team· 6 min read
Fraction Calculator: Add, Subtract, Multiply, and Divide Fractions

Fraction Arithmetic Made Easy

Fractions are one of the most challenging concepts in basic math, yet they appear everywhere: cooking recipes (3/4 cup), construction (5/8 inch), music (3/4 time), and programming (floating-point precision issues).

The Four Operations

Addition and Subtraction

To add or subtract fractions, you need a common denominator:

// Adding fractions
1/3 + 1/4
= 4/12 + 3/12    (LCD = 12)
= 7/12

// Subtracting fractions
3/4 - 1/6
= 9/12 - 2/12    (LCD = 12)
= 7/12

Multiplication

Multiply straight across - numerator times numerator, denominator times denominator:

// Multiplying fractions
2/3 * 4/5
= (2*4) / (3*5)
= 8/15

Division

Flip the second fraction and multiply (multiply by the reciprocal):

// Dividing fractions
2/3 / 4/5
= 2/3 * 5/4
= 10/12
= 5/6   (simplified)

Simplifying Fractions

To simplify, find the Greatest Common Divisor (GCD) and divide both numerator and denominator:

function simplify(num, den) {
  const gcd = (a, b) => b === 0 ? a : gcd(b, a % b);
  const d = gcd(Math.abs(num), Math.abs(den));
  return [num / d, den / d];
}

simplify(8, 12);  // [2, 3]  (8/12 = 2/3)
simplify(15, 25); // [3, 5]  (15/25 = 3/5)

Mixed Numbers

A mixed number like 2 1/3 can be converted to an improper fraction:

// 2 1/3 = (2*3 + 1) / 3 = 7/3
// 3 2/5 = (3*5 + 2) / 5 = 17/5

Common Mistakes

  • Adding numerators AND denominators (1/3 + 1/4 is NOT 2/7)
  • Forgetting to simplify the final result
  • Not finding the LCD before adding/subtracting

Skip the manual calculations. Use the PureTools Fraction Calculator to perform any fraction operation with step-by-step solutions. Handles mixed numbers, simplification, and conversion to decimals.