|
| 1 | +# Fix: ShortestVectors(..., "positive") should also accept vectors |
| 2 | +# that are nonpositive by replacing them with their negation. |
| 3 | + |
| 4 | +gap> E8 := |
| 5 | +> [ [ 2, -1, 0, 0, 0, 0, 0, 0 ], [ -1, 2, -1, 0, 0, 0, 0, 0 ], |
| 6 | +> [ 0, -1, 2, -1, 0, 0, 0, 0 ], [ 0, 0, -1, 2, -1, 0, 0, 0 ], |
| 7 | +> [ 0, 0, 0, -1, 2, -1, 0, -1 ], [ 0, 0, 0, 0, -1, 2, -1, 0 ], |
| 8 | +> [ 0, 0, 0, 0, 0, -1, 2, 0 ], [ 0, 0, 0, 0, -1, 0, 0, 2 ] ];; |
| 9 | +gap> Length( ShortestVectors( E8, 2 ).vectors ); |
| 10 | +120 |
| 11 | +gap> sv := ShortestVectors( E8, 2, "positive" );; |
| 12 | +gap> Length( sv.vectors ); |
| 13 | +120 |
| 14 | +gap> ForAll( sv.vectors, x -> ForAll( x, y -> y >= 0 ) ); |
| 15 | +true |
0 commit comments