14 #ifndef OR_TOOLS_LINEAR_SOLVER_MODEL_VALIDATOR_H_
15 #define OR_TOOLS_LINEAR_SOLVER_MODEL_VALIDATOR_H_
20 #include "absl/types/optional.h"
21 #include "ortools/linear_solver/linear_solver.pb.h"
39 const MPModelProto&
model,
double abs_value_threshold = 0.0,
42 bool accept_trivially_infeasible_bounds =
false);
51 const MPModelProto&
model);
57 std::optional<LazyMutableCopy<MPModelProto>>
67 MPModelRequest* request, MPSolutionResponse*
response);
88 MPConstraintProto* to);
SharedResponseManager * response
Collection of objects used to extend the Constraint Solver library.
bool ExtractValidMPModelInPlaceOrPopulateResponseStatus(MPModelRequest *request, MPSolutionResponse *response)
Like ExtractValidMPModelOrPopulateResponseStatus(), but works in-place: if the MPModel needed extract...
std::string FindErrorInMPModelDeltaProto(const MPModelDeltaProto &delta, const MPModelProto &model)
Like FindErrorInMPModelProto, but for a MPModelDeltaProto applied to a given baseline model (assumed ...
void ApplyVerifiedMPModelDelta(const MPModelDeltaProto &delta, MPModelProto *model)
std::optional< LazyMutableCopy< MPModelProto > > ExtractValidMPModelOrPopulateResponseStatus(const MPModelRequest &request, MPSolutionResponse *response)
If the model is valid and non-empty, returns it (possibly after extracting the model_delta).
std::string FindErrorInMPModelProto(const MPModelProto &model, double abs_value_threshold, const bool accept_trivially_infeasible_bounds)
Returns an empty string iff the model is valid and not trivially infeasible.
std::string FindFeasibilityErrorInSolutionHint(const MPModelProto &model, double tolerance)
Returns an empty string if the solution hint given in the model is a feasible solution.
void MergeMPConstraintProtoExceptTerms(const MPConstraintProto &from, MPConstraintProto *to)