pub enum FbbtOp {
}Expand description
One node in an FBBT-friendly expression tape. Operand fields are
indices into the same tape’s ops vector, and must reference
strictly earlier slots (< self). The result of the whole tape is
the value computed at slot ops.len() - 1 (the last entry).
Variants§
Const(f64)
Numeric constant.
Var(usize)
Reference to problem variable i (0-based).
Add(usize, usize)
Sub(usize, usize)
Mul(usize, usize)
Div(usize, usize)
PowInt(usize, u32)
x^n for non-negative integer n. Variable-exponent power is
emitted as FbbtOp::Opaque (interval Pow with a
non-constant exponent is non-trivial and rare in practice;
pounce defers it).
Neg(usize)
Sqrt(usize)
Exp(usize)
Ln(usize)
Abs(usize)
Sin(usize)
Cos(usize)
Opaque
“Don’t reason about this slot.” The forward pass assigns
ENTIRE to it; the reverse pass declines to push information
through it. Providers emit this for operators FBBT doesn’t
support (extern function calls, AMPL log10 / sum, non-integer
or variable-exponent powers).
Implementations§
Trait Implementations§
impl StructuralPartialEq for FbbtOp
Auto Trait Implementations§
impl Freeze for FbbtOp
impl RefUnwindSafe for FbbtOp
impl Send for FbbtOp
impl Sync for FbbtOp
impl Unpin for FbbtOp
impl UnsafeUnpin for FbbtOp
impl UnwindSafe for FbbtOp
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T, U> Imply<T> for U
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more