elt< C | a1, ..., an> : Code, List -> ModTupRngElt
Given a length n additive code C with alphabet F, then the codewords
of C lie in F(n). Given
elements a1, ..., an belonging
to F, construct the codeword (a1, ..., an) of C.
A check is made that the vector (a1, ..., an) is an element of C.
Given an additive code C which is defined as a subset of the F-space
V = F(n), and an element u belonging to V,
create the codeword of C corresponding to u. The function
will fail if u does not belong to C.
The zero word of the additive code C.
A random codeword of the additive code C.
Sum of the codewords u and v, where u and
v belong to the same linear code C.
Additive inverse of the codeword u belonging
to the linear code C.
Difference of the codewords u and v, where
u and v belong to the same linear code C.
Given an element a belonging to the alphabet F,
and a codeword u belonging to the additive code
C, return the codeword a * u.
Normalize a codeword u of an additive code C, returning a scalar multiple
of u such that its first non-zero entry is 1.
The Hamming distance between the codewords u and v,
where u and v belong to the same additive code C.
The Hamming weight of the codeword u, i.e., the number of non-zero
components of u.
InnerProduct(u, v) : ModTupRngElt, ModTupRngElt -> RngElt
Inner product of the vectors u and v with respect to
the Euclidean norm, where u and v belong to the parent
vector space of the code C.
Given vectors u and v defined over a finite field L and a subfield K
of L, this function returns the trace of the inner product of the vectors
u and v with respect to K.
Given a word w belonging to the [n, k] code C, return its
support as a subset of the integer set { 1 .. n }. The support of w
consists of the coordinates at which w has non-zero entries.
Given an [n, k : kg] K-additive code C and
a codeword u of C return the
coordinates of u with respect to the current basis of C.
The coordinates of u are returned
as a sequence Q = [a1, ..., akg] of elements from K
such that u = a1 * C.1 + ... + akg * C.(kg).
Given a word w belonging to the code C, return the
ambient space V of C.
Given a vector u, return the vector obtained from u by
cyclically shifting its components to the right by k coordinate
positions.
Given a vector u, destructively rotate u by k coordinate positions.
Trace(u) : ModTupFldElt -> ModTupFldElt
Given a vector u with components in K, and a subfield S of K,
construct the vector with components in S obtained from u by taking
the trace of each component with respect to S. If S is omitted,
it is taken to be the prime field of K.
The function returns true if and only if the codewords u and v
belonging to the same additive code are equal.
The function returns true if and only if the codewords u and v
belonging to the same additive code are not equal.
The function returns true if and only if the codeword u is the
zero vector.
Given a codeword u belonging to the code C defined
over the ring R, return the i-th component of u
(as an element of R).
Given an element u belonging to a subcode C of the full R-space
V = Rn, a positive integer i, 1 ≤i≤n, and an
element x of R, this function returns a vector in V
which is u with its i-th component redefined to be x.
V2.28, 13 July 2023