<T>LAPACK 0.1.1
C++ Template Linear Algebra PACKage
Loading...
Searching...
No Matches
testutils.hpp File Reference

Utility functions for the unit tests. More...

#include "testdefinitions.hpp"
#include "MatrixMarket.hpp"
#include <tlapack/plugins/debugutils.hpp>
#include <tlapack/base/utils.hpp>
#include <tlapack/blas/gemm.hpp>
#include <tlapack/blas/herk.hpp>
#include <tlapack/lapack/lacpy.hpp>
#include <tlapack/lapack/lange.hpp>
#include <tlapack/lapack/lanhe.hpp>
#include <tlapack/lapack/laset.hpp>
#include <catch2/catch_template_test_macros.hpp>
#include <catch2/generators/catch_generators.hpp>
Include dependency graph for testutils.hpp:

Go to the source code of this file.

Macros

#define SKIP_TEST   return
 Skip the current test.
 

Functions

template<TLAPACK_MATRIX matrix_t>
real_type< type_t< matrix_t > > tlapack::check_generalized_similarity_transform (matrix_t &A, matrix_t &Q, matrix_t &Z, matrix_t &B)
 Calculates ||Q'*A*Z - B||.
 
template<TLAPACK_MATRIX matrix_t>
real_type< type_t< matrix_t > > tlapack::check_generalized_similarity_transform (matrix_t &A, matrix_t &Q, matrix_t &Z, matrix_t &B, matrix_t &res, matrix_t &work)
 Calculates res = Q'*A*Z - B and the frobenius norm of res.
 
template<TLAPACK_MATRIX matrix_t>
real_type< type_t< matrix_t > > tlapack::check_orthogonality (matrix_t &Q)
 Calculates ||Q'*Q - I||_F if m <= n or ||Q*Q' - I||_F otherwise.
 
template<TLAPACK_MATRIX matrix_t>
real_type< type_t< matrix_t > > tlapack::check_orthogonality (matrix_t &Q, matrix_t &res)
 Calculates res = Q'*Q - I if m <= n or res = Q*Q' otherwise Also computes the frobenius norm of res.
 
template<TLAPACK_MATRIX matrix_t>
real_type< type_t< matrix_t > > tlapack::check_similarity_transform (matrix_t &A, matrix_t &Q, matrix_t &B)
 Calculates ||Q'*A*Q - B||.
 
template<TLAPACK_MATRIX matrix_t>
real_type< type_t< matrix_t > > tlapack::check_similarity_transform (matrix_t &A, matrix_t &Q, matrix_t &B, matrix_t &res, matrix_t &work)
 Calculates res = Q'*A*Q - B and the frobenius norm of res.
 
void tlapack::print_matrix_c (const LegacyMatrix< std::complex< float >, size_t, Layout::ColMajor > &A)
 
void tlapack::print_matrix_d (const LegacyMatrix< double, size_t, Layout::ColMajor > &A)
 
void tlapack::print_matrix_r (const LegacyMatrix< float, size_t, Layout::ColMajor > &A)
 
void tlapack::print_matrix_z (const LegacyMatrix< std::complex< double >, size_t, Layout::ColMajor > &A)
 
void tlapack::print_rowmajormatrix_c (const LegacyMatrix< std::complex< float >, size_t, Layout::RowMajor > &A)
 
void tlapack::print_rowmajormatrix_d (const LegacyMatrix< double, size_t, Layout::RowMajor > &A)
 
void tlapack::print_rowmajormatrix_r (const LegacyMatrix< float, size_t, Layout::RowMajor > &A)
 
void tlapack::print_rowmajormatrix_z (const LegacyMatrix< std::complex< double >, size_t, Layout::RowMajor > &A)
 
std::string tlapack::visualize_matrix_c (const LegacyMatrix< std::complex< float >, size_t, Layout::ColMajor > &A)
 
std::string tlapack::visualize_matrix_d (const LegacyMatrix< double, size_t, Layout::ColMajor > &A)
 
std::string tlapack::visualize_matrix_r (const LegacyMatrix< float, size_t, Layout::ColMajor > &A)
 
std::string tlapack::visualize_matrix_z (const LegacyMatrix< std::complex< double >, size_t, Layout::ColMajor > &A)
 
std::string tlapack::visualize_rowmajormatrix_c (const LegacyMatrix< std::complex< float >, size_t, Layout::RowMajor > &A)
 
std::string tlapack::visualize_rowmajormatrix_d (const LegacyMatrix< double, size_t, Layout::RowMajor > &A)
 
std::string tlapack::visualize_rowmajormatrix_r (const LegacyMatrix< float, size_t, Layout::RowMajor > &A)
 
std::string tlapack::visualize_rowmajormatrix_z (const LegacyMatrix< std::complex< double >, size_t, Layout::RowMajor > &A)
 

Detailed Description

Utility functions for the unit tests.

Author
Thijs Steel, KU Leuven, Belgium
Weslley S Pereira, University of Colorado Denver, USA