GCS: Interface to query whether the used diagnose matrix is empty
================================================================= Diagnose constraints do not include among others driven constraints. This function allows to know whether the solver is considering an empty matrix.
This commit is contained in:
committed by
abdullahtahiriyo
parent
229c515b72
commit
3605770b68
@@ -417,6 +417,7 @@ System::System()
|
||||
, hasUnknowns(false)
|
||||
, hasDiagnosis(false)
|
||||
, isInit(false)
|
||||
, emptyDiagnoseMatrix(true)
|
||||
, maxIter(100)
|
||||
, maxIterRedundant(100)
|
||||
, sketchSizeMultiplier(false)
|
||||
@@ -533,6 +534,8 @@ void System::clear()
|
||||
hasUnknowns = false;
|
||||
hasDiagnosis = false;
|
||||
|
||||
emptyDiagnoseMatrix = true;
|
||||
|
||||
redundant.clear();
|
||||
conflictingTags.clear();
|
||||
redundantTags.clear();
|
||||
@@ -3844,6 +3847,7 @@ SolverReportingManager::Manager().LogToFile("GCS::System::diagnose()\n");
|
||||
// eventually crash. This fixes issues #0002372/#0002373.
|
||||
if (plist.empty() || (plist.size() - pdrivenlist.size()) == 0) {
|
||||
hasDiagnosis = true;
|
||||
emptyDiagnoseMatrix = true;
|
||||
dofs = 0;
|
||||
return dofs;
|
||||
}
|
||||
@@ -3879,6 +3883,9 @@ SolverReportingManager::Manager().LogToFile("GCS::System::diagnose()\n");
|
||||
hasDiagnosis = true;
|
||||
dofs = pdiagnoselist.size();
|
||||
|
||||
if(J.rows() > 0)
|
||||
emptyDiagnoseMatrix = false;
|
||||
|
||||
// There is a legacy decision to use QR decomposition. I (abdullah) do not know all the
|
||||
// consideration taken in that decisions. I see that:
|
||||
// - QR decomposition is able to provide information about the rank and redundant/conflicting constraints
|
||||
|
||||
Reference in New Issue
Block a user