コード例 #1
0
ファイル: test_inplace_solve.cpp プロジェクト: manctl/boost
int main() {
  const int n=10;

  // typedefs are needed as macros do not work with "," in template arguments
  typedef ublas::compressed_matrix<double, ublas::row_major>     commat_doub_rowmaj;
  typedef ublas::compressed_matrix<double, ublas::column_major>  commat_doub_colmaj;
  typedef ublas::matrix<double, ublas::row_major>                mat_doub_rowmaj;
  typedef ublas::matrix<double, ublas::column_major>             mat_doub_colmaj;
  typedef ublas::mapped_matrix<double, ublas::row_major>         mapmat_doub_rowmaj;
  typedef ublas::mapped_matrix<double, ublas::column_major>      mapmat_doub_colmaj;
  typedef ublas::coordinate_matrix<double, ublas::row_major>     cormat_doub_rowmaj;
  typedef ublas::coordinate_matrix<double, ublas::column_major>  cormat_doub_colmaj;
  typedef ublas::mapped_vector_of_mapped_vector<double, ublas::row_major> mvmv_doub_rowmaj;
  typedef ublas::mapped_vector_of_mapped_vector<double, ublas::column_major> mvmv_doub_colmaj;

  BOOST_UBLAS_TEST_BEGIN();

  BOOST_UBLAS_TEST_DO( test_inplace_solve<commat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<commat_doub_colmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mat_doub_colmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mapmat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mapmat_doub_colmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<cormat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<cormat_doub_colmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mvmv_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mvmv_doub_colmaj> );

  BOOST_UBLAS_TEST_END();
}
コード例 #2
0
int main()
{
    BOOST_UBLAS_TEST_BEGIN();

    BOOST_UBLAS_TEST_DO( test_coordinate_vector_inplace_merge_random );

    BOOST_UBLAS_TEST_END();

    return EXIT_SUCCESS;;
}
コード例 #3
0
ファイル: begin_end.cpp プロジェクト: 0xDEC0DE8/mcsema
int main()
{
    BOOST_UBLAS_TEST_BEGIN();

    BOOST_UBLAS_TEST_DO( test_vector_iteration );
    BOOST_UBLAS_TEST_DO( test_vector_const_iteration );
    BOOST_UBLAS_TEST_DO( test_row_major_matrix_iteration );
    BOOST_UBLAS_TEST_DO( test_col_major_matrix_iteration );

    BOOST_UBLAS_TEST_END();
}
コード例 #4
0
ファイル: num_columns.cpp プロジェクト: OggYiu/rag-engine
int main()
{
    BOOST_UBLAS_TEST_BEGIN();

    BOOST_UBLAS_TEST_DO( test_row_major_matrix_container );
    BOOST_UBLAS_TEST_DO( test_col_major_matrix_container );
    BOOST_UBLAS_TEST_DO( test_matrix_expression );
    BOOST_UBLAS_TEST_DO( test_matrix_reference );

    BOOST_UBLAS_TEST_END();
}
コード例 #5
0
int main()
{
	BOOST_UBLAS_TEST_SUITE( "Test 'utils.hpp' functionalities" );

	BOOST_UBLAS_TEST_BEGIN();
		BOOST_UBLAS_TEST_DO( check );
		BOOST_UBLAS_TEST_DO( check_eq );
		BOOST_UBLAS_TEST_DO( check_close );
		BOOST_UBLAS_TEST_DO( check_rel_close );
		BOOST_UBLAS_TEST_DO( check_vector_eq );
		BOOST_UBLAS_TEST_DO( check_vector_close );
		BOOST_UBLAS_TEST_DO( check_vector_rel_close );
		BOOST_UBLAS_TEST_DO( check_matrix_eq );
		BOOST_UBLAS_TEST_DO( check_matrix_close );
		BOOST_UBLAS_TEST_DO( check_matrix_rel_close );
	BOOST_UBLAS_TEST_END();
}
コード例 #6
0
int main() {

  // typedefs are needed as macros do not work with "," in template arguments
  typedef ublas::compressed_matrix<double, ublas::row_major>     commat_doub_rowmaj;
  typedef ublas::compressed_matrix<double, ublas::column_major>  commat_doub_colmaj;
  typedef ublas::matrix<double, ublas::row_major>                mat_doub_rowmaj;
  typedef ublas::matrix<double, ublas::column_major>             mat_doub_colmaj;
  typedef ublas::mapped_matrix<double, ublas::row_major>         mapmat_doub_rowmaj;
  typedef ublas::mapped_matrix<double, ublas::column_major>      mapmat_doub_colmaj;
  typedef ublas::coordinate_matrix<double, ublas::row_major>     cormat_doub_rowmaj;
  typedef ublas::coordinate_matrix<double, ublas::column_major>  cormat_doub_colmaj;
  typedef ublas::mapped_vector_of_mapped_vector<double, ublas::row_major> mvmv_doub_rowmaj;
  typedef ublas::mapped_vector_of_mapped_vector<double, ublas::column_major> mvmv_doub_colmaj;

  BOOST_UBLAS_TEST_BEGIN();

#ifdef USE_MATRIX
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mat_doub_colmaj> );
#endif

#ifdef USE_COMPRESSED_MATRIX
  BOOST_UBLAS_TEST_DO( test_inplace_solve<commat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<commat_doub_colmaj> );
#endif

#ifdef USE_MAPPED_MATRIX
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mapmat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mapmat_doub_colmaj> );
#endif

#ifdef USE_COORDINATE_MATRIX
  BOOST_UBLAS_TEST_DO( test_inplace_solve<cormat_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<cormat_doub_colmaj> );
#endif

#ifdef USE_MAPPED_VECTOR_OF_MAPPED_VECTOR
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mvmv_doub_rowmaj> );
  BOOST_UBLAS_TEST_DO( test_inplace_solve<mvmv_doub_colmaj> );
#endif

  BOOST_UBLAS_TEST_END();
}