# picos.expressions.exp_sumxtr¶

Implements SumExtremes.

Classes

class picos.expressions.exp_sumxtr.SumExtremes(x, k, largest, eigenvalues=False)[source]

Sum of the largest or smallest elements or eigenvalues.

Definition

Let .

1. If is an -dimensional real vector or matrix and eigenvalues == False, then this is the sum of the largest or smallest scalar elements of , depending on the truth value of largest.

Special cases:

• If , this is either the largest element or the smallest element of .

• If , this is the sum of all elements of .

2. If is an hermitian matrix and eigenvalues == True, then this is the sum of the largest or smallest eigenvalues of , depending on the truth value of largest. Recall that the eigenvalues of a hermitian matrix are real.

Special cases:

• If , this is either the largest eigenvalue or the smallest eigenvalue of .

• If , this equals the trace .

If the given exceeds the of either case, then is silently clipped to .

__ge__(other)[source]

Return a constraint that the expression is lower-bounded.

__init__(x, k, largest, eigenvalues=False)[source]

Construct a SumExtremes.

Parameters
• x (ComplexAffineExpression) – The affine expression to take a sum over.

• k (int) – Number of summands.

• largest (bool) – Whether to sum over the largest (eigen)values as opposed to the smallest.

• eigenvalues (bool) – Whether to sum eigenvalues instead of elements.

__le__(other)[source]

Return a constraint that the expression is upper-bounded.

__mul__(other)[source]

Denote multiplication with another expression on the right.

__rmul__(other)[source]

Denote multiplication with another expression on the left.

property eigenvalues

Whether the sum concerns eigenvalues as opposed to elements.

property full

Whether the sum concerns all (eigen)values of the expression.

property k

Number of (eigen)values to sum.

property largest

Whether the sum concerns largest values as opposed to smallest.

property x

The expression under the sum.