pub(super) fn variable_feasible_value(&self, variable: usize) -> Option<OF> {
        // There is no reason to want to know the latest value for a variable already removed.
        debug_assert!(!self.removed_variables.iter().any(|&(j, _)| j == variable));

        let lower = self.variable_bound(variable, BoundDirection::Lower);
        let upper = self.variable_bound(variable, BoundDirection::Upper);

        // It is often positive slacks that get removed here, so we pick the upper bound if
        // there is one, because it makes it more likely that a meaningful variable is zero,
        // which in turn might lead to sparser solutions.
        match (lower, upper) {
            (None, None) => Some(OF::zero()),
            (None, Some(bound)) => Some(bound.clone()),
            (Some(bound), None) => Some(bound.clone()),
            (Some(lower), Some(upper)) => {
                if lower <= upper {
                    Some(upper.clone())
                } else {
                    None
                }
            }
        }
    }
/// Whether a the latest version of variable has any feasible value.
Whether a the latest version of variable has any feasible value.
Whether a the latest version of variable has any feasible value .
pub(super) fn variable_feasible_value(&self, variable: usize) -> Option<OF> {
        // There is no reason to want to know the latest value for a variable already removed.
        debug_assert!(!self.removed_variables.iter().any(|&(j, _)| j == variable));
        let lower = self.variable_bound(variable, BoundDirection::Lower);
        let upper = self.variable_bound(variable, BoundDirection::Upper);
        // It is often positive slacks that get removed here, so we pick the upper bound if
        // there is one, because it makes it more likely that a meaningful variable is zero,
        // which in turn might lead to sparser solutions.
        match (lower, upper) {
            (None, None) => Some(OF::zero()),
            (None, Some(bound)) => Some(bound.clone()),
            (Some(bound), None) => Some(bound.clone()),
            (Some(lower), Some(upper)) => {
                if lower <= upper {
                    Some(upper.clone())
                } else {
                    None
                }
            }
        }
    }
pub ( super ) fn variable_feasible_value ( & self , variable : usize ) -> Option < OF > { // There is no reason to want to know the latest value for a variable already removed. debug_assert ! ( self removed_variables iter ( ) any ( ( j ) j variable ) ) ; let lower = self . variable_bound ( variable , BoundDirection :: Lower ) ; let upper = self . variable_bound ( variable , BoundDirection :: Upper ) ; // It is often positive slacks that get removed here, so we pick the upper bound if // there is one, because it makes it more likely that a meaningful variable is zero, // which in turn might lead to sparser solutions. match ( lower , upper ) { ( None , None ) => Some ( OF :: zero ( ) ) , ( None , Some ( bound ) ) => Some ( bound . clone ( ) ) , ( Some ( bound ) , None ) => Some ( bound . clone ( ) ) , ( Some ( lower ) , Some ( upper ) ) => { if lower <= upper { Some ( upper . clone ( ) ) } else { None } } } }
Whether a the latest version of variable has any feasible value.
Whether a the latest version of variable has any feasible value .
&self
variable
usize
&self
variable
usize