Skip to main content

WmcManager

Struct WmcManager 

pub struct WmcManager { /* private fields */ }

Implementations§

§

impl WmcManager

pub fn new(_ps: &PathSum) -> Self

pub fn enable_precise_gpmc_weights(&mut self, precision_bits: usize)

pub fn encode_trace(&mut self, ps: &PathSum) -> Result<()>

pub fn to_dimacs_string(&self, tool_name: &str) -> String

pub fn has_exact_unweighted_tautology( &self, normalization_twice_log2: usize, ) -> bool

Exact WMC shortcut, restricted to tautological, unweighted CNF.

Each assignment to the declared variables satisfies every clause, so the count is exactly 2^variables. Only accept when this matches the trace normalization exponent. This never reasons from Ganak’s floating stdout or assumes that zero path variables imply SAT.

pub fn try_to_dimacs_string(&self, tool_name: &str) -> Result<String>

pub fn solve(&self, tool_name: &str) -> Result<Complex<f64>>

Backward-compatible entrypoint for callers that do not own a deadline. The public verification path uses solve_with_deadline instead.

pub fn solve_with_deadline( &self, tool_name: &str, deadline: Option<Instant>, ) -> Result<Complex<f64>>

pub fn observe_with_deadline( &self, tool_name: &str, deadline: Option<Instant>, ) -> Result<SolverObservation>

Opt-in typed native measurement; ordinary solve APIs remain compatible.

pub fn solve_with_deadline_printed( &self, tool_name: &str, deadline: Option<Instant>, ) -> Result<PrintedCount>

Preserve the solver’s original decimal result through a typed boundary. The returned precision interval covers printed digits only.

pub fn solve_with_deadline_distance_printed( &self, tool_name: &str, deadline: Option<Instant>, ) -> Result<PrintedCount>

Typed result for the public distance-mode verifier, preserving the selected solver (GPMC effective default 30 digits, native Ganak mode 6).

pub fn solve_with_deadline_distance_printed_precision( &self, tool_name: &str, deadline: Option<Instant>, digits: u32, ) -> Result<PrintedCount>

Explicit per-call precision: no second solver call or global state.

pub fn numerical_weight_count(&self) -> usize

Number of phase-weight literals used in a conditional f64 input budget.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.