allow taking inverses mod 1