is_lp_derivation
A Lift & Project (L&P) derivation from a CNF formula F : Finset (Finset (CnfLit (Fin n))) is a list π : List (LinIneq n) where each line π[i] is: (1) the trivial line 0 ≥ 0; (2) a Boolean box axiom x_v ≥ 0 or -x_v ≥ -1 for some v : Fin n; (3) an embedded clause C ∈ F; (4) a linear combination of two earlier lines π[j], π[k] (j, k < i) with non-negative integer coefficients lam1, lam2 : ℕ; or (5) a Lift & Project cut from two earlier lines π[j], π[k] (j, k < i) with arbitrary coefficient vector c : Fin n → ℤ, variable v : Fin n, and integers d, d', d'' : ℤ, such that π[j].coeffs = c, π[j].const = d - d', π[k].coeffs = c + d'' * e_v, π[k].const = d, concluding π[i].coeffs = c + d' * e_v and π[i].const = d.
Statement
def is_lp_derivation (n : ℕ) (F : Finset (Finset (CnfLit (Fin n)))) (π : List (LinIneq n)) : Prop
- Defined in
- arXiv:2611.24548 Definition 4.2
- Verified
- 19 Nov 2026
- Axioms
- none listed
- Built on 3
- LinIneqA linear inequality c^T x ≥ d over n Boolean variables, with integer coefficient vector c : Fin n → ℤ and integer constant term d : ℤ.
- CnfLitA CNF literal over a variable type V is either a positive variable or a negated variable.
- cnf_lit_decidable_eqDecidable equality on CNF literals, derived from decidable equality on the underlying variables.
- Used by 1
- is_lp_refutationA Lift & Project refutation of a CNF formula F : Finset (Finset (CnfLit (Fin n))) is an L&P derivation π : List (LinIneq n) from F…
Read back from the Lean
Given a number of variables n : ℕ, a CNF formula F : Finset (Finset (CnfLit (Fin n))) represented as a set of clauses (sets of literals over Fin n), and a sequence of linear inequalities π : List (LinIneq n), is_lp_derivation n F π asserts that every line i of π (indexed by Fin π.length) satisfies at least one of the following six derivation rules:
1. **Trivial inequality ($0 \ge 0$)**: For all variables j : Fin n, the coefficient π[i].coeffs j = 0 and the constant π[i].const = 0.
2. **Variable lower bound ($x_v \ge 0$)**: There exists a variable v : Fin n such that π[i].const = 0 and for all j : Fin n, π[i].coeffs j is 1 if j = v and 0 otherwise.
3. **Variable upper bound ($-x_v \ge -1$, i.e., $x_v \le 1$)**: There exists a variable v : Fin n such that π[i].const = -1 and for all j : Fin n, π[i].coeffs j is -1 if j = v and 0 otherwise.
4. **Clause axiom from $F$**: There exists a clause C ∈ F such that:
- For all j : Fin n, π[i].coeffs j = (if CnfLit.pos j ∈ C then 1 else 0) - (if CnfLit.neg j ∈ C then 1 else 0), and
- π[i].const = 1 - ∑ j : Fin n, (if CnfLit.neg j ∈ C then (1 : ℤ) else 0).
5. **Non-negative linear combination**: There exist previous line indices j, k < i and non-negative integers (natural numbers) lam1, lam2 : ℕ such that:
- For all m : Fin n, π[i].coeffs m = lam1 * π[j].coeffs m + lam2 * π[k].coeffs m, and
- π[i].const = lam1 * π[j].const + lam2 * π[k].const.
6. **Branching/split cut rule**: There exist previous line indices j, k < i, a coefficient vector c : Fin n → ℤ, a variable v : Fin n, and integers d, d', d'' : ℤ such that:
- Line j has coefficients c and constant d - d',
- Line k has coefficients c modified at v by + d'' (i.e., c m + if m = v then d'' else 0) and constant d,
- Line i has coefficients c modified at v by + d' (i.e., c m + if m = v then d' else 0) and constant d.
Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.
Lean source view module on GitHub
/-- A Lift & Project (L&P) derivation from a CNF formula F. -/ def is_lp_derivation (n : ℕ) (F : Finset (Finset (CnfLit (Fin n)))) (π : List (LinIneq n)) : Prop := ∀ i : Fin π.length, ( (∀ j, π[i].coeffs j = 0) ∧ π[i].const = 0 ) ∨ ( ∃ v : Fin n, (∀ j, π[i].coeffs j = if j = v then 1 else 0) ∧ π[i].const = 0 ) ∨ ( ∃ v : Fin n, (∀ j, π[i].coeffs j = if j = v then -1 else 0) ∧ π[i].const = -1 ) ∨ ( ∃ C ∈ F, (∀ j, π[i].coeffs j = (if CnfLit.pos j ∈ C then 1 else 0) - (if CnfLit.neg j ∈ C then 1 else 0)) ∧ π[i].const = 1 - ∑ j : Fin n, (if CnfLit.neg j ∈ C then (1 : ℤ) else 0) ) ∨ ( ∃ (j k : Fin π.length) (lam1 lam2 : ℕ), j < i ∧ k < i ∧ (∀ m, π[i].coeffs m = (lam1 : ℤ) * π[j].coeffs m + (lam2 : ℤ) * π[k].coeffs m) ∧ π[i].const = (lam1 : ℤ) * π[j].const + (lam2 : ℤ) * π[k].const ) ∨ ( ∃ (j k : Fin π.length) (c : Fin n → ℤ) (v : Fin n) (d d' d'' : ℤ), j < i ∧ k < i ∧ (∀ m, π[j].coeffs m = c m) ∧ π[j].const = d - d' ∧ (∀ m, π[k].coeffs m = c m + if m = v then d'' else 0) ∧ π[k].const = d ∧ (∀ m, π[i].coeffs m = c m + if m = v then d' else 0) ∧ π[i].const = d )