Sostactic
polynomial inequalities using sums-of-squares in Lean
Details
- External ID
- 47820134
- Source
- HN
- Company
- —
- Product
- Sostactic
- Website domain
- github.com
- Launched
- April 18, 2026
- Cohort
- —
- Upvotes
- 14
- Upvotes percentile
- 0.6876606683804627
- Tags
- —
- Fetched at
- Sept. 7, 2026, 9:26 p.m.
- Updated at
- Sept. 7, 2026, 9:26 p.m.
Description
Current support for nonlinear inequalities in Lean is quite limited. This package attempts to solve this. It contains a collection of Lean4 tactics for proving polynomial inequalities via sum-of-squares (SOS) decompositions, powered by a Python backend. You can use it via Python or Lean.These tactics are significantly more powerful than `nlinarith` and `positivity` -- i.e., they can prove inequalities they cannot. In theory, they can be used to prove any of the following types of statements- prove that a polynomial is nonnegative globally - prove that a polynomial is nonnegative over a semialgebraic set (i.e., defined by a set of polynomial inequalities) - prove that a semialgebraic set is empty, i.e., that a system of polynomial inequalities is infeasibleThe underlying theory is based on the following observation: if a polynomial can be written as a sum of squares of other polynomials, then it is nonnegative everywhere. Theorems proving the existence of such decompositions were one of the landmark achievements of real algebraic geometry in the 20th century, and its connection to semidefinite programming in the 21st century made it a practical computational tool, and is what this software does in the background.
Enrichment
- Theme
- scientific computing and research algorithms
- Vertical
- Horizontal
- Function
- Dev tools
- Audience
- Developer
- AI stance
- Not AI
- Project type
- Hobby / open-source project
- Normalized one-liner
- polynomial inequality solver for lean
- Manually corrected
- False
Could you build this?
No Building formal verification tactics in Lean 4 based on real algebraic geometry and semidefinite programming (sum-of-squares decompositions) requires deep mathematical research and expertise in interactive theorem proving.
What it would actually take: Requires Lean 4 metaprogramming/tactic framework paired with a backend solver interface (e.g., Python with SymPy, Mosek/SCS for semidefinite programming). The hard problem is generating certifiable, exact rational arithmetic proofs inside Lean's proof kernel from numerical SDP solver outputs (positivstellensatz certificates). This demands specialized expertise in automated deduction, formal logic, and convex optimization.
Discussion
1 comment analyzed.
Competitors
Other products that read as similar to this one — 41 launches clear the similarity bar, closest 8 shown.
Attention rank: #15 of 42 (itself plus its competitors, highest first — normalized so YC and Product Hunt are compared fairly).
Launched 110 days after the earliest competitor.
- Compute polynomials twice as fast · hn · 2026-09-09 · 137 upvotes · similarity 0.44
- ConZF · github · 2026-09-18 · 17 upvotes · similarity 0.43
- Lean4 proof that SSOT requires definition-time hooks and introspection · hn · 2026-01-08 · 10 upvotes · similarity 0.43
- spivak-lean · github · 2026-09-26 · 42 upvotes · similarity 0.42
- Spivak's Calculus formalized in Lean 4 · hn · 2026-09-26 · 22 upvotes · similarity 0.42
- I made a calculator that works over disjoint sets of intervals · hn · 2026-04-18 · 314 upvotes · similarity 0.42
- PoincareConjecture · github · 2026-09-28 · 12 upvotes · similarity 0.40
- The A-C Coupling Theorem · hn · 2026-06-13 · 5 upvotes · similarity 0.39
Other launches for this product
- No other launches for this product.
Same idea, different domain
Nobody's really built a dev tools tool for Sales yet.