A cyclic code is associated to an
irreducible polynomial over
which divides
.
For example, to get the
cyclic code over
having generator matrix
R:=PolynomialRing(GF(2),["x"]);; x:=Indeterminate(GF(2),"x");; g:=x^3+x+1; Factors(x^7-1); C:=GeneratorPolCode(g,7,GF(2)); G:=GeneratorMat(C);
To get the parity check matrix, type
H:=CheckMat(C);
Try IsCyclicCode(C);
To get the dimension of the code, type
Dimension(C); To get its
minimum distance, type MinimumDistance(C);