From 35b57bd6de2e1db25309b7cf20b39a5675bdb44f Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Tue, 11 Aug 2015 00:41:51 -0400 Subject: [PATCH] Slightly simplify LL() code. --- mjo/cone/cone.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mjo/cone/cone.py b/mjo/cone/cone.py index 02d5258..821b959 100644 --- a/mjo/cone/cone.py +++ b/mjo/cone/cone.py @@ -673,8 +673,8 @@ def lyapunov_rank(K): # K is not solid, restrict to its span. K = _rho(K) - # Lemma 2 - beta += m*(n - m) + (n - m)**2 + # Non-solid reduction lemma. + beta += (n - m)*n if l > 0: # K is not pointed, restrict to the span of its dual. Uses a @@ -682,8 +682,8 @@ def lyapunov_rank(K): # _rho(K.dual()).dual(). K = _rho(K, K.dual()) - # Lemma 3 - beta += m * l + # Non-pointed reduction lemma. + beta += l * m beta += len(LL(K)) return beta -- 2.44.2