#include "mat_checks.h" namespace UnitTest { bool AreClose(const itpp::mat &expected, const itpp::mat &actual, double tolerance) { if ((expected.rows() != actual.rows()) || (expected.cols() != actual.cols())) { return false; } for (int i = 0; i < expected.rows(); ++i) { for (int j = 0; j < expected.cols(); ++j) { if (!AreClose(expected(i, j), actual(i, j), tolerance)) { return false; } } } return true; } }