Skip to content

Conversation

@amontoison
Copy link
Member

close #204
We need a JuMP model with a SNF as objective and a VNF for the constraints for the tests.

@amontoison
Copy link
Member Author

amontoison commented Jan 23, 2025

@blegat
It seems that your code to add a VectorNonlinearFunction in the model is not working here.
I checked the documentation and the function MathOptInterface.Nonlinear.add_constraint is not defined for a VNF.

cc @odow

@amontoison amontoison changed the title Support MOI.VectorNonlinearFunction Improve the error message for VectorNonlinearFunction Jan 23, 2025
@blegat
Copy link
Contributor

blegat commented Jan 23, 2025

We could also use bridges in MathOptNLPModel(model). Making sure to only select bridges that do not add variables:
https://github.com/JuliaPolyhedra/Polyhedra.jl/blob/master/src/lphrep.jl#L40-L91

@amontoison
Copy link
Member Author

@blegat For the bridges, do you have one that reformulate the complementarity constraints x \ perp y into x >=0, y>=0, xy == 0?

@amontoison amontoison merged commit a212d5e into JuliaSmoothOptimizers:main Jan 24, 2025
23 of 24 checks passed
@amontoison amontoison deleted the support_VNF branch January 24, 2025 15:10
@odow
Copy link
Contributor

odow commented Jan 24, 2025

Nope. It's on my TODO list for a separate package. Also note that your definition of complementarity does not match MOI's. The restrictions on x depend on the domain of y.

@amontoison
Copy link
Member Author

amontoison commented Jan 24, 2025

We use this reformulation in our case for SCOPF:
JuliaSmoothOptimizers/AmplNLReader.jl#144

I should add a proper support of these constraints in the API NLPModels.jl such that the hybrid ExaModels.jl can exploit what you did in MOI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support MOI.VectorNonlinearFunction

3 participants