From 4cd4c8995512b6383723bd1959277f90ca70d582 Mon Sep 17 00:00:00 2001 From: fwesselm Date: Wed, 19 Jun 2024 09:54:45 +0200 Subject: [PATCH 1/5] Add constructor to make VS happy --- src/io/HighsIO.h | 19 +- src/lp_data/HighsOptions.h | 122 +++++++++++ src/presolve/ICrash.h | 8 +- src/simplex/HEkk.h | 68 ++++-- src/simplex/HighsSimplexAnalysis.h | 322 ++++++++++++++++++++--------- 5 files changed, 418 insertions(+), 121 deletions(-) diff --git a/src/io/HighsIO.h b/src/io/HighsIO.h index 7dd398d86d..cf041d5baa 100644 --- a/src/io/HighsIO.h +++ b/src/io/HighsIO.h @@ -18,7 +18,7 @@ #include #include "lp_data/HighsCallback.h" -//#include "util/HighsInt.h" +// #include "util/HighsInt.h" class HighsOptions; @@ -45,14 +45,23 @@ struct HighsLogOptions { bool* output_flag; bool* log_to_console; HighsInt* log_dev_level; - void (*user_log_callback)(HighsLogType, const char*, void*) = nullptr; - void* user_log_callback_data = nullptr; + void (*user_log_callback)(HighsLogType, const char*, void*); + void* user_log_callback_data; std::function user_callback; - void* user_callback_data = nullptr; - bool user_callback_active = false; + void* user_callback_data; + bool user_callback_active; void clear(); + HighsLogOptions() + : log_stream(nullptr), + output_flag(nullptr), + log_to_console(nullptr), + log_dev_level(nullptr), + user_log_callback(nullptr), + user_log_callback_data(nullptr), + user_callback_data(nullptr), + user_callback_active(false){}; }; /** diff --git a/src/lp_data/HighsOptions.h b/src/lp_data/HighsOptions.h index 38be9b59ae..879ed8e60e 100644 --- a/src/lp_data/HighsOptions.h +++ b/src/lp_data/HighsOptions.h @@ -424,6 +424,128 @@ struct HighsOptionsStruct { // Logging callback identifiers HighsLogOptions log_options; virtual ~HighsOptionsStruct() {} + + HighsOptionsStruct() + : presolve(""), + solver(""), + parallel(""), + run_crossover(""), + time_limit(0.0), + solution_file(""), + write_model_file(""), + random_seed(0), + ranging(""), + infinite_cost(0.0), + infinite_bound(0.0), + small_matrix_value(0.0), + large_matrix_value(0.0), + primal_feasibility_tolerance(0.0), + dual_feasibility_tolerance(0.0), + ipm_optimality_tolerance(0.0), + objective_bound(0.0), + objective_target(0.0), + threads(0), + user_bound_scale(0), + user_cost_scale(0), + highs_debug_level(0), + highs_analysis_level(0), + simplex_strategy(0), + simplex_scale_strategy(0), + simplex_crash_strategy(0), + simplex_dual_edge_weight_strategy(0), + simplex_primal_edge_weight_strategy(0), + simplex_iteration_limit(0), + simplex_update_limit(0), + simplex_min_concurrency(0), + simplex_max_concurrency(0), + log_file(""), + write_model_to_file(false), + write_solution_to_file(false), + write_solution_style(0), + glpsol_cost_row_location(0), + output_flag(false), + log_to_console(false), + ipm_iteration_limit(0), + pdlp_native_termination(false), + pdlp_scaling(false), + pdlp_iteration_limit(0), + pdlp_e_restart_method(0), + pdlp_d_gap_tol(0.0), + qp_iteration_limit(0), + qp_nullspace_limit(0), + log_dev_level(0), + log_githash(false), + solve_relaxation(false), + allow_unbounded_or_infeasible(false), + use_implied_bounds_from_presolve(false), + lp_presolve_requires_basis_postsolve(false), + mps_parser_type_free(false), + keep_n_rows(0), + cost_scale_factor(0), + allowed_matrix_scale_factor(0), + allowed_cost_scale_factor(0), + ipx_dualize_strategy(0), + simplex_dualize_strategy(0), + simplex_permute_strategy(0), + max_dual_simplex_cleanup_level(0), + max_dual_simplex_phase1_cleanup_level(0), + simplex_price_strategy(0), + simplex_unscaled_solution_strategy(0), + presolve_reduction_limit(0), + restart_presolve_reduction_limit(0), + presolve_substitution_maxfillin(0), + presolve_rule_off(0), + presolve_rule_logging(false), + simplex_initial_condition_check(false), + no_unnecessary_rebuild_refactor(false), + simplex_initial_condition_tolerance(0.0), + rebuild_refactor_solution_error_tolerance(0.0), + dual_steepest_edge_weight_error_tolerance(0.0), + dual_steepest_edge_weight_log_error_threshold(0.0), + dual_simplex_cost_perturbation_multiplier(0.0), + primal_simplex_bound_perturbation_multiplier(0.0), + dual_simplex_pivot_growth_tolerance(0.0), + presolve_pivot_threshold(0.0), + factor_pivot_threshold(0.0), + factor_pivot_tolerance(0.0), + start_crossover_tolerance(0.0), + less_infeasible_DSE_check(false), + less_infeasible_DSE_choose_row(false), + use_original_HFactor_logic(false), + run_centring(false), + max_centring_steps(0), + centring_ratio_tolerance(0.0), + icrash(false), + icrash_dualize(false), + icrash_strategy(""), + icrash_starting_weight(0.0), + icrash_iterations(0), + icrash_approx_iter(0), + icrash_exact(false), + icrash_breakpoints(false), + mip_detect_symmetry(false), + mip_allow_restart(false), + mip_max_nodes(0), + mip_max_stall_nodes(0), + mip_max_leaves(0), + mip_max_improving_sols(0), + mip_lp_age_limit(0), + mip_pool_age_limit(0), + mip_pool_soft_limit(0), + mip_pscost_minreliable(0), + mip_min_cliquetable_entries_for_parallelism(0), + mip_report_level(0), + mip_feasibility_tolerance(0.0), + mip_rel_gap(0.0), + mip_abs_gap(0.0), + mip_heuristic_effort(0.0), + mip_min_logging_interval(0.0), +#ifdef HIGHS_DEBUGSOL + mip_debug_solution_file(""), +#endif + mip_improving_solution_save(false), + mip_improving_solution_report_sparse(false), + mip_improving_solution_file(""){}; }; // For now, but later change so HiGHS properties are string based so that new diff --git a/src/presolve/ICrash.h b/src/presolve/ICrash.h index 9484b61535..dfe3d40bc7 100644 --- a/src/presolve/ICrash.h +++ b/src/presolve/ICrash.h @@ -85,7 +85,13 @@ struct Quadratic { double mu; std::vector lambda; - Quadratic(HighsLp lp_, ICrashOptions options_) : lp(lp_), options(options_) {} + Quadratic(HighsLp lp_, ICrashOptions options_) + : lp(lp_), + options(options_), + lp_objective(0.0), + quadratic_objective(0.0), + residual_norm_2(0.0), + mu(0.0) {} }; // Functions: Call. diff --git a/src/simplex/HEkk.h b/src/simplex/HEkk.h index c91aba199a..24baeb6338 100644 --- a/src/simplex/HEkk.h +++ b/src/simplex/HEkk.h @@ -25,7 +25,41 @@ class HighsLpSolverObject; class HEkk { public: - HEkk() {} + HEkk() + : callback_(nullptr), + options_(nullptr), + timer_(nullptr), + lp_name_(""), + model_status_(HighsModelStatus::kNotset), + simplex_in_scaled_space_(false), + cost_scale_(1.0), + cost_perturbation_base_(0.0), + cost_perturbation_max_abs_cost_(0.0), + iteration_count_(0), + dual_simplex_cleanup_level_(0), + dual_simplex_phase1_cleanup_level_(0), + previous_iteration_cycling_detected(-kHighsInf), + solve_bailout_(false), + called_return_from_solve_(false), + exit_algorithm_(SimplexAlgorithm::kNone), + return_primal_solution_status_(0), + return_dual_solution_status_(0), + original_num_col_(0), + original_num_row_(0), + original_num_nz_(0), + original_offset_(0.0), + edge_weight_error_(0.0), + build_synthetic_tick_(0.0), + total_synthetic_tick_(0.0), + debug_solve_call_num_(0), + debug_basis_id_(0), + time_report_(false), + debug_initial_build_synthetic_tick_(0), + debug_solve_report_(false), + debug_iteration_report_(false), + debug_basis_report_(false), + debug_dual_feasible(false), + debug_max_relative_dual_steepest_edge_weight_error(0) {} /** * @brief Interface to simplex solvers */ @@ -155,14 +189,14 @@ class HEkk { HSimplexNla simplex_nla_; HotStart hot_start_; - double cost_scale_ = 1; + double cost_scale_; double cost_perturbation_base_; double cost_perturbation_max_abs_cost_; - HighsInt iteration_count_ = 0; - HighsInt dual_simplex_cleanup_level_ = 0; - HighsInt dual_simplex_phase1_cleanup_level_ = 0; + HighsInt iteration_count_; + HighsInt dual_simplex_cleanup_level_; + HighsInt dual_simplex_phase1_cleanup_level_; - HighsInt previous_iteration_cycling_detected = -kHighsIInf; + HighsInt previous_iteration_cycling_detected; bool solve_bailout_; bool called_return_from_solve_; @@ -197,17 +231,17 @@ class HEkk { double edge_weight_error_; - double build_synthetic_tick_ = 0; - double total_synthetic_tick_ = 0; - HighsInt debug_solve_call_num_ = 0; - HighsInt debug_basis_id_ = 0; - bool time_report_ = false; - HighsInt debug_initial_build_synthetic_tick_ = 0; - bool debug_solve_report_ = false; - bool debug_iteration_report_ = false; - bool debug_basis_report_ = false; - bool debug_dual_feasible = false; - double debug_max_relative_dual_steepest_edge_weight_error = 0; + double build_synthetic_tick_; + double total_synthetic_tick_; + HighsInt debug_solve_call_num_; + HighsInt debug_basis_id_; + bool time_report_; + HighsInt debug_initial_build_synthetic_tick_; + bool debug_solve_report_; + bool debug_iteration_report_; + bool debug_basis_report_; + bool debug_dual_feasible; + double debug_max_relative_dual_steepest_edge_weight_error; std::vector bad_basis_change_; diff --git a/src/simplex/HighsSimplexAnalysis.h b/src/simplex/HighsSimplexAnalysis.h index 20d1e14e2d..7ac3035d41 100644 --- a/src/simplex/HighsSimplexAnalysis.h +++ b/src/simplex/HighsSimplexAnalysis.h @@ -58,7 +58,133 @@ const HighsLogType kIterationReportLogType = HighsLogType::kVerbose; */ class HighsSimplexAnalysis { public: - HighsSimplexAnalysis() {} + HighsSimplexAnalysis() + : timer_(nullptr), + pointer_serial_factor_clocks(nullptr), + numRow(0), + numCol(0), + numTot(0), + model_name_(""), + lp_name_(""), + analyse_lp_data(false), + analyse_simplex_summary_data(false), + analyse_simplex_runtime_data(false), + analyse_simplex_time(false), + analyse_factor_data(false), + analyse_factor_time(false), + analyse_simplex_data(false), + simplex_strategy(0), + edge_weight_mode(EdgeWeightMode::kSteepestEdge), + solve_phase(0), + simplex_iteration_count(0), + devex_iteration_count(0), + pivotal_row_index(0), + leaving_variable(0), + entering_variable(0), + rebuild_reason(0), + rebuild_reason_string(""), + reduced_rhs_value(0.0), + reduced_cost_value(0.0), + edge_weight(0.0), + edge_weight_error(0.0), + primal_delta(0.0), + primal_step(0.0), + dual_step(0.0), + pivot_value_from_column(0.0), + pivot_value_from_row(0.0), + factor_pivot_threshold(0.0), + numerical_trouble(0.0), + objective_value(0.0), + num_primal_infeasibility(0), + num_dual_infeasibility(0), + sum_primal_infeasibility(0.0), + sum_dual_infeasibility(0.0), + num_dual_phase_1_lp_dual_infeasibility(0), + max_dual_phase_1_lp_dual_infeasibility(0.0), + sum_dual_phase_1_lp_dual_infeasibility(0.0), + num_devex_framework(0), + col_aq_density(0.0), + row_ep_density(0.0), + row_ap_density(0.0), + row_DSE_density(0.0), + col_steepest_edge_density(0.0), + col_basic_feasibility_change_density(0.0), + row_basic_feasibility_change_density(0.0), + col_BFRT_density(0.0), + primal_col_density(0.0), + dual_col_density(0.0), + num_costly_DSE_iteration(0), + costly_DSE_measure(0.0), + multi_iteration_count(0), + multi_chosen(0), + multi_finished(0), + min_concurrency(0), + num_concurrency(0), + max_concurrency(0), + num_col_price(0), + num_row_price(0), + num_row_price_with_switch(0), + num_primal_cycling_detections(0), + num_dual_cycling_detections(0), + num_quad_chuzc(0), + num_heap_chuzc(0), + sum_quad_chuzc_size(0.0), + sum_heap_chuzc_size(0.0), + max_quad_chuzc_size(0), + max_heap_chuzc_size(0), + num_improve_choose_column_row_call(0), + num_remove_pivot_from_pack(0), + num_correct_dual_primal_flip(0), + min_correct_dual_primal_flip_dual_infeasibility(kHighsInf), + max_correct_dual_primal_flip(0.0), + num_correct_dual_cost_shift(0), + max_correct_dual_cost_shift_dual_infeasibility(0.0), + max_correct_dual_cost_shift(0.0), + net_num_single_cost_shift(0), + num_single_cost_shift(0), + max_single_cost_shift(0.0), + sum_single_cost_shift(0.0), + num_dual_steepest_edge_weight_check(0), + num_dual_steepest_edge_weight_reject(0), + num_wrong_low_dual_steepest_edge_weight(0), + num_wrong_high_dual_steepest_edge_weight(0), + average_frequency_low_dual_steepest_edge_weight(0.0), + average_frequency_high_dual_steepest_edge_weight(0.0), + average_log_low_dual_steepest_edge_weight_error(0.0), + average_log_high_dual_steepest_edge_weight_error(0.0), + max_average_frequency_low_dual_steepest_edge_weight(0.0), + max_average_frequency_high_dual_steepest_edge_weight(0.0), + max_sum_average_frequency_extreme_dual_steepest_edge_weight(0.0), + max_average_log_low_dual_steepest_edge_weight_error(0.0), + max_average_log_high_dual_steepest_edge_weight_error(0.0), + max_sum_average_log_extreme_dual_steepest_edge_weight_error(0.0), + num_invert_report_since_last_header(-1), + num_iteration_report_since_last_header(-1), + last_user_log_time(-kHighsInf), + delta_user_log_time(1e0), + average_concurrency(0.0), + average_fraction_of_possible_minor_iterations_performed(0.0), + sum_multi_chosen(0), + sum_multi_finished(0), + num_invert(0), + num_kernel(0), + num_major_kernel(0), + max_kernel_dim(0.0), + sum_kernel_dim(0.0), + running_average_kernel_dim(0.0), + sum_invert_fill_factor(0.0), + sum_kernel_fill_factor(0.0), + sum_major_kernel_fill_factor(0.0), + running_average_invert_fill_factor(1.0), + running_average_kernel_fill_factor(1.0), + running_average_major_kernel_fill_factor(1.0), + AnIterIt0(0), + AnIterPrevIt(0), + AnIterTraceNumRec(0), + AnIterTraceIterDl(0), + AnIterNumInvert{}, + AnIterNumEdWtIt{} {} + // Pointer to timer HighsTimer* timer_; @@ -162,38 +288,38 @@ class HighsSimplexAnalysis { // double dual_steepest_edge_weight_log_error_threshold; // Local copies of simplex data for reporting - HighsInt simplex_strategy = 0; - EdgeWeightMode edge_weight_mode = EdgeWeightMode::kSteepestEdge; - HighsInt solve_phase = 0; - HighsInt simplex_iteration_count = 0; - HighsInt devex_iteration_count = 0; - HighsInt pivotal_row_index = 0; - HighsInt leaving_variable = 0; - HighsInt entering_variable = 0; - HighsInt rebuild_reason = 0; - std::string rebuild_reason_string = ""; - double reduced_rhs_value = 0; - double reduced_cost_value = 0; - double edge_weight = 0; - double edge_weight_error = 0; - double primal_delta = 0; - double primal_step = 0; - double dual_step = 0; - double pivot_value_from_column = 0; - double pivot_value_from_row = 0; - double factor_pivot_threshold = 0; - double numerical_trouble = 0; - double objective_value = 0; - HighsInt num_primal_infeasibility = 0; - HighsInt num_dual_infeasibility = 0; - double sum_primal_infeasibility = 0; - double sum_dual_infeasibility = 0; + HighsInt simplex_strategy; + EdgeWeightMode edge_weight_mode; + HighsInt solve_phase; + HighsInt simplex_iteration_count; + HighsInt devex_iteration_count; + HighsInt pivotal_row_index; + HighsInt leaving_variable; + HighsInt entering_variable; + HighsInt rebuild_reason; + std::string rebuild_reason_string; + double reduced_rhs_value; + double reduced_cost_value; + double edge_weight; + double edge_weight_error; + double primal_delta; + double primal_step; + double dual_step; + double pivot_value_from_column; + double pivot_value_from_row; + double factor_pivot_threshold; + double numerical_trouble; + double objective_value; + HighsInt num_primal_infeasibility; + HighsInt num_dual_infeasibility; + double sum_primal_infeasibility; + double sum_dual_infeasibility; // This triple is an original infeasibility record, so it includes max, // but it's only used for reporting - HighsInt num_dual_phase_1_lp_dual_infeasibility = 0; - double max_dual_phase_1_lp_dual_infeasibility = 0; - double sum_dual_phase_1_lp_dual_infeasibility = 0; - HighsInt num_devex_framework = 0; + HighsInt num_dual_phase_1_lp_dual_infeasibility; + double max_dual_phase_1_lp_dual_infeasibility; + double sum_dual_phase_1_lp_dual_infeasibility; + HighsInt num_devex_framework; double col_aq_density; double row_ep_density; double row_ap_density; @@ -208,21 +334,21 @@ class HighsSimplexAnalysis { double costly_DSE_measure; // Local copies of parallel simplex data for reporting - HighsInt multi_iteration_count = 0; - HighsInt multi_chosen = 0; - HighsInt multi_finished = 0; - HighsInt min_concurrency = 0; - HighsInt num_concurrency = 0; - HighsInt max_concurrency = 0; + HighsInt multi_iteration_count; + HighsInt multi_chosen; + HighsInt multi_finished; + HighsInt min_concurrency; + HighsInt num_concurrency; + HighsInt max_concurrency; // Unused // HighsInt multi_num = 0; // Useless // double basis_condition = 0; // Maybe useful // Records of how pivotal row PRICE was done - HighsInt num_col_price = 0; - HighsInt num_row_price = 0; - HighsInt num_row_price_with_switch = 0; + HighsInt num_col_price; + HighsInt num_row_price; + HighsInt num_row_price_with_switch; HighsValueDistribution before_ftran_upper_sparse_density; HighsValueDistribution ftran_upper_sparse_density; @@ -235,29 +361,29 @@ class HighsSimplexAnalysis { HighsValueDistribution cleanup_dual_step_distribution; HighsValueDistribution cleanup_primal_change_distribution; - HighsInt num_primal_cycling_detections = 0; - HighsInt num_dual_cycling_detections = 0; - - HighsInt num_quad_chuzc = 0; - HighsInt num_heap_chuzc = 0; - double sum_quad_chuzc_size = 0; - double sum_heap_chuzc_size = 0; - HighsInt max_quad_chuzc_size = 0; - HighsInt max_heap_chuzc_size = 0; - - HighsInt num_improve_choose_column_row_call = 0; - HighsInt num_remove_pivot_from_pack = 0; - - HighsInt num_correct_dual_primal_flip = 0; - double min_correct_dual_primal_flip_dual_infeasibility = kHighsInf; - double max_correct_dual_primal_flip = 0; - HighsInt num_correct_dual_cost_shift = 0; - double max_correct_dual_cost_shift_dual_infeasibility = 0; - double max_correct_dual_cost_shift = 0; - HighsInt net_num_single_cost_shift = 0; - HighsInt num_single_cost_shift = 0; - double max_single_cost_shift = 0; - double sum_single_cost_shift = 0; + HighsInt num_primal_cycling_detections; + HighsInt num_dual_cycling_detections; + + HighsInt num_quad_chuzc; + HighsInt num_heap_chuzc; + double sum_quad_chuzc_size; + double sum_heap_chuzc_size; + HighsInt max_quad_chuzc_size; + HighsInt max_heap_chuzc_size; + + HighsInt num_improve_choose_column_row_call; + HighsInt num_remove_pivot_from_pack; + + HighsInt num_correct_dual_primal_flip; + double min_correct_dual_primal_flip_dual_infeasibility; + double max_correct_dual_primal_flip; + HighsInt num_correct_dual_cost_shift; + double max_correct_dual_cost_shift_dual_infeasibility; + double max_correct_dual_cost_shift; + HighsInt net_num_single_cost_shift; + HighsInt num_single_cost_shift; + double max_single_cost_shift; + double sum_single_cost_shift; // Tolerances for analysis of TRAN stages - could be needed for // control if this is ever used again! @@ -290,46 +416,46 @@ class HighsSimplexAnalysis { // double AnIterCostlyDseFq; //!< Frequency of iterations when DSE is costly // double AnIterCostlyDseMeasure; - HighsInt num_dual_steepest_edge_weight_check = 0; - HighsInt num_dual_steepest_edge_weight_reject = 0; - HighsInt num_wrong_low_dual_steepest_edge_weight = 0; - HighsInt num_wrong_high_dual_steepest_edge_weight = 0; - double average_frequency_low_dual_steepest_edge_weight = 0; - double average_frequency_high_dual_steepest_edge_weight = 0; - double average_log_low_dual_steepest_edge_weight_error = 0; - double average_log_high_dual_steepest_edge_weight_error = 0; - double max_average_frequency_low_dual_steepest_edge_weight = 0; - double max_average_frequency_high_dual_steepest_edge_weight = 0; - double max_sum_average_frequency_extreme_dual_steepest_edge_weight = 0; - double max_average_log_low_dual_steepest_edge_weight_error = 0; - double max_average_log_high_dual_steepest_edge_weight_error = 0; - double max_sum_average_log_extreme_dual_steepest_edge_weight_error = 0; - - HighsInt num_invert_report_since_last_header = -1; - HighsInt num_iteration_report_since_last_header = -1; - double last_user_log_time = -kHighsInf; - double delta_user_log_time = 1e0; + HighsInt num_dual_steepest_edge_weight_check; + HighsInt num_dual_steepest_edge_weight_reject; + HighsInt num_wrong_low_dual_steepest_edge_weight; + HighsInt num_wrong_high_dual_steepest_edge_weight; + double average_frequency_low_dual_steepest_edge_weight; + double average_frequency_high_dual_steepest_edge_weight; + double average_log_low_dual_steepest_edge_weight_error; + double average_log_high_dual_steepest_edge_weight_error; + double max_average_frequency_low_dual_steepest_edge_weight; + double max_average_frequency_high_dual_steepest_edge_weight; + double max_sum_average_frequency_extreme_dual_steepest_edge_weight; + double max_average_log_low_dual_steepest_edge_weight_error; + double max_average_log_high_dual_steepest_edge_weight_error; + double max_sum_average_log_extreme_dual_steepest_edge_weight_error; + + HighsInt num_invert_report_since_last_header; + HighsInt num_iteration_report_since_last_header; + double last_user_log_time; + double delta_user_log_time; double average_concurrency; double average_fraction_of_possible_minor_iterations_performed; - HighsInt sum_multi_chosen = 0; - HighsInt sum_multi_finished = 0; + HighsInt sum_multi_chosen; + HighsInt sum_multi_finished; // Analysis of INVERT form - HighsInt num_invert = 0; - HighsInt num_kernel = 0; - HighsInt num_major_kernel = 0; - double max_kernel_dim = 0; - double sum_kernel_dim = 0; - double running_average_kernel_dim = 0; - double sum_invert_fill_factor = 0; - double sum_kernel_fill_factor = 0; - double sum_major_kernel_fill_factor = 0; - double running_average_invert_fill_factor = 1; - double running_average_kernel_fill_factor = 1; - double running_average_major_kernel_fill_factor = 1; - - HighsInt AnIterIt0 = 0; + HighsInt num_invert; + HighsInt num_kernel; + HighsInt num_major_kernel; + double max_kernel_dim; + double sum_kernel_dim; + double running_average_kernel_dim; + double sum_invert_fill_factor; + double sum_kernel_fill_factor; + double sum_major_kernel_fill_factor; + double running_average_invert_fill_factor; + double running_average_kernel_fill_factor; + double running_average_major_kernel_fill_factor; + + HighsInt AnIterIt0; HighsInt AnIterPrevIt; // Major operation analysis struct From 8b10c1745cc5144e506612f6557507372f26ad28 Mon Sep 17 00:00:00 2001 From: fwesselm Date: Wed, 19 Jun 2024 09:59:14 +0200 Subject: [PATCH 2/5] Minor changes --- src/io/HighsIO.h | 2 +- src/simplex/HighsSimplexAnalysis.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/io/HighsIO.h b/src/io/HighsIO.h index cf041d5baa..adead90c24 100644 --- a/src/io/HighsIO.h +++ b/src/io/HighsIO.h @@ -18,7 +18,7 @@ #include #include "lp_data/HighsCallback.h" -// #include "util/HighsInt.h" +//#include "util/HighsInt.h" class HighsOptions; diff --git a/src/simplex/HighsSimplexAnalysis.h b/src/simplex/HighsSimplexAnalysis.h index 7ac3035d41..93b88bcc93 100644 --- a/src/simplex/HighsSimplexAnalysis.h +++ b/src/simplex/HighsSimplexAnalysis.h @@ -182,6 +182,7 @@ class HighsSimplexAnalysis { AnIterPrevIt(0), AnIterTraceNumRec(0), AnIterTraceIterDl(0), + AnIterTrace{}, AnIterNumInvert{}, AnIterNumEdWtIt{} {} From dc93a4f4125b954f39a3f58a315cdf89dffc270d Mon Sep 17 00:00:00 2001 From: fwesselm Date: Wed, 19 Jun 2024 10:19:51 +0200 Subject: [PATCH 3/5] Add missing initializations --- src/mip/HighsDomain.h | 1 + src/mip/HighsSearch.h | 1 + src/simplex/HighsSimplexAnalysis.h | 1 + src/util/HighsMatrixSlice.h | 10 ++++++---- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/src/mip/HighsDomain.h b/src/mip/HighsDomain.h index fb09c99164..40968d0266 100644 --- a/src/mip/HighsDomain.h +++ b/src/mip/HighsDomain.h @@ -358,6 +358,7 @@ class HighsDomain { conflictPoolPropagation(other.conflictPoolPropagation), infeasible_(other.infeasible_), infeasible_reason(other.infeasible_reason), + infeasible_pos(0), colLowerPos_(other.colLowerPos_), colUpperPos_(other.colUpperPos_), branchPos_(other.branchPos_), diff --git a/src/mip/HighsSearch.h b/src/mip/HighsSearch.h index ccea0a26ef..c9c665e21a 100644 --- a/src/mip/HighsSearch.h +++ b/src/mip/HighsSearch.h @@ -96,6 +96,7 @@ class HighsSearch { std::shared_ptr stabilizerOrbits = nullptr) : lower_bound(parentlb), estimate(parentestimate), + branching_point(0.0), lp_objective(-kHighsInf), other_child_lb(parentlb), nodeBasis(std::move(parentBasis)), diff --git a/src/simplex/HighsSimplexAnalysis.h b/src/simplex/HighsSimplexAnalysis.h index 93b88bcc93..b12dd1c134 100644 --- a/src/simplex/HighsSimplexAnalysis.h +++ b/src/simplex/HighsSimplexAnalysis.h @@ -180,6 +180,7 @@ class HighsSimplexAnalysis { running_average_major_kernel_fill_factor(1.0), AnIterIt0(0), AnIterPrevIt(0), + AnIterOp{}, AnIterTraceNumRec(0), AnIterTraceIterDl(0), AnIterTrace{}, diff --git a/src/util/HighsMatrixSlice.h b/src/util/HighsMatrixSlice.h index 6c71253672..3da09ce402 100644 --- a/src/util/HighsMatrixSlice.h +++ b/src/util/HighsMatrixSlice.h @@ -196,7 +196,7 @@ class HighsMatrixSlice { using pointer = const HighsSliceNonzero*; using reference = const HighsSliceNonzero&; - iterator(HighsInt node) : currentNode(node) {} + iterator(HighsInt node) : pos_(), nodeNext(nullptr), currentNode(node) {} iterator(const HighsInt* nodeIndex, const double* nodeValue, const HighsInt* nodeNext, HighsInt node) : pos_(node == -1 ? nullptr : nodeIndex + node, @@ -276,7 +276,8 @@ class HighsMatrixSlice { using pointer = const HighsSliceNonzero*; using reference = const HighsSliceNonzero&; - iterator(HighsInt node) : currentNode(node) {} + iterator(HighsInt node) + : pos_(), nodeLeft(nullptr), nodeRight(nullptr), currentNode(node) {} iterator(const HighsInt* nodeIndex, const double* nodeValue, const HighsInt* nodeLeft, const HighsInt* nodeRight, HighsInt node) : pos_(nodeIndex + node, nodeValue + node), @@ -374,7 +375,8 @@ class HighsMatrixSlice { using pointer = const HighsSliceNonzero*; using reference = const HighsSliceNonzero&; - iterator(HighsInt node) : currentNode(node) {} + iterator(HighsInt node) + : pos_(), nodeLeft(nullptr), nodeRight(nullptr), currentNode(node) {} iterator(const HighsInt* nodeIndex, const double* nodeValue, const HighsInt* nodeLeft, const HighsInt* nodeRight, HighsInt node) : pos_(nodeIndex, nodeValue), @@ -477,7 +479,7 @@ class HighsMatrixSlice { using pointer = const HighsSliceNonzero*; using reference = const HighsSliceNonzero&; - iterator(const HighsInt* node) : node(node) {} + iterator(const HighsInt* node) : pos_(), node(node), currentNode(0) {} iterator(const HighsInt* nodeIndex, const double* nodeValue, const HighsInt* node) : pos_(nodeIndex, nodeValue), node(node), currentNode(0) {} From 105fdee064ccb9d4b6dfb5e8d910e2fe7f58da5e Mon Sep 17 00:00:00 2001 From: fwesselm Date: Wed, 19 Jun 2024 21:17:05 +0200 Subject: [PATCH 4/5] Fix typo --- src/simplex/HEkk.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/simplex/HEkk.h b/src/simplex/HEkk.h index 24baeb6338..6384e22c10 100644 --- a/src/simplex/HEkk.h +++ b/src/simplex/HEkk.h @@ -38,7 +38,7 @@ class HEkk { iteration_count_(0), dual_simplex_cleanup_level_(0), dual_simplex_phase1_cleanup_level_(0), - previous_iteration_cycling_detected(-kHighsInf), + previous_iteration_cycling_detected(-kHighsIInf), solve_bailout_(false), called_return_from_solve_(false), exit_algorithm_(SimplexAlgorithm::kNone), From 093a696e8e40cb51c7217a960e02fa2bcd0cc890 Mon Sep 17 00:00:00 2001 From: fwesselm Date: Fri, 21 Jun 2024 09:58:05 +0200 Subject: [PATCH 5/5] Fix initialization --- src/mip/HighsDomain.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mip/HighsDomain.h b/src/mip/HighsDomain.h index 40968d0266..57ff4fe45c 100644 --- a/src/mip/HighsDomain.h +++ b/src/mip/HighsDomain.h @@ -358,7 +358,7 @@ class HighsDomain { conflictPoolPropagation(other.conflictPoolPropagation), infeasible_(other.infeasible_), infeasible_reason(other.infeasible_reason), - infeasible_pos(0), + infeasible_pos(other.infeasible_pos), colLowerPos_(other.colLowerPos_), colUpperPos_(other.colUpperPos_), branchPos_(other.branchPos_),