Implementation of WeightedSumConstraint.


class picos.constraints.con_wsum.WeightedSumConstraint(wsum, relation, rhs)[source]

Bases: Constraint

Bound on a convex or concave weighted sum of expressions.

class Conversion[source]

Bases: ConstraintConversion

Bound on a weighted sum of expressions conversion.

classmethod convert(con, options)[source]

Implement convert.

classmethod predict(subtype, options)[source]

Implement predict.

__init__(wsum, relation, rhs)[source]

Construct a WeightedSumConstraint.

  • wsum (WeightedSum) – Left hand side expression.

  • relation (str) – Constraint relation symbol.

  • rhs (AffineExpression) – Right hand side expression.