NVIDIA / NVIDIA/cuopt

[FEA] Adding constraints and variables to an existing LP problem (C/C++ API)

Open
#725 14 comments 0 reactions 1 assignee View on GitHub

@Kh4ster is already working on this.

Since Dec 17, 2025.

awaiting response feature request
Dominant language
Cuda
Stars
1k
Forks
233
Avg merge
4d 4h
Merged PRs (30d)
95

Description

Hi all,

Thanks for your great work in developing cuopt.

I would like to ask if you could provide a feature in the C/C++ API for expanding an existing LP problem by adding additional constraints and variables and/or modifying existing constraints and variables (changing a matrix coefficient, an objective coefficient or a constraint/variable bound).

There seems to be something in the python API regarding adding constraints/variables, but I have not seen anything related in the C API. For the latter, it seems that the only way for modifying an LP problem is to delete the existing instance and build/solve from scratch the augmented one. In the C++ API, there are several get-type functions in the class optimization_problem_t which return non-cost references to containers e.g. :

rmm::device_uvector<f_t>& get_constraint_matrix_values();

Could these be used for augmenting the existing problem? Would that be safe?

Most simplex solvers support problem modifications since these provide runtime benefits if the primal/dual of the initial problem stays feasible in the modified instance. It would be very nice to have this also in cuopt, if possible.

Thanks,

C.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.