code wiki / (root) / nx_discount_test.nx

nx_discount_test.nx

buildroot/runtime/nx_discount_test.nx

5291 B116 linesdepth 8pulls 11 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_discount_test.nx -- discount-loop saturation strategy smoke. Verifies: (a) discount loop derives the empty clause (UNSAT) on the classic test, (b) discount prunes more clauses than Otter on the same input, (c) tautological inputs are dropped.

dependencies 9 imports · 0 importers

nx_syscalls.nx nx_runtime.nx nx_tier.nx nx_result.nx nx_unify.nx nx_resolution.nx nx_subsumption.nx nx_tautology.nx nx_saturation.nx nx_discount_test.nx

imports: nx_syscalls.nxnx_runtime.nxnx_tier.nxnx_result.nxnx_unify.nxnx_resolution.nxnx_subsumption.nxnx_tautology.nxnx_saturation.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main println sys_write strlen sys_mmap nx_clause_new sys_mmap ↻ nx_clause_add nx_result_err sys_mmap ↻ nx_clause_lit_at nx_result_ok sys_mmap ↻ nx_lit_make sys_mmap ↻ mk_p sys_mmap ↻ nx_term_app sys_mmap ↻ nx_saturation_new sys_mmap ↻ nx_dt_new sys_mmap ↻ nx_dt_node_new sys_mmap ↻ nx_sat_add_unproc nx_result_err ↻ nx_sat_unproc_at nx_result_ok ↻ nx_sat_run_discount nx_sat_pick_given nx_sat_unproc_at ↻ nx_is_tautology nx_clause_lit_at ↻ nx_lit_is_reflexive_eq nx_term_arg nx_term_eq nx_term_eq ↻ nx_term_arg ↻ nx_term_eq ↻

structs

none

consts

17const SYM_A: nx_int = 100
18const SYM_P: nx_int = 200
19const SYM_Q: nx_int = 201
20const SYM_EQ: nx_int = 50

functions

22func mk_p(p_sym: nx_int, c_sym: nx_int) -> *Term
called by 1: main calls 2: sys_mmapnx_term_app
28func main() -> nx_exit