MCPcopy Create free account
hub / github.com/ERGO-Code/HiGHS / passLinearObjectives

Method passLinearObjectives

highs/lp_data/Highs.cpp:713–723  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

711}
712
713HighsStatus Highs::passLinearObjectives(
714 const HighsInt num_linear_objective,
715 const HighsLinearObjective* linear_objective) {
716 if (num_linear_objective < 0) return HighsStatus::kOk;
717 this->multi_linear_objective_.clear();
718 for (HighsInt iObj = 0; iObj < num_linear_objective; iObj++)
719 if (this->addLinearObjective(linear_objective[iObj], iObj) !=
720 HighsStatus::kOk)
721 return HighsStatus::kError;
722 return HighsStatus::kOk;
723}
724
725HighsStatus Highs::addLinearObjective(
726 const HighsLinearObjective& linear_objective, const HighsInt iObj) {

Callers 1

Calls 2

addLinearObjectiveMethod · 0.95
clearMethod · 0.45

Tested by

no test coverage detected