nx_inst_gen.nx
buildroot/runtime/nx_inst_gen.nx
about
nx_inst_gen.nx -- instance generation (Inst-Gen).
Per Vampire-displacement roadmap Phase 2. Korovin + Voronkov 2003
alternative to resolution: instead of resolving complementary
literals away (producing a single resolvent), INSTANTIATE both
clauses with the unifier (producing two more-specific clauses).
The downstream SAT-coupled prover (iProver, Vampire+SAT) then
works on ground instances to prove UNSAT. Inst-Gen excels at
problems with large finite Herbrand universes where resolution
blows up but ground reasoning succeeds.
Standard formulation:
C ∨ L D ∨ ¬L' σ = mgu(L, L')
----------------------
(C ∨ L)σ (D ∨ ¬L')σ
Both resulting clauses keep their full literal sets -- σ just
makes them more specific. No literals are removed. This is the
crucial difference from resolution.
API:
nx_inst_gen(c1, i, c2, j, c1_out, c2_out) -> *NxResult
Caller allocates c1_out + c2_out; primitive populates both with
the σ-applied versions.
dependencies 6 imports · 1 importers
imports: nx_syscalls.nxnx_runtime.nxnx_tier.nxnx_result.nxnx_unify.nxnx_resolution.nx
imported by: nx_inst_gen_test.nx
structs
| none |
consts
| none |
functions
| 43 | func nx_inst_apply_clause(c: *Clause, sigma: *Subst, out: *Clause) -> *NxResult called by 1: nx_inst_gen calls 5: nx_clause_lit_atnx_lit_apply_substnx_clause_addnx_result_is_errnx_result_ok |
| 62 | func nx_inst_gen(c1: *Clause, i: nx_int, called by 1: main calls 7: nx_result_errnx_clause_lit_atnx_subst_newnx_unifynx_result_is_errnx_inst_apply_clause+1 |