Exploring gradient-based optimization methods on classic test functions without constraints
Comparing Gradient Descent vs Conjugate Gradient methods on different landscape types:
Understanding how different solvers handle constraints in real-world optimization problems
Optimization solvers can be categorized by their algorithmic approach and the order of derivative information they use. This landscape shows where popular solvers sit in this space:
Key Insight: ECOS (Interior Point) and OSQP (Active Set) represent fundamentally different philosophies for handling constraints during optimization.
"Never Touch the Boundary"
"Walk Along the Boundary"
We demonstrate the solver differences using a realistic quantitative finance problem: constructing a market-neutral portfolio that maximizes alpha while maintaining zero market exposure.
Notice the smooth objective function improvement and consistent constraint satisfaction
Observe the "dip and rise" objective pattern as constraints are prioritized differently
Direct comparison of constraint violation patterns and convergence behavior
Maintains strict feasibility throughout, smooth monotonic improvement, reaches stability earlier (~iteration 30)
Shows "dip and rise" objective pattern, larger constraint violations during exploration, longer convergence time
ECOS: simultaneous constraint satisfaction
OSQP: strategic constraint prioritization
Both reach nearly identical optimal portfolios, but via fundamentally different paths
The animations were generated using:
Each solver's path was simulated to reflect their actual algorithmic behavior, with ECOS maintaining barrier margins and OSQP implementing active set identification strategies.