Skip to content

QingtanZeng/CvxSolverImpl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Overview

The repo serves the following three development objectives:

  1. implementation of conic optimization algorithms at principle level;
  2. test open-source convex solvers' interface and performance in Julia and C/C++;
  3. customized solvers based on open-source projects, for embedded system (CPU + Parallel acceleration).

Based on solvers' classification in three dimensions,

{First-Order, Second-Order} x {IPM, Exterior Point Method(Penalty)} x {Primal, Primal-dual},

only the three types of solvers and corresponding projects are focused, for real-time trajectory generation's OCP on embedded system:

  1. Homogeneous Self-dual Embedding(HSDE) IPM for Linear SOCP : ECOS
  2. Homogeneous Embedding(HE) IPM for Quadratic SOCP: Clarabel
  3. HE Douglas-Rachford Splitting(DRS) for Quadratic SOCP: SCS
    and a similar variant, Proportional-integral projected gradient method (PIPG)

HE DRS is preferred for real-time platform, due to the advantages:

  1. Infeasibility Certification concurrent with convergence, by Homogeneous Embedding;
  2. Converges rapidly to local modest precision solution, by first-order splitting iteration;
  3. Low computational load of single iteration, by conical projection and fixed LDLT decomposition,
    compared to updated decomposition of each iteration in IPM's newton direction;
  4. Warm-start, beneficial for MPC.

An Implementation of Douglas-Rachford Splitting(DRS) for Quadratic SOCP

An example:

image

The optimal solution is clearly x₁=1, x₂=1, and cost=2.

The convergence process is shown below, where O(1/k) sublinear convergence rate is obvious that gap, percent of equality error, percent of primal-dual variables' change is linear in the logarithmic coordinate.
Therefore converge rapidly to modest precision solution with <3% error, which is acceptable under most real-time trajectory generation cases. Feasibility is far more important than optimality and high precision, especially requiring >10Hz updates to deal with constantly changing environment, sudden disturbance, or MPC tasks.

Convergence of DRS for Quadratic SOCP

About

test and customized conic solvers for embeded system

Resources

Stars

Watchers

Forks