The latter GCD is calculated from the gcd(147, 462 mod 147) = gcd(147, 21), which in turn is calculated from the gcd(21, 147 mod 21) = gcd(21, 0) = 21.
Мы должны трижды отнять 147 ("q"1 = 3), оставаясь с остатком 21.: 462 = 3 × 147 + 21.