Changeset 427


Ignore:
Timestamp:
Aug 5, 2005 4:34:00 PM (14 years ago)
Author:
andreasw
Message:

In case of wrong inertia: in the number of negative eigenvalues is TOO
SMALL, we now first try to fix that by increaseing pivot tolerance,
and otherwise pretend that the system is singular.

Location:
branches/dev/PDSystemImpl/PDFullSpace
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/dev/PDSystemImpl/PDFullSpace/IpPDFullSpaceSolver.cpp

    r425 r427  
    457457                                                 delta_c, delta_d);
    458458        }
     459        else if (retval==SYMSOLVER_WRONG_INERTIA &&
     460                 augSysSolver_->NumberOfNegEVals() < numberOfEVals) {
     461          Jnlst().Printf(J_DETAILED, J_LINEAR_ALGEBRA,
     462                         "Number of negative eigenvalues too small!\n");
     463          // If the number of negative eigenvalues is too small, then
     464          // we first try to remedy this by asking for better quality
     465          // solution (e.g. increasing pivot tolerance), and if that
     466          // doesn't help, we assume that the system is singular
     467          bool assume_singular = true;
     468          if (!augsys_improved_) {
     469            Jnlst().Printf(J_DETAILED, J_LINEAR_ALGEBRA,
     470                           "Asking augmented system solver to improve quality of its solutions.\n");
     471            augsys_improved_ = augSysSolver_->IncreaseQuality();
     472            if (augsys_improved_) {
     473              IpData().Append_info_string("q");
     474              resolve_with_better_quality = true;
     475              assume_singular = false;
     476            }
     477            else {
     478              Jnlst().Printf(J_DETAILED, J_LINEAR_ALGEBRA,
     479                             "Quality could not be improved\n");
     480            }
     481          }
     482          if (assume_singular) {
     483            perturbHandler_->PerturbForSingularity(delta_x, delta_s,
     484                                                   delta_c, delta_d);
     485            IpData().Append_info_string("M");
     486          }
     487        }
    459488        else if (retval==SYMSOLVER_WRONG_INERTIA ||
    460489                 retval==SYMSOLVER_SINGULAR) {
    461 
    462490          // Get new perturbation factors from the perturbation
    463491          // handlers for the case of wrong inertia
  • branches/dev/PDSystemImpl/PDFullSpace/IpPardisoSolverInterface.cpp

    r321 r427  
    257257    // count
    258258    if (check_NegEVals && (numberOfNegEVals!=negevals_)) {
     259      Jnlst().Printf(J_DETAILED, J_LINEAR_ALGEBRA,
     260                     "Wrong inertia: required are %d, but we got %d.\n",
     261                     numberOfNegEVals, negevals_);
    259262      return SYMSOLVER_WRONG_INERTIA;
    260263    }
Note: See TracChangeset for help on using the changeset viewer.