From 26494d7a5a0aded0ebdafc23bc77ec755cb93a47 Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Fri, 22 Nov 2024 15:57:16 -0500 Subject: [PATCH] mjo/cone/cone.py: remove I don't feel like documenting these properly, and they aren't used anywhere else. --- mjo/cone/all.py | 1 - mjo/cone/cone.py | 41 ----------------------------------------- 2 files changed, 42 deletions(-) delete mode 100644 mjo/cone/cone.py diff --git a/mjo/cone/all.py b/mjo/cone/all.py index 2ef437f..ad27640 100644 --- a/mjo/cone/all.py +++ b/mjo/cone/all.py @@ -2,7 +2,6 @@ All imports from mjo.cone modules. """ -from mjo.cone.cone import * from mjo.cone.completely_positive import * from mjo.cone.doubly_nonnegative import * from mjo.cone.faces import * diff --git a/mjo/cone/cone.py b/mjo/cone/cone.py deleted file mode 100644 index 5b9f839..0000000 --- a/mjo/cone/cone.py +++ /dev/null @@ -1,41 +0,0 @@ -r""" -Matrices aren't vectors in Sage, so these ugly little functions -allow you to create some important cones of matrices quickly and -easily, without the boilerplate. -""" - -from sage.geometry.toric_lattice import ToricLattice - -def LL_cone(K): - r""" - The cone of Lyapunov-like operators on ``K``. - """ - gens = K.lyapunov_like_basis() - L = ToricLattice(K.lattice_dim()**2) - return Cone(( g.list() for g in gens ), lattice=L, check=False) - -def Sigma_cone(K): - r""" - The cone of cross-positive operators on ``K``. - """ - gens = K.cross_positive_operators_gens() - L = ToricLattice(K.lattice_dim()**2) - return Cone(( g.list() for g in gens ), lattice=L, check=False) - -def Z_cone(K): - r""" - The cone of Z-operators on ``K``. - """ - gens = K.Z_operators_gens() - L = ToricLattice(K.lattice_dim()**2) - return Cone(( g.list() for g in gens ), lattice=L, check=False) - -def pi_cone(K1, K2=None): - r""" - The cone of positice operators on ``K``. - """ - if K2 is None: - K2 = K1 - gens = K1.positive_operators_gens(K2) - L = ToricLattice(K1.lattice_dim()*K2.lattice_dim()) - return Cone(( g.list() for g in gens ), lattice=L, check=False) -- 2.49.0