Skip to content
Snippets Groups Projects
Commit 6c70767a authored by Giovanni La Mura's avatar Giovanni La Mura
Browse files

Make test_zivert silent on success

parent 098daf96
No related branches found
No related tags found
No related merge requests found
......@@ -39,30 +39,21 @@
int main() {
int result = (int)SUCCESS;
printf("INFO: matrix inversion test.\n");
printf("INFO: sizeof(np_int) = %ld\n", sizeof(np_int));
#ifdef USE_MAGMA
magma_init();
printf("INFO: sizeof(magma_int_t) = %ld\n", sizeof(magma_int_t));
#endif
const np_int n = 3;
const np_int n = 2;
const np_int nn = n * n;
const double tolerance = 1.0e-6;
dcomplex **test_matrix;
dcomplex *vec_matrix = new dcomplex[n];
dcomplex *vec_inv_matrix = new dcomplex[n];
dcomplex *vec_matrix = new dcomplex[nn];
dcomplex *vec_inv_matrix = new dcomplex[nn];
for (int ivi = 0; ivi < nn; ivi++) vec_matrix[ivi] = 1.0 + ivi + I * (1.0 + ivi);
test_matrix[0] = vec_matrix;
test_matrix[1] = vec_matrix + 2;
vec_inv_matrix[0] = 3.0 + I * 3.0;
vec_inv_matrix[1] = 1.0 / 3.0 + I * 0.0;
vec_inv_matrix[2] = 2.0 / 3.0 + I * 0.0;
vec_inv_matrix[3] = 6.0 + I * 6.0;
vec_inv_matrix[4] = 2.0 + I * 2.0;
vec_inv_matrix[5] = 0.5 + I * 0.0;
vec_inv_matrix[6] = 9.0 + I * 9.0;
vec_inv_matrix[7] = 4.0 + I * 4.0;
vec_inv_matrix[8] = 0.0 + I * 0.0;
test_matrix = &vec_matrix;
vec_inv_matrix[0] = -1.0 + I * 1.0;
vec_inv_matrix[1] = 0.5 - I * 0.5;
vec_inv_matrix[2] = 0.75 - I * 0.75;
vec_inv_matrix[3] = -0.25 + I * 0.25;
#ifdef USE_MAGMA
if (sizeof(np_int) != sizeof(magma_int_t)) {
printf("ERROR: sizeof(np_int) = %ld; sizeof(magma_int_t) = %ld\n",
......@@ -81,7 +72,6 @@ int main() {
}
delete[] vec_inv_matrix;
delete[] vec_matrix;
delete[] test_matrix;
#ifdef USE_MAGMA
magma_finalize();
#endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment