update vendor

This commit is contained in:
Ettore Di Giacinto
2021-08-07 14:27:41 +02:00
parent 4d6cccb2fa
commit 77c4bf1fd1
8 changed files with 628 additions and 1 deletions

View File

@@ -39,6 +39,16 @@ func (s *Solver) initWatcherList(clauses []*Clause) {
}
}
// Should be called when new vars are added to the problem (see Solver.newVar)
func (s *Solver) addVarWatcherList(v Var) {
cnfVar := int(v.Int())
for i := s.nbVars; i < cnfVar; i++ {
s.wl.wlistBin = append(s.wl.wlistBin, nil, nil)
s.wl.wlist = append(s.wl.wlist, nil, nil)
s.wl.wlistPb = append(s.wl.wlistPb, nil, nil)
}
}
// appendClause appends the clause without checking whether the clause is already satisfiable, unit, or unsatisfiable.
// To perform those checks, call s.AppendClause.
// clause is supposed to be a problem clause, not a learned one.