| 234 | } |
| 235 | |
| 236 | std::tuple<HighsStatus, dense_array_t<double>, HighsInt, |
| 237 | dense_array_t<HighsInt>> |
| 238 | highs_getBasisInverseRowSparse(Highs* h, HighsInt row) { |
| 239 | HighsInt num_row = h->getNumRow(); |
| 240 | |
| 241 | HighsStatus status = HighsStatus::kOk; |
| 242 | HighsInt solution_num_nz = 0; |
| 243 | std::vector<double> solution_vector(num_row); |
| 244 | std::vector<HighsInt> solution_index(num_row); |
| 245 | double* solution_vector_ptr = static_cast<double*>(solution_vector.data()); |
| 246 | HighsInt* solution_index_ptr = static_cast<HighsInt*>(solution_index.data()); |
| 247 | |
| 248 | if (num_row > 0) |
| 249 | status = h->getBasisInverseRow(row, solution_vector_ptr, &solution_num_nz, |
| 250 | solution_index_ptr); |
| 251 | return std::make_tuple(status, py::cast(solution_vector), solution_num_nz, |
| 252 | py::cast(solution_index)); |
| 253 | } |
| 254 | |
| 255 | std::tuple<HighsStatus, dense_array_t<double>> highs_getBasisInverseCol( |
| 256 | Highs* h, HighsInt col) { |
nothing calls this directly
no test coverage detected