QPALM
A proximal augmented Lagrangian method for QPs.
Functions
linesearch.h File Reference

Routines to perform exact linesearch. More...

#include "types.h"
#include "constants.h"

Go to the source code of this file.

Functions

c_float exact_linesearch (QPALMWorkspace *work, solver_common *c)
 Execute exact linesearch (using qsort) More...
 
void vec_array_copy (c_float *a, array_element *b, size_t n)
 Helper function to copy vector a in array b (with indices) More...
 
void select_subsequence (const array_element *a, array_element *b, const c_int *L, size_t n)
 Select subsequence based on a set of indices, $b = a(L)$. More...
 
c_float vec_prod_ind (const c_float *a, const c_float *b, const c_int *L, size_t n)
 Inner product over index set, $a(L)^T\cdot b(L)$. More...
 
int compare (const void *a, const void *b)
 Helper function for qsort. More...
 

Detailed Description

Routines to perform exact linesearch.

Author
Ben Hermans

Once the direction is found using the semismooth Newton method, the functions in this file can be called to calculate a stepsize with exact linesearch.

Function Documentation

◆ compare()

int compare ( const void *  a,
const void *  b 
)

Helper function for qsort.

Carries out comparison between two array_elements

Parameters
aPointer to array element
bPointer to array element
Returns
a.x > b.x

◆ exact_linesearch()

c_float exact_linesearch ( QPALMWorkspace work,
solver_common c 
)

Execute exact linesearch (using qsort)

Parameters
workWorkspace
cLinear systems solver environment
Returns
tau Step size

◆ select_subsequence()

void select_subsequence ( const array_element a,
array_element b,
const c_int L,
size_t  n 
)

Select subsequence based on a set of indices, $b = a(L)$.

Parameters
aInput array
bOutpur array
LIndex set
nLength of a

◆ vec_array_copy()

void vec_array_copy ( c_float a,
array_element b,
size_t  n 
)

Helper function to copy vector a in array b (with indices)

Parameters
aVector
bArray (vector with added indices)
nVector length

◆ vec_prod_ind()

c_float vec_prod_ind ( const c_float a,
const c_float b,
const c_int L,
size_t  n 
)

Inner product over index set, $a(L)^T\cdot b(L)$.

Parameters
aVector
bVector
LIndex set
nVector length