Skip to main content

Integrating Functions of Two Variables

Introduction

It’s irrefutable that calculus is an incredible tool-especially when it comes to calculating the area underneath different functions. At this point you may have mastered integration in two-dimensions and be looking for a new challenge. If so, look no further! Integration can also be done in 3-dimensions, adding another layer of useful applications to calculus’ repertoire.

The Problem

Imagine you are a marine biologist who works for an aquarium. The aquarium has created a design for its shark habitat and brings the plans to you for approval. You want to make sure the sharks won’t be overcrowded in the tank, and want to calculate how many cubic feet of water there will be for each shark. To do that, you need to know the volume of the tank. The depth of the tank at any given \( x \) and \( y \) coordinate is by the following equation: \[ f(x,y)= \frac{1}{4}\ \cos(6y) + \frac{1}{4}\ \sin(2x^2) - \frac{1}{2}\ x+ \frac{1}{2}\ y +2 \] The curve of this equation looks as follows:

But wait- there’s more! The tank is not rectangular like the region shown above. Its base is the triangle bounded by the functions \( g_{1}(x)= \frac{1}{2}\ + \frac{1}{4}\ x \) , \( g_{2}(x)= \frac{1}{2}\ - \frac{3}{4}\ x \) , and \( x=2 \) as shown below:

Consequently, this means our tank is modeled by the function below, but cut off at the lines depicted in the xy plane:

How in the world do we go about calculating the volume of this shape? Before we use calculus to find the exact volume, we will find an approximate of those calculations to demonstrate how our integration will work.

The Approximation

If you remember, integration in 2-dimensions is like dividing your region into infinitely many rectangular slices. So, to get an idea of what is happening here, we will start by dividing our shape into rectangular prisms. I arbitrarily decided to divide the region into a grid of boxes with dimensions of 0.2 by 0.2. We will build a prism for each of these boxes using whatever the value of \( f(x, y) \) is at the midpoint of each grid point. Any box with a midpoint outside of the region, however, will be assigned a value of 0. This means our solid will consist of the following prisms:

Now, let’s calculate the volume for each of the prisms. The length and width of each will be 0.2, and the height will be the corresponding value of \( f(x,y) \). This gives us the following values:

When we add up the volumes of all of these prisms, we find that the approximate volume is \( 2.912 \textrm{ units}^3 \) . The resulting approximation looks like the following:

The Solution

We just successfully estimated the volume of our solid by dividing it up into rectangular prisms. You may already suspect that by using calculus we can divide our region into an infinite number of rectangular prisms, and that by doing so we can obtain the exact volume of the shape. But how do we do this in three dimensions? Normally when do an integral in 2-dimensions we integrate just over the \( x \) axis. However, now that we are in 3-dimensions we must integrate over the \( y \) axis as well. This means our integral will look something like: \[ \int_{a}^{b} \int_{c}^{d} f(x,y) \,dy \,dx \]

Great! Now we just need to figure out what \( a \), \( b \), \( c \), and \( d \) are. Let’s look at \( c \) and \( d \). They correspond to our integration over \( y \). So let’s look at our region again and see what \( y \) values it is bounded by. Anytime we make a vertical slice, our region is bounded by the lines \( g_{1} \) and \( g_{2} \):

This means that instead of being an integer, our bounds will be these lines: \( c=g_{2}(x)= \frac{1}{2}\ - \frac{3}{4}\ x \)and \( d=g_{1}(x)= \frac{1}{2}\ + \frac{1}{4}\ x \) . This may seem weird at first, but it makes sense since these equations will give our upper and lower bounds of \( y \) for whatever \( x \) value we are looking at.

Determining \( a \) and \( b \) are a lot easier. Since our regions stretches from \( x = 0 \) to \( x= 2 \), we can see that \( a =0 \) and \( b = 2 \). This makes our equation: \[ \int_{0}^{2} \int_{\frac{1}{2}\ - \frac{3}{4}\ x }^{\frac{1}{2}\ + \frac{1}{4}\ x } \frac{1}{4}\ \cos(6y) + \frac{1}{4}\ \sin(2x^2) - \frac{1}{2}\ x+ \frac{1}{2}\ y +2 \,dy \,dx \]

Now we move on to the calculations. First, we find our antiderivative as usual: \[ = \int_{0}^{2} \frac{1}{24}\ \sin(6y) + \frac{1}{4}\ y \sin(2x^2) - \frac{1}{2}\ xy+ \frac{1}{4}\ y^2 +2y \,dy \Bigg\vert_{\frac{1}{2}\ + \frac{1}{4}\ x }^{\frac{1}{2}\ - \frac{3}{4}\ x} \,dx \] We treat the function bounds the same as we would treat an integer bound: \[ = \int_{0}^{2} \frac{1}{24}\ \sin(3+ \frac{3}{2}\ x) + \frac{1}{8}\ \sin(2x^2) + \frac{1}{16}\ x \sin(2x^2) - \frac{1}{4}\ x- \frac{1}{8}\ x^2 + \frac{1}{4}( \frac{1}{2}\ + \frac{1}{4}\ x)^2 +1+ \frac{1}{2}\ x - \frac{1}{24}\ \sin(3- \frac{9}{2}\ x) - \frac{1}{8}\ \sin(2x^2) + \frac{3}{16}\ x \sin(2x^2) + \frac{1}{4}\ x- \frac{3}{8}\ x^2 - \frac{1}{4}( \frac{1}{2}\ - \frac{3}{4}\ x)^2 -1+ \frac{3}{2}\ x \,dx \] We can simplify this and perform our second integration: \[ = \int_{0}^{2} \frac{1}{24}\ \sin(3+ \frac{3}{2}\ x) + \frac{1}{4}\ x \sin(2x^2) - \frac{1}{24}\ \sin(3- \frac{9}{2}\ x) - \frac{5}{8}\ x^2 + \frac{9}{4}\ x \,dx \] \[ = \frac{1}{8}\ \int_{0}^{2} \frac{1}{4}\ \sin(3+ \frac{3}{2}\ x) + 2x \sin(2x^2) - \frac{1}{4}\ \sin(3- \frac{9}{2}\ x) -5x^2+18x \,dx \] \[ = \frac{1}{8}\ \bigg[ - \frac{1}{6}\ \cos(3+ \frac{3}{2}\ x) - \frac{1}{2}\ \cos(2x^2) - \frac{1}{18}\ \cos(3- \frac{9}{2}\ x) - \frac{5}{3}\ x^3 +9x^2 \bigg] \bigg\vert_{0}^{2} \] \[ = \frac{1}{8} \Big( - \frac{1}{6}\ \cos(6) - \frac{1}{2}\ \cos(8) - \frac{1}{18}\ \cos(-6) - \frac{5}{3}\ (8)+36+ \frac{1}{6}\ \cos(3) + \frac{1}{2}\ \cos(0) + \frac{1}{18}\ \cos(3) +0+0 \Big) \] \[ =2.834 \textrm{ units}^3 \]

Therefore, the tank's exact volume is \( 2.834 \textrm{ units}^3 \) which you can use to make sure the aquarium sharks are happy.

Why this example?

This example was chosen for several reasons:

  • Various aspects of the functions were constructed to make integration possible, especially with the sin and cos functions in the \( f(x,y) \) equation. The bounds were carefully chosen so that non-integrable terms would cancel and that any remaining terms could be integrated with nothing more complicated than a u substitution. This was easiest to achieve with linear functions that had the same y intercept.
  • The \( f(x,y) \) function was constructed using sin and cos functions due to the interesting shape it creates. The resulting function has several hills and valleys that made the resulting model interesting to look at since it resulted in notable changes in the heights of the prism.

Author: Sarah Bombrys

Comments

Popular posts from this blog

Do Over: Integration Over a Region in a Plane

Throughout the semester we have covered a variety of topics and how their mathematical orientation applies to real world scenarios. One topic we discussed, and I would like to revisit, is integration over a region in a plane which involves calculating a double integral. Integrating functions of two variables allows us to calculate the volume under the function in a 3D space. You can see a more in depth description and my previous example in my blog post, https://ukyma391.blogspot.com/2021/09/integration-for-over-regions-in-plane_27.html . I want to revisit this topic because in my previous attempt my volume calculations were incorrect, and my print lacked structural stability. I believed this print and calculation was the topic I could most improve on and wanted to give it another chance. What needed Improvement? The function used previously was f(x) = cos(xy) bounded on [-3,3] x [-1,3]. After solving for the estimated and actual volume, it was difficult to represent in a print...

Knot 9-31

Knot 9-31 A knot is mathematics is defined as a closed, non-self-intersecting curve that is placed in three dimensions and cannot be the "unknot". The main difference between a knot in the real world and a known in mathematics is that a knot in mathematics does not contain any extra strands. The example following will help visualize this. Today, I have specifically chosen knot 9-31 from the Knot Atlas. This knot is very unique and contains some very interesting properties that we are going to look into. The Crossing Number For my knot today, I chose knot 9-31 from the Knot Atlas. This knot contains 9 crossings! The Unknotting Number The unknotting number is exactly what is sounds like. This is the minimum number of times the knot must be passed through itself to untie it. Luckily, the Knot Atlas is super useful and provides the unknotting number for us, but I still...

Do Over: Integration for Over Regions in the Plane

Introduction Earlier in the semester, we visited the topic of integration for over region regions in the plane. This was our first experience with taking integration in the third dimension. To do this, we had to use double integrals to calculate the volume of a region between two surfaces. This topic seems relatively straightforward and anyone who has taken a higher calculus class knows of double integrals. Today, we are going to revisit this topic for a couple of reasons. Why Double Integrals Again? As mentioned before, I am revisiting this topic for a couple of reasons. One of the main reasons is due to how the 3D print turned out. Due to the function, I chose, the final rectangular prism was stand alone. When printing, this resulted in a sloppy prism that lacked structural integrity. The image below is a reference to my original design that includes the prism that had the issue. The main cause of ...