Game Development Reference
In-Depth Information
One last helpful analogy: think of a derivative as a speedometer that
tells you an instantaneous rate of change, and the integral as an odometer
describing the continuous summation of this rate of change. Notice that
the reading on the speedometer does not depend on that road trip last
summer, or even what happened two seconds ago. The speedometer reading
is only affected by what is happening at that instant. The odometer, on
the other hand, is a running tally, and the entire history since the car was
first driven off the lot is included in its reading. Our girl under the sewing
table must pay attention to the pedal the entire time if she is going to make
an accurate estimate of the total amount of fabric consumed at any given
time.
Many types of engineering problems solved with integrals are couched in
terms of continuous summations such as these: What is the total displace-
ment, when I know the velocity function v(t)? What is the total amount
of water in the bathtub, given the history of the deflection angle of the
faucet? How much fuel is remaining, given the burn rate as a function of
time? To set up the integral for problems like these, we can first imagine
approximating the value we wish to calculate by using a finite sum (
)
and a finite step size (∆x). We then use a limit argument to replace the
, and the ∆x with a dx (review Equation (11.22)). This is the
essence of what is meant by a “continuous summation.”
Of course, we can use the integral to calculate the area under a curve, as
calculus textbooks are so fond of pointing out. As we sweep a line from left
to right, the function being integrated determines the rate at which we are
accumulating area. Where the function has a large value, our total area is
adding up more rapidly, because the “slices” in that area are tall. However,
from the viewpoint of a video game programmer, calculus textbooks seem
to focus on this particular application of the integral in great disproportion
to its application to real world problems.
with a
11.7.2 The Relationship between the Derivative
and the Integral
Let's see how we calculate integrals now that the purpose of an integral is
(we hope) firmly grounded in your mind. Looking at the definition Equa-
tion (11.22), one wonders how in the world you can evaluate this limit. For
the derivative, we were able to manipulate the expression being taken to
the limit such that we could simply substitute ∆t = 0, but this doesn't
seem possible in Equation (11.22). As it turns out, Equation (11.22) is
mostly useful as a way to recognize when the problem you have is an in-
tegral, and is helpful to properly turn that problem into integral notation.
It's also used when we approximate integrals numerically, where instead
of taking the slice width down to zero, we just stop at some small but
Search WWH ::




Custom Search