MBDynCase.mbd MBDyn file working

This commit is contained in:
Aik-Siong Koh
2023-10-16 11:28:33 -06:00
parent 84cb979354
commit 0b07ff126a
20 changed files with 723 additions and 57 deletions

View File

@@ -29,7 +29,7 @@ void GESpMatParPvPrecise::doPivoting(int p)
while (lookForFirstNonZeroInPivotCol) {
spRowi = matrixA->at(i);
if (spRowi->find(p) == spRowi->end()) {
if (i <= p) throwSingularMatrixError("");
if (i <= p) throwSingularMatrixError("doPivoting");
}
else {
markowitzPivotColCount = 0;
@@ -71,7 +71,7 @@ void GESpMatParPvPrecise::doPivoting(int p)
if (aip != std::numeric_limits<double>::min()) rowPositionsOfNonZerosInPivotColumn->at(markowitzPivotColCount - 1) = rowPivoti;
}
pivotValues->at(p) = max;
if (max < singularPivotTolerance) throwSingularMatrixError("");
if (max < singularPivotTolerance) throwSingularMatrixError("doPivoting");
}
void GESpMatParPvPrecise::preSolvewithsaveOriginal(SpMatDsptr spMat, FColDsptr fullCol, bool saveOriginal)
@@ -97,7 +97,7 @@ void GESpMatParPvPrecise::preSolvewithsaveOriginal(SpMatDsptr spMat, FColDsptr f
{
auto& spRowi = spMat->at(i);
auto maxRowMagnitude = spRowi->maxMagnitude();
if (maxRowMagnitude == 0) throwSingularMatrixError("");
if (maxRowMagnitude == 0) throwSingularMatrixError("preSolvewithsaveOriginal");
rowScalings->at(i) = 1.0 / maxRowMagnitude;
matrixA->at(i) = spRowi->conditionedWithTol(singularPivotTolerance * maxRowMagnitude);
rowOrder->at(i) = i;