You run the pump at medium for one minute, but it’s taking too long so you bump it up to high. After two minutes on high, the raft is nearly inflated but the pump seems like it’s getting a bit hot as it works to counter-act the tendency of the raft to want to deflate, so you switch it to low for one more minute before turning it off.
Figure5.1.2.Graph modelling output of an air pump with three settings.
A function can only take on one output value at any given input value, which is why we have an open circle at the endpoint of each line segment in the graph in Figure 5.1.2. For example, if we call that inflation rate function , then but . Of course, this function is just a model of the behaviour of the air pump described in Example 5.1.1 — we could have put open circles at the beginnings of the line segments and closed ones at the ends instead, and it wouldn’t affect our analysis of the inflation of the raft.
There is no single constant value or formula that describes the function’s output values at every possible input value, so we describe the function’s output values using different output values on different subdomains.
Suppose we wanted to determine the output value without the graph in front of us. We would first scan the subdomains in the right column, and notice that the input falls into the subdomain . Matching up this subdomain with its specified output value, we find that .
A step function whose domain can be split into equal-length intervals so that the “steps” in output value only occur at boundaries between these intervals.
The step function in Example 5.1.4 is not regular — the steps in output value from to and from to both occur after intervals of length , but the next two steps in output value occur after intervals of length greater than . Because the irrational number is involved in these longer two interval lengths, there is no way to subdivide all these intervals into equal-length intervals so that output-value changes only occur at interval boundaries.
On the other hand, the air pump model in Example 5.1.1 is regular because we can split the middle interval in half, and then changes in output-value still only occur at boundaries of these length- intervals.
When a quantity changes with a rate function that can be modelled by a step function, then the rate function is not constant over its entire domain because it is not always the same rate value for all time. However, a stepped rate function is constant over specific subdomains, so we can still apply the above formula on each of those subdomains and then total up all of those partial accumulations.
For the situation described in Example 5.1.1, how much air has been pumped into the raft? To answer this question, we will split the inflation time period up.
You are ordering a quantity of saffron, a very expensive spice, for your bulk food preparation business. The supplier offers a discount scheme based on the amount you order:
The first 500 g ordered is priced at $3.00 per gram.
Any additional amount ordered above500 g is priced at $2.75 per gram, for orders up to 1 kg total. For example, if an order of 600 g is placed, then only the additional 100 g quantity is charged at $2.75 per gram, while the “initial” quantity of 500 g is still charged at $3.00 per gram.
Any additional amount above 1 kg is priced at $2.50 per gram.
Consider what the calculations in Example 5.2.1 represent on the graph of the inflation rate function. On each subdomain, we used the constant-rate accumulation formula
The rate represents the height of the graph on that particular subdomain, while the duration represents the length of time that this rate was in effect. Geometrically, the product of a height and a length represents the area of a rectangle:
So each partial accumulation calculation in Example 5.2.1 corresponds to an area of a rectangle related to the graph of the stepped rate function. Let’s see exactly how.
For the total accumulation, we added up the results of these three calculations. Graphically, the total accumulation corresponds to the total area of the rectangles formed between the stepped rate function’s levels and the -axis.
We talk above about accumulation corresponding to area, but the results of each of our accumulation calculations in Example 5.2.1 are in units of , not — why is that?
by interpreting each rate value as a height and each time duration as a length on the rate graph. Through this correspondence between the two formulas above, the magnitudes of accumulation and graphical area will be the same, but their units of measurement will not coincide.
On a car trip from Camrose to Wetaskiwin, it takes the driver 6 min at the posted Camrose city speed limit of 50 km⁄h to get out onto the highway, then 24 min at the posted highway speed limit of 100 km⁄h to reach Wetaskiwin, and another 9 min at the posted Wetaskiwin city speed limit of 50 km⁄h to reach the final destination.
Keep in mind that the stepped rate function in Example 5.2.9 is a simplified model. In reality, a car cannot change its rate of travel instantaneously, and so our rate graph should have periods of increasing speed (that is, acceleration) and periods of decreasing speed (that is, deceleration). Moreover, it is unlikely the car was travelling at exactly50 km⁄h during the city portions of the trip, or at exactly100 km⁄h during the highway portion — in reality there would have been dips and rises in the rate graph, as the car went up or down hills, around corners, or was stuck behind or pulled out to pass slower-moving vehicles. However, often a simplified model is good enough, and trying to take into account all of the little variations in velocity during the trip might be too complicated for the simple purpose of estimating the distance travelled.
In fact, we will learn in the next chapter how estimating accumulation using simplified models involving stepped rate functions can actually help us to calculate accumulation exactly for more complicated models.
In Example 5.2.2, we analyzed a purchasing scenario with a rate function describing variation in cost per unit mass, (whereas our other examples have all involved variation per unit time). Do you see how the total cost calculation in that example corresponds to a sum of areas of rectangles on the rate function graph?
One minute after inflating your raft (as in Example 5.1.1), a previously patched leak begins leaking again at a rate of 0.2 m3⁄min, and three minutes pass before you notice, quickly slap a piece of tape over the leak, and turn the air pump back on to medium for two minutes. (We’ll assume in our simplified model that all of this happens instantaneously.)
How much air is in the raft now? We just have to repeat the calculation of Example 5.1.1, but take into account the periods of air-loss and re-inflation.
Can we still interpret the calculation in Example 5.2.13 as a sum of rectangle areas on the rate graph? While leaking air, the amount of accumulated air in the raft is decreasing, and so we should interpret the rate of air leakage as a negative rate of variance. The static period between the initial inflation and the start of the leakage could also be interpreted as a period with rate 0 m3⁄min.
If we allow rectangles to be assigned negative area and also consider a line segment along the horizontal axis as a rectangle with height , then the above calculation is still a sum of rectangle areas.
If a function is positive on a domain, then the area bounded between the graph of the function and the horizontal axis over that domain is positively-oriented and we assign positive number to that area.
If a function is negative on a domain, then the area bounded between the graph of the function and the horizontal axis over that domain is negatively-oriented and we assign a negative number to that area.
In the examples in this section, total accumulation was calculated as a sum of products. The situation of calculating a sum where each term in the sum follows a pattern comes up a lot in mathematics, so mathematicians have developed a special notation for it.
The Greek letter stands for “Sum”, the variable is called the index variable for the sum, and the “start” and “end” values and are called the lower bound and upper bound, respectively, for the summation.
The Greek letter is called “sigma”, where is the uppercase version and is the lower case version. This letter corresponds to the letter S in the English alphabet, hence its use to represent a Sum.
While we used the value as sort of a “default” start value in the definition of Sigma notation above, we can use any start value we like, according to the summation pattern we are trying to describe.
The “” is required because in the subtraction we have “taken away” every object up to and including the one indexed by the “starting index value,” but we actually want to include that “starting” object in the collection being counted. For example, if we have a sum indexed from to , then we are adding up terms, not terms.
While there are variations of Sigma notation where the index variable may “step” by more than , we can avoid that by expressing each of our even numbers as times a number that increases by only from term to term:
Only a constant may be factored out of Sigma notation — any expression involving the index variable cannot be factored out, because if the sum were written out that variable part would be different from term to term and so would not actually be a common factor.
So this same sum that we expressed in Example 5.3.2 using a single Sigma expression can be re-expressed using two Sigma expressions, if we had some particular reason for wanting to do so:
However, remember that by default the only letter that Sage treats as a variable is x, so if we want to use k for our index variable as we’ve been doing in our Sigma notation, we have to first tell Sage that we want k to be treated as a variable.
Let’s unpack the notation of the definition above for the inflate-deflate-reinflate model from Example 5.2.13. The step function in the model “steps” output values at the following input values.
just as in our previous calculation, and each term in the sum represents an oriented rectangle area, as pictured in Figure 5.2.14 (though one of the rectangles has height and can’t be seen in that diagram).
It may seem that summing ten rectangle areas in Example 5.4.5 is more work than summing six rectangle areas in Example 5.4.2. But when programming a computer to do such sums, the regularly-spaced ten rectangles is easier to program then the irregularly-spaced six rectangles, and computers don’t care how many rectangle areas you ask them to sum (unless the number of rectangles is very, very large).