diff --git a/polygon_generator.cc b/polygon_generator.cc index 4d7e1a2..d234c0b 100644 --- a/polygon_generator.cc +++ b/polygon_generator.cc @@ -18,7 +18,7 @@ polygon poly_generate::rectangle(double width, double height, double mass) { {-width / 2, height / 2}, {width / 2, height / 2}, {width / 2, -height / 2}}, - one_over_twelve * mass * width * std::pow(height, 3), + one_over_twelve * mass * (width * width + height * height), mass}; }