We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 80380ce commit 2fd0251Copy full SHA for 2fd0251
include/proxsuite/proxqp/dense/solver.hpp
@@ -259,6 +259,9 @@ iterative_residual(const Model<T>& qpmodel,
259
qpwork.err.head(qpmodel.dim).noalias() -= Hdx;
260
break;
261
case HessianType::Diagonal:
262
+#ifndef NDEBUG
263
+ PROXSUITE_THROW_PRETTY(!qpwork.H_scaled.isDiagonal(), std::invalid_argument, "H is not diagonal.");
264
+#endif
265
Hdx.array() = qpwork.H_scaled.diagonal().array() *
266
qpwork.dw_aug.head(qpmodel.dim).array();
267
0 commit comments