From 57d53914965f8600fda606c0482f75a31f27cee8 Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Sun, 5 May 2024 16:39:24 +0200 Subject: Add __str__ to OptVariable --- sumofsquares/optvariable.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sumofsquares/optvariable.py b/sumofsquares/optvariable.py index 4c687de..ab450f8 100644 --- a/sumofsquares/optvariable.py +++ b/sumofsquares/optvariable.py @@ -35,6 +35,9 @@ class OptVariableImpl(OptVariableMixin): name: str shape: tuple[int, int] + def __str__(self): + return self.name + def init_opt_variable_expr(name, shape): return OptVariableImpl(name, shape) -- cgit v1.2.1