The goal is to get Excel to successfully plot a curve of a piecewise function that looks something like this.
If X=0 y=240
If X=1-2 y=240+45(X-0)
If X=3-10 y=240+90+39(X-2)
If X=11-14 y=240+90+232+24(X-10)
If X=15-18 y=240+90+232+96+12(X-14)
Then I need to be able to integrate piecewise or be able to get it to calculate the total area under the curve up until any value of X.
If possible, I would like to be able to substitute a different series of equations and different limits of X for each equation to quickly generate a different curve.