Type Alias mz_transform::attribute::cardinality::SymExp

source ·
pub type SymExp = SymbolicExpression<FactorizerVariable>;
Expand description

SymbolicExpressions specialized to factorizer variables

Aliased Type§

enum SymExp {
    Constant(OrderedFloat<f64>),
    Symbolic(FactorizerVariable, usize),
    Sum(Vec<SymbolicExpression<FactorizerVariable>>),
    Product(Vec<SymbolicExpression<FactorizerVariable>>),
    Max(Box<SymbolicExpression<FactorizerVariable>>, Box<SymbolicExpression<FactorizerVariable>>),
    Min(Box<SymbolicExpression<FactorizerVariable>>, Box<SymbolicExpression<FactorizerVariable>>),
}

Variants§

§

Constant(OrderedFloat<f64>)

A constant expression

§

Symbolic(FactorizerVariable, usize)

Variable(x, n) represents x^n

§

Sum(Vec<SymbolicExpression<FactorizerVariable>>)

Sum([e_1, ..., e_m]) represents e_1 + … + e_m

§

Product(Vec<SymbolicExpression<FactorizerVariable>>)

Product([e_1, ..., e_m]) represents e_1 * … * e_m

§

Max(Box<SymbolicExpression<FactorizerVariable>>, Box<SymbolicExpression<FactorizerVariable>>)

The maximum value of two expressions

§

Min(Box<SymbolicExpression<FactorizerVariable>>, Box<SymbolicExpression<FactorizerVariable>>)

The minimum value of two expressions

Implementations§

source§

impl SymExp

source

pub fn humanize(&self, h: &dyn ExprHumanizer, f: &mut Formatter<'_>) -> Result

Render a symbolic expression nicely

Trait Implementations§

source§

impl Display for SymExp

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more