Sponsored links: Algebra eBooks
 

Help Index

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z

The Maxima on-line user's manual

Algebra Calculator

Search:

Inv_mod Calculator

Inv_mod

Function: inv_mod (<n>, <m>) Computes the inverse of <n> modulo <m>. inv_mod (n,m) returns false, if <n> is a zero divisor modulo <m>.

p:47;
q:59;
n:p*q;
phi_n: (p-1)*(q-1);
e:79;
gcd(e,phi_n);
d:inv_mod(e,phi_n);
m:65;
c:power_mod(m,e,n);
power_mod(c,d,n);

          (%i1) inv_mod(3, 41);
          (%o1)                           14
          (%i2) ratsimp(3^-1), modulus=41;
          (%o2)                           14
          (%i3) inv_mod(3, 42);
          (%o3)                          false

(%o1)                                true
(%i2) 

Inv_mod Example

Related Examples

inv_mod-mod-power_mod

power_mod(1366, 10000...

mod(3^15,5);

power_mod(2, -1, 5);

Calculate

inv_mod-mod

inv_mod(-2244,2671);

Calculate

inv_mod-mod

inv_mod(-16,67);

Calculate

inv_mod-mod

inv_mod(-1141,2671);

Calculate

inv_mod-mod

inv_mod(15,17);

Calculate

inv_mod-mod-power_mod

inv_mod(42,5);

power_mod(66,173,323);

Calculate

inv_mod-mod

inv_mod(7,17);

Calculate

inv_mod-mod

inv_mod(2,18);

Calculate

inv_mod-mod

inv_mod(2274,2671);

Calculate

inv_mod-mod

inv_mod(-820,2671);

Calculate