Sha256: 2919150d9adda2141c798f42d7d6fd8d79540d4f840414c36bbfe5e734cb6ac5
Contents?: true
Size: 448 Bytes
Versions: 1
Compression:
Stored size: 448 Bytes
Contents
class BinaryFormula attr_accessor :f1, :f2 def initialize(f1, f2) @f1 = f1 @f2 = f2 end #syntactic equivalenz def ==(other) other.class == self.class && other.f1 == @f1 && other.f2 == @f2 end alias eql? == def literal? false end def atomic_formula? false end def nnf? @f1.nnf? && @f2.nnf? end def dnf? @f1.dnf? && @f2.dnf? end def nnf self.class.new(@f1.nnf, @f2.nnf) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
dpll_solver-0.0.1 | lib/dpll_solver/formulas/binary_formula.rb |