Skip to content

Commit

Permalink
Highs::reportModel now uses const HighsModel& model argument so it ca…
Browse files Browse the repository at this point in the history
…n report the presolved LP
  • Loading branch information
jajhall committed Jul 30, 2024
1 parent 76a7e76 commit ce2da38
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/Highs.h
Original file line number Diff line number Diff line change
Expand Up @@ -1374,7 +1374,7 @@ class Highs {
HighsStatus openWriteFile(const string filename, const string method_name,
FILE*& file, HighsFileType& file_type) const;

void reportModel();
void reportModel(const HighsModel& model);
void newHighsBasis();
void forceHighsSolutionBasisSize();
//
Expand Down
16 changes: 8 additions & 8 deletions src/lp_data/Highs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -710,7 +710,7 @@ HighsStatus Highs::writeLocalModel(HighsModel& model,
}
if (filename == "") {
// Empty file name: report model on logging stream
reportModel();
reportModel(model);
return_status = HighsStatus::kOk;
} else {
Filereader* writer =
Expand Down Expand Up @@ -4019,13 +4019,13 @@ void Highs::logHeader() {
return;
}

void Highs::reportModel() {
reportLp(options_.log_options, model_.lp_, HighsLogType::kVerbose);
if (model_.hessian_.dim_) {
const HighsInt dim = model_.hessian_.dim_;
reportHessian(options_.log_options, dim, model_.hessian_.start_[dim],
model_.hessian_.start_.data(), model_.hessian_.index_.data(),
model_.hessian_.value_.data());
void Highs::reportModel(const HighsModel& model) {
reportLp(options_.log_options, model.lp_, HighsLogType::kVerbose);
if (model.hessian_.dim_) {
const HighsInt dim = model.hessian_.dim_;
reportHessian(options_.log_options, dim, model.hessian_.start_[dim],
model.hessian_.start_.data(), model.hessian_.index_.data(),
model.hessian_.value_.data());
}
}

Expand Down

0 comments on commit ce2da38

Please sign in to comment.