diff --git a/src/math/lp/nla_expr.h b/src/math/lp/nla_expr.h index 12e23d6d6..e9717f4d6 100644 --- a/src/math/lp/nla_expr.h +++ b/src/math/lp/nla_expr.h @@ -310,7 +310,7 @@ public: } return *this; } - if (is_var()) { + if (is_var() || children().size() == 1) { *this = scalar(T(1)); return *this; }