Skip to content

PiecewiseExpand

PiecewiseExpand(function)

expands piecewise expressions into a Piecewise function. Currently only Abs, Clip, If, Ramp, UnitStep are converted to Piecewise expressions.

PiecewiseExpand(function, Reals)

expands function piecewise under the assumption, that all variables are real numbers.

See:

Examples

>> PiecewiseExpand(Abs(x), Reals)
Piecewise({{-x,x<0}},x)

Abs, Clip, If, Piecewise, Ramp, UnitStep

Implementation status

  • ✅ - full supported

Github