Index
Graph of Piecewise Function
To plot a graoh piecewise function either plot several graphs, each in its part
of function domain; or use logical and compariso functions to define the function
analytically by one expression.
Example. Plot the graph of
1st method
Define two graphs in Cartesian coordinates:
-x;0,1
1-x;1,2
2nd method
Define the graph by a single expression in Cartesian coordinates:
-x*and(ge(x,0),le(x,1))+(1-x)*and(ge(x,1),le(x,2))