From 4646a5c35c222b1f82de21d27b59edf4ea4e9422 Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Fri, 7 Jun 2024 16:29:14 +0200 Subject: Add ExpCone support in solver.scs --- sumofsquares/solver/scs.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/sumofsquares/solver/scs.py b/sumofsquares/solver/scs.py index 71c2248..faad4e1 100644 --- a/sumofsquares/solver/scs.py +++ b/sumofsquares/solver/scs.py @@ -110,11 +110,13 @@ def solve_cone(prob: ConicProblem, verbose: bool = False, for (linear, constant) in prob.constraints["s"]: # -1 because RHS - b_rows.append(vec(constant) * -1) + b_rows.append(vec(-constant)) A_rows.append(np.hstack(tuple(vec(m) for m in linear))) - if prob.constraints["e"]: - raise NotImplementedError + for (linear, constant) in prob.constraints["e"]: + for i in range(3): + b_rows.append(constant[i]) + A_rows.append(np.hstack(tuple(-m[i] for m in linear))) if prob.constraints["e*"]: raise NotImplementedError -- cgit v1.2.1