Part 1 can be found here.

In Part 1 of this series, we took an extremely high-level, birds-eye view of calculus of a single variable. We did not do any calculations or prove any theorems; if you would like to learn how to do this, there are many excellent Calc 1 courses available for free online, including MIT’s Single Variable Calculus course. Instead, we attempted to develop an intuitive understanding of the notions of a derivative and integral of functions of a single variable.

Today, we’re gonna breeze right on through Calcs 2 and 3. We’ll extend our new tools, differentiation and integration, from functions of a single variable, to functions of 2 and 3 variables, and then on to vector calculus. Our goal today is to reach Stokes’ and the Divergence theorems, which we will then use in Part 3 to transform the differential formulations of Maxwell’s Equations into their integral counterparts.

That’s a lot of big words – let’s define what some of them mean.


The double integral just extends the integral to two variables. That is, if the single integral is the area between the curve and x-axis, a 2D shape, a double integral is the volume between a surface and the xy-plane, a 3D shape. Alternately, if I have a function f(x,y) of two variables, then the double integral as shown below is the sum of all values of f(x,y) in the region where a<=x<=b and c<=y<=d.

The triple integral extends the integral to three variables. Unfortunately, the region between a graph of 3 variables and the xyz-plane is a 4D shape, so visualizing it gets tricky. Instead, consider it the sum of all values of f(x,y,z) in the region where a<=x<=b, c<=y<=d, e<=z<=f. For instance, integrating a density function g(x,y,z) as in the equation below would yield the total mass of the object bounded by a-f:

(This and previous screenshot taken from https://www.youtube.com/watch?v=UubU3U2C8WM)

Of course, nothing stops us from extending this concept further into quadruple and nth-integrals. Nothing – except the fact that we are working here in three-dimensional space, and so triple integrals will be quite sufficient for our purposes.


So far, all the calculus that we have been doing has been over a scalar field, the real numbers. It is also possible to do calculus over vector fields, which is to say that we will consider functions that operate not on the real numbers, but on vectors.

Vectors are quantities that have both magnitude and direction. For instance, the speed of an object might be 1 meter per second, while its velocity is 1 meter per second straight off the ground, or <0,0,1> in a standard xyz coordinate system.

Like real numbers or scalars, vectors can be added together, and multiplied by real numbers. There are two ways to ‘multiply’ vectors. There is the dot product, a.b = ax*bx + ay*by + az*bz, which produces a scalar. And there is the cross product, which produces a vector with magnitude a x b = |a||b|sin(theta) and direction perpendicular to vectors a and b by the right hand rule (take your right hand, stick your thumb straight up, and with your fingers, sweep vector a into vector b. Your thumb points in the direction of the cross product). You’ll see other formulations of the cross product below that seem to have no connection to what I just described – this is because of linear algebra weirdness that I don’t have time to get into here, but just know it’s all about symmetry and rotation in 3 dimensional space.

To understand the difference between scalar and vector fields, consider the air in a given space. At any given point in the space, we can measure both a temperature and a wind velocity. We can define a temperature field as a function in a region of 3D space which, for any given point, would output the temperature at that point. As temperature has magnitude but not direction, it is a scalar, and a temperature field is a scalar field. By contrast, wind velocity is a vector, and so a similarly-defined wind velocity field is a vector field.

In electronics, there are 2 main vector fields that we are concerned with – the electric field, and the magnetic field. These can both be considered components of a broader electromagnetic field, but for our purposes it is most convenient to treat them separately. The electric field assigns to each point in 3D space a vector representing the electric force exerted on charged particles at that point, while the magnetic field does the same with the magnetic force.

The electric field is conservative, or path-independent. That is, if you move a particle between two points in the field, the same work will be expended regardless of which path you choose between the two points. The magnetic field is only conservative under certain conditions.


Let’s introduce a new symbol, , pronounced ‘del’. You can kind of think of as the ‘derivative vector’ <∂/∂x, ∂/∂y, ∂/∂z>. The ∂, usually pronounced ‘du’, indicates that these are partial derivatives, which just means that a multivariable function is being differentiated against just one of its variables. We’re going to use it to do three new things to a vector field F=<P(x,y,z), Q(x,y,z), R(x,y,z)> –

F, read “del dot F”, is the divergence of the field. It is also written divF. It has value ∂P/∂x+∂Q/∂y+∂R/∂z, which is a scalar and corresponds to the dot product of the ‘derivative vector’ and F. As the below visualization of 2 dimensional divergence shows, it can be considered as a quantification of the tendency of vectors to travel away from the point – 

https://en.wikipedia.org/wiki/Divergence

× F, read “del cross F”, is the curl of the field. It is also written curlF. It has value <∂R/∂y-∂Q/∂z), (∂P/∂x-∂R/∂z), (∂Q/∂x-∂P/∂y)>, which is a vector and corresponds to the cross product of the ‘derivative vector’ and F. It is the tendency of vectors in the field to rotate around a given point in the field, as shown in the 2D visual below – 

https://calcworkshop.com/vector-calculus/curl-and-divergence

∇F, read “gradF”, is the gradient vector field of the field. It has value <∂F/∂x, ∂F/∂y, ∂F/∂z>, which is itself a vector field. We won’t use it here, but know that it is essential for simplifying calculations when working with conservative vector fields such as the gravitational field or the electric fields.

https://www.smbc-comics.com/?id=3225


Consider a charged particle moving through an electric field, as shown in the diagram below. 

http://hyperphysics.phy-astr.gsu.edu/hbase/intare.html

We wish to calculate the total electric force that is exerted on the particle as it moves through the field on curve C between points A and B. We break the curve into pieces of infinitesimal length, labeled ds above but I’ve also seen dr and dl used. We then calculate the dot product of the two vectors. This is because the force is strongest when it has the same direction as the velocity of the particle. When the two are not perfectly aligned, the force on the product is given by the dot product, which also can be computed as a.b=|a||b|cos(theta), where |a| and |b| are the magnitudes of a and b, and theta is the angle between them. By summing these infinitesimal dot products together, we obtain the total force exerted on the particle as it moves through the field. This integral is called a line integral, and for a curve C that can be expressed as a vector function r(t), a<=t<=b, its value is as follows – 

As r(t)=<x(t), y(t), z(t)>, the contents of the right side integral can also be written as

 F(<x(t), y(t), z(t)>).<x’(t), y’(t), z’(t)>dt.


Imagine a charged particle inside a bubble. This is a magic bubble – with your mind, you can instantly shape it into whatever you a want, a cube, a d20, Danny Devito, so long as the bubble remains completely sealed. This magic bubble of ours is called a Gaussian surface, or simply a closed 3D surface. Now, consider the electric field lines that emanate from the particle. Where these field lines pass through the surface, they become electric flux, as shown in the diagram below.

https://www.toppr.com/guides/physics/electric-charges-and-fields/electric-flux

Flux is a quantification of the extent to which a field is ‘passing through’ a given surface. Note that as in the diagram, that surface need not be closed, though closed or Gaussian surfaces will be useful for us later. Both types of surfaces may be used to compute surface integrals, as defined below – 

Intimidated by that equation? Don’t worry – you don’t need to understand it. Feel free to tell people you do, though.

(equation and image from https://en.wikipedia.org/wiki/Surface_integral)

Geometrically, the surface integral can be interpreted as the sum of all electric flux through a given surface. 


Stokes’ Theorem, shown below, states that, for a vector field F and a surface S that has boundary curve C, the line integral of the field along the curve is equal to the surface integral of that field’s curl.

Here, dr is considered to point in the direction of the 1D infinitesimal of the curve, while dS is considered to point straight out from the 2D infinitesimal of the surface.

Stokes’ Theorem has very important implications for both computation and theorems, but for our purposes, it is one of two equations that we will use in Part 3 to move between the differential and integral formulations of Maxwell’s Equations. The other is the Divergence Theorem, given below –

Here, the n with a hat denotes the normal vector to the infinitesimal surface dS (note that dS is not bold as in the description of Stokes’ Theorem, indicating that it represents a scalar rather than a vector). The normal vector has direction perpendicular to the surface. Also, the loop on the right double integral indicates that the surface in question is closed, as in the diagram below. You will also sometimes see a loop on the line integral in Stokes’ Theorem to indicate the same of the boundary curve C.

Equations and image from https://en.wikipedia.org/wiki/Divergence_theorem

Thus, the Divergence Theorem states that the triple integral of the divergence of the field within a region is equal to the integral of the field through the boundary surface of that region. This makes intuitive sense – if divergence is a quantification of the tendency of vectors in a field to radiate out from a certain point, then the total sum of the divergence for all points within an area is equal to the net outflow of vectors through the boundary of that area.


So far, I have written almost 3000 words, and I have yet to introduce a single one of Maxwell’s Equations. Let’s change that…in Part 3. See you soon!


Leave a Reply

Your email address will not be published. Required fields are marked *