[sdpb] 80/233: Fixed old bug again

Tobias Hansen thansen at moszumanska.debian.org
Thu Mar 9 04:06:21 UTC 2017


This is an automated email from the git hooks/post-receive script.

thansen pushed a commit to branch master
in repository sdpb.

commit 622dcfee20bbb3f40d83143662fd6b840d0aa31b
Author: David Simmons-Duffin <dsd at athena.sns.ias.edu>
Date:   Tue Aug 19 23:15:02 2014 -0400

    Fixed old bug again
---
 src/SDPSolver.cpp | 5 ++---
 src/SDPSolver.h   | 1 -
 src/main.cpp      | 1 -
 3 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/src/SDPSolver.cpp b/src/SDPSolver.cpp
index 2c33b01..f94fde2 100644
--- a/src/SDPSolver.cpp
+++ b/src/SDPSolver.cpp
@@ -47,15 +47,14 @@ SDPSolver::SDPSolver(const SDP &sdp):
     QRWorkspace.push_back(Vector(3*X.blocks[b].rows - 1));
   }
 
+  // Computations needed for free variable elimination
   basicIndices = linearlyIndependentRowIndices(sdp.FreeVarMatrix);
   for (int i = 0, p = 0; p < sdp.FreeVarMatrix.rows; p++)
-    if (p == basicIndices[i])
+    if (i < basicIndices.size() && p == basicIndices[i])
       i++;
     else
       nonBasicIndices.push_back(p);
 
-  // Computations needed for free variable elimination
-
   // LU Decomposition of D_B
   for (int n = 0; n < FreeVarMatrixBasicLU.cols; n++)
     for (int m = 0; m < FreeVarMatrixBasicLU.rows; m++)
diff --git a/src/SDPSolver.h b/src/SDPSolver.h
index 9bf764a..98db51a 100644
--- a/src/SDPSolver.h
+++ b/src/SDPSolver.h
@@ -111,7 +111,6 @@ public:
   Matrix Q;
   vector<Integer> Qpivots;
   Vector basicKernelCoords;
-  Matrix BasicKernelSpan;
   vector<vector<int> > schurStabilizeIndices;
   vector<Real> schurStabilizeLambdas;
   vector<Vector> schurStabilizeVectors;
diff --git a/src/main.cpp b/src/main.cpp
index 949a1c6..d11ff6c 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -43,7 +43,6 @@ int solveSDP(const path &sdpFile,
   cout << parameters << endl;
 
   const SDP sdp = readBootstrapSDP(sdpFile);
-
   SDPSolver solver(sdp);
 
   if (exists(checkpointFile))

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/sdpb.git



More information about the debian-science-commits mailing list