This is just a sandbox for you to work in, if you’d like. Be aware that there is no way to save your work except to cut and paste it elsewhere.
Some common commands:
Mod(a,n)computes the residue of
n. If you need to do a giant exponent, put it outside, like
Mod(a,n)^eso the computer does it sensibly.
gcd(a,b)computes the gcd of
xgcd(a,b)computes the extended euclidean algorithm of
b(i.e. it outputs the solution to the linear Diophantine equation $ax+by=gcd(a,b)$).
primitive_root(p)will give a primitive root modulo
next_prime(n)will compute the first prime after
n(e.g. $n+1$, $n+2$ etc.)
is_prime(n)will return True if
nis prime, and false otherwise.
factor(n)will display a factorization of
euler_phi(n)will compute the Euler phi (totient) function of
randint(n,m)will give a random integer between