⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 test_file_matrix.cxx

📁 InsightToolkit-1.4.0(有大量的优化算法程序)
💻 CXX
字号:
/*
  fsm
*/
#include <vcl_iostream.h>
#include <testlib/testlib_root_dir.h>

#include <testlib/testlib_test.h>
#include <vnl/vnl_file_matrix.h>
#include <vnl/vnl_matlab_print.h>

void test_file_matrix()
{
#if 0
  vnl_file_matrix<double> H((testlib_root_dir()+
    "/core/vnl/tests/data_3x3_matrix").c_str());

  vnl_matlab_print(vcl_cout, H, "H");
  TEST("file_matrix 3x3", H.rows(), 3);
  TEST("file_matrix 3x3", H.cols(), 3);

  testlib_test_assert_near("data(1,2)", H(1,2), 0.0185);

  H /= H[0][0];

  vnl_matlab_print(vcl_cout, H, "H");
  testlib_test_assert_near("file_matrix 3x3", H(0,0), 1.0);
#endif
}

TESTMAIN(test_file_matrix);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -