up previous next

create a new finite field

NewRingFp(P: INT): RING

Create a new small prime finite field with characteristic P .

NOTE: in ring definitions you can use the convenient notation ZZ/(p)

NOTE: calling twice NewRingFp will produce two different rings, even with identical input: equality test is performed on the pointers. See RingID .

/**/ p := NextPrime(1000);
/**/ Fp := NewRingFp(p);
/**/ Use Fp[x];
/**/ product([x-i | i in 1..p]);
x^1009 - x
/**/ Use ZZ/(p)[x]; --> convenient shorthand in ring defn
/**/ product([x-i | i in 1..p]);
x^1009 - x

See Also