Skip to content

Add iteration-count accessors to SolvedModel#45

Open
GermanHeim wants to merge 1 commit into
rust-or:mainfrom
GermanHeim:iterations
Open

Add iteration-count accessors to SolvedModel#45
GermanHeim wants to merge 1 commit into
rust-or:mainfrom
GermanHeim:iterations

Conversation

@GermanHeim

Copy link
Copy Markdown
Contributor

After a solve, HiGHS exposes per-algorithm iteration counts through its solution-info values (simplex_iteration_count, ipm_iteration_count, etc.).
Right now, there's no safe way to read them: a caller has to reach for SolvedModel::as_mut_ptr() and call the raw Highs_getIntInfoValue FFI itself.

With this PR, we add five new public methods on SolvedModel, mirroring the existing accessors:
simplex_iteration_count(), ipm_iteration_count(), qp_iteration_count(), pdlp_iteration_count(), and crossover_iteration_count().

I also addeda small private int_info_value(name) helper that wraps Highs_getIntInfoValue + try_handle_status.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant