diff --git a/c++/som/configuration.cpp b/c++/som/configuration.cpp index 49d5f5826..9701520ba 100644 --- a/c++/som/configuration.cpp +++ b/c++/som/configuration.cpp @@ -115,9 +115,6 @@ configuration configuration::operator+(configuration const& c) const { } configuration& configuration::operator*=(double alpha) { - if(alpha < 0) - TRIQS_RUNTIME_ERROR - << "Cannot multiply a configuration by a negative number " << alpha; std::transform(rects.begin(), rects.end(), rects.begin(), [&](rectangle const& r) { return r * alpha; }); cache_ptr.invalidate_entry(); diff --git a/test/c++/configuration.cpp b/test/c++/configuration.cpp index f4c11bb54..f1598960f 100644 --- a/test/c++/configuration.cpp +++ b/test/c++/configuration.cpp @@ -64,9 +64,6 @@ TEST(configuration, Detached) { TEST(configuration, Arithmetics) { EXPECT_PRINT(conf1_str + "," + conf2_str, conf1 + conf2); - EXPECT_THROW(-2.0 * conf1, triqs::runtime_error); - EXPECT_THROW(conf1 * (-2.0), triqs::runtime_error); - EXPECT_PRINT("(c:-2, w:2.6, h:0.6),(c:1.3, w:2.6, h:1.2),(c:2, w:2.6, h:1.4)", 2.0 * conf1); EXPECT_PRINT(