Equality Constraints: Hard Versus Elastic
If equality terms correspond to softer tasks that may be relaxed in the case of inconsistency, ElastiQP supports elastic equalities through pairs of opposing elastic inequality constraints, with corresponding penalty terms.
Elastic equalities are represented by two opposing inequalities that can be violated at a penalized cost.
In general, this structure should be reserved only for cases where equalities may be soft, due to the additional cost imposed by adding two inequalities for every equality.
Evaluation
For comparison, ElastiQP was evaluated against three leading solvers for the small, dense problem setting: DAQP, PIQP, and ProxQP, as well as qpax, which implements an efficient condensed elastic mode similar to ElastiQP.
Additionally, to properly evaluate which family of solvers is best suited to elastic robot control problems, ElastiQP’s active-set method was compared against elastic PDAL and IPM variants. These variants are detailed further in the appendix.
All results were recorded on a laptop with an Intel Core Ultra 7 258V CPU. C++ solvers were compiled with GCC 13.3 and -O3 optimization. Compiling with -march=native tends to provide an additional performance gain on larger-scale problems, so the reported numbers are conservative.
The reported performance gain from -march=native is not specified in the provided text.
qpax is a purely JAX/Python library. Its values reflect JIT-compiled CPU performance using a recent JAX version, 0.11.0, with double precision.
Feasible Control Loops
ElastiQP demonstrates extremely fast, microsecond-level performance on both feasible and infeasible domains, with even cold-started solves on the hardest infeasible problems, hum-wbc, remaining comfortably below the 1 ms target required for 1 kHz control.
Warm-starting reliably delivers an additional 2–4× performance improvement on larger-scale problems, making ElastiQP the most reliable, always-feasible method for delivering high-frequency solves on challenging control problems.
In the strictly feasible setting, DAQP is the fastest method for solving these problems, with ElastiQP following closely behind. Active-set methods such as DAQP and ElastiQP perform very strongly in this setting on both cold and warm starts: relatively few constraints are active at the optimum, enabling fast cold starts, and the active set is relatively stable across timesteps, enabling fast warm starts.
The additional handling required for elasticity costs only a few microseconds at these problem scales, an acceptable trade-off for the reliability of an always-feasible method. The PDAL variants, ProxQP and ElastiQP-PDAL, also exhibit good warm-started performance but fall behind the active-set variants, particularly on smaller-scale problems.
Compared with the expanded slack form of DAQP, ElastiQP’s condensation provides an improvement of over 40×. For ElastiQP’s PDAL and IPM variants, condensation improves performance by 10× and 20×, respectively. This gap increases to over 250× for cold-started PDAL.
ElastiQP is also 30–80× faster than qpax, the main elastic-condensed baseline.
Infeasible Control Loops
In the infeasible setting, ElastiQP dramatically outperforms all alternative solvers and strategies for posing the relaxed problem.
As expected, standard hard-constrained solvers—DAQP, PIQP, ProxQP, and qpax’s hard form—fail to solve an infeasible problem. Reporting infeasibility can sometimes take a dangerously long time.
Consider a warm-started controller using ProxQP: if even a single timestep is momentarily infeasible, it could take upwards of 93 milliseconds to report infeasibility and manage the situation, compared with the nominal 1 millisecond budget.
The second-best solver to ElastiQP in this setting is ProxQP’s sparse backend, solving the expanded slack form, but only when warm-started. Even then, this method is not fast enough for reliable 1 kHz control on humanoid-scale problems and is around 20–40× slower than ElastiQP.
The other alternatives, ProxQP-slack and PIQP-slack, fall further behind in speed.
Frequently Asked Questions
What is ElastiQP? ElastiQP is an always-feasible quadratic programming solver for constrained robot control.
How does ElastiQP handle soft equality constraints? It represents elastic equalities using pairs of opposing elastic inequality constraints with corresponding penalty terms.
How does warm-starting affect ElastiQP’s performance? Warm-starting provides an additional 2–4× performance improvement on larger-scale problems.
Why is ElastiQP useful for infeasible control problems? It maintains fast, feasible control solves when hard-constrained alternatives fail or take too long to report infeasibility.
