65.176 CodeWeightEnumerator

CodeWeightEnumerator( code )

CodeWeightEnumerator returns a polynomial of the following form:
f(x) = sum_i=0^n A_i x^i,

where A_i is the number of codewords in code with weight i.

    gap> CodeWeightEnumerator( ElementsCode( [ [ 0,0,0 ], [ 0,0,1 ],
    > [ 0,1,1 ], [ 1,1,1 ] ], GF(2) ) );
    x^3 + x^2 + x + 1
    gap> CodeWeightEnumerator( HammingCode( 3, GF(2) ) );
    x^7 + 7*x^4 + 7*x^3 + 1 

Previous Up Top Next
Index

GAP 3.4.4
April 1997