/// \brief Return the second dimensions size of a test matrix /// /// \pre Matrix cannot be empty (ie first dimension size must be > 0) else an invalid_argument_exception will be thrown /// /// \pre Matrix must have a consistent size of the second dimension else an invalid_argument_exception will be thrown /// /// \returns The size of the second dimension static size_t get_second_dimension_size(const bool_deq_vec &arg_test_matrix ///< The test matrix to query ) { if (arg_test_matrix.empty()) { BOOST_THROW_EXCEPTION(invalid_argument_exception("Cannot get second dimension size for empty test matrix")); } const bool_deq::size_type second_dimension_size = arg_test_matrix.front().size(); for (const bool_deq &entry : arg_test_matrix) { if (second_dimension_size != entry.size()) { BOOST_THROW_EXCEPTION(invalid_argument_exception("Test matrix does not have a consistent second dimension size")); } } return second_dimension_size; }