pympcc.sosc_check

pympcc.sosc_check(result, problem, *, tol=0.0, fd_h=None, active_tol=1e-06)[source]

Check MPCC second-order sufficient conditions at result.x.

Parameters:
  • result (MPCCResult) – Converged solve result.

  • problem (MPCCProblem) – Source problem (original space, not presolve-reduced).

  • tol (float) – Eigenvalue threshold: SOSC holds when min_eigenvalue > tol (default 0.0 — strict positive definiteness).

  • fd_h (float or None) – Step size for FD Hessian approximation when problem.lagrangian_hessian is not provided. Defaults to problem.fd_h.

  • active_tol (float) – Constraint tolerance for active-set detection (default 1e-6).

Returns:

soscbool or None

True = SOSC holds, False = SOSC violated, None = check skipped.

min_eigenvaluefloat or None

Minimum eigenvalue of the reduced Hessian W = Z^T H Z. None when the check was skipped.

null_space_dimint or None

Dimension of the critical cone (columns in Z).

n_activeint or None

Number of active constraint rows in A.

skipped_reasonstr or None

Explanation when sosc is None.

Return type:

dict