Class SubProblem

java.lang.Object
  extended by SubProblem

public class SubProblem
extends java.lang.Object

A subproblem is a formula and an (partial) assignment with the same number of variables. Useful to model a subproblem of a larger SAT problem consisting of the formula without an assignment. The (partial) assignment specifies a subtree of the total solution space for the larger problem.

Version:
2008.01.10 * Modification log: 1. 2008/02/07 Added constructor SubProblem(SubProblem s) which copy a SubProblem 0. Created 2008/Jan by Andrea Lobo (AL) and Danielle Socha (DS)
Author:
Danielle and Dr. Lobo

Constructor Summary
SubProblem()
           
SubProblem(Formula inputF, Assignment pa)
          Constructor for SubProblem
SubProblem(SubProblem s)
          Constructor for Subproblem
 
Method Summary
 Assignment getAssignment()
          Rerturns the current assignment
 Formula getFormula()
          Rerturns the current formula
 void setFormula(Formula inputF)
          Sets the formula
 void setPartialAssignment(Assignment pa)
          Sets the partial assignment
 java.lang.String toString()
          the values of the variables
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SubProblem

public SubProblem()

SubProblem

public SubProblem(Formula inputF,
                  Assignment pa)
Constructor for SubProblem

Parameters:
inputF - input file name containg the information for the formula; formatted per the International SAT competitions format
pa - the parial assignment

SubProblem

public SubProblem(SubProblem s)
Constructor for Subproblem

Parameters:
a - current SubProblem
Method Detail

setFormula

public void setFormula(Formula inputF)
Sets the formula

Parameters:
inputF - input file name containg the information for the formula; formatted per the International SAT competitions format

setPartialAssignment


public void setPartialAssignment(Assignment pa)
Sets the partial assignment

Parameters:
pa - the partial assignment

getFormula

public Formula 
getFormula()
Rerturns the current formula

Returns:
the formula

getAssignment

public Assignment getAssignment()
Rerturns the current assignment

Returns:
the assignment

toString

public java.lang.String toString()
the values of the variables

Overrides:
toString in class java.lang.Object
Returns:
a String with the values of the variables in the subproblem