Repository navigation
Add an opaque cone type - #143
Merged
Merged
Conversation
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
PSLP_CONE_OPAQUE, a cone block type for sets the presolver does not model (a PSD cone, a power cone, the dual exponential cone).Guarantee (stated in
PSLP_API.h): an opaque block comes back in the reduced problem with the samedimand the same order of its rows, and no information is derived from its rows. The presolver only changes the variables the rows are written in (it fixes a variable, substitutes one out or merges parallel columns), so the entries andrhsof the rows may change, buts = A_B x - r_Bhas the same value at a reduced point as at the postsolved point. Postsolve returns the duals given for the rows of the block unchanged.Why the change is small: the LP reductions already skip cone rows by the row tag
R_TAG_CONE, not by cone type, and cone rows lock their columns in both directions. The change is the new type (anydim >= 1), an assert incones_shrinkthat an opaque block never loses a row, and the documented guarantee.PSLP_CONE_EXPstays a separate type: it is passed through today, but without this promise, so reductions for exponential cones can still be added.Tests (
tests/test_cones.h):test_cones_opaque_untouched: a block whose rows would trigger LP reductions as linear rows (a singleton row, a row parallel to a linear row, a row that becomes empty, columns that appear in the block only); the block keeps its five rows, and an arbitrary reduced point postsolves to the same block slack and the same block duals;test_cones_opaque_constant_block: a constant opaque block that would be infeasible as an SOC is not judged and stays, while the SOC block ahead of it is removed.🤖 Generated with Claude Code