Math

Fraction calculator

Use the Fraction calculator for fast, clear results with formulas and practical examples.

Fraction calculator

Result5/6
Decimal0.8333333333

What this calculator answers

Use this calculator when both operands are ratios of integers. The exact reduced fraction is the primary answer; the decimal is supplementary and may repeat indefinitely.

Input definitions

First numerator and denominator
The integer a and non-zero integer b in the first fraction a/b.
Operation
Addition, subtraction, multiplication, or division.
Second numerator and denominator
The integer c and non-zero integer d in the second fraction c/d. Division also requires c ≠ 0.

Formulas and variables

Addition and subtraction

a/b ± c/d = (ad ± bc) / bd
  • b ≠ 0
  • d ≠ 0

The resulting numerator and denominator are divided by their greatest common divisor.

Multiplication

a/b × c/d = ac / bd
  • b ≠ 0
  • d ≠ 0

Cross-cancellation before multiplication is equivalent and can keep integers smaller.

Division

a/b ÷ c/d = ad / bc
  • b ≠ 0
  • c ≠ 0
  • d ≠ 0

Dividing by a fraction means multiplying by its reciprocal.

Assumptions and rounding

  • All four entered parts are integers within JavaScript’s safe integer range.
  • Denominators are normalized so the final denominator is positive.
  • The fraction is reduced exactly by the greatest common divisor before a decimal is shown.
  • Decimal display may round a repeating expansion, while the fraction remains exact.

Worked examples

Add one half and one third

Compute 1/2 + 1/3.

Calculation
  1. Use common denominator 2 × 3 = 6.
  2. Cross-products: 1 × 3 + 1 × 2 = 3 + 2 = 5.
  3. The result is 5/6; gcd(5, 6) = 1, so it is already reduced.

Result: 5/6, approximately 0.8333333333.

Divide three quarters by two fifths

Compute 3/4 ÷ 2/5.

Calculation
  1. Invert the second fraction: 2/5 becomes 5/2.
  2. Multiply: 3 × 5 / (4 × 2) = 15/8.
  3. gcd(15, 8) = 1; as a mixed number, 15/8 = 1 7/8.

Result: 15/8, or 1.875.

Questions people ask

Why must a denominator be non-zero?
A fraction represents division by its denominator. Division by zero has no defined finite value.
Why do I invert the second fraction when dividing?
Multiplying by d/c reverses multiplication by c/d, so (a/b) ÷ (c/d) equals (a/b) × (d/c).
Is the decimal answer always exact?
Only fractions whose reduced denominator contains no prime factors other than 2 and 5 terminate in base ten. Others repeat and must be rounded for display.
How is a negative sign normalized?
The final denominator is kept positive, so any negative sign is placed on the numerator.

Boundaries and common mistakes

  • Do not add denominators when adding fractions; use a common denominator and cross-products.
  • Division by a fraction with numerator zero is also division by zero.
  • A rounded decimal should not replace the reduced fraction when an exact answer is required.

Sources and scope

Content and formula review date:

Reviewed by the CalculatorToolset editorial team against the cited definitions and engine tests.

Report a calculation or content issue: support@calculatortoolset.com

Variables, defaults, and limits

First numerator
First numerator is a number input. The displayed starter value is 1; it is an example, not a hidden assumption.
Default: 1
Accepted values: The field has no narrower HTML limit, but it must still satisfy the documented formula domain and produce a finite result. Numeric entries must be finite and unambiguous.
First denominator
First denominator is a number input. The displayed starter value is 2; it is an example, not a hidden assumption.
Default: 2
Accepted values: The field has no narrower HTML limit, but it must still satisfy the documented formula domain and produce a finite result. Numeric entries must be finite and unambiguous.
Operation
Operation is a choice input. The displayed starter value is Add; it is an example, not a hidden assumption.
Default: Add
Accepted values: The field has no narrower HTML limit, but it must still satisfy the documented formula domain and produce a finite result. Available choices: Add, Subtract, Multiply, Divide.
Second numerator
Second numerator is a number input. The displayed starter value is 1; it is an example, not a hidden assumption.
Default: 1
Accepted values: The field has no narrower HTML limit, but it must still satisfy the documented formula domain and produce a finite result. Numeric entries must be finite and unambiguous.
Second denominator
Second denominator is a number input. The displayed starter value is 3; it is an example, not a hidden assumption.
Default: 3
Accepted values: The field has no narrower HTML limit, but it must still satisfy the documented formula domain and produce a finite result. Numeric entries must be finite and unambiguous.

Worked examples

Fraction calculator evaluated example 1

Use the page’s labelled starter inputs to verify Fraction calculator.

Inputs
  • First numerator: 1
  • First denominator: 2
  • Operation: Add
  • Second numerator: 1
  • Second denominator: 3

Evaluated result: 5/6

Fraction calculator evaluated example 2

Enter -7/12 divided by 5/18 to obtain -21/10.

Inputs
  • First numerator: -7
  • First denominator: 12
  • Operation: Divide
  • Second numerator: 5
  • Second denominator: 18

Evaluated result: -21/10

Validation and boundaries

  • Every visible required input must be present; a missing value is never replaced with zero.
  • NaN, positive or negative infinity, unsafe overflow, and a non-finite final result are rejected.
  • Field-specific minimums, maximums, and choices apply to First numerator, First denominator, Operation, Second numerator, Second denominator.
  • Zero, negative values, and discrete counts are accepted only when the displayed field definition permits them.
  • Both fraction denominators must be nonzero; division also requires a nonzero numerator in the second fraction.

Review and correction links

Frequently asked questions

Why is the result -21/10 instead of -2 1/10?
The tool normalizes output as a reduced improper fraction and supplies a decimal; it does not format mixed numbers.
What question does Fraction calculator answer?
Use the Fraction calculator for fast, clear results with formulas and practical examples. The implemented relationship is R=reduce_gcd({(x₁x₅+x₄x₂)/(x₂x₅); (x₁x₅−x₄x₂)/(x₂x₅); x₁x₄/(x₂x₅); x₁x₅/(x₂x₄)}); selector=x₃; x₁=First numerator; x₂=First denominator; x₃=Operation; x₄=Second numerator; x₅=Second denominator.
Which inputs does Fraction calculator use?
It uses the visible fields First numerator, First denominator, Operation, Second numerator, Second denominator. No hidden value is substituted for an omitted required input.
What happens when Fraction calculator receives an invalid or extreme value?
The page rejects missing, ambiguous, out-of-range, or non-finite values and refuses to display a non-finite result.
Why can Fraction calculator differ from another result?
Different unit conventions, endpoint policies, fee or rate assumptions, formula domains, and premature rounding can produce a different answer.
Can I use Fraction calculator as professional advice?
No. It answers the displayed mathematical question and cannot account for omitted real-world facts.
How can I verify the Fraction calculator result?
Recalculate the two evaluated examples without rounding intermediate values and compare the declared formula or convention with Elementary rational arithmetic.

Source and review scope

Elementary rational arithmetic

Scope: Elementary rational arithmetic is used to check the formula, definition, or convention relevant to Fraction calculator. The citation does not supply current personal, lender, tax, medical, or market data.

Source checked:

Continue with related tools