multiplicative inverse of 13 modulo 512