It is a generalization of the extended Euclidean algorithm used to solve linear Diophantine equations.