Skip to content

Clarification on lcons/ucons/sense in OptimizationProblem documentation #291

@DanielVandH

Description

@DanielVandH

What are lcons and ucons in the definition of an OptimizationProblem? The documentation says:

lcons and ucons are the upper and lower bounds for equality constraints on the optimization. They should be an AbstractArray matching the geometry of u, where (lcons[I],ucons[I]) is the constraint (lower and upper bounds) for cons[I].

But in OptimizationProblem, this cons vector seems to take the form res = cons(x, p) and the constranits are satisfied when res = 0 - where do the lower and upper bounds come in here? Maybe it would be useful to have a clear mathematical representation of an optimisation problem that lays this out, e.g (a LaTeXed version of?)

minimise f(u, p)
subject to lb[i] <= u[i] <= ub[i], i in eachindex(u)
lb[I] <= cons(u, p)[I] <= ucons[I], i in eachindex(u),

assuming that the latter is what lcons/ucons is actually supposed to represent.

Also just on the problem of this OptimizationProblem documentation, the sense keyword is not defined in this documentation (actually, lcons/ucons/sense are the only fields left blank at the bottom), and the objective function at the start of the documentation I imagine is supposed to be just $$\min_u f(u, p)$$ rather than $\min_u f(u, p) = 0$.

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