14#ifndef PDLP_SHARDED_QUADRATIC_PROGRAM_H_
15#define PDLP_SHARDED_QUADRATIC_PROGRAM_H_
23#include "Eigen/SparseCore"
55 const Eigen::SparseMatrix<double, Eigen::ColMajor, int64_t>&
57 return transposed_constraint_matrix_;
62 return constraint_matrix_sharder_;
66 return transposed_constraint_matrix_sharder_;
84 const Eigen::VectorXd& row_scaling_vec);
87 Eigen::VectorXd& variable_upper_bounds) {
93 Eigen::VectorXd& constraint_upper_bounds) {
115 Eigen::SparseMatrix<double, Eigen::ColMajor, int64_t>
116 transposed_constraint_matrix_;
117 std::unique_ptr<ThreadPool> thread_pool_;
118 Sharder constraint_matrix_sharder_;
119 Sharder transposed_constraint_matrix_sharder_;
ShardedQuadraticProgram(ShardedQuadraticProgram &&)=default
int64_t PrimalSize() const
const Sharder & ConstraintMatrixSharder() const
Returns a Sharder intended for the columns of the QP's constraint matrix.
void SwapConstraintBounds(Eigen::VectorXd &constraint_lower_bounds, Eigen::VectorXd &constraint_upper_bounds)
const QuadraticProgram & Qp() const
const Sharder & TransposedConstraintMatrixSharder() const
Returns a Sharder intended for the rows of the QP's constraint matrix.
void SwapVariableBounds(Eigen::VectorXd &variable_lower_bounds, Eigen::VectorXd &variable_upper_bounds)
const Eigen::SparseMatrix< double, Eigen::ColMajor, int64_t > & TransposedConstraintMatrix() const
Returns a reference to the transpose of the QP's constraint matrix.
ShardedQuadraticProgram(const ShardedQuadraticProgram &)=delete
Movable but not copyable.
void SetConstraintBounds(int64_t constraint_index, std::optional< double > lower_bound, std::optional< double > upper_bound)
ShardedQuadraticProgram & operator=(ShardedQuadraticProgram &&)=default
ShardedQuadraticProgram(QuadraticProgram qp, int num_threads, int num_shards, operations_research::SolverLogger *logger=nullptr)
const Sharder & DualSharder() const
Returns a Sharder intended for dual vectors.
ShardedQuadraticProgram & operator=(const ShardedQuadraticProgram &)=delete
void ReplaceLargeConstraintBoundsWithInfinity(double threshold)
void SwapObjectiveVector(Eigen::VectorXd &objective)
const Sharder & PrimalSharder() const
Returns a Sharder intended for primal vectors.
void RescaleQuadraticProgram(const Eigen::VectorXd &col_scaling_vec, const Eigen::VectorXd &row_scaling_vec)
Validation utilities for solvers.proto.
Eigen::VectorXd variable_lower_bounds
Eigen::VectorXd constraint_lower_bounds
Eigen::VectorXd objective_vector
Eigen::VectorXd variable_upper_bounds
Eigen::VectorXd constraint_upper_bounds