52 vec.resize(
vec.getSize() + 1);
287 "13 -171 29 41 37 17\n"
288 "11 61 -278 131 19 23\n"
289 "-3 53 123 -317 41 7\n"
290 "11 97 23 47 -297 41\n"
291 "13 19 11 37 61 -143\n");
338 " 13 -171 29 41 37 17\n"
339 " 11 61 -278 131 19 23\n"
340 " -3 53 123 -317 41 7\n"
341 " 11 97 23 47 -297 41\n"
342 " 13 19 11 37 61 -143\n";
407 (
makeMatrix(3,
"1 2 1\n1 4 1\n2 2 1\n2 4 1")));
410 (
makeMatrix(3,
"1 2 0\n1 4 2\n2 2 3\n2 4 5")));
413 (
makeMatrix(3,
"5 -1 6\n 13 -5 5\n -14 5 -7\n -6 1 -8")));
415 (
makeMatrix(4,
"-17 -15 -16 29\n -16 7 -24 18\n"
416 "-2 -10 27 -14\n -1 12 19 -25")));
void swap(HilbertSlice &a, HilbertSlice &b)
void multiplyRow(Matrix &mat, size_t row, const mpq_class &mult)
Multiplies row row with mult.
bool solve(Matrix &sol, const Matrix &lhs, const Matrix &rhs)
Sets sol to some matrix such that lhs*sol=rhs and returns true if such a matrix exists.
mpq_class getParallelogramAreaSq(const Matrix &mat)
Returns the square of the area of the parallelogram whose vertices are the 4 rows of mat.
bool isParallelogram(const Matrix &mat)
Returns true if the rows of mat are the (4) vertices of a parallelogram.
void addMultiplyRow(Matrix &mat, size_t resultRow, size_t sourceRow, const mpq_class &mult)
Adds mult times row sourceRow to row resultRow of mat.
bool rowReduce(Matrix &mat)
Reduces mat to row-echelon form, i.e.
void swapRows(Matrix &mat, size_t row1, size_t row2)
Swaps row row1 and row row2 of mat.
void nullSpace(Matrix &basis, const Matrix &matParam)
Sets the columns of basis to a basis of the null space of mat.
mpq_class determinant(const Matrix &mat)
Returns the determinant of mat.
void subMatrix(Matrix &sub, const Matrix &mat, size_t rowBegin, size_t rowEnd, size_t colBegin, size_t colEnd)
Sets sub to the sub-matrix of mat with rows in the interval [rowBegin, rowEnd) and columns in the int...
void rowReduceFully(Matrix &mat)
Reduces mat to reduced row-echelon form, i.e.
bool inverse(Matrix &inv, const Matrix &mat)
Sets inv to the inverse of mat.
void transpose(Matrix &trans, const Matrix &mat)
Sets trans to the transpose of mat.
void nameFactoryRegister(NameFactory< AbstractProduct > &factory)
Registers the string returned by ConcreteProduct::getStaticName() to a function that default-construc...
#define ASSERT_TRUE(VALUE)
#define ASSERT_FALSE(VALUE)
#define TEST(SUITE, TEST_NAME)
#define TEST_SUITE(SUITE)