Ratio Simplifier Formula

Understand the math behind the ratio simplifier. Each variable explained with a worked example.

Formulas Used

Gcd Val

gcd_val = gcd(round(abs(a)), round(abs(b)))

Simplified A

simplified_a = round(abs(a)) / gcd(round(abs(a)), round(abs(b)))

Simplified B

simplified_b = round(abs(b)) / gcd(round(abs(a)), round(abs(b)))

Decimal Ratio

decimal_ratio = b != 0 ? a / b : 0

Variables

VariableDescriptionDefault
aFirst Number12
bSecond Number8

How It Works

How to Simplify a Ratio

Method

1. Find the GCD (greatest common divisor) of both numbers 2. Divide both numbers by the GCD

Example: 12:8

  • GCD(12, 8) = 4
  • 12/4 : 8/4 = 3:2
  • Worked Example

    Simplify the ratio 12:8.

    a = 12b = 8
    1. 01GCD(12, 8) = 4
    2. 0212/4 = 3
    3. 038/4 = 2
    4. 04Simplified ratio: 3:2
    5. 05Decimal: 12/8 = 1.5

    Frequently Asked Questions

    What is a ratio?

    A ratio compares two quantities by division. The ratio 3:2 means for every 3 of the first quantity, there are 2 of the second.

    Is a ratio the same as a fraction?

    Ratios and fractions are related. The ratio 3:2 can be written as the fraction 3/2. However, ratios can compare more than two quantities (e.g., 1:2:3).

    How do I know if a ratio is fully simplified?

    A ratio is fully simplified when the GCD of all its parts is 1, meaning no common factor can further reduce the numbers.

    Ready to run the numbers?

    Open Ratio Simplifier