switch to more compact modular multiplicative inverse