Stay organized with collections Save and categorize content based on your preferences.

C++ Reference: class CoreBasedOptimizer

Note: This documentation is automatically generated.

Same as MinimizeIntegerVariableWithLinearScanAndLazyEncoding() but use a core-based approach instead. Note that the given objective_var is just used for reporting the lower-bound/upper-bound and do not need to be linked with its linear representation.

Unlike MinimizeIntegerVariableWithLinearScanAndLazyEncoding() this function just return the last solver status. In particular if it is INFEASIBLE but feasible_solution_observer() was called, it means we are at OPTIMAL.

Arguments: IntegerVariable objective_var, const std::vector<IntegerVariable>& variables, const std::vector<IntegerValue>& coefficients, std::function<void()> feasible_solution_observer, Model* model


Return type: SatSolver::Status

TODO(user): Change the algo slighlty to allow resuming from the last aborted position. Currently, the search is "resumable", but it will restart some of the work already done, so it might just never find anything.


Return type: SatSolver::Status

Arguments: const std::vector<Literal>& literals, const std::vector<IntegerVariable>& vars, const std::vector<Coefficient>& coefficients, Coefficient offset

A different way to encode the objective as core are found. If the vector if literals is passed it will use that, otherwise it will encode the passed integer variables. In both cases, the vector used should be of the same size as the coefficients vector. It seems to be more powerful, but it isn't completely implemented yet. TODO(user): - Support resuming for interleaved search. - Implement all core heurisitics.