The slope for the first part of the function is 1 since this is a line represented by
The slope of this line is 1 (it is the coefficient of x). If we take its derivative, the result is 1.
For the second part of the function, we need to take its derivative:
We have that the derivative for a constant is 0. So, the derivative for 1 is zero.
And we know that:
So
So, in this case, is a line with a slope of -2x, and then, the slopes of both piecewise function are different. In the first case, slope = 1, and in the second case, slope= -2x.
In the first function, for x near to 1, the slope is 1. For the second function (parabola) for x = 1, the slope is -2(1) = -2.