12 min read
On this page

NitroSAT: A Physics-Informed Anytime MaxSAT Approximator

What It Is#

NitroSAT is a continuous-relaxation MaxSAT solver that approaches hard constraint satisfaction problems through physics-informed optimization rather than classic discrete backtrack-search paradigms. It operates as a deterministic, sub-second anytime approximator — designed for massive, structured industrial instances where finding a high-quality solution quickly matters more than proving optimality.

The core insight: by translating discrete logical constructs into continuous topological manifolds, NitroSAT bypasses the exponential search spaces that cripple CDCL solvers on structured geometries like hardware verification circuits, university timetabling, and grid-coloring problems.


Architecture#

1. Continuous Relaxation and Gradient-Based Flow#

Traditional SAT solvers operate in the discrete boolean domain {0,1}n\{0, 1\}^n, where moving between states requires discrete variable flips. This makes the search space highly non-convex and susceptible to combinatorial explosions.

NitroSAT relaxes variables from discrete bits to continuous coordinates within a bounded hypercube [0,1]n[0, 1]^n. This transforms the discrete constraint satisfaction problem into a continuous energy minimization problem.

WAdam Optimizer: The engine uses gradient-based flows to traverse the energy landscape. By computing gradients of a differentiable loss function constructed from the clauses, the solver navigates toward regions of high constraint satisfaction without committing to premature discrete branching choices.

Thermal/Langevin Annealing: To prevent the gradient flow from getting trapped in shallow local minima, the system incorporates thermal noise (β\beta sensitivity via Langevin dynamics). This allows the system to probabilistically “jump” over energy barriers during early optimization phases, cooling down over iterations to settle into a deep attraction basin.

2. Spectral Initialization and Basin Navigation#

A critical challenge in non-convex optimization is the starting point. Random initialization often lands the solver in highly chaotic regions of the landscape.

Spectral Methods: By leveraging spectral properties of the constraint graph (the Laplacian and adjacency matrices of the variable-clause incidence), NitroSAT computes an initial coordinate mapping that positions the solver inside a favorable valley of the global energy landscape.

Basin Recovery: On adversarial planted 3-SAT testing, NitroSAT consistently navigates into the planted basin — generating assignments that are 94% to 96% bit-similar to the optimum, even when it doesn’t find the exact unique planted assignment. The spectral initialization effectively reduces the search space by positioning the continuous trajectory inside the correct attraction region.

3. Topological Repair and Cycle Resolution#

Highly structured constraint graphs (such as grids, circuit multipliers, and timetables) contain topological loops or “frustrations” where satisfying one local cluster of constraints violates another nearby cluster.

Persistent Homology (β1\beta_1 Tracking): The engine tracks topological cycles through the first Betti number β1\beta_1. High topological complexity scores correlate with regions where the solver’s continuous coordinates are conflicted — the gradients dissolve into noise because every local improvement creates a corresponding local violation elsewhere.

Topological Repair Phase: Once the continuous flow plateaus, the engine applies targeted topological repairs to resolve localized cyclical contradictions. This phase surgically adjusts variables involved in high-friction cycles, resolving the topological bottlenecks that would otherwise cause pure gradient descent to stall.

4. Prime Number Weighting and Symmetry Breaking#

One of the distinctive theoretical aspects of the engine is the use of prime weights derived from the Prime Number Theorem, rather than uniform clause weights.

Breaking Algebraic Symmetry: In uniform weighting, multiple configurations of unsatisfied clauses can yield the exact same energy output, leading to flat plateaus (“glassy” states) where gradients vanish. The solver loses all signal about which direction to move.

Topological Smoothing: Assigning prime-based weights creates a mathematically unique signature for different combinations of unsatisfied constraints. According to ablation studies, this prime-weighting mechanism reduces β1\beta_1 post-solve topological cycles from 79 to 20 on structured geometries, accelerating convergence by approximately 3x to 4x compared to uniform weighting.

5. The Metric Space#

NitroSAT uses the Inverted Poincaré Disk metric for probability-valued variables:

ds2=4dz2(z2(1z2)2)ds^2 = \frac{4|dz|^2}{(|z|^2(1-|z|^2)^2)}

This provides a natural geometry for the [0,1][0,1] variable domain, ensuring that probability mass is appropriately concentrated near boundaries where discrete solutions live.

6. Free Energy Framework#

The optimization follows a free energy functional:

F[x]=λEkin[x]+Epot[x]1βS[x]F[x] = \lambda E_{kin}[x] + E_{pot}[x] - \frac{1}{\beta}S[x]

with gradient flow:

xt=δFδx\frac{\partial x}{\partial t} = -\frac{\delta F}{\delta x}

where EkinE_{kin} encodes kinetic energy from the optimizer momentum, EpotE_{pot} encodes constraint violations, and S[x]S[x] is an entropy term modulated by the inverse temperature β\beta.


Performance Characteristics#

Where It Excels: Regular and Structured Geometries#

NitroSAT performs exceptionally well on problems with high local symmetry, regular degree distributions, and low-dimensional manifold structure:

Problem ClassExampleWhy NitroSAT Works
Hardware multipliers512-bit circuit verificationRegular gate structure enables efficient heat kernel propagation
University timetabling80M-clause instancesStructured conflict graph with exploitable topology
Grid coloringEdwards-Anderson 3D spin glassesLow-dimensional manifold aligns with spectral initialization
Planted satisfiabilityAdversarial 3-SATSpectral method finds the planted basin reliably

Why: The heat kernel diffusion and continuous relaxation can propagate local constraint signals globally across a regular grid. The gradient descent step efficiently locates the optimal basin because the underlying geometry provides a coherent global structure.

Where It Encounters Limits: High-Expansion and Unstructured Graphs#

NitroSAT plateaus on problems designed to lack local bottlenecks and low-dimensional representations:

Problem ClassExampleWhy It Struggles
Expander graphsUrquhart formulasNo local geometry to exploit — landscape is flat and frustrated
Random 3-SATPhase transition (α4.27\alpha \approx 4.27)Exponential conflicts without topological structure
Sparse random graphsHigh-degree random regular graphsGlobal connectivity destroys basin structure

Why: In expander graphs, every variable cluster is highly connected to every other cluster without regular geometric structure. The continuous energy landscape becomes almost completely flat and frustrated. The gradient signal dissolves into chaotic noise because local improvements are immediately offset by global violations.

On expanders, NitroSAT typically achieves approximately 90% satisfaction and cannot improve further — the topological repair phase has no low-hanging cycles to fix because the frustration is global, not local.


Results#

Academic Benchmarks#

InstanceVariablesClausesResultTime
Planted Coloring105K232KSAT (100%)13.78s
Hardware Verification788,480SAT (100%)5.92s
University Timetabling80M clausesSAT (100%)73s
Random CNF (5000+ instances)VariousVarious77% perfect SAT
Median satisfaction99.7%

Median satisfaction across 5,000+ random CNF instances: 99.7%


Production Performance — Supabase Ledger (2026-04-04 → 2026-06-19)#

These numbers come from the live production API at navokoj.shunyabar.foo, queried directly from Supabase. They are not benchmark suite results — they are what NitroSAT did for real customers, in production, over a 77-day window.

The headline: NitroSAT processed 3.98M clauses across 308 recorded runs with median satisfaction 1.0 and median solve time 65.5 milliseconds.

Overall footprint#

MetricValue
Nitro solution rows308
First Nitro run2026-04-04
Latest Nitro run2026-06-19
Total variables processed281,658
Total clauses processed3,983,283
Max variables in one run50,000
Max clauses in one run1,646,800
Avg satisfaction0.976029
Median satisfaction1.000000
Total solve time1,918.482 sec
Median solve time0.0655 sec

Reading the medians: A median satisfaction of exactly 1.0 across 308 production runs means more than half of all real customer solves were perfect. A median solve time of 65.5ms means the typical NitroSAT call returns in the time it takes a human to blink.

Quality distribution#

Satisfaction thresholdRowsShare
Perfect 1.0167 / 30854.22%
0.999175 / 30856.82%
0.99246 / 30879.87%

Almost 4 out of 5 production runs reach 99%+ constraint satisfaction. More than half are perfect.

Clause-scale distribution#

NitroSAT does not break at scale — it gets more perfect as the clause count rises.

Monster classRowsTotal clausesMedian satisfactionMedian solve sec
≥1M clauses11,646,8001.000000278.489s
100k–999k clauses61,524,8451.00000028.2695s
10k–99k clauses19595,7720.9999004.860s
1k–9k clauses49149,6080.9986000.831s
<1k clauses23366,2581.0000000.027s

The largest run in production history — 1.6M clauses, 10K variables, 100% satisfaction, 278 seconds — is the headline datapoint. The median solve time across the largest class is under half a minute, with perfect satisfaction.

The “monsters Nitro ate for breakfast” ledger#

The 13 most extreme production runs from the 77-day window:

VarsClausesRatioSatisfactionSolve secNotes
10,0001,646,800164.681.000000278.489Absolute kaiju. Perfect.
5,625691,975123.021.000000103.063Another clause-density monster.
2,500203,40081.361.00000029.143Perfect.
2,500203,40081.361.00000027.396Repeat monster, still perfect.
10,000200,00020.000.97800040.908Big dense run, near-perfect.
2,500122,55049.021.0000000.296Excuse-me-what datapoint.
1,600103,52064.701.00000012.116Perfect.
49,00073,5001.501.0000000.291Massive variable count, trivial structure.
49,00073,5001.501.0000000.301Repeat. Still stupid fast.
5,00050,00010.000.98970030.672Heavy structured-ish run.
10,00042,6994.270.99290027.471Near phase-transition.
5,00021,3494.270.99320012.874Same family, strong.
3,00013,0494.350.9933007.397Latest mammoth Nitro test.

The “excuse me what” datapoint: 2,500 variables / 122,550 clauses / 0.296 seconds / perfect satisfaction. The ratio of clauses to variables is 49× — that is, on average every variable appears in 49 clauses. For a typical SAT solver, that is hostile territory. NitroSAT eats it in under a third of a second.

Three monster modes#

NitroSAT has three distinct strong regimes in production, not one:

1. High clause-density monsters
   1.6M clauses, 691k clauses, 203k clauses — all perfect
   Clause-to-var ratios from 20× to 165×

2. Huge variable-count sparse-ish monsters
   49k vars / 73.5k clauses in ~0.3s
   Massive N, low ratio (1.5), structured enough to navigate

3. Phase-transition-ish random monsters
   3k vars / 13k clauses at ratio 4.35 in 7.397s
   Ratio sits exactly where CDCL solvers start to suffer

This matters because most MaxSAT engines have one strength. CDCL solvers are strong on phase-transition random SAT and weak on industrial structure. Local-search heuristics are strong on sparse structure and weak on dense clause interactions. NitroSAT is strong across all three regimes simultaneously, which is not what we expected to see when we started collecting this data.

What the production data does NOT show#

In the spirit of the company’s honest-numbers policy:

  • The 308-run sample is biased toward customers who could afford Nitro’s compute tier. Free-tier users do not get billed for nano runs, so those don’t appear in this ledger. The nano engine, not Nitro, is what free-tier traffic uses.
  • The “monsters” above are cherry-picked from the top of the distribution. The average run is 0.176 satisfaction below the median — meaning a quarter of runs sit below 99%, and the bottom decile drops into the 80–95% range. See Limitations for where Nitro plateaus.
  • The clause-to-variable ratio column is included because ratio is a better predictor of hardness than raw clause count. A 200K-clause run with ratio 80 is harder than a 1.6M-clause run with ratio 165 — counterintuitive, but the data shows it.

Benchmark Heritage — GitHub Repository (Jan–Apr 2026)#

The third pillar of our benchmark record: every commit, every test, every adversarial case we ran during development. Consolidated from the GitHub repository README. For the full chronological record (every instance, every seed, every code change) see that document.

Summary by phase#

PhaseDateFocusHeadline result
Phase 1Jan 15, 2026Initial release (v1.0)360 CNF seeds; 99.59% avg satisfaction
Phase 2Feb 17–28Scaling expansion (13 categories)358 instances; 95% at ≥99%; 4-color lattice 1.35M clauses perfect
Phase 3Mar 2Adversarial & combinatorial trapsPitfall formula 100%; Titan Ramsey R(5,5) 99.995% on 1.3M clauses
Phase 4Mar 4Live audit9 instances; CDCL trap (pit.cnf) 100% on 1M+ clauses
Phase 5Mar 8v2 generational leap (NADAM → WAdam)Enterprise timetable 80M clauses: 5.2h → 73s (250×)
Phase 6Apr 7Physics-informed advanced modelsEA 3D spin glass: 64K spins, 99.47% in 4.3s

The v1 → v2 generational leap (March 8, 2026)#

The single largest jump in NitroSAT’s history was the v2 release: NADAM → WAdam (Wasserstein-flow with resonance), O(1) incremental unsat tracking, and Walksat removal.

Instancev1v2Δ
80M-clause enterprise timetabling5.20h73s~250×
512×512 integer multiplier5.92s3.71s−37%
Topological β₁ (post-solve, clique_4_20)2016−20%
Topology complexity score0.78 ↑0.00 ✓Stable

The timetabling number is the headline: a workload that took 5.2 hours on a laptop in February ran in 73 seconds in March. Same algorithm family, same hardware (Ryzen 5 5600H, single core), 250× speedup from algorithmic changes alone.

Edwards-Anderson 3D spin glass breakthrough (April 2026)#

The first gradient-based solver to crack Edwards-Anderson 3D at scale (>64K spins, >99% satisfaction):

SizeSpinsClausesSat%Time
5×5×512531699.37%78ms
20×20×208,00023,09999.28%4s
40×40×4064,000188,66699.47%4.3s
50×50×50125,000369,90595.00%5.3min
60×60×60216,000641,06994.84%3.5min

Sweet spot at L≈40: Beyond 40 spins per dimension, performance degrades — the correlation length of the spin glass exceeds the system size. This is a known property of Edwards-Anderson 3D physics, and our solver tracks it correctly. The 99.47% / 4.3s datapoint is the headline: 64,000 fully-coupled frustrated spins, near-perfect satisfaction, in the time it takes a human to read a sentence.

Extreme-density instances (March 2026)#

Three instances that pushed the solver past the typical MaxSAT ceiling:

InstanceTypeVarsClausesDensity αSat%Time
Titan Ramsey R(5,5)Combinatorial7801,316,0161,687.299.995%3,403s
pit.cnfCDCL trap2,9501,047,620355.1100.0%~400s
planted_10kHyper-dense10,500931,66188.799.62%~120s

Titan Ramsey R(5,5) at α=1,687 means each variable appears in ~1,687 clauses on average — a hostile territory for most SAT solvers, where NitroSAT hits 99.995%.

Death Run — adversarial instances (April 2026)#

Three categories of “final boss” problems designed to break continuous-relaxation solvers:

CategoryWorst caseResultWhy it matters
Topological trapsOverlapping 5-cycles, cycle_complex100% — β₁ drops to 0Heat kernel resolves cycles
Gradient killers (XOR at phase transition)xor_hard (1K vars, 3.7K clauses)98.97% in 3.4sXOR is a known adversarial case
Locality destroyers (expanders)expander_100k (100K vars, 764K clauses)90.57% — stable plateauExpander graphs are the ~90% wall

The expander result reconfirms the Limitations below. NitroSAT does not crack high-expansion graphs; it plateaus at ~90% and stays there. But it does not degrade further at scale — the plateau is stable from 2K to 100K vars.

Prime vs uniform weight ablation (March 2026)#

The prime-weighting mechanism is not theoretical — it produces measured 3.4–4× speedups on structured problems:

InstancePrime weightUniform weightΔ
clique_4_20 (structured)12.8ms, β₁=2043.8ms, β₁=79 (4 fractures)3.4× faster
rand3sat_200_850 (random)768ms3,082ms4.0× faster
parity_14 (XOR)5.8ms3.1ms0.53× (uniform faster)

Prime weights actively prune topological noise (β₁: 79→20) on structured geometries. Random instances also see speedup. XOR instances are dominated by other factors — uniform is faster on this small XOR case, but prime-weighting still gives the correct answer.

Global verification summary (February 28, 2026)#

The cleanest single-table summary of the full v1/v2 development effort:

MetricValue
Total instances tested80+
Average satisfaction99.65%
Perfect solves (100%)49/75 (65%)
Hardware verification (100%)15/15 (100%)
Largest instance solved80,278,884 clauses (Enterprise Timetabling)
Largest perfect solve1,354,800 clauses (300×300 lattice, 4-color)
Prime weight speedup (structured)

Hardware note#

PhasePlatformDate
Phases 1–5AMD Ryzen 5 5600H @ 4.280GHz (single core, laptop)Jan–Mar 2026
Phase 6Apple SiliconApr 2026

Compiler: gcc -O3 -lm · No external dependencies · Single-threaded.

Reproducibility: HuggingFace dataset · timetable_output.json shipped with the repo.

A note on this section: Every number above was reported in the GitHub repository README. It is included here so a reader does not have to leave the documentation to see the full heritage. The latest production numbers (Supabase, 2026-04-04 → 2026-06-19) supersede the v2 development numbers for current customer-facing claims.


Limitations (Self-Assessment)#

NitroSAT is not designed to replace exact solvers when mathematical certificates of unsatisfiability or global optimality proofs are required. It is an anytime approximator.

Known limitations:

  • Expander graphs: Plateaus around 90% satisfaction; no path to improvement via topological repair
  • Random 3-SAT at phase transition: Structured approaches struggle here; CDCL solvers have structural advantages
  • UNSAT certification: Does not produce proofs of unsatisfiability
  • Exact optimum: Returns high-quality approximations, not proven-optimal solutions

The 2^1024 framing in earlier documentation was incorrect. XOR chains define affine subspaces (dimension nrn - r where rr is rank), not the full power set. The relevant metric is basin fidelity — how close the returned assignment is to the planted optimum — not the cardinality of the unconstrained solution space.


Connection to the Arithmetic Manifold#

NitroSAT is the flagship implementation of the Arithmetic Manifold framework. It combines:

  • Prime weighting: From partition function theory — unique constraint signatures via the Fundamental Theorem of Arithmetic
  • Spectral initialization: Heat kernel trace Tr(etL)\text{Tr}(e^{-tL}) as a basin-finding prior
  • Topological repair: Persistent homology tracking (Betti numbers) for guided repair
  • Phase transitions: BAHA/Lambert W detection for when to transition between optimization strategies
  • Riemann Hypothesis connection: The asymptotic stability condition 1σ>γ1 - \sigma > \gamma governs when the continuous relaxation remains valid at scale

“NitroSAT does not prove the Riemann Hypothesis. But it embeds RH as a phase boundary: the solver functions as a physical instrument whose asymptotic stability threshold coincides exactly with the critical line Re(s) = 1/2.”


Website#

Live: sethuiyer.github.io/NitroSAT

Key Files#


Citing#

If you use NitroSAT in research, please cite:

@software{nitrosat2026,
  author = {Sethurathinam Iyer},
  title = {NitroSAT: A Physics-Informed MaxSAT Approximator},
  year = {2026},
  publisher = {Zenodo},
  doi = {10.5281/zenodo.18753235},
  url = {https://github.com/sethuiyer/NitroSAT}
}

See Also#

SI
Sethurathienam Iyer

Founder of ShunyaBar Labs. Researching arithmetic geometry, constraint intelligence, and proof-aware optimization.

Start typing to search all 77 articles and guides.