pub struct IntExpr {
pub constant: i64,
pub coeffs: BTreeMap<i64, i64>,
}Expand description
Integer linear expression of the form c + a₁x₁ + a₂x₂ + … + aₙxₙ.
Similar to crate::lia::LinearExpr but uses integer coefficients
instead of rationals for exact integer arithmetic.
Fields§
§constant: i64The constant term c.
coeffs: BTreeMap<i64, i64>Maps variable index to its integer coefficient (sparse representation).
Implementations§
Trait Implementations§
impl Eq for IntExpr
impl StructuralPartialEq for IntExpr
Auto Trait Implementations§
impl Freeze for IntExpr
impl RefUnwindSafe for IntExpr
impl Send for IntExpr
impl Sync for IntExpr
impl Unpin for IntExpr
impl UnwindSafe for IntExpr
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