 We can find the area of a two-dimensional region by a double sum of the differential squares dx dy or dy dx. Now, suppose our region is a two-dimensional object whose density changes at different points. We can find the mass using a weighted sum. So, for example, suppose a square 1 meter on a side is made by joining together four smaller squares of equal size but different densities. If the densities of these smaller squares are 1, 2, 3, and 0 kilograms per square meter, what's the total mass of the square? So, to do that, we'll take each of our four parts, find its area, find the density, multiply them to get the mass, and add everything up. Now, since these four squares are of equal area and the large square has an area of one square meter, then each square has an area of one-quarter square meter. The densities are given as 0, 1, 2, and 3, and importantly, we'll keep those units kilograms per square meter. Remember, units act like algebraic variables. So, if we multiply the area by the density, our units will be kilograms, which is a unit of mass. And the mass is the product of area with density. And we sum up all of the individual masses. So, that's for the discrete case. What about the continuous case? For that, we're going to need a definite integral. So, let's take a 3 by 5 meter sheet of metal, and let's assume our density is 12 x y kilograms per square meter, where x and y are the distances in meters from one corner. And let's find the mass of the sheet. So, if we draw our differential of area, a very small square, that differential of area dA has density 12 x y, and so its mass will be density times area 12 x y dA. Now, we do need to decide whether we're going to integrate first with respect to x or with respect to y, and since our region is rectangular, it doesn't actually matter whether we sum first along x or along y. So, let's sum along x first. So, we'll sum our mass between x equals 0 and x equals 3, and then we'll sum along y as y goes from 0 to 5. And now we can evaluate our inside integral and the remaining integral. And remember, units are important, and fighting a sum or a differential doesn't actually change the units. So, our double integral 12 x y is given as having units of kilograms per square meter. dx, well, x and y is the distance in meters, so dx is also a distance in meters, and likewise dy. And remember, units can be treated just like algebraic variables. This gives us a double integral of kilograms. But remember, fighting a sum doesn't change the units, and so our final answer should be in kilograms. And since this is a unit of mass, we're probably correct. If our region isn't rectangular, nothing important changes. First, we should graph the region. So, if we allow x to vary first, we're going to run from x equals 0 to x equals, and well, while we could solve for x, let's not. And that's because we've already solved for y. So, if we allow y to vary first, we'll run from y equals 0 to y equals 8 minus 4x. Then, we can allow x to vary from x equals 0 up to x equals 2. So, we'll evaluate the inside integral. We'll evaluate the integral, which gives us our numerical value. But again, we should always verify that our units are what we need them to be. So, again, if we look at our integrand, 3x plus 2y has units of kilograms per square meter. dy and dx are both measured in meters, and so our units of the integral will be kilograms. And since we're looking for mass and a kilogram is a unit of mass, our answer is probably correct.