You are asked to implement a package that will allow to implement a simple satisfiability solver (look up sat solving, links recommended by Alexey here and here). Essentially, the data structure implements a Boolean formula over Boolean variables in a certain format (CNF). The functionality that is added is particularly suitable to implement (very basic) solvers that can tell whether a given formula has an assignment that renders the formula true. The classes that are required are: Variable - a Boolean variable. A variable may be unset, which means that it's value is (currently) unknown, or set, in which case it is either true or false. Literal - this is either a variable or a negated variable. Clause - this is a disjunction of literals. In our package the clause is an array of literals. It has to be memory efficient (i.e., not allocate space for more literals than it actually has). In more efficient sat solvers, when a variable is set it notifies all the clauses in which it appears. For that, our variables are going to contain pointers to the clauses that contain them. Again, the Variable should not allocate more space than required for storing these pointers. Formula - this is the main class here. A formula is the conjunction of a set of clauses. It also contains all the variables that appears in these clauses in order to coordinate the solving process. Again, the containers in the Formula should not be larger than required. Notice that some of the options are quite advanced. For example, force in Clause, and resolve in Formula. As mentioned, the main point of the exercise is in the copy constructor of Formula. So you should invest most of your effort in that. If the different copy constructors work fine, then proceed to the more advanced options that go in the direction of sat solving. Technically, I have created the header files of all these classes. You have to complete them with additional members and complete the implementations. You will have to submit eight files: Variable.*pp, Literal.*pp, Clause.*pp, and Formula.*pp. You can submit one additional file called Solver.cpp. This file can contain your own version of a sat solver that improves on the one that I included below. The [url removed, login to view] file has to contain a main and it will be compiled using the same Makefile that is supplied below. The header files include detailed descriptions of the functions that you are required to implement.

there are some classes that need to be implemented and some coding

the structure of the code is what is the main work





PRICE : $ 20

Skills: C Programming, C++ Programming, Software Architecture

See more: literal clause, disjunction literals, what is structure in cpp, what is data structure in programming, what is data structure in c, what is c# programming, what is c programming, what is a variable in programming, what is an array in programming, what is a data structure in c, what is a class in programming, what are classes in programming, variables in programming, set in c, set data structure, programming with cpp, programming what is a class, programming pointers, programming in data structure, programming data structure, process data structure, pointers in data structure, pointers in c programming, pointers c programming, need help with programming assignment

About the Employer:
( 647 reviews ) New Delhi, India

Project ID: #5183365

2 freelancers are bidding on average $55 for this job


Hi i can do this. i can do this. i can do this. i can do this. i can do this. i can do this. i can do this. i can do this.

$90 USD in 3 days
(5 Reviews)

Hi! I am a new freelancer.. But i am an expert on C++.. And i can do this for you quickly... Hope you would give this to me and support my cause. Thank you.

$20 USD in 1 day
(0 Reviews)