pub struct Problem {
pub circuit: Circuit,
pub details: ProblemDetails,
}
Expand description
Problem that may be returned by the problem parsers
Fields§
§circuit: Circuit
Combinational circuit as the core of the problem
details: ProblemDetails
Additional details on the problem
Implementations§
Source§impl Problem
impl Problem
Sourcepub fn simplify(&self) -> Result<(Self, Vec<Literal>), Literal>
pub fn simplify(&self) -> Result<(Self, Vec<Literal>), Literal>
Simplify the circuit (see Circuit::simplify()
), and map the gate
literals in the additional problem details accordingly
If the reachable circuit fragment contains a cycle, this method returns
Err(l)
, where l
represents a gate that is part of the cycle.
On success, simplify()
returns the simplified problem along with a
Vec<Literal>
which maps the gates of self
to literals valid in the
simplified circuit. The simplified circuit only contains gates reachable
from the problem details (except for the
AIGER literal map).
Trait Implementations§
impl Eq for Problem
impl StructuralPartialEq for Problem
Auto Trait Implementations§
impl Freeze for Problem
impl RefUnwindSafe for Problem
impl Send for Problem
impl Sync for Problem
impl Unpin for Problem
impl UnwindSafe for Problem
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more