Эх сурвалжийг харах

sovler status file

Former-commit-id: b76a8a1f3796d2cacd2099f912ae5dbb83674897
Alec Jacobson (jalec 12 жил өмнө
parent
commit
4c419d4ec7

+ 16 - 0
include/igl/SolverStatus.h

@@ -0,0 +1,16 @@
+#ifndef IGL_SOLVER_STATUS_H
+#define IGL_SOLVER_STATUS_H
+namespace igl
+{
+  enum SolverStatus
+  {
+    // Good
+    SOLVER_STATUS_CONVERGED = 0,
+    // OK
+    SOLVER_STATUS_MAX_ITER = 1,
+    // Bad
+    SOLVER_STATUS_ERROR = 2,
+    NUM_SOLVER_STATUSES = 3,
+  };
+};
+#endif

+ 3 - 12
include/igl/active_set.h

@@ -1,22 +1,13 @@
-#ifndef ACTIVE_SET_H
-#define ACTIVE_SET_H
+#ifndef IGL_ACTIVE_SET_H
+#define IGL_ACTIVE_SET_H
 
 #include "igl_inline.h"
+#include "SolverStatus.h"
 #include <Eigen/Core>
 #include <Eigen/Sparse>
 
 namespace igl
 {
-  enum SolverStatus
-  {
-    // Good
-    SOLVER_STATUS_CONVERGED = 0,
-    // OK
-    SOLVER_STATUS_MAX_ITER = 1,
-    // Bad
-    SOLVER_STATUS_ERROR = 2,
-    NUM_SOLVER_STATUSES = 3,
-  };
   struct active_set_params;
   // Known Bugs: rows of [Aeq;Aieq] **must** be linearly independent. Should be
   // using QR decomposition otherwise: