Changeset 428 for library/tests/mat_checks.cpp
- Timestamp:
- 07/24/09 13:57:16 (15 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
library/tests/mat_checks.cpp
r426 r428 3 3 namespace UnitTest 4 4 { 5 6 bool AreClose(const itpp::vec &expected, const itpp::vec &actual, 7 double tolerance) { 8 if (expected.length() != actual.length()) { 9 return false; 10 } 11 12 for (int i = 0; i < expected.length(); ++i) { 13 if (!AreClose(expected(i), actual(i), tolerance)) { 14 return false; 15 } 16 } 17 18 return true; 19 } 5 20 6 21 bool AreClose(const itpp::mat &expected, const itpp::mat &actual, double tolerance) {