27 size_t m = work->
data->
m;
37 size_t n = work->
data->
n;
68 size_t m = work->
data->
m;
84 size_t n = work->
data->
n;
85 c_float norm_DinvQx, norm_Dinvq, norm_DinvAtyh, max_norm;
99 max_norm =
c_max(norm_DinvQx,
c_max(norm_Dinvq, norm_DinvAtyh));
112 size_t n = work->
data->
n;
113 size_t m = work->
data->
m;
126 if (eps_pinf_norm_Edy == 0) {
139 for(
size_t i=0; i < m; i++)
147 for(
size_t i=0; i < m; i++)
155 && (out_of_bounds <= -eps_pinf_norm_Edy);
160 c_float eps_dinf_norm_Ddx, dxQdx, dxdx;
161 size_t n = work->
data->
n;
162 size_t m = work->
data->
m;
176 if (eps_dinf_norm_Ddx == 0) {
184 for (k = 0; k < m; k++) {
191 for (k = 0; k < m; k++) {
#define QPALM_INFTY
infinity, used to indicate one-sided constraints
Custom memory allocation, print and utility functions, and data types for floats and ints.
ladel_int c_int
type for integer numbers
ladel_double c_float
type for floating point numbers
#define c_max(a, b)
maximum of two values
#define c_min(a, b)
minimum of two values
QPALM main solver routines.
c_float compute_objective(QPALMWorkspace *work)
Compute the (unscaled) primal objective value at the current iterate.
Linear algebra with vectors.
void vec_add_scaled(const c_float *a, const c_float *b, c_float *c, c_float sc, size_t n)
Scaled addition of one vector to another vector, .
void vec_self_mult_scalar(c_float *a, c_float sc, size_t n)
Mulitply vector with a constant scale factor.
void vec_ew_prod(const c_float *a, const c_float *b, c_float *c, size_t n)
Elementwise product, .
c_float vec_prod(const c_float *a, const c_float *b, size_t n)
Inner product between two vectors, .
void prea_vec_copy(const c_float *a, c_float *b, size_t n)
Copy vector a into preallocated vector b.
c_float vec_norm_inf(const c_float *a, size_t n)
Infinity norm of a vector, .
size_t m
number of constraints m
c_float * bmin
dense array for lower bounds (size m)
size_t n
number of variables n
c_float * q
dense array for linear part of cost function (size n)
c_float * bmax
dense array for upper bounds (size m)
c_float pri_res_norm
norm of primal residual
c_float dua2_res_norm
norm of intermediate dual residual (minus proximal term)
c_float objective
objective function value
c_float dua_res_norm
norm of dual residual
c_float * Dinv
primal variable rescaling
c_float c
objective scaling
c_float * E
dual variable scaling
c_float * Einv
dual variable rescaling
c_float cinv
objective rescaling
c_float * D
primal variable scaling
c_int proximal
boolean, use proximal method of multipliers or not
c_float eps_dual_inf
dual infeasibility tolerance
c_float eps_prim_inf
primal infeasibility tolerance
c_float eps_rel
relative convergence tolerance
c_int scaling
scaling iterations, if 0 then scaling is disabled
c_float eps_abs
absolute convergence tolerance
c_float * x
primal solution
c_float * delta_y
difference of consecutive dual iterates
c_float * x
primal iterate
c_float * yh
candidate dual update
QPALMScaling * scaling
scaling vectors
c_float eps_pri
primal tolerance
QPALMInfo * info
solver information
c_float * z
projection of Axys onto the constraint set [bmin, bmax]
c_float * temp_m
placeholder for vector of size m
QPALMSolution * solution
problem solution
c_float * pri_res
primal residual
c_float eps_dua
dual tolerance
c_float * x_prev
previous primal iterate
c_float * Adelta_x
A * delta_x.
c_float * delta_x
difference of consecutive primal iterates
c_float eps_rel_in
intermediate relative tolerance
QPALMSettings * settings
problem settings
c_float * x0
record of the primal iterate during the last dual update
c_float eps_dua_in
intermediate dual tolerance
c_float gamma
proximal penalty factor
c_float * dphi
gradient of the Lagrangian
c_float * Atdelta_y
A' * delta_y.
c_float * temp_2m
placeholder for vector of size 2m
c_float * Aty
A' * y (useful for saving one mat_tpose_vec)
c_float eps_abs_in
intermediate absolute tolerance
QPALMData * data
problem data to work on (possibly scaled)
c_float * temp_n
placeholder for vector of size n
c_float * d
primal update step
c_int is_primal_infeasible(QPALMWorkspace *work)
Check whether the problem is primal infeasible.
void calculate_residual_norms_and_tolerances(QPALMWorkspace *work)
Calls the routines that compute the norm of the residuals and the tolerances.
void store_solution(QPALMWorkspace *work)
Helper function to store the (unscaled) solution in the solution struct.
c_int is_solved(QPALMWorkspace *work)
Check whether the primal and dual residual norms are smaller than the primal and dual tolerances.
c_int is_dual_infeasible(QPALMWorkspace *work)
Check whether the problem is dual infeasible.
c_int check_subproblem_termination(QPALMWorkspace *work)
Check whether the subproblem is solved.
void calculate_primal_tolerance(QPALMWorkspace *work)
Calculates the primal tolerance and stores it in work->eps_pri.
void calculate_dual_tolerances(QPALMWorkspace *work)
Calculates the dual tolerance for the problem and current subproblem and stores them in work->eps_dua...
void calculate_dual_residuals(QPALMWorkspace *work)
Calculates the infinity norm of the dual residual and the residual of the subproblem and stores them ...
void calculate_primal_residual(QPALMWorkspace *work)
Calculates the infinity norm of the primal residual and stores it in work->info->pri_res_norm.
Routines to check the termination and infeasibility criteria.