Egyptian Fraction Decomposer
Enter a numerator and denominator of a proper fraction.
Result
How it is calculated
The tool uses the greedy method. The fraction is first reduced by the greatest common divisor, so 2/4 is treated as 1/2. For the remaining fraction a/b it takes the largest unit fraction that does not exceed it, 1/x with x = ceil(b ÷ a). That unit fraction is subtracted, a/b − 1/x = (a×x − b) / (b×x), the new fraction is reduced, and the process repeats until nothing remains. The unit fractions found are distinct and listed in order, together with the number of terms. Numerator and denominator must be whole numbers with 0 < numerator < denominator; 3/2, 5/5, 0/5 and 2.5/7 give no result. The method always ends, but the answer is not guaranteed to have the fewest terms. Denominators can grow very fast, and when the next denominator would no longer fit in a 64-bit whole number (5/121 is one such case) the tool shows no result rather than a wrong one.
Worked example
Decompose 4/13. First ceil(13 ÷ 4) = 4, so take 1/4: 4/13 − 1/4 = (16 − 13)/52 = 3/52. Next ceil(52 ÷ 3) = 18, so take 1/18: 3/52 − 1/18 = (54 − 52)/936 = 2/936 = 1/468. What remains is already a unit fraction. The tool lists 1/4 + 1/18 + 1/468 and counts 3 terms. Adding them back over the common denominator 468 gives 117 + 26 + 1 = 144 over 468, which reduces to 4/13.
Common mistakes
- Entering an improper fraction or a mixed number such as 7/4 or 1 3/4. Only fractions below 1 are accepted, so split off the whole part and decompose the remainder.
- Entering a decimal numerator or denominator, such as 2.5/7. Both must be whole numbers; multiply top and bottom by 10 first (25/70).
- Expecting the shortest or neatest decomposition. The greedy answer for 6/7 is 1/2 + 1/3 + 1/42, but for other fractions it produces long chains with huge denominators where a hand-picked answer is much shorter.
- Believing the result is the only Egyptian fraction. Many fractions have several valid decompositions, and the tool shows just the greedy one.
- Trying fractions like 5/121 and reading the empty result as invalid input. The fraction is fine; the greedy denominators simply outgrow what the tool can compute exactly.
About this calculator
An Egyptian fraction expresses a proper fraction as a sum of distinct unit fractions — fractions with numerator 1, like 1/2 + 1/3 + 1/10 — the form ancient Egyptian mathematicians used (as recorded in documents like the Rhind Mathematical Papyrus) since their numeral system had no convenient way to write general fractions such as 2/5.
This decomposer uses the greedy algorithm, sometimes called the Fibonacci–Sylvester method after Fibonacci's 13th-century description and Sylvester's 19th-century proof that it always terminates: at each step it subtracts the largest unit fraction not exceeding the remaining value, then repeats on the remainder. The result is always a finite sum of distinct unit fractions, though not necessarily the shortest one possible — a genuinely open problem for some fractions is finding the minimum number of terms.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm’s Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments (1)
The greedy answer is correct but rarely the tidiest, so treat it as one valid decomposition rather than the only one. Try 2/5, which comes out as 1/3 + 1/15, then 6/7, which gives 1/2 + 1/3 + 1/42. Some fractions such as 5/121 return nothing at all because the denominators outgrow exact arithmetic, which says nothing about whether the input was valid. Which fractions are you decomposing: a puzzle, a class exercise, or history?