Skip to content

Quadratic functions in the constraints are not picked up by MathOptNLPModel #173

@abelsiqueira

Description

@abelsiqueira

More specifically,

model = Model()
@variable(model, x[1:2])
@objective(model, Min, sum(x .^ 4))
@constraint(model, sum(x .^ 2) == 1)
nlp = MathOptNLPModel(model)

warns with

┌ Warning: Function MathOptInterface.ScalarQuadraticFunction{Float64} is not supported.
└ @ NLPModelsJuMP ~/.julia/packages/NLPModelsJuMP/1KSlI/src/utils.jl:219

And indeed, there are no constraints in the model. Solving the problem via JuMP using NLPModels.Optimizer works.

cc. @blegat, if you can help us again.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions