Trapezoid

Diagram Context 
if nperiod<0
nperiod=Inf;
end
z=[0,rising,rising+width,rising+width+falling,period];
if ~TestIncreaseMonotonically(z)
error('Incorrect parameters. Please check block parameters.')
end