How to convert a HeavisideTheta to a PieceWise function
- To: mathgroup at smc.vnet.net
- Subject: [mg93774] How to convert a HeavisideTheta to a PieceWise function
- From: "wxziwyz at 126.com" <wangxz1983 at gmail.com>
- Date: Tue, 25 Nov 2008 07:19:01 -0500 (EST)
For example: we have f(x) = (x + (-2 + x) HeavisideTheta[-2 + x] - 2 (-1 + x) HeavisideTheta[-1 + x]) HeavisideTheta[x] apparently, this is a piecewise function. My problem is, How to transfer it into a Piecewise expression, i.e. f(x) = Piecewise[{{0, x < 0}, {x, 0 < x <= 1}, {2- x, 1 < x <= 2}, {0, x > 2}}] Is there any function in Mathematica can do this?