Architecture and Method Guide¶
The current codebase supports multiple constrained polynomial optimization pathways. Historically, the documentation emphasized SDP hierarchies. The present structure extends this to include geometric and SONC methods on the same algebraic backbone.
From Polynomial Expressions to Group-Rings¶
Instead of treating input only as classical polynomial expressions, Irene builds optimization models through commutative semigroups and their semigroup algebras. This representation supports:
Symbolic manipulation of monomial support and exponents.
Geometric operations on Newton polytopes.
Differential operators through user-provided derivation maps.
The shift in perspective is important: instead of viewing optimization only as operations in \(\mathbb{R}[x_1,\dots,x_n]\), Irene treats expressions as elements of a semigroup algebra that can be converted to geometric data (supports, exponent tuples, convex combinations) used directly in GP and SONC routines.
Module Layers¶
The codebase is organized into six abstraction layers, each with clear boundaries:
Symbolic Engine:
symbolic_engine.py— SymEngine primary / SymPy fallback router for all polynomial operations (expand, Gröbner basis, Poly API, matrix construction).Algebra layer:
grouprings.py— commutative semigroups, semigroup algebras, and derivation operators.Problem layer:
program.py— optimization problem definition with objective and constraint management.Relaxation layer:
relaxations.py(SDP hierarchy),geometric.py(GP relaxations),sonc.py(SONC circuit polynomials),sosonc.py(SOS+SONC combined bounds). Unified access viarelaxation_api.py(RelaxationEngine+compare_all()).Structural optimization:
border_basis.py(border basis for quotient algebras),sparsity.py(correlative sparsity detection),newton_polytope.py(Newton polytope pruning of monomial bases).Solver layer:
sdp.py(native SDP solver interface),cvxpy_solver.py(CVXPY DCP layer bridging to CLARABEL/SCS/CVXOPT backends),dsdp.py(DSDP mean relaxation with SymEngine bridge).Tooling:
telemetry.py(timing/decoration utilities),matrices.py(moment/localizing matrix construction),invariant.py(group-invariant polynomial optimization).
Choosing a Relaxation Family¶
Use SDP relaxations when you need a moment/SOS hierarchy and semidefinite certificates. Use geometric relaxations when the transformed formulation is naturally handled by GP. Use SONC relaxations for sparse circuit-structured formulations in constrained settings.
|
|---|
|
|
|
Typical Workflow¶
Define algebra generators and build expressions in a semigroup algebra.
Form an optimization problem with objective and constraints.
Select relaxation family (SDP, GP, or SONC).
Solve and interpret a certified lower bound.