Skip to content

Order-maintaining copy_to  #2236

@matbesancon

Description

@matbesancon

It would be handy in some cases to have a second implementation of copy_to that adds variables (and constraints) in the order of increasing index instead of constrained and then free.

That way one can get rid of the index_map. Concretely, I'm working on non-linear on top of MOI with a function f(x) that takes the vector of variables in order of variable index. When copying the model, this would be handy to keep the same order to avoid having to call f(permutation_matrix * x) all the time

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