A clause in a CNF.
The literal (i, b) is satisfied if the assignment to i agrees with b.
- atoms : Array α
- polarities : ByteArray
- isBool_polarities (i : Nat) (h : i < self.polarities.size) : self.polarities[i] = 0 ∨ self.polarities[i] = 1
Instances For
@[instance_reducible]
@[instance_reducible]
theorem Std.Sat.CNF.Clause.Internal.polarity_eq_getElem {α : Type u_1} {c : Clause α} {i : Nat} (h : i < c.polarities.size) :
@[simp]
@[simp]
@[instance_reducible]
@[instance_reducible]
instance Std.Sat.CNF.Clause.instDecidableMemLiteralOfDecidableEq {α : Type u_1} [DecidableEq α] {lit : Literal α} {c : Clause α} :
@[implemented_by Std.Sat.CNF.Clause.forIn'ImplUnsafe]
def Std.Sat.CNF.Clause.forIn'Impl {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] (c : Clause α) (b : β) (f : (l : Literal α) → l ∈ c → β → m (ForInStep β)) :
m β
Reference implementation for forIn' on Clause, iterating directly over the packed
representation without materializing literals.
Instances For
@[instance_reducible]
instance Std.Sat.CNF.Clause.instForIn'LiteralInferInstanceMembershipOfMonad {m : Type u_1 → Type u_2} {α : Type u_3} [Monad m] :
ForIn' m (Clause α) (Literal α) inferInstance
The disjunction of two clauses, obtained by concatenating their literals.
Instances For
@[simp]
@[instance_reducible]
instance Std.Sat.CNF.Clause.instDecidableVarMemOfDecidableEq {α : Type u_1} {v : α} {c : Clause α} [DecidableEq α] :
@[instance_reducible]
@[instance_reducible]
instance Std.Sat.CNF.instDecidableMemClauseOfDecidableEq {α : Type u_1} {c : Clause α} {f : CNF α} [DecidableEq α] :
@[instance_reducible]
instance Std.Sat.CNF.instDecidableVarMemOfDecidableEq {α : Type u_1} {v : α} {f : CNF α} [DecidableEq α] :
theorem Std.Sat.CNF.VarMem_of {α✝ : Type u_1} {f : CNF α✝} {c : Clause α✝} {v : α✝} (h : c ∈ f) (w : Clause.VarMem v c) :
VarMem v f
@[simp]