Added partial optimality test. Added base class for partial optimality methods.