Go to the source code of this file.
|
ScsPrivWorkspace * | scs_init_priv (const ScsAMatrix *A, const ScsSettings *stgs) |
|
scs_int | scs_solve_lin_sys (const ScsAMatrix *A, const ScsSettings *stgs, ScsPrivWorkspace *p, scs_float *b, const scs_float *s, scs_int iter) |
|
void | scs_free_priv (ScsPrivWorkspace *p) |
|
void | scs_accum_by_a_trans (const ScsAMatrix *A, ScsPrivWorkspace *p, const scs_float *x, scs_float *y) |
|
void | scs_accum_by_a (const ScsAMatrix *A, ScsPrivWorkspace *p, const scs_float *x, scs_float *y) |
|
scs_int | scs_validate_linsys (const ScsAMatrix *A) |
|
char * | scs_get_linsys_method (const ScsAMatrix *A, const ScsSettings *stgs) |
|
char * | scs_get_linsys_summary (ScsPrivWorkspace *p, const ScsInfo *info) |
|
void | scs_normalize_a (ScsAMatrix *A, const ScsSettings *stgs, const ScsCone *k, ScsScaling *scal) |
|
void | scs_unnormalize_a (ScsAMatrix *A, const ScsSettings *stgs, const ScsScaling *scal) |
|
void | scs_free_a_matrix (ScsAMatrix *A) |
|
scs_int | scs_linsys_is_indirect (void) |
|
scs_int | scs_linsys_total_cg_iters (ScsPrivWorkspace *priv) |
|
scs_float | scs_linsys_total_solve_time_ms (ScsPrivWorkspace *priv) |
|
Stores the necessary private workspace, only the linear system solver interacts with this struct
Frees the memory allocated in ScsAMatrix.
Frees scs_linsys_priv_workspace structure and allocated memory in it.
Returns string describing method, can return null, if not null free will be called on output
Returns string containing summary information about linear system solves, can return null, if not null free will be called on output
initialize scs_linsys_priv_workspace structure and perform any necessary preprocessing
scs_int scs_linsys_is_indirect |
( |
void |
| ) |
|
Whether the solution of the linear system is based on an indirect method.
- Returns
1
if indirect, 0
otherwise
Total number of CG iterations if an indirect method is used, -1
otherwise
- Parameters
-
priv | private workspace structure |
- Returns
- total CG iterations
Returns the total solve time for the linear system (in ms
).
- Parameters
-
priv | private workspace structure |
- Returns
- solve time in
ms
normalizes A matrix, sets w->E
and w->D
diagonal scaling matrices,Anew = d->SCALE * (D^-1)*A*(E^-1)
(different to paper which is D*A*E
) D and E must be all positive entries, D must satisfy cone boundaries must set (w->meanNormRowA
= mean of norms of rows of normalized A) THEN scale resulting A
by d->SCALE
.
Solves [d->RHO_X * I A' ; A -I] x = b
for x
, stores result in b
, s
contains warm-start, iter
is current scs iteration count
- Parameters
-
A | sparse matrix A |
stgs | user-specified settings |
p | private structure |
b | right hand side |
s | initial guess |
iter | |
- Returns
- on success, returns 0
unnormalizes A
matrix, unnormalizes by w->D
and w->E
and d->SCALE
.
Returns negative num if input data is invalid