Why Extended GCD Matters
The extended Euclidean algorithm is more than a gcd shortcut. It finds the greatest common divisor and the numbers that build it. Those numbers are called Bezout coefficients. They prove that ax plus by equals gcd(a,b). This calculator keeps every division row visible. That makes the method easier to audit, teach, and reuse.
Useful Number Theory Work
Many modular arithmetic tasks need this result. A modular inverse exists when two numbers are coprime. The coefficient beside the chosen value becomes the inverse after modulus normalization. Linear Diophantine equations also depend on the same idea. If c is divisible by the gcd, then ax plus by equals c has integer solutions. If not, no integer solution exists.
How the Method Builds Answers
The algorithm repeatedly divides the larger active remainder by the smaller active remainder. Each pass records a quotient and a new remainder. At the same time, it updates two coefficient chains. These chains track how every remainder came from the original inputs. When the last nonzero remainder appears, its stored coefficients become the Bezout pair.
Advanced Result Checks
This page adds checks that help prevent silent mistakes. It accepts negative values and zero where valid. It converts signs after running the core remainder process. It verifies the final identity directly. It also reports lcm, inverse status, a selected Diophantine solution, and the complete general solution. The optional parameter t lets you inspect another point on the solution line.
Practical Input Advice
Enter integers only. Avoid decimals, because the theorem is about whole numbers. Use target c when you want a linear equation result. Leave it unchanged when you only need gcd and coefficients. Review the check line before trusting any inverse. The identity should match exactly.
Export and Study Benefits
The CSV export is useful for spreadsheets and worksheets. The PDF export is useful for reports and class notes. The step table shows quotient, remainder, and coefficient changes. You can compare each row with hand calculations. The example table gives known cases for quick testing. Use small inputs first. Then move to larger values once the pattern is clear. The tool is designed for algebra, cryptography practice, contest preparation, daily practice, and discrete mathematics review.