cprover
dimacs_cnf_dumpt Class Reference

#include <dimacs_cnf.h>

Inheritance diagram for dimacs_cnf_dumpt:
[legend]
Collaboration diagram for dimacs_cnf_dumpt:
[legend]

Public Member Functions

 dimacs_cnf_dumpt (std::ostream &_out)
 
virtual ~dimacs_cnf_dumpt ()
 
virtual const std::string solver_text ()
 
virtual void lcnf (const bvt &bv)
 
virtual resultt prop_solve ()
 
virtual tvt l_get (literalt) const
 
virtual size_t no_clauses () const
 
- Public Member Functions inherited from cnft
 cnft ()
 
virtual ~cnft ()
 
virtual literalt land (literalt a, literalt b) override
 
virtual literalt lor (literalt a, literalt b) override
 
virtual literalt land (const bvt &bv) override
 Tseitin encoding of conjunction between multiple literals. More...
 
virtual literalt lor (const bvt &bv) override
 Tseitin encoding of disjunction between multiple literals. More...
 
virtual literalt lxor (const bvt &bv) override
 Tseitin encoding of XOR between multiple literals. More...
 
virtual literalt lxor (literalt a, literalt b) override
 
virtual literalt lnand (literalt a, literalt b) override
 
virtual literalt lnor (literalt a, literalt b) override
 
virtual literalt lequal (literalt a, literalt b) override
 
virtual literalt limplies (literalt a, literalt b) override
 
virtual literalt lselect (literalt a, literalt b, literalt c) override
 
virtual literalt new_variable () override
 Generate a new variable and return it as a literal. More...
 
virtual size_t no_variables () const override
 
virtual void set_no_variables (size_t no)
 
void gate_and (literalt a, literalt b, literalt o)
 Tseitin encoding of conjunction of two literals. More...
 
void gate_or (literalt a, literalt b, literalt o)
 Tseitin encoding of disjunction of two literals. More...
 
void gate_xor (literalt a, literalt b, literalt o)
 Tseitin encoding of XOR of two literals. More...
 
void gate_nand (literalt a, literalt b, literalt o)
 Tseitin encoding of NAND of two literals. More...
 
void gate_nor (literalt a, literalt b, literalt o)
 Tseitin encoding of NOR of two literals. More...
 
void gate_equal (literalt a, literalt b, literalt o)
 Tseitin encoding of equality between two literals. More...
 
void gate_implies (literalt a, literalt b, literalt o)
 Tseitin encoding of implication between two literals. More...
 
- Public Member Functions inherited from propt
 propt ()
 
virtual ~propt ()
 
virtual void set_equal (literalt a, literalt b)
 asserts a==b in the propositional formula More...
 
virtual void l_set_to (literalt a, bool value)
 
void l_set_to_true (literalt a)
 
void l_set_to_false (literalt a)
 
void lcnf (literalt l0, literalt l1)
 
void lcnf (literalt l0, literalt l1, literalt l2)
 
void lcnf (literalt l0, literalt l1, literalt l2, literalt l3)
 
virtual bool has_set_to () const
 
virtual bool cnf_handled_well () const
 
virtual void set_assumptions (const bvt &)
 
virtual bool has_set_assumptions () const
 
virtual void set_variable_name (literalt, const irep_idt &)
 
bvt new_variables (std::size_t width)
 generates a bitvector of given width with new variables More...
 
virtual void set_assignment (literalt a, bool value)=0
 
virtual bool is_in_conflict (literalt l) const =0
 Returns true if an assumption is in the final conflict. More...
 
virtual bool has_is_in_conflict () const
 
virtual void set_frozen (literalt)
 
virtual void set_time_limit_seconds (uint32_t)
 
- Public Member Functions inherited from messaget
virtual void set_message_handler (message_handlert &_message_handler)
 
message_handlertget_message_handler ()
 
 messaget ()
 
 messaget (const messaget &other)
 
messagetoperator= (const messaget &other)
 
 messaget (message_handlert &_message_handler)
 
virtual ~messaget ()
 
mstreamtget_mstream (unsigned message_level) const
 
mstreamterror () const
 
mstreamtwarning () const
 
mstreamtresult () const
 
mstreamtstatus () const
 
mstreamtstatistics () const
 
mstreamtprogress () const
 
mstreamtdebug () const
 
void conditional_output (mstreamt &mstream, const std::function< void(mstreamt &)> &output_generator) const
 Generate output to mstream using output_generator if the configured verbosity is at least as high as that of mstream. More...
 

Protected Attributes

std::ostream & out
 
- Protected Attributes inherited from cnft
size_t _no_variables
 
- Protected Attributes inherited from propt
bvt lcnf_bv
 
- Protected Attributes inherited from messaget
message_handlertmessage_handler
 
mstreamt mstream
 

Additional Inherited Members

- Public Types inherited from propt
enum  resultt { resultt::P_SATISFIABLE, resultt::P_UNSATISFIABLE, resultt::P_ERROR }
 
- Public Types inherited from messaget
enum  message_levelt {
  M_ERROR =1, M_WARNING =2, M_RESULT =4, M_STATUS =6,
  M_STATISTICS =8, M_PROGRESS =9, M_DEBUG =10
}
 
- Static Public Member Functions inherited from cnft
static bvt eliminate_duplicates (const bvt &)
 eliminate duplicates from given vector of literals More...
 
- Static Public Member Functions inherited from messaget
static unsigned eval_verbosity (const std::string &user_input, const message_levelt default_verbosity, message_handlert &dest)
 Parse a (user-)provided string as a verbosity level and set it as the verbosity of dest. More...
 
static mstreamteom (mstreamt &m)
 
static mstreamtendl (mstreamt &m)
 
- Protected Member Functions inherited from cnft
bool process_clause (const bvt &bv, bvt &dest)
 filter 'true' from clause, eliminate duplicates, recognise trivially satisfied clauses More...
 
- Static Protected Member Functions inherited from cnft
static bool is_all (const bvt &bv, literalt l)
 

Detailed Description

Definition at line 42 of file dimacs_cnf.h.

Constructor & Destructor Documentation

◆ dimacs_cnf_dumpt()

dimacs_cnf_dumpt::dimacs_cnf_dumpt ( std::ostream &  _out)
explicit

Definition at line 33 of file dimacs_cnf.cpp.

◆ ~dimacs_cnf_dumpt()

virtual dimacs_cnf_dumpt::~dimacs_cnf_dumpt ( )
inlinevirtual

Definition at line 46 of file dimacs_cnf.h.

Member Function Documentation

◆ l_get()

virtual tvt dimacs_cnf_dumpt::l_get ( literalt  ) const
inlinevirtual

Implements propt.

Definition at line 60 of file dimacs_cnf.h.

References tvt::unknown().

◆ lcnf()

void dimacs_cnf_dumpt::lcnf ( const bvt bv)
virtual

Implements propt.

Definition at line 97 of file dimacs_cnf.cpp.

References out, and write_dimacs_clause().

◆ no_clauses()

virtual size_t dimacs_cnf_dumpt::no_clauses ( ) const
inlinevirtual

Implements cnft.

Definition at line 65 of file dimacs_cnf.h.

◆ prop_solve()

virtual resultt dimacs_cnf_dumpt::prop_solve ( )
inlinevirtual

Implements propt.

Definition at line 55 of file dimacs_cnf.h.

References propt::P_ERROR.

◆ solver_text()

virtual const std::string dimacs_cnf_dumpt::solver_text ( )
inlinevirtual

Implements propt.

Definition at line 48 of file dimacs_cnf.h.

Member Data Documentation

◆ out

std::ostream& dimacs_cnf_dumpt::out
protected

Definition at line 71 of file dimacs_cnf.h.

Referenced by lcnf().


The documentation for this class was generated from the following files: