[][src]Function osqp_sys::osqp_update_P

pub unsafe extern "C" fn osqp_update_P(
    work: *mut OSQPWorkspace,
    Px_new: *const osqp_float,
    Px_new_idx: *const osqp_int,
    P_new_n: osqp_int
) -> osqp_int

Update elements of matrix P (upper triangular) without changing sparsity structure.

If Px_new_idx is OSQP_NULL, Px_new is assumed to be as long as P->x and the whole P->x is replaced.

@param work Workspace structure @param Px_new Vector of new elements in P->x (upper triangular) @param Px_new_idx Index mapping new elements to positions in P->x @param P_new_n Number of new elements to be changed @return output flag: 0: OK 1: P_new_n > nnzP <0: error in the update