|
This section is concerned with the construction of bases for vector spaces.
VectorSpaceWithBasis(a) : AlgMatElt -> ModTupFld
VectorSpaceWithBasis(a) : ModMatFldElt -> ModTupFld
KSpaceWithBasis(Q) : [ModTupFldElt] -> ModTupFld
KSpaceWithBasis(a) : AlgMatElt -> ModTupFld
KSpaceWithBasis(a) : ModMatFldElt -> ModTupFld
KModuleWithBasis(Q) : [ModTupFldElt] -> ModTupFld
Create a vector space having as basis the terms of B (rows of a).
The current basis for the vector space V, returned as a sequence of
vectors.
The i-th basis element for the vector space V.
The current basis for the vector space V, returned as the rows of a
matrix belonging to the matrix space K(m x n), where m
is the dimension of V and n is the over-dimension of V.
Given a vector v belonging to the r-dimensional K-vector space V,
with basis v1, ..., vr, return a sequence [a1, ..., ar] of
elements of K giving the coordinates of v relative to the V-basis:
v = a1 * v1 + ... + ar * vr.
The dimension of the vector space V.
Given a sequence Q containing r linearly independent vectors belonging
to the vector space U, extend the vectors of Q to a basis for U. The
basis is returned in the form of a sequence T such that T[i] = Q[i],
i = 1, ... r.
Given an r-dimensional subspace U of the vector space V,
return a basis for V in the form of a sequence T of elements
such that the first r elements correspond to the given basis
vectors for U.
Given a set S of elements belonging to the vector space V,
return true if the elements of S are linearly independent.
Given a sequence Q of elements belonging to the vector space V,
return true if the terms of Q are linearly independent.
These operations will be illustrated in the context of the
subspace G3 of the 11-dimensional vector space over GF(3) defining
the ternary Golay code.
> V11 := VectorSpace(FiniteField(3), 11);
> G3 := sub< V11 | [1,0,0,0,0,0,1,1,1,1,1], [0,1,0,0,0,0,0,1,2,2,1],
> [0,0,1,0,0,0,1,0,1,2,2], [0,0,0,1,0,0,2,1,0,1,2],
> [0,0,0,0,1,0,2,2,1,0,1], [0,0,0,0,0,1,1,2,2,1,0] >;
> Dimension(G3);
6
> Basis(G3);
[
(1 0 0 0 0 0 1 1 1 1 1),
(0 1 0 0 0 0 0 1 2 2 1),
(0 0 1 0 0 0 1 0 1 2 2),
(0 0 0 1 0 0 2 1 0 1 2),
(0 0 0 0 1 0 2 2 1 0 1),
(0 0 0 0 0 1 1 2 2 1 0)
]
> S := ExtendBasis(G3, V11);
> S;
[
(1 0 0 0 0 0 1 1 1 1 1),
(0 1 0 0 0 0 0 1 2 2 1),
(0 0 1 0 0 0 1 0 1 2 2),
(0 0 0 1 0 0 2 1 0 1 2),
(0 0 0 0 1 0 2 2 1 0 1),
(0 0 0 0 0 1 1 2 2 1 0),
(0 0 0 0 0 0 1 0 0 0 0),
(0 0 0 0 0 0 0 1 0 0 0),
(0 0 0 0 0 0 0 0 1 0 0),
(0 0 0 0 0 0 0 0 0 1 0),
(0 0 0 0 0 0 0 0 0 0 1)
]
> C3:= Complement(V11, G3);
> C3;
Vector space of degree 11, dimension 5 over GF(3)
Echelonized basis:
(0 0 0 0 0 0 1 0 0 0 0)
(0 0 0 0 0 0 0 1 0 0 0)
(0 0 0 0 0 0 0 0 1 0 0)
(0 0 0 0 0 0 0 0 0 1 0)
(0 0 0 0 0 0 0 0 0 0 1)
> G3 + C3;
Full Vector space of degree 11 over GF(3)
> G3 meet C3;
Vector space of degree 11, dimension 0 over GF(3)
> x := Random(G3);
> x;
(1 1 2 0 0 1 1 1 1 2 0)
> c := Coordinates(G3, x);
> c;
[ 1, 1, 2, 0, 0, 1 ]
> G3 ! &+[ c[i] * G3.i : i in [1 .. Dimension(G3)]];
(1 1 2 0 0 1 1 1 1 2 0)
[Next][Prev] [Right] [Left] [Up] [Index] [Root]
|