1 | initial version |
The first thing to try is:
sage: Q.basis()
[
(1, 0),
(0, 1)
]
but as you can see, it returns a basis within itself, not within $V$. So what you have to do is to lift each element of that basis into $V$:
sage: [Q.lift(b) for b in Q.basis()]
[(1, 0, 0, 0), (0, 0, 1, -7/5)]
If you prefer, you can make this basis a matrix as follows:
sage: matrix([Q.lift(b) for b in Q.basis()])
[ 1 0 0 0]
[ 0 0 1 -7/5]
2 | No.2 Revision |
The Let me first give a name to the quotient $V/W$:
sage: Q = V/W
Now, searching within the avaiable methods, the first thing to try is:
sage: Q.basis()
[
(1, 0),
(0, 1)
]
but as you can see, it returns a basis within itself, not within $V$. So what you have to do is to lift each element of that basis into $V$:
sage: [Q.lift(b) for b in Q.basis()]
[(1, 0, 0, 0), (0, 0, 1, -7/5)]
If you prefer, you can make this basis a matrix as follows:
sage: matrix([Q.lift(b) for b in Q.basis()])
[ 1 0 0 0]
[ 0 0 1 -7/5]