sasoptpy.expr_sum

expr_sum(argv)[source]

Summation function for Expression objects

Returns
expExpression

Sum of given arguments

Notes

This function is faster for expressions compared to Python’s native sum() function.

Examples

>>> x = so.VariableGroup(10000, name='x')
>>> y = so.expr_sum(2*x[i] for i in range(10000))