The extended Euclidean algorithm givesBack-substituting in these equations produces the Bezout identityThus one integer solution is . In fact, subtracting this Bezout identity from any other solution and using that and are coprime integers gives all solutions: , , where .
For the modular arithmetic calculation, is a prime number and is coprime to it, so Fermat little theorem gives . Since , and the preceding Bezout identity identifies as the modular multiplicative inverse of , we obtainConsequently the least positive representative is .
Articles by others on the same topic
There are currently no matching articles.