User:SamHB/MVCalc1
Type classification: this resource is a course. |
Subject classification: this is a physics resource. |
Subject classification: this is a mathematics resource. |
Educational level: this is a secondary education resource. |
Educational level: this is a tertiary (university) resource. |
Multivariable calculus (also known as multivariate calculus) is the study of problems of differential and integral calculus in situations in which the number of variables being differentiated with respect to, or integrated over, is greater than one. Simply put, it is calculus in multiple dimensions.
It is a field rich in theoretical issues and even richer in practical applications. In particular, it relates to vectors, areas, volumes, curves, surfaces, and their analogs in dimensions even higher than the familiar three.
MV calculus is a rather advanced course. A thorough understanding of it involves a number of prerequisite fields, with which the student will need to become familiar. They will not be covered in this course, though they will be covered elsewhere in Wikiversity. They include:
- Differential and integral calculus, of course. The student will be required to evaluate definite integrals, either through knowledge of the subject, or through computer programs or web sites that can perform integration. Some integrators are listed at the end of this article.
- The various theoretical mathematical issues that go with a good understanding of calculus, such as limits and elementary set theory.
- Finite-dimensional linear algebra—vectors, linear transformations, matrices, inversion, determinants, and orthogonal matrices.
- The basic notion of using different coordinate systems (such as polar coordinates) to describe a space. This concept is central to the subject. Much of what we do will involve operating in a coordinate system suited to the problem at hand.
- For the physical applications that will be covered, an understanding of the underlying physics. This may include, at various times, vectors, electric and magnetic fields, velocity, and momentum.
MV calculus is a wide-ranging subject. It can involve very abstract and theoretical issues, as well as intuitive geometrical ones. This course will emphasize the latter. In particular, it will not cover:
- The inverse function theorem and implicit function theorem.
- Fubini's theorem. We will give plausible geometrical arguments for multiple integration, and let it go at that. We will not give rigorous proofs.
- Measure theory.
- Issues of repeated differentiability and "smoothness".
- Various theoretical considerations of "pathological" situations such as divergent integrals or non-orientable manifolds.
We will not give rigorous proofs of the various theorems here. Such proofs are taught in college-level analysis and differential geometry courses, and often dwell upon esoteric issues of singularities and infinities.
Integration
[edit | edit source]In multivariable calculus, and in the related areas of physics, we will be extending the notion of the integral well beyond the simple case of the Riemann Integral from elementary calculus. In fact, integration will be the main subject of this course.
These extensions will consist of
- Integration over higher-dimensional regions, such as surfaces and volumes, with sophisticated ways of specifying these regions.
- Integration of functions, typically representing physical quantities, such as integration of density to get total mass, or integration of a gravitational or electric field along a path to get potential energy or electric potential.
- Integration of vector fields, for example, a magnetic field, across a surface to get the total flux.
- Integration in coordinate systems other than the familiar Cartesian coordinates, such that the physically correct result is always obtained, independently of the coordinate system used.
In all cases, the additional sophistication in the integrals will just involve things that are done to set up the mathematical problem. The actual integration will always be the same—one-dimensional Riemann integration of some function. That is, the integration that we will do will always reduce to the familiar definite integration for elementary calculus:
Recall that the solution to such a problem is easy to state, though maybe not easy to solve: Find a function such that is the derivative of :
Then the integral is the difference between the values of at and :
We will generalize the familiar integration of mathematical functions defined on intervals of the real numbers, to integration over geometric curves, surfaces, and volumes. We will take a slightly different viewpoint from that of elementary calculus. Instead of integrating a mathematical function—an act which gets the area under the graph of the function—the focus will be on integration over geometric regions. This is just a change in the way we think about these operations—when solving actual problems to get actual answers, we will still perform integration in the usual way.
The first thing we do is develop a more sophisticated way of measuring the area of a plane figure. We know that the area under the graph of a function can be obtained by calculating the definite integral:
This can give us the area of a figure with a straight horizontal bottom edge, straight vertical left and right edges, and an arbitrary function giving the top edge. It adds up the areas of tiny vertical strips, where the width of each strip is the mysterious symbol "dx" and the height is . We could replace with
so we have
This is two nested integrals, or a double integral. The quantity in parentheses is the integrand of the outer integral. As such, it is a function of x, so its limits are permitted to depend on x. In more complicated problems, such as finding the total electric charge, we might replace the inner integrand ("1" in the present example) with the density of electric charge, which could be a function of x and y.
The big parentheses are usually omitted, but their implict meaning must be followed. The innermost integral, and its limits of integration, relate to the innermost "d" symbol, and so on.
In general, the area of a region is:
This is the essence of how double (and later, triple) integrals are used to calculate areas, volumes, and other things over 2 or 3-dimensional regions.
A triple integral could be written:
Each successive integral may use the values of all outer integration variables in specifying its limits. The limits of the outermost integral must be constants.
While this use of double integrals to calculate areas may seem like excessive make-work, and using "1" as the integrand may seem boring, it allows us to find the areas of many (but not all[1]) regions.
If and give the upper and lower edges of a region, its area is:
Suppose we have a circle of radius R centered at (A, B). The integration limits are A-R and A+R. The upper function is:
and the lower function is:
The area of the circle is:
We use the change-of-variable theorem to shift x, using the substitution x = A + u:
(We'll have a lot more to say about the change-of-variable theorem later, but now we are just using the version from elementary calculus, that helps us calculate ordinary integrals.) When we evaluate this integral, we get:
The geometrical interpretation is that we have divided the region into thin vertical strips abutting each other from left to right, and then divided each strip into tiny squares, abutting each other from bottom to top, and added up all the areas. A better way to look at this is that we have simply divided the figure into tiny square or rectangular pieces (tiny parallelograms will in fact turn out to be the best way to think about this) and added up their areas.
We could have performed the double integration in the other order, dividing the circle into horizontal strips first, and then subdividing those, so that dx is the "inner" integral and dy the "outer" one. This would have gotten the same result. The theorem that says that this is so is Fubini's theorem. Proving it is outside the scope of this course.
Now, given that Fubini's theorem says that the order of the integrations doesn't matter, we can "abstract away" that order, say that we are really just "integrating over a region", and use a more abstract notation. Once we have defined a 2-dimensional region R, we can just write two successive integral signs with the subscript R instead of the written-out limits of integration, and use the symbol "dA" to mean "infinitesimal piece of area". (Recall that "dx" means, in an informal way, "infinitesimal bit of length".) The integral would look like:
or, more generally, if is some function that we want to integrate (for example, density):
where p is some way of indicating a point in the region. We will always use a coordinate system, so, for example, if we are using polar coordinates, the integral might look like:
For triple integrals over a volume, we do something similar:
The symbols dA and dV are often called the "area element" and "volume element", respectively.
Obviously, we have more work to do before we can integrate over regions described by coordinate systems other than Cartesian coordinates.
Digression: Other notation for integrals.
People sometimes use various creative symbols to describe particular types of regions. Don't worry about these notations—we are listing them here to explain things that you might see elsewhere. means a 1-dimensional region, that is, an arc, , whose end point is the same as its starting point. That is, the arc is a closed loop. means a 2-dimensional region, that is, a surface, , that is the boundary of some 3-dimensional volume. (that's right; a partial derivative symbol!) means the boundary of . So, for example, is the integral over the surface of the volume . This notation arises in the general form of Stokes' theorem. |
Change of Variable; Change of Coordinate System
[edit | edit source]The change-of-variable theorem is an extremely important tool of integral calculus. It is even more important in multivariate calculus, since it is central to the concepts of coordinate systems and coordinate system change operations. It is implicit in nearly all integrals over curves, surfaces, and volumes.
We would like to be able to perform the integrations of the previous section in coordinate systems other than plain Cartesian coordinates. In fact, the use of arbitrary coordinate systems (often called "curvilinear coordinates"), is the central object of this course. For example, the integral to find the area of a circle would be easier to set up if we were using polar coordinates, because a circle is trivial to describe in polar coordinates. To do this, we need to revisit the change-of-variable theorem from elementary calculus, and extend it to higher dimensions.
Basically, the change-of-variable theorem of elementary calculus says that algebraic substitution and manipulations actually work, even when the manipulations involve the "d" symbol. (Remember that things like "dx" are infinitesimals; their actual value would have to be considered to be zero. By a miracle of calculus notation, we can manipulate them anyway.)
Here is a simple example, not (yet) involving integrals. Suppose y is a function of u, and u is a function of x, as follows:
We know that
Can we get from this? The change-of-variable theorem says that we can multiply the derivatives and "cancel" the du:
We can remove u from this, getting the answer in terms of x:
This is the same answer as the chain rule would have given:
It's easy to see why this is true—the multiplication in the chain rule is just the multiplication from which we canceled the dy.
We can do the same thing for integrals, observing why the "dx" symbol in an integral is such an important part of the notation that integrals use. Given:
we introduce a new variable u:
so the integral is
We have
So, taking the usual liberties with the notation:
so the integral is:
Tricks like this are staples of integration technique.
Why do we consider the change-of-variable theorem from elementary calculus to be so important? Because a change of variable is actually a change of coordinate system.
When we were integrating
and we made the substitution
we were actually changing from the coordinate system on our "space" to the new coordinate system .
So, to review what the change-of-variable procedure does, if is one coordinate system and is another, and we want to calculate
where is a function of position in "space" (1-dimensional) and is a description of the region in terms of , we have
The integral on the right is an integral in terms of . The region is defined in terms of in determining the limits of the integration, and is the same function of position, defined in terms of .
Let's try this for an example in two dimensions. Suppose is a unit disk, which happens to be more dense at the edges than in the center, and is the density at a given point. The density is the square of the distance from the center.
To find the mass of the whole disk we need to get
We know the coordinate change functions between Cartesian and polar coordinates:
We rewrite the integral using the change-of-variable theorem:
We need to figure out what
must mean. We will work this out shortly, but here is a sneak peek. It will be called the Jacobian determinant, or just Jacobian, denoted , or just when the context is clear. In this case its value will be (we will explain that soon), so:
Partial Derivatives, the Chain Rule, and the Jacobian Matrix
[edit | edit source]To make sense of the mysterious
we are going to have to extend the concept of derivatives to multiple dimensions. When a function depends on multiple arguments the partial derivative is required. This is the derivative of a function with respect to a particular one of its arguments, while holding all the other arguments fixed.
For example, if is a function of two arguments (for example, it's the temperature measured over a disk or other 2-dimensional object), then it has the two partial derivatives:
When we change coordinate systems, we have N functions of N arguments, where N is the dimension of the space. (N will be 2 or 3 for the cases we handle, but the methods work for any N.)
For example, when converting between 2-dimensional polar coordinates and Cartesian coordinates, we have and , each of which is a function of and , and vice-versa:
In 3-dimensional spherical coordinates, we have , and , each of which is a function of , and , and vice-versa:
It is useful to put the N (2, 3, or whatever) partial derivatives into an NxN matrix, like this:
Or, going in the other direction:
This is the derivative matrix of the transformation from one coordinate system to the other. It is often called the Jacobian matrix, though some authors use the term "Jacobian" specifically to refer to the matrix's determinant. To avoid any confusion on this point, we will always put square brackets around matrices, and use boldface letters to denote determinants.
The notation for the Jacobian matrix from the coordinate system to is:
and the determinant is:
For 2-dimensional polar coordinates, the Jacobian matrices are:
with determinant , and:
with determinant .
For 3-dimensional spherical coordinates, the Jacobian matrices are:
with determinant , and:
with determinant .
The chain rule of elementary calculus tells us that, if two functions are chained together in a sequence, the derivative of the final chained function is the product of the individual derivatives. If is a function of , with derivative , and is a function of , with derivative , the the derivative of as a function of is:
A miracle of calculus notation makes this all look straightforward.
In multiple dimensions, we might have as functions of , which are themselves functions of . This means that are functions of . What are their partial derivatives? What is the Jacobian matrix?
The Chain Rule for Partial Derivatives tells us that:
In terms of the matrices, this means that:
But that's just the formula for matrix multiplication!
So we have
This is the chain rule for multivariable calculus.
It follows from this that, if the second change is just the inverse of the first, bringing us back to the original coordinate system, the two matrices are inverses. And their determinants are reciprocals of each other.
Exercise: Check that for the matrices referred to above, going back and forth between Cartesian and polar/spherical coordinates.
The coordinates should always be chosen such that the Jacobian determinant is positive. If it isn't, exchange the order of two of the coordinates. This ensures that the coordinate system is "right handed". (Or more precisely, that it has the same handedness as the Cartesian system.) As an example, the coordinate order is correct for polar coordinates; is not. The order is correct for spherical coordinates; is not.
The Jacobian determinant must not be zero. (Equivalently, the Jacobian matrix must not be singular.) The astute reader will notice that this means that polar coordinates don't work at the origin, and spherical coordinates don't work at the north and south poles.
The rule we are developing, for integrating over a region in arbitrary coordinates and , is:
where and are Cartesian coordinates.
Using this formula, the area of a circle is now trivial:
Exercise: Use spherical coordinates, with , to get the volume of a sphere. Compare this with the complexity of the integral to find the volume in Cartesian coordinates.
Why Do We Put the J Determinant Into an Integral?
[edit | edit source]We need to show that the formula, from the previous section, for an integral in arbitrary coordinates, is correct:
When we calculate a surface integral in 2 dimensions with Cartesian coordinates, we are breaking the surface into tiny rectangles delineated by tiny changes in the coordinate values and . Those tiny changes can be denoted and . The area is is the product . That area is multiplied by the integrand function (evaluated somewhere in the rectangle), and the results are added. As the sizes of the rectangles becomes infinitesimal, the error arising from imprecision in evaluating goes to zero, in accordance with the theory of Riemann integration, and we get the true integral:
We can use a different Cartesian coordinate system (shifted or rotated), still using the same formula:
but the function must be expressed in terms of the new coordinates, and the meaning of in terms of the limits of integration on and will be different. The areas of the tiny rectangles will still be .
How about non-Cartesian coordinate systems such as polar cordinates? Since the coordinate lines are not straight, we don't really have rectangles, but, in the limit as the surface elements get smaller, the tiny areas delineated by the lines of constant and become arbitrarily close to being rectangular. Also, we know that the "height" of each almost-rectangle is , and its "width" is . Hence the area is , and an integral in polar coordinates is therefore:
We already calculated that , the Jacobian determinant for the transformation is , so the integral is:
We will work out the general case next, for a transformation between any coordinate system and Cartesian coordinates. Many treatments of this require the use of orthogonal coordinates, that is, coordinate systems in which the coordinate lines always cross at right angles. Essentially all of the coordinate systems that people use in practice (polar, cylindrical, spherical, etc.) satisfy this condition. However we will derive the theorems for any (nonsingular) coordinate system.
Transforming Between Arbitrary Coordinates and Cartesian Coordinates in Two Dimensions
[edit | edit source]When we use an arbitrary coordinate system , the tiny patches delineated by the lines of constant and aren't necessarily rectangular, because the lines don't intersect at right angles. The tiny patches are parallelograms. The lines of constant and , while not orthogonal, still approach straightness as the patch gets smaller.
In the example shown, the blue patch has and .
Now label 3 of the points: A, B, and C.
When we move from point A to point B, does not change, but increases by .001, that is, . Since and , the true Cartesian coordinates of these points, depend on and , we can calculate their change, using the partial derivatives. and tell us how much and change for this tiny change in while holding constant, so
Similarly, as we move from A to C, we get:
(The reason for the minus sign is that was decreasing while was increasing.)
The third diagram shows the overall rectangle, with area
which is
But the yellow part has area
and the pink part has area
so the actual inner parallelogram has area
This establishes that the Jacobian determinant, from a 2-dimensional Cartesian system to an arbitrary coordinate system, is the correct multiplier to use when integrating.
Transforming Between Arbitrary Coordinates in Two Dimensions
[edit | edit source]But we can do better—we can handle transformations among any (2-dimensional) coordinate systems. Suppose that the coordinates that we have been calling and , and have been assuming are Cartesian, are not Cartesian. The argument above still holds, with some minor modifications. We aren't allowed to say that is the true area of the patch, and we aren't allowed to assume that the coordinate lines are perpendicular.
First, we are going to change the names and to and , because we don't like to use names , , (or ) for any coordinate system that isn't Cartesian.
Now suppose that the area of a patch, in coordinates, is given by . is the correction factor for the coordinate system. (From what we proved above, we know that it is just the Jacobian . can vary from one point to another, just as Jacobians can.)
The picture now looks like the diagram at the right. The outer parallelogram is delineated by the lines in the coordinate system, with a dimension of
and an dimension of
Its area is
Now the two pink triangles can be combined into a parallelogram with a dimension of
and an dimension of
So their combined area is
Similarly, the area of the combined yellow triangles is
So the area of the inner parallelogram (the one delineated by the lines in the coordinate system) is
This means that, if an integral can be expressed in coordinates as
we can calculate it in coordinates as
We can move into the integrand function that we call : , and treat that as the new integrand.
So we get the general formula for change of arbitrary coordinates in (2-dimensional) integration—multiply by the Jacobian determinant:
We need to have it work in the other direction too, of course:
This requires that
but we have already established that the matrices are inverse, so their determinants are reciprocals.
This means that (in 2 dimensions) we can change coordinate systems at will, introducing a Jacobian determinant whenever we do so.
Transforming Between Arbitrary Coordinates in Any Number of Dimensions
[edit | edit source]Finally, we generalize this to 3 (or more) dimensions. We use a geometrical trick equivalent to the one that elementary geometry students use for deriving the area of a parallelogram—part of the parallelogram is removed from one side and reattached to the other, as shown at the right.
- (We could have used the same trick in 2 dimensions; instead we used a method that makes it easier to see the connection between the geometry and the calculation of the determinant.)
We will first consider a change of coordinates in which only one coordinate is different. That is, we have a coordinate system , in which the volume of a tiny chunk of space delineated by the coordinate lines is .
Let be another coordinate system, but with a very simple transformation—only the third coordinate is allowed to be different.
The Jacobian matrix is
The Jacobian determinant is
Now suppose we have a tiny chunk of space delineated by the lines in the coordinate system, with sides , , and . The diagram at the right shows that chunk, relative to the system.
Since the first two coordinates are the same, the chunk fits properly into the coordinate system, but is pushed upward in the coordinate.
We chop off a "level" (relative to the coordinates) piece from the top of the chunk, and insert it at the bottom. The volume is unchanged. It is
This means that an integral that would have been
in one coordinate system is
in the other.
As before, we move into the integrand: , so we have:
So we have shown that the transformation formula works in 3 dimensions (actually, any number of dimensions, but the "parallelogram trick" can't be visualized) as long as the coordinate transformation involves only one coordinate. But we can make coordinate changes repeatedly, so we can change the coordinates one at a time until we get the desired coordinate system.
- Actually, there is a slight problem that we need to point out. We don't have complete freedom to choose the order of the coordinates. We could not change the system to one coordinate at a time, because the intermediate stage would be or , both of which are singular. But we can always change a given coordinate in one system into some coordinate in the other system.
To summarize the integral transformation rule:
|
In 1 dimension this is just the change-of-variable theorem from elementary calculus.
Example: Volume of a Solid Torus
[edit | edit source]Mathematicians usually use the word "torus" to mean the 2-dimensional surface—it has interesting topological and geometrical properties. But for now, we are interested in the 3-dimensional solid torus. What is its volume?
Let be the main radius, and be the cross-sectional radius. (We consider only the case .) A naive approximation would give the volume as the cross-sectional area times the main circumference, or . But is that exactly right? The volume contribution is greater in the "outside" part, and smaller in the "inside" part.
We can solve the problem by creating "toroidal coordinates"[2] in 3-dimensional space, . is the angle around the main center, is the angle around the cross-sectional circle, and is the distance from the cross-sectional center.
- This coordinate system is not acceptable for all of space—there are points (outside of the torus) that have two different sets of coordinates. But it works inside the torus.
In these coordinates, the solid torus is just the set of points with . (We will look at the surface of the torus in a later lecture. It is the restriction .)
The transformation to Cartesian coordinates is:
The Jacobian matrix is:
The determinant is:
So the volume of the torus is:
Exercise: Calculate the volumes of the inside part () and the outside part () separately.
Exercise: The angular momentum of a rigid body rotating around some axis is the rotation speed times the integral, over the volume, of the density times the distance from the axis of rotation. What is the angular momentum of a torus of uniform density rotating around its main axis?
Exercise: The moment of rotational inertia is the integral of the density times the square of the distance from the axis of rotation. What is the moment of rotational inertia of a torus of uniform density?
Example: Confocal Coordinates
[edit | edit source]This example illustrates the wide applicability of coordinate systems. This coordinate system is not commonly used. The coordinates are and . is a fixed parameter giving the position of the foci. Lines of constant are ellipses, and lines of constant are hyperbolas.
The transformation to Cartesian coordinates is:
The Jacobian matrix is:
The determinant is:
Suppose we want to find the area of the ellipse formed by holding .
The semi-major axis is , and the semi-minor axis is .
The area is:
External Integration Software
[edit | edit source]Footnotes and References
[edit | edit source]- ↑ The restriction is that a vertical lines must enter and leave the region just once. But more complicated regions can be broken up into smaller ones, so that any reasonable region may in fact be integrated. Furthermore, changing the coordinate system can often help.
- ↑ This coordinate system is not standard; you won't find it in the literature. We are just making it up. We can make up any coordinate system we want.